From fe245dc1cf2cf805927bdadffedb5265416b1513 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Tue, 17 Feb 2026 17:26:19 +0100 Subject: [PATCH 001/135] updated go mod + dependencies --- apis/config/deviation_clear_types.go | 99 ++++ go.mod | 170 +++---- go.sum | 425 +++++++++--------- pkg/reconcilers/resource/fake.go | 67 ++- pkg/registry/configblame/strategy_resource.go | 2 +- pkg/registry/generic/strategy_resource.go | 2 +- pkg/registry/generic/strategy_status.go | 2 +- .../runningconfig/strategy_resource.go | 2 +- pkg/registry/store/store.go | 12 +- 9 files changed, 470 insertions(+), 311 deletions(-) create mode 100644 apis/config/deviation_clear_types.go diff --git a/apis/config/deviation_clear_types.go b/apis/config/deviation_clear_types.go new file mode 100644 index 00000000..61636f4f --- /dev/null +++ b/apis/config/deviation_clear_types.go @@ -0,0 +1,99 @@ +/* +Copyright 2026 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package config + +import ( + "reflect" + + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "github.com/sdcio/config-server/apis/condition" +) + +type DeviationClearType string + +const ( + DeviationClearType_TARGET DeviationClearType = "target" + DeviationClearType_CONFIG DeviationClearType = "config" + DeviationClearType_ALL_CONFIG DeviationClearType = "allConfig" + DeviationClearType_ALL DeviationClearType = "all" +) + +func (r DeviationClearType) String() string { + switch r { + case DeviationClearType_TARGET: + return "target" + case DeviationClearType_CONFIG: + return "config" + case DeviationClearType_ALL_CONFIG: + return "allConfig" + case DeviationClearType_ALL: + return "all" + default: + return "unknown" + } +} + +// DeviationSpec defines the desired state of Deviation +type DeviationClearSpec struct { + Items []DeviationClearItem `json:"items" protobuf:"bytes,1,rep,name=items"` +} + +type DeviationClearItem struct { + Type DeviationClearType `json:"type" protobuf:"bytes,1,opt,name=type"` + // Name of the config - mandatory if the type is config - not applicable for the other types + ConfigName *string `json:"configName,omitempty" protobuf:"bytes,2,opt,name=configName"` + // Paths of the respective type that should be cleared + Paths []string `json:"paths" protobuf:"bytes,3,rep,name=paths"` +} + +// DeviationStatus defines the observed state of Deviationgit +type DeviationClearStatus struct { + // ConditionedStatus provides the status of the Readiness using conditions + // if the condition is true the other attributes in the status are meaningful + condition.ConditionedStatus `json:",inline" protobuf:"bytes,1,opt,name=conditionedStatus"` +} + +// +genclient +// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object +// +kubebuilder:object:root=true +// +kubebuilder:storageversion +// +kubebuilder:subresource:status +// +kubebuilder:resource:categories={sdc} + +// DeviationClear is the Schema for the DeviationClear API +type DeviationClear struct { + metav1.TypeMeta `json:",inline"` + metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + + Spec DeviationClearSpec `json:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"` + Status DeviationClearStatus `json:"status,omitempty" protobuf:"bytes,3,opt,name=status"` +} + +// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object +// +kubebuilder:object:root=true + +// DeviationClearList contains a list of DeviationClears +type DeviationClearList struct { + metav1.TypeMeta `json:",inline"` + metav1.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + Items []Deviation `json:"items" protobuf:"bytes,2,rep,name=items"` +} + +// DeviationClearKind type metadata. +var ( + DeviationClearKind = reflect.TypeOf(DeviationClear{}).Name() +) diff --git a/go.mod b/go.mod index ceb1d557..fc98a215 100644 --- a/go.mod +++ b/go.mod @@ -1,72 +1,68 @@ module github.com/sdcio/config-server -go 1.24.0 - -toolchain go1.24.3 - -//replace sigs.k8s.io/structured-merge-diff/v4 => sigs.k8s.io/structured-merge-diff/v4 v4.4.1 +go 1.25.0 require ( - github.com/dgraph-io/badger/v4 v4.8.0 - github.com/go-git/go-git/v5 v5.12.0 + github.com/dgraph-io/badger/v4 v4.9.1 + github.com/go-git/go-git/v5 v5.16.5 github.com/gogo/protobuf v1.3.2 github.com/google/go-cmp v0.7.0 github.com/google/uuid v1.6.0 - github.com/henderiw/apiserver-builder v0.0.4 - github.com/henderiw/apiserver-store v0.0.2 + github.com/henderiw/apiserver-builder v0.0.5-0.20260217153329-7417ac911bd8 + github.com/henderiw/apiserver-store v0.0.3-0.20260217161537-573fa9ffabd2 github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c github.com/henderiw/logger v0.0.0-20230911123436-8655829b1abe github.com/henderiw/store v0.0.2-0.20241030044529-f6baff74eab3 github.com/openconfig/gnmi v0.14.1 github.com/openconfig/gnmic/pkg/api v0.1.9 github.com/openconfig/gnmic/pkg/cache v0.1.3 - github.com/otiai10/copy v1.14.0 + github.com/otiai10/copy v1.14.1 github.com/pkg/errors v0.9.1 - github.com/prometheus/client_golang v1.23.0 + github.com/prometheus/client_golang v1.23.2 github.com/prometheus/client_model v0.6.2 - github.com/prometheus/prometheus v0.300.1 + github.com/prometheus/prometheus v0.309.1 github.com/sdcio/sdc-protos v0.0.50 - github.com/spf13/cobra v1.9.1 + github.com/spf13/cobra v1.10.2 github.com/stretchr/testify v1.11.1 - go.opentelemetry.io/otel v1.38.0 + go.opentelemetry.io/otel v1.39.0 go.starlark.net v0.0.0-20250205221240-492d3672b3f4 - go.uber.org/zap v1.27.0 - golang.org/x/mod v0.29.0 - golang.org/x/sync v0.18.0 - google.golang.org/grpc v1.78.0 + go.uber.org/zap v1.27.1 + golang.org/x/mod v0.30.0 + golang.org/x/sync v0.19.0 + google.golang.org/grpc v1.79.1 google.golang.org/protobuf v1.36.11 - k8s.io/api v0.33.2 - k8s.io/apimachinery v0.33.2 - k8s.io/apiserver v0.33.0 - k8s.io/client-go v0.33.1 - k8s.io/code-generator v0.33.1 - k8s.io/component-base v0.33.1 - k8s.io/kube-openapi v0.0.0-20250318190949-c8a335a9a2ff - k8s.io/utils v0.0.0-20250321185631-1f6e0b77f77e - sigs.k8s.io/controller-runtime v0.20.4 - sigs.k8s.io/structured-merge-diff/v4 v4.7.0 - sigs.k8s.io/yaml v1.4.0 + k8s.io/api v0.35.1 + k8s.io/apimachinery v0.35.1 + k8s.io/apiserver v0.35.1 + k8s.io/client-go v0.35.1 + k8s.io/code-generator v0.35.1 + k8s.io/component-base v0.35.1 + k8s.io/kube-openapi v0.0.0-20250910181357-589584f1c912 + k8s.io/utils v0.0.0-20251002143259-bc988d571ff4 + sigs.k8s.io/controller-runtime v0.23.1 + sigs.k8s.io/structured-merge-diff/v6 v6.3.2 + sigs.k8s.io/yaml v1.6.0 ) require ( bitbucket.org/creachadair/stringset v0.0.14 // indirect - cel.dev/expr v0.24.0 // indirect + cel.dev/expr v0.25.1 // indirect cloud.google.com/go/compute/metadata v0.9.0 // indirect dario.cat/mergo v1.0.0 // indirect github.com/AlekSi/pointer v1.2.0 // indirect github.com/Microsoft/go-winio v0.6.2 // indirect github.com/NYTimes/gziphandler v1.1.1 // indirect - github.com/ProtonMail/go-crypto v1.0.0 // indirect + github.com/ProtonMail/go-crypto v1.1.6 // indirect github.com/antlr4-go/antlr/v4 v4.13.1 // indirect github.com/beorn7/perks v1.0.1 // indirect github.com/blang/semver/v4 v4.0.0 // indirect github.com/bufbuild/protocompile v0.14.1 // indirect - github.com/cenkalti/backoff/v4 v4.3.0 // indirect + github.com/cenkalti/backoff/v5 v5.0.3 // indirect github.com/cespare/xxhash/v2 v2.3.0 // indirect - github.com/cloudflare/circl v1.3.7 // indirect + github.com/cloudflare/circl v1.6.1 // indirect github.com/coreos/go-semver v0.3.1 // indirect - github.com/coreos/go-systemd/v22 v22.5.0 // indirect - github.com/cyphar/filepath-securejoin v0.2.4 // indirect + github.com/coreos/go-systemd/v22 v22.6.0 // indirect + github.com/cyphar/filepath-securejoin v0.4.1 // indirect github.com/davecgh/go-spew v1.1.2-0.20180830191138-d8f796af33cc // indirect github.com/dgraph-io/ristretto/v2 v2.2.0 // indirect github.com/dgryski/go-rendezvous v0.0.0-20200823014737-9f7001d12a5f // indirect @@ -77,96 +73,104 @@ require ( github.com/evanphx/json-patch/v5 v5.9.11 // indirect github.com/felixge/httpsnoop v1.0.4 // indirect github.com/fsnotify/fsnotify v1.9.0 // indirect - github.com/fxamacker/cbor/v2 v2.8.0 // indirect + github.com/fxamacker/cbor/v2 v2.9.0 // indirect github.com/go-git/gcfg v1.5.1-0.20230307220236-3a3c6141e376 // indirect - github.com/go-git/go-billy/v5 v5.5.0 // indirect + github.com/go-git/go-billy/v5 v5.6.2 // indirect github.com/go-logr/logr v1.4.3 // indirect github.com/go-logr/stdr v1.2.2 // indirect github.com/go-logr/zapr v1.3.0 // indirect - github.com/go-openapi/jsonpointer v0.21.1 // indirect - github.com/go-openapi/jsonreference v0.21.0 // indirect - github.com/go-openapi/swag v0.23.1 // indirect + github.com/go-openapi/jsonpointer v0.22.1 // indirect + github.com/go-openapi/jsonreference v0.21.3 // indirect + github.com/go-openapi/swag v0.25.4 // indirect + github.com/go-openapi/swag/cmdutils v0.25.4 // indirect + github.com/go-openapi/swag/conv v0.25.4 // indirect + github.com/go-openapi/swag/fileutils v0.25.4 // indirect + github.com/go-openapi/swag/jsonname v0.25.4 // indirect + github.com/go-openapi/swag/jsonutils v0.25.4 // indirect + github.com/go-openapi/swag/loading v0.25.4 // indirect + github.com/go-openapi/swag/mangling v0.25.4 // indirect + github.com/go-openapi/swag/netutils v0.25.4 // indirect + github.com/go-openapi/swag/stringutils v0.25.4 // indirect + github.com/go-openapi/swag/typeutils v0.25.4 // indirect + github.com/go-openapi/swag/yamlutils v0.25.4 // indirect github.com/go-redis/redis/v8 v8.11.5 // indirect github.com/golang/glog v1.2.5 // indirect - github.com/golang/groupcache v0.0.0-20210331224755-41bb18bfe9da // indirect + github.com/golang/groupcache v0.0.0-20241129210726-2c02b8208cf8 // indirect github.com/golang/protobuf v1.5.4 // indirect github.com/google/btree v1.1.3 // indirect - github.com/google/cel-go v0.25.0 // indirect + github.com/google/cel-go v0.26.0 // indirect github.com/google/flatbuffers v25.2.10+incompatible // indirect - github.com/google/gnostic-models v0.6.9 // indirect - github.com/grafana/regexp v0.0.0-20240518133315-a468a5bfb3bc // indirect + github.com/google/gnostic-models v0.7.0 // indirect + github.com/grafana/regexp v0.0.0-20250905093917-f7b3be9d1853 // indirect github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0 // indirect - github.com/grpc-ecosystem/grpc-gateway/v2 v2.26.3 // indirect + github.com/grpc-ecosystem/grpc-gateway/v2 v2.27.3 // indirect github.com/inconshreveable/mousetrap v1.1.0 // indirect github.com/jbenet/go-context v0.0.0-20150711004518-d14ea06fba99 // indirect github.com/jhump/protoreflect v1.17.0 // indirect - github.com/josharian/intern v1.0.0 // indirect github.com/json-iterator/go v1.1.12 // indirect github.com/kevinburke/ssh_config v1.2.0 // indirect - github.com/klauspost/compress v1.18.0 // indirect + github.com/klauspost/compress v1.18.2 // indirect github.com/kylelemons/godebug v1.1.0 // indirect - github.com/mailru/easyjson v0.9.0 // indirect github.com/minio/highwayhash v1.0.2 // indirect github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd // indirect - github.com/modern-go/reflect2 v1.0.2 // indirect + github.com/modern-go/reflect2 v1.0.3-0.20250322232337-35a7c28c31ee // indirect github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822 // indirect github.com/nats-io/jwt/v2 v2.5.2 // indirect github.com/nats-io/nats-server/v2 v2.10.4 // indirect github.com/nats-io/nats.go v1.32.0 // indirect github.com/nats-io/nkeys v0.4.7 // indirect github.com/nats-io/nuid v1.0.1 // indirect - github.com/onsi/ginkgo/v2 v2.22.2 // indirect - github.com/onsi/gomega v1.36.2 // indirect github.com/openconfig/grpctunnel v0.1.0 // indirect - github.com/pjbgf/sha1cd v0.3.0 // indirect + github.com/otiai10/mint v1.6.3 // indirect + github.com/pjbgf/sha1cd v0.3.2 // indirect github.com/pmezard/go-difflib v1.0.1-0.20181226105442-5d4384ee4fb2 // indirect - github.com/prometheus/common v0.65.0 // indirect + github.com/prometheus/common v0.67.4 // indirect github.com/prometheus/procfs v0.16.1 // indirect github.com/sdcio/logger v0.0.3 // indirect github.com/sergi/go-diff v1.3.2-0.20230802210424-5b0b94c5c0d3 // indirect - github.com/skeema/knownhosts v1.2.2 // indirect - github.com/spf13/pflag v1.0.6 // indirect + github.com/skeema/knownhosts v1.3.1 // indirect + github.com/spf13/pflag v1.0.9 // indirect github.com/stoewer/go-strcase v1.3.0 // indirect github.com/x448/float16 v0.8.4 // indirect github.com/xanzy/ssh-agent v0.3.3 // indirect - go.etcd.io/etcd/api/v3 v3.5.21 // indirect - go.etcd.io/etcd/client/pkg/v3 v3.5.21 // indirect - go.etcd.io/etcd/client/v3 v3.5.21 // indirect + go.etcd.io/etcd/api/v3 v3.6.5 // indirect + go.etcd.io/etcd/client/pkg/v3 v3.6.5 // indirect + go.etcd.io/etcd/client/v3 v3.6.5 // indirect go.opentelemetry.io/auto/sdk v1.2.1 // indirect go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.60.0 // indirect - go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.60.0 // indirect - go.opentelemetry.io/otel/exporters/otlp/otlptrace v1.35.0 // indirect - go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc v1.35.0 // indirect - go.opentelemetry.io/otel/metric v1.38.0 // indirect - go.opentelemetry.io/otel/sdk v1.38.0 // indirect - go.opentelemetry.io/otel/trace v1.38.0 // indirect - go.opentelemetry.io/proto/otlp v1.5.0 // indirect + go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.64.0 // indirect + go.opentelemetry.io/otel/exporters/otlp/otlptrace v1.39.0 // indirect + go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc v1.39.0 // indirect + go.opentelemetry.io/otel/metric v1.39.0 // indirect + go.opentelemetry.io/otel/sdk v1.39.0 // indirect + go.opentelemetry.io/otel/trace v1.39.0 // indirect + go.opentelemetry.io/proto/otlp v1.9.0 // indirect go.uber.org/multierr v1.11.0 // indirect + go.yaml.in/yaml/v2 v2.4.3 // indirect + go.yaml.in/yaml/v3 v3.0.4 // indirect go4.org/netipx v0.0.0-20231129151722-fdeea329fbba // indirect - golang.org/x/crypto v0.44.0 // indirect - golang.org/x/exp v0.0.0-20250408133849-7e4ce0ab07d0 // indirect - golang.org/x/net v0.47.0 // indirect - golang.org/x/oauth2 v0.32.0 // indirect - golang.org/x/sys v0.38.0 // indirect - golang.org/x/term v0.37.0 // indirect - golang.org/x/text v0.31.0 // indirect - golang.org/x/time v0.11.0 // indirect - golang.org/x/tools v0.38.0 // indirect - golang.org/x/tools/go/packages/packagestest v0.1.1-deprecated // indirect + golang.org/x/crypto v0.46.0 // indirect + golang.org/x/exp v0.0.0-20250808145144-a408d31f581a // indirect + golang.org/x/net v0.48.0 // indirect + golang.org/x/oauth2 v0.34.0 // indirect + golang.org/x/sys v0.39.0 // indirect + golang.org/x/term v0.38.0 // indirect + golang.org/x/text v0.32.0 // indirect + golang.org/x/time v0.14.0 // indirect + golang.org/x/tools v0.39.0 // indirect gomodules.xyz/jsonpatch/v2 v2.4.0 // indirect - google.golang.org/genproto v0.0.0-20241118233622-e639e219e697 // indirect - google.golang.org/genproto/googleapis/api v0.0.0-20251029180050-ab9386a59fda // indirect - google.golang.org/genproto/googleapis/rpc v0.0.0-20251029180050-ab9386a59fda // indirect - gopkg.in/evanphx/json-patch.v4 v4.12.0 // indirect + google.golang.org/genproto/googleapis/api v0.0.0-20251213004720-97cd9d5aeac2 // indirect + google.golang.org/genproto/googleapis/rpc v0.0.0-20251202230838-ff82c1b0f217 // indirect + gopkg.in/evanphx/json-patch.v4 v4.13.0 // indirect gopkg.in/inf.v0 v0.9.1 // indirect gopkg.in/natefinch/lumberjack.v2 v2.2.1 // indirect gopkg.in/warnings.v0 v0.1.2 // indirect gopkg.in/yaml.v3 v3.0.1 // indirect - k8s.io/apiextensions-apiserver v0.32.1 // indirect - k8s.io/gengo/v2 v2.0.0-20250207200755-1244d31929d7 // indirect + k8s.io/apiextensions-apiserver v0.35.0 // indirect + k8s.io/gengo/v2 v2.0.0-20250922181213-ec3ebc5fd46b // indirect k8s.io/klog/v2 v2.130.1 // indirect - k8s.io/kms v0.33.0 // indirect + k8s.io/kms v0.35.1 // indirect sigs.k8s.io/apiserver-network-proxy/konnectivity-client v0.32.0 // indirect - sigs.k8s.io/json v0.0.0-20241014173422-cfa47c3a1cc8 // indirect + sigs.k8s.io/json v0.0.0-20250730193827-2d320260d730 // indirect sigs.k8s.io/randfill v1.0.0 // indirect ) diff --git a/go.sum b/go.sum index 3e551730..68b6d3c2 100644 --- a/go.sum +++ b/go.sum @@ -1,20 +1,22 @@ bitbucket.org/creachadair/stringset v0.0.14 h1:t1ejQyf8utS4GZV/4fM+1gvYucggZkfhb+tMobDxYOE= bitbucket.org/creachadair/stringset v0.0.14/go.mod h1:Ej8fsr6rQvmeMDf6CCWMWGb14H9mz8kmDgPPTdiVT0w= -cel.dev/expr v0.24.0 h1:56OvJKSH3hDGL0ml5uSxZmz3/3Pq4tJ+fb1unVLAFcY= -cel.dev/expr v0.24.0/go.mod h1:hLPLo1W4QUmuYdA72RBX06QTs6MXw941piREPl3Yfiw= +cel.dev/expr v0.25.1 h1:1KrZg61W6TWSxuNZ37Xy49ps13NUovb66QLprthtwi4= +cel.dev/expr v0.25.1/go.mod h1:hrXvqGP6G6gyx8UAHSHJ5RGk//1Oj5nXQ2NI02Nrsg4= cloud.google.com/go/compute/metadata v0.9.0 h1:pDUj4QMoPejqq20dK0Pg2N4yG9zIkYGdBtwLoEkH9Zs= cloud.google.com/go/compute/metadata v0.9.0/go.mod h1:E0bWwX5wTnLPedCKqk3pJmVgCBSM6qQI1yTBdEb3C10= dario.cat/mergo v1.0.0 h1:AGCNq9Evsj31mOgNPcLyXc+4PNABt905YmuqPYYpBWk= dario.cat/mergo v1.0.0/go.mod h1:uNxQE+84aUszobStD9th8a29P2fMDhsBdgRYvZOxGmk= github.com/AlekSi/pointer v1.2.0 h1:glcy/gc4h8HnG2Z3ZECSzZ1IX1x2JxRVuDzaJwQE0+w= github.com/AlekSi/pointer v1.2.0/go.mod h1:gZGfd3dpW4vEc/UlyfKKi1roIqcCgwOIvb0tSNSBle0= +github.com/Masterminds/semver/v3 v3.4.0 h1:Zog+i5UMtVoCU8oKka5P7i9q9HgrJeGzI9SA1Xbatp0= +github.com/Masterminds/semver/v3 v3.4.0/go.mod h1:4V+yj/TJE1HU9XfppCwVMZq3I84lprf4nC11bSS5beM= github.com/Microsoft/go-winio v0.5.2/go.mod h1:WpS1mjBmmwHBEWmogvA2mj8546UReBk4v8QkMxJ6pZY= github.com/Microsoft/go-winio v0.6.2 h1:F2VQgta7ecxGYO8k3ZZz3RS8fVIXVxONVUPlNERoyfY= github.com/Microsoft/go-winio v0.6.2/go.mod h1:yd8OoFMLzJbo9gZq8j5qaps8bJ9aShtEA8Ipt1oGCvU= github.com/NYTimes/gziphandler v1.1.1 h1:ZUDjpQae29j0ryrS0u/B8HZfJBtBQHjqw2rQ2cqUQ3I= github.com/NYTimes/gziphandler v1.1.1/go.mod h1:n/CVRwUEOgIxrgPvAQhUUr9oeUtvrhMomdKFjzJNB0c= -github.com/ProtonMail/go-crypto v1.0.0 h1:LRuvITjQWX+WIfr930YHG2HNfjR1uOfyf5vE0kC2U78= -github.com/ProtonMail/go-crypto v1.0.0/go.mod h1:EjAoLdwvbIOoOQr3ihjnSoLZRtE8azugULFRteWMNc0= +github.com/ProtonMail/go-crypto v1.1.6 h1:ZcV+Ropw6Qn0AX9brlQLAUXfqLBc7Bl+f/DmNxpLfdw= +github.com/ProtonMail/go-crypto v1.1.6/go.mod h1:rA3QumHc/FZ8pAHreoekgiAbzpNsfQAosU5td4SnOrE= github.com/anmitsu/go-shlex v0.0.0-20200514113438-38f4b401e2be h1:9AeTilPcZAjCFIImctFaOjnTIavg87rW78vTPkQqLI8= github.com/anmitsu/go-shlex v0.0.0-20200514113438-38f4b401e2be/go.mod h1:ySMOLuWl6zY27l47sB3qLNK6tF2fkHG55UZxx8oIVo4= github.com/antlr4-go/antlr/v4 v4.13.1 h1:SqQKkuVZ+zWkMMNkjy5FZe5mr5WURWnlpmOuzYWrPrQ= @@ -27,27 +29,27 @@ github.com/blang/semver/v4 v4.0.0 h1:1PFHFE6yCCTv8C1TeyNNarDzntLi7wMI5i/pzqYIsAM github.com/blang/semver/v4 v4.0.0/go.mod h1:IbckMUScFkM3pff0VJDNKRiT6TG/YpiHIM2yvyW5YoQ= github.com/bufbuild/protocompile v0.14.1 h1:iA73zAf/fyljNjQKwYzUHD6AD4R8KMasmwa/FBatYVw= github.com/bufbuild/protocompile v0.14.1/go.mod h1:ppVdAIhbr2H8asPk6k4pY7t9zB1OU5DoEw9xY/FUi1c= -github.com/bwesterb/go-ristretto v1.2.3/go.mod h1:fUIoIZaG73pV5biE2Blr2xEzDoMj7NFEuV9ekS419A0= github.com/cenkalti/backoff/v4 v4.3.0 h1:MyRJ/UdXutAwSAT+s3wNd7MfTIcy71VQueUuFK343L8= github.com/cenkalti/backoff/v4 v4.3.0/go.mod h1:Y3VNntkOUPxTVeUxJ/G5vcM//AlwfmyYozVcomhLiZE= +github.com/cenkalti/backoff/v5 v5.0.3 h1:ZN+IMa753KfX5hd8vVaMixjnqRZ3y8CuJKRKj1xcsSM= +github.com/cenkalti/backoff/v5 v5.0.3/go.mod h1:rkhZdG3JZukswDf7f0cwqPNk4K0sa+F97BxZthm/crw= github.com/cespare/xxhash/v2 v2.3.0 h1:UL815xU9SqsFlibzuggzjXhog7bL6oX9BbNZnL2UFvs= github.com/cespare/xxhash/v2 v2.3.0/go.mod h1:VGX0DQ3Q6kWi7AoAeZDth3/j3BFtOZR5XLFGgcrjCOs= -github.com/cloudflare/circl v1.3.3/go.mod h1:5XYMA4rFBvNIrhs50XuiBJ15vF2pZn4nnUKZrLbUZFA= -github.com/cloudflare/circl v1.3.7 h1:qlCDlTPz2n9fu58M0Nh1J/JzcFpfgkFHHX3O35r5vcU= -github.com/cloudflare/circl v1.3.7/go.mod h1:sRTcRWXGLrKw6yIGJ+l7amYJFfAXbZG0kBSc8r4zxgA= +github.com/cloudflare/circl v1.6.1 h1:zqIqSPIndyBh1bjLVVDHMPpVKqp8Su/V+6MeDzzQBQ0= +github.com/cloudflare/circl v1.6.1/go.mod h1:uddAzsPgqdMAYatqJ0lsjX1oECcQLIlRpzZh3pJrofs= github.com/coreos/go-semver v0.3.1 h1:yi21YpKnrx1gt5R+la8n5WgS0kCrsPp33dmEyHReZr4= github.com/coreos/go-semver v0.3.1/go.mod h1:irMmmIw/7yzSRPWryHsK7EYSg09caPQL03VsM8rvUec= -github.com/coreos/go-systemd/v22 v22.5.0 h1:RrqgGjYQKalulkV8NGVIfkXQf6YYmOyiJKk8iXXhfZs= -github.com/coreos/go-systemd/v22 v22.5.0/go.mod h1:Y58oyj3AT4RCenI/lSvhwexgC+NSVTIJ3seZv2GcEnc= +github.com/coreos/go-systemd/v22 v22.6.0 h1:aGVa/v8B7hpb0TKl0MWoAavPDmHvobFe5R5zn0bCJWo= +github.com/coreos/go-systemd/v22 v22.6.0/go.mod h1:iG+pp635Fo7ZmV/j14KUcmEyWF+0X7Lua8rrTWzYgWU= github.com/cpuguy83/go-md2man/v2 v2.0.6/go.mod h1:oOW0eioCTA6cOiMLiUPZOpcVxMig6NIQQ7OS05n1F4g= -github.com/cyphar/filepath-securejoin v0.2.4 h1:Ugdm7cg7i6ZK6x3xDF1oEu1nfkyfH53EtKeQYTC3kyg= -github.com/cyphar/filepath-securejoin v0.2.4/go.mod h1:aPGpWjXOXUn2NCNjFvBE6aRxGGx79pTxQpKOJNYHHl4= +github.com/cyphar/filepath-securejoin v0.4.1 h1:JyxxyPEaktOD+GAnqIqTf9A8tHyAG22rowi7HkoSU1s= +github.com/cyphar/filepath-securejoin v0.4.1/go.mod h1:Sdj7gXlvMcPZsbhwhQ33GguGLDGQL7h7bg04C/+u9jI= github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= github.com/davecgh/go-spew v1.1.2-0.20180830191138-d8f796af33cc h1:U9qPSI2PIWSS1VwoXQT9A3Wy9MM3WgvqSxFWenqJduM= github.com/davecgh/go-spew v1.1.2-0.20180830191138-d8f796af33cc/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= -github.com/dgraph-io/badger/v4 v4.8.0 h1:JYph1ChBijCw8SLeybvPINizbDKWZ5n/GYbz2yhN/bs= -github.com/dgraph-io/badger/v4 v4.8.0/go.mod h1:U6on6e8k/RTbUWxqKR0MvugJuVmkxSNc79ap4917h4w= +github.com/dgraph-io/badger/v4 v4.9.1 h1:DocZXZkg5JJHJPtUErA0ibyHxOVUDVoXLSCV6t8NC8w= +github.com/dgraph-io/badger/v4 v4.9.1/go.mod h1:5/MEx97uzdPUHR4KtkNt8asfI2T4JiEiQlV7kWUo8c0= github.com/dgraph-io/ristretto/v2 v2.2.0 h1:bkY3XzJcXoMuELV8F+vS8kzNgicwQFAaGINAEJdWGOM= github.com/dgraph-io/ristretto/v2 v2.2.0/go.mod h1:RZrm63UmcBAaYWC1DotLYBmTvgkrs0+XhBd7Npn7/zI= github.com/dgryski/go-farm v0.0.0-20240924180020-3414d57e47da h1:aIftn67I1fkbMa512G+w+Pxci9hJPB8oMnkcP3iZF38= @@ -56,8 +58,8 @@ github.com/dgryski/go-rendezvous v0.0.0-20200823014737-9f7001d12a5f h1:lO4WD4F/r github.com/dgryski/go-rendezvous v0.0.0-20200823014737-9f7001d12a5f/go.mod h1:cuUVRXasLTGF7a8hSLbxyZXjz+1KgoB3wDUb6vlszIc= github.com/dustin/go-humanize v1.0.1 h1:GzkhY7T5VNhEkwH0PVJgjz+fX1rhBrR7pRT3mDkpeCY= github.com/dustin/go-humanize v1.0.1/go.mod h1:Mu1zIs6XwVuF/gI1OepvI0qD18qycQx+mFykh5fBlto= -github.com/elazarl/goproxy v0.0.0-20230808193330-2592e75ae04a h1:mATvB/9r/3gvcejNsXKSkQ6lcIaNec2nyfOdlTBR2lU= -github.com/elazarl/goproxy v0.0.0-20230808193330-2592e75ae04a/go.mod h1:Ro8st/ElPeALwNFlcTpWmkr6IoMFfkjXAvTHpevnDsM= +github.com/elazarl/goproxy v1.7.2 h1:Y2o6urb7Eule09PjlhQRGNsqRfPmYI3KKQLFpCAV3+o= +github.com/elazarl/goproxy v1.7.2/go.mod h1:82vkLNir0ALaW14Rc399OTTjyNREgmdL2cVoIbS6XaE= github.com/emicklei/go-restful/v3 v3.12.2 h1:DhwDP0vY3k8ZzE0RunuJy8GhNpPL6zqLkDf9B/a0/xU= github.com/emicklei/go-restful/v3 v3.12.2/go.mod h1:6n3XBCmQQb25CM2LCACGz8ukIrRry+4bhvbpWn3mrbc= github.com/emirpasic/gods v1.18.1 h1:FXtiHYKDGKCW2KzwZKx0iC0PQmdlorYgdFG9jPXJ1Bc= @@ -70,18 +72,18 @@ github.com/felixge/httpsnoop v1.0.4 h1:NFTV2Zj1bL4mc9sqWACXbQFVBBg2W3GPvqp8/ESS2 github.com/felixge/httpsnoop v1.0.4/go.mod h1:m8KPJKqk1gH5J9DgRY2ASl2lWCfGKXixSwevea8zH2U= github.com/fsnotify/fsnotify v1.9.0 h1:2Ml+OJNzbYCTzsxtv8vKSFD9PbJjmhYF14k/jKC7S9k= github.com/fsnotify/fsnotify v1.9.0/go.mod h1:8jBTzvmWwFyi3Pb8djgCCO5IBqzKJ/Jwo8TRcHyHii0= -github.com/fxamacker/cbor/v2 v2.8.0 h1:fFtUGXUzXPHTIUdne5+zzMPTfffl3RD5qYnkY40vtxU= -github.com/fxamacker/cbor/v2 v2.8.0/go.mod h1:vM4b+DJCtHn+zz7h3FFp/hDAI9WNWCsZj23V5ytsSxQ= -github.com/gliderlabs/ssh v0.3.7 h1:iV3Bqi942d9huXnzEF2Mt+CY9gLu8DNM4Obd+8bODRE= -github.com/gliderlabs/ssh v0.3.7/go.mod h1:zpHEXBstFnQYtGnB8k8kQLol82umzn/2/snG7alWVD8= +github.com/fxamacker/cbor/v2 v2.9.0 h1:NpKPmjDBgUfBms6tr6JZkTHtfFGcMKsw3eGcmD/sapM= +github.com/fxamacker/cbor/v2 v2.9.0/go.mod h1:vM4b+DJCtHn+zz7h3FFp/hDAI9WNWCsZj23V5ytsSxQ= +github.com/gliderlabs/ssh v0.3.8 h1:a4YXD1V7xMF9g5nTkdfnja3Sxy1PVDCj1Zg4Wb8vY6c= +github.com/gliderlabs/ssh v0.3.8/go.mod h1:xYoytBv1sV0aL3CavoDuJIQNURXkkfPA/wxQ1pL1fAU= github.com/go-git/gcfg v1.5.1-0.20230307220236-3a3c6141e376 h1:+zs/tPmkDkHx3U66DAb0lQFJrpS6731Oaa12ikc+DiI= github.com/go-git/gcfg v1.5.1-0.20230307220236-3a3c6141e376/go.mod h1:an3vInlBmSxCcxctByoQdvwPiA7DTK7jaaFDBTtu0ic= -github.com/go-git/go-billy/v5 v5.5.0 h1:yEY4yhzCDuMGSv83oGxiBotRzhwhNr8VZyphhiu+mTU= -github.com/go-git/go-billy/v5 v5.5.0/go.mod h1:hmexnoNsr2SJU1Ju67OaNz5ASJY3+sHgFRpCtpDCKow= +github.com/go-git/go-billy/v5 v5.6.2 h1:6Q86EsPXMa7c3YZ3aLAQsMA0VlWmy43r6FHqa/UNbRM= +github.com/go-git/go-billy/v5 v5.6.2/go.mod h1:rcFC2rAsp/erv7CMz9GczHcuD0D32fWzH+MJAU+jaUU= github.com/go-git/go-git-fixtures/v4 v4.3.2-0.20231010084843-55a94097c399 h1:eMje31YglSBqCdIqdhKBW8lokaMrL3uTkpGYlE2OOT4= github.com/go-git/go-git-fixtures/v4 v4.3.2-0.20231010084843-55a94097c399/go.mod h1:1OCfN199q1Jm3HZlxleg+Dw/mwps2Wbk9frAWm+4FII= -github.com/go-git/go-git/v5 v5.12.0 h1:7Md+ndsjrzZxbddRDZjF14qK+NN56sy6wkqaVrjZtys= -github.com/go-git/go-git/v5 v5.12.0/go.mod h1:FTM9VKtnI2m65hNI/TenDDDnUf2Q9FHnXYjuz9i5OEY= +github.com/go-git/go-git/v5 v5.16.5 h1:mdkuqblwr57kVfXri5TTH+nMFLNUxIj9Z7F5ykFbw5s= +github.com/go-git/go-git/v5 v5.16.5/go.mod h1:QOMLpNf1qxuSY4StA/ArOdfFR2TrKEjJiye2kel2m+M= github.com/go-logr/logr v1.2.2/go.mod h1:jdQByPbusPIv2/zmleS9BjJVeZ6kBagPoEUsqbVz/1A= github.com/go-logr/logr v1.4.3 h1:CjnDlHq8ikf6E492q6eKboGOC0T8CDaOvkHCIg8idEI= github.com/go-logr/logr v1.4.3/go.mod h1:9T104GzyrTigFIr8wt5mBrctHMim0Nb2HLGrmQ40KvY= @@ -89,61 +91,88 @@ github.com/go-logr/stdr v1.2.2 h1:hSWxHoqTgW2S2qGc0LTAI563KZ5YKYRhT3MFKZMbjag= github.com/go-logr/stdr v1.2.2/go.mod h1:mMo/vtBO5dYbehREoey6XUKy/eSumjCCveDpRre4VKE= github.com/go-logr/zapr v1.3.0 h1:XGdV8XW8zdwFiwOA2Dryh1gj2KRQyOOoNmBy4EplIcQ= github.com/go-logr/zapr v1.3.0/go.mod h1:YKepepNBd1u/oyhd/yQmtjVXmm9uML4IXUgMOwR8/Gg= -github.com/go-openapi/jsonpointer v0.21.1 h1:whnzv/pNXtK2FbX/W9yJfRmE2gsmkfahjMKB0fZvcic= -github.com/go-openapi/jsonpointer v0.21.1/go.mod h1:50I1STOfbY1ycR8jGz8DaMeLCdXiI6aDteEdRNNzpdk= -github.com/go-openapi/jsonreference v0.21.0 h1:Rs+Y7hSXT83Jacb7kFyjn4ijOuVGSvOdF2+tg1TRrwQ= -github.com/go-openapi/jsonreference v0.21.0/go.mod h1:LmZmgsrTkVg9LG4EaHeY8cBDslNPMo06cago5JNLkm4= -github.com/go-openapi/swag v0.23.1 h1:lpsStH0n2ittzTnbaSloVZLuB5+fvSY/+hnagBjSNZU= -github.com/go-openapi/swag v0.23.1/go.mod h1:STZs8TbRvEQQKUA+JZNAm3EWlgaOBGpyFDqQnDHMef0= +github.com/go-openapi/jsonpointer v0.22.1 h1:sHYI1He3b9NqJ4wXLoJDKmUmHkWy/L7rtEo92JUxBNk= +github.com/go-openapi/jsonpointer v0.22.1/go.mod h1:pQT9OsLkfz1yWoMgYFy4x3U5GY5nUlsOn1qSBH5MkCM= +github.com/go-openapi/jsonreference v0.21.3 h1:96Dn+MRPa0nYAR8DR1E03SblB5FJvh7W6krPI0Z7qMc= +github.com/go-openapi/jsonreference v0.21.3/go.mod h1:RqkUP0MrLf37HqxZxrIAtTWW4ZJIK1VzduhXYBEeGc4= +github.com/go-openapi/swag v0.25.4 h1:OyUPUFYDPDBMkqyxOTkqDYFnrhuhi9NR6QVUvIochMU= +github.com/go-openapi/swag v0.25.4/go.mod h1:zNfJ9WZABGHCFg2RnY0S4IOkAcVTzJ6z2Bi+Q4i6qFQ= +github.com/go-openapi/swag/cmdutils v0.25.4 h1:8rYhB5n6WawR192/BfUu2iVlxqVR9aRgGJP6WaBoW+4= +github.com/go-openapi/swag/cmdutils v0.25.4/go.mod h1:pdae/AFo6WxLl5L0rq87eRzVPm/XRHM3MoYgRMvG4A0= +github.com/go-openapi/swag/conv v0.25.4 h1:/Dd7p0LZXczgUcC/Ikm1+YqVzkEeCc9LnOWjfkpkfe4= +github.com/go-openapi/swag/conv v0.25.4/go.mod h1:3LXfie/lwoAv0NHoEuY1hjoFAYkvlqI/Bn5EQDD3PPU= +github.com/go-openapi/swag/fileutils v0.25.4 h1:2oI0XNW5y6UWZTC7vAxC8hmsK/tOkWXHJQH4lKjqw+Y= +github.com/go-openapi/swag/fileutils v0.25.4/go.mod h1:cdOT/PKbwcysVQ9Tpr0q20lQKH7MGhOEb6EwmHOirUk= +github.com/go-openapi/swag/jsonname v0.25.4 h1:bZH0+MsS03MbnwBXYhuTttMOqk+5KcQ9869Vye1bNHI= +github.com/go-openapi/swag/jsonname v0.25.4/go.mod h1:GPVEk9CWVhNvWhZgrnvRA6utbAltopbKwDu8mXNUMag= +github.com/go-openapi/swag/jsonutils v0.25.4 h1:VSchfbGhD4UTf4vCdR2F4TLBdLwHyUDTd1/q4i+jGZA= +github.com/go-openapi/swag/jsonutils v0.25.4/go.mod h1:7OYGXpvVFPn4PpaSdPHJBtF0iGnbEaTk8AvBkoWnaAY= +github.com/go-openapi/swag/jsonutils/fixtures_test v0.25.4 h1:IACsSvBhiNJwlDix7wq39SS2Fh7lUOCJRmx/4SN4sVo= +github.com/go-openapi/swag/jsonutils/fixtures_test v0.25.4/go.mod h1:Mt0Ost9l3cUzVv4OEZG+WSeoHwjWLnarzMePNDAOBiM= +github.com/go-openapi/swag/loading v0.25.4 h1:jN4MvLj0X6yhCDduRsxDDw1aHe+ZWoLjW+9ZQWIKn2s= +github.com/go-openapi/swag/loading v0.25.4/go.mod h1:rpUM1ZiyEP9+mNLIQUdMiD7dCETXvkkC30z53i+ftTE= +github.com/go-openapi/swag/mangling v0.25.4 h1:2b9kBJk9JvPgxr36V23FxJLdwBrpijI26Bx5JH4Hp48= +github.com/go-openapi/swag/mangling v0.25.4/go.mod h1:6dxwu6QyORHpIIApsdZgb6wBk/DPU15MdyYj/ikn0Hg= +github.com/go-openapi/swag/netutils v0.25.4 h1:Gqe6K71bGRb3ZQLusdI8p/y1KLgV4M/k+/HzVSqT8H0= +github.com/go-openapi/swag/netutils v0.25.4/go.mod h1:m2W8dtdaoX7oj9rEttLyTeEFFEBvnAx9qHd5nJEBzYg= +github.com/go-openapi/swag/stringutils v0.25.4 h1:O6dU1Rd8bej4HPA3/CLPciNBBDwZj9HiEpdVsb8B5A8= +github.com/go-openapi/swag/stringutils v0.25.4/go.mod h1:GTsRvhJW5xM5gkgiFe0fV3PUlFm0dr8vki6/VSRaZK0= +github.com/go-openapi/swag/typeutils v0.25.4 h1:1/fbZOUN472NTc39zpa+YGHn3jzHWhv42wAJSN91wRw= +github.com/go-openapi/swag/typeutils v0.25.4/go.mod h1:Ou7g//Wx8tTLS9vG0UmzfCsjZjKhpjxayRKTHXf2pTE= +github.com/go-openapi/swag/yamlutils v0.25.4 h1:6jdaeSItEUb7ioS9lFoCZ65Cne1/RZtPBZ9A56h92Sw= +github.com/go-openapi/swag/yamlutils v0.25.4/go.mod h1:MNzq1ulQu+yd8Kl7wPOut/YHAAU/H6hL91fF+E2RFwc= +github.com/go-openapi/testify/enable/yaml/v2 v2.0.2 h1:0+Y41Pz1NkbTHz8NngxTuAXxEodtNSI1WG1c/m5Akw4= +github.com/go-openapi/testify/enable/yaml/v2 v2.0.2/go.mod h1:kme83333GCtJQHXQ8UKX3IBZu6z8T5Dvy5+CW3NLUUg= +github.com/go-openapi/testify/v2 v2.0.2 h1:X999g3jeLcoY8qctY/c/Z8iBHTbwLz7R2WXd6Ub6wls= +github.com/go-openapi/testify/v2 v2.0.2/go.mod h1:HCPmvFFnheKK2BuwSA0TbbdxJ3I16pjwMkYkP4Ywn54= github.com/go-redis/redis/v8 v8.11.5 h1:AcZZR7igkdvfVmQTPnu9WE37LRrO/YrBH5zWyjDC0oI= github.com/go-redis/redis/v8 v8.11.5/go.mod h1:gREzHqY1hg6oD9ngVRbLStwAWKhA0FEgq8Jd4h5lpwo= github.com/go-task/slim-sprig/v3 v3.0.0 h1:sUs3vkvUymDpBKi3qH1YSqBQk9+9D/8M2mN1vB6EwHI= github.com/go-task/slim-sprig/v3 v3.0.0/go.mod h1:W848ghGpv3Qj3dhTPRyJypKRiqCdHZiAzKg9hl15HA8= -github.com/godbus/dbus/v5 v5.0.4/go.mod h1:xhWf0FNVPg57R7Z0UbKHbJfkEywrmjJnf7w5xrFpKfA= github.com/gogo/protobuf v1.3.2 h1:Ov1cvc58UF3b5XjBnZv7+opcTcQFZebYjWzi34vdm4Q= github.com/gogo/protobuf v1.3.2/go.mod h1:P1XiOD3dCwIKUDQYPy72D8LYyHL2YPYrpS2s69NZV8Q= -github.com/golang-jwt/jwt/v4 v4.5.2 h1:YtQM7lnr8iZ+j5q71MGKkNw9Mn7AjHM68uc9g5fXeUI= -github.com/golang-jwt/jwt/v4 v4.5.2/go.mod h1:m21LjoU+eqJr34lmDMbreY2eSTRJ1cv77w39/MY0Ch0= +github.com/golang-jwt/jwt/v5 v5.3.0 h1:pv4AsKCKKZuqlgs5sUmn4x8UlGa0kEVt/puTpKx9vvo= +github.com/golang-jwt/jwt/v5 v5.3.0/go.mod h1:fxCRLWMO43lRc8nhHWY6LGqRcf+1gQWArsqaEUEa5bE= github.com/golang/glog v1.2.5 h1:DrW6hGnjIhtvhOIiAKT6Psh/Kd/ldepEa81DKeiRJ5I= github.com/golang/glog v1.2.5/go.mod h1:6AhwSGph0fcJtXVM/PEHPqZlFeoLxhs7/t5UDAwmO+w= -github.com/golang/groupcache v0.0.0-20210331224755-41bb18bfe9da h1:oI5xCqsCo564l8iNU+DwB5epxmsaqB+rhGL0m5jtYqE= -github.com/golang/groupcache v0.0.0-20210331224755-41bb18bfe9da/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc= +github.com/golang/groupcache v0.0.0-20241129210726-2c02b8208cf8 h1:f+oWsMOmNPc8JmEHVZIycC7hBoQxHH9pNKQORJNozsQ= +github.com/golang/groupcache v0.0.0-20241129210726-2c02b8208cf8/go.mod h1:wcDNUvekVysuuOpQKo3191zZyTpiI6se1N1ULghS0sw= github.com/golang/protobuf v1.5.4 h1:i7eJL8qZTpSEXOPTxNKhASYpMn+8e5Q6AdndVa1dWek= github.com/golang/protobuf v1.5.4/go.mod h1:lnTiLA8Wa4RWRcIUkrtSVa5nRhsEGBg48fD6rSs7xps= github.com/google/btree v1.1.3 h1:CVpQJjYgC4VbzxeGVHfvZrv1ctoYCAI8vbl07Fcxlyg= github.com/google/btree v1.1.3/go.mod h1:qOPhT0dTNdNzV6Z/lhRX0YXUafgPLFUh+gZMl761Gm4= -github.com/google/cel-go v0.25.0 h1:jsFw9Fhn+3y2kBbltZR4VEz5xKkcIFRPDnuEzAGv5GY= -github.com/google/cel-go v0.25.0/go.mod h1:hjEb6r5SuOSlhCHmFoLzu8HGCERvIsDAbxDAyNU/MmI= +github.com/google/cel-go v0.26.0 h1:DPGjXackMpJWH680oGY4lZhYjIameYmR+/6RBdDGmaI= +github.com/google/cel-go v0.26.0/go.mod h1:A9O8OU9rdvrK5MQyrqfIxo1a0u4g3sF8KB6PUIaryMM= github.com/google/flatbuffers v25.2.10+incompatible h1:F3vclr7C3HpB1k9mxCGRMXq6FdUalZ6H/pNX4FP1v0Q= github.com/google/flatbuffers v25.2.10+incompatible/go.mod h1:1AeVuKshWv4vARoZatz6mlQ0JxURH0Kv5+zNeJKJCa8= -github.com/google/gnostic-models v0.6.9 h1:MU/8wDLif2qCXZmzncUQ/BOfxWfthHi63KqpoNbWqVw= -github.com/google/gnostic-models v0.6.9/go.mod h1:CiWsm0s6BSQd1hRn8/QmxqB6BesYcbSZxsz9b0KuDBw= -github.com/google/go-cmp v0.5.9/go.mod h1:17dUlkBOakJ0+DkrSSNjCkIjxS6bF9zb3elmeNGIjoY= +github.com/google/gnostic-models v0.7.0 h1:qwTtogB15McXDaNqTZdzPJRHvaVJlAl+HVQnLmJEJxo= +github.com/google/gnostic-models v0.7.0/go.mod h1:whL5G0m6dmc5cPxKc5bdKdEN3UjI7OUGxBlw57miDrQ= github.com/google/go-cmp v0.7.0 h1:wk8382ETsv4JYUZwIsn6YpYiWiBsYLSJiTsyBybVuN8= github.com/google/go-cmp v0.7.0/go.mod h1:pXiqmnSA92OHEEa9HXL2W4E7lf9JzCmGVUdgjX3N/iU= github.com/google/gofuzz v1.0.0/go.mod h1:dBl0BpW6vV/+mYPU4Po3pmUjxk6FQPldtuIdl/M65Eg= github.com/google/gofuzz v1.2.0 h1:xRy4A+RhZaiKjJ1bPfwQ8sedCA+YS2YcCHW6ec7JMi0= github.com/google/gofuzz v1.2.0/go.mod h1:dBl0BpW6vV/+mYPU4Po3pmUjxk6FQPldtuIdl/M65Eg= -github.com/google/pprof v0.0.0-20241210010833-40e02aabc2ad h1:a6HEuzUHeKH6hwfN/ZoQgRgVIWFJljSWa/zetS2WTvg= -github.com/google/pprof v0.0.0-20241210010833-40e02aabc2ad/go.mod h1:vavhavw2zAxS5dIdcRluK6cSGGPlZynqzFM8NdvU144= +github.com/google/pprof v0.0.0-20251213031049-b05bdaca462f h1:HU1RgM6NALf/KW9HEY6zry3ADbDKcmpQ+hJedoNGQYQ= +github.com/google/pprof v0.0.0-20251213031049-b05bdaca462f/go.mod h1:67FPmZWbr+KDT/VlpWtw6sO9XSjpJmLuHpoLmWiTGgY= github.com/google/uuid v1.6.0 h1:NIvaJDMOsjHA8n1jAhLSgzrAzy1Hgr+hNrb57e+94F0= github.com/google/uuid v1.6.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= github.com/gorilla/websocket v1.5.4-0.20250319132907-e064f32e3674 h1:JeSE6pjso5THxAzdVpqr6/geYxZytqFMBCOtn/ujyeo= github.com/gorilla/websocket v1.5.4-0.20250319132907-e064f32e3674/go.mod h1:r4w70xmWCQKmi1ONH4KIaBptdivuRPyosB9RmPlGEwA= -github.com/grafana/regexp v0.0.0-20240518133315-a468a5bfb3bc h1:GN2Lv3MGO7AS6PrRoT6yV5+wkrOpcszoIsO4+4ds248= -github.com/grafana/regexp v0.0.0-20240518133315-a468a5bfb3bc/go.mod h1:+JKpmjMGhpgPL+rXZ5nsZieVzvarn86asRlBg4uNGnk= +github.com/grafana/regexp v0.0.0-20250905093917-f7b3be9d1853 h1:cLN4IBkmkYZNnk7EAJ0BHIethd+J6LqxFNw5mSiI2bM= +github.com/grafana/regexp v0.0.0-20250905093917-f7b3be9d1853/go.mod h1:+JKpmjMGhpgPL+rXZ5nsZieVzvarn86asRlBg4uNGnk= github.com/grpc-ecosystem/go-grpc-middleware v1.4.0 h1:UH//fgunKIs4JdUbpDl1VZCDaL56wXCB/5+wF6uHfaI= -github.com/grpc-ecosystem/go-grpc-middleware v1.4.0/go.mod h1:g5qyo/la0ALbONm6Vbp88Yd8NsDy6rZz+RcrMPxvld8= +github.com/grpc-ecosystem/go-grpc-middleware/providers/prometheus v1.0.1 h1:qnpSQwGEnkcRpTqNOIR6bJbR0gAorgP9CSALpRcKoAA= +github.com/grpc-ecosystem/go-grpc-middleware/providers/prometheus v1.0.1/go.mod h1:lXGCsh6c22WGtjr+qGHj1otzZpV/1kwTMAqkwZsnWRU= +github.com/grpc-ecosystem/go-grpc-middleware/v2 v2.3.0 h1:FbSCl+KggFl+Ocym490i/EyXF4lPgLoUtcSWquBM0Rs= +github.com/grpc-ecosystem/go-grpc-middleware/v2 v2.3.0/go.mod h1:qOchhhIlmRcqk/O9uCo/puJlyo07YINaIqdZfZG3Jkc= github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0 h1:Ovs26xHkKqVztRpIrF/92BcuyuQ/YW4NSIpoGtfXNho= github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0/go.mod h1:8NvIoxWQoOIhqOTXgfV/d3M/q6VIi02HzZEHgUlZvzk= -github.com/grpc-ecosystem/grpc-gateway v1.16.0 h1:gmcG1KaJ57LophUzW0Hy8NmPhnMZb4M0+kPpLofRdBo= -github.com/grpc-ecosystem/grpc-gateway v1.16.0/go.mod h1:BDjrQk3hbvj6Nolgz8mAMFbcEtjT1g+wF4CSlocrBnw= -github.com/grpc-ecosystem/grpc-gateway/v2 v2.26.3 h1:5ZPtiqj0JL5oKWmcsq4VMaAW5ukBEgSGXEN89zeH1Jo= -github.com/grpc-ecosystem/grpc-gateway/v2 v2.26.3/go.mod h1:ndYquD05frm2vACXE1nsccT4oJzjhw2arTS2cpUD1PI= -github.com/henderiw/apiserver-builder v0.0.4 h1:H0VBAs74x6Tf2KCQ3Us3kkWjzA/kj3eBpvnylwDIGdo= -github.com/henderiw/apiserver-builder v0.0.4/go.mod h1:guryT8mhwZhroye1C7JoiLlqLmXnxg/pFKwoxLGZTQQ= -github.com/henderiw/apiserver-store v0.0.2 h1:0nfgU9wPl/zZmtSOta2MlFm+WsXlEl0Mo2EKwsk6B4w= -github.com/henderiw/apiserver-store v0.0.2/go.mod h1:sz0/rzH0rk/WJMztre8hmctMkaY1ANRWCKM67SK5Ei0= +github.com/grpc-ecosystem/grpc-gateway/v2 v2.27.3 h1:NmZ1PKzSTQbuGHw9DGPFomqkkLWMC+vZCkfs+FHv1Vg= +github.com/grpc-ecosystem/grpc-gateway/v2 v2.27.3/go.mod h1:zQrxl1YP88HQlA6i9c63DSVPFklWpGX4OWAc9bFuaH4= +github.com/henderiw/apiserver-builder v0.0.5-0.20260217153329-7417ac911bd8 h1:7yl2k/Ikj0guao72jcP1vDD6lhu7R0FfBFH7VdVpY30= +github.com/henderiw/apiserver-builder v0.0.5-0.20260217153329-7417ac911bd8/go.mod h1:1Dhrku4EnByHETdZLZQ0bLK8Xd9Vmjuh22mf5Y+7hfw= +github.com/henderiw/apiserver-store v0.0.3-0.20260217161537-573fa9ffabd2 h1:shdijRNT8Ex13ibuHeKGbmDCt5Q2jvqRfdd7FWTFxiA= +github.com/henderiw/apiserver-store v0.0.3-0.20260217161537-573fa9ffabd2/go.mod h1:lGsqtfR6J/EFZfaww2CvCpD+6N/eRqWMK7wRSOTQM2c= github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c h1:nFnCNyRV1Ej/zqV/gn8UnFESkoPUXhwpUCZyhSYGSYA= github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c/go.mod h1:PrPJdVAwtl5tL323wykHZ5L/b7tfJJsjhegza/wq4fQ= github.com/henderiw/logger v0.0.0-20230911123436-8655829b1abe h1:+R53KH7fW+pmqlfSYVTCGPn8pj6gqBGcQ0nq7L1h8+g= @@ -156,18 +185,16 @@ github.com/jbenet/go-context v0.0.0-20150711004518-d14ea06fba99 h1:BQSFePA1RWJOl github.com/jbenet/go-context v0.0.0-20150711004518-d14ea06fba99/go.mod h1:1lJo3i6rXxKeerYnT8Nvf0QmHCRC1n8sfWVwXF2Frvo= github.com/jhump/protoreflect v1.17.0 h1:qOEr613fac2lOuTgWN4tPAtLL7fUSbuJL5X5XumQh94= github.com/jhump/protoreflect v1.17.0/go.mod h1:h9+vUUL38jiBzck8ck+6G/aeMX8Z4QUY/NiJPwPNi+8= -github.com/jonboulle/clockwork v0.4.0 h1:p4Cf1aMWXnXAUh8lVfewRBx1zaTSYKrKMF2g3ST4RZ4= -github.com/jonboulle/clockwork v0.4.0/go.mod h1:xgRqUGwRcjKCO1vbZUEtSLrqKoPSsUpK7fnezOII0kc= -github.com/josharian/intern v1.0.0 h1:vlS4z54oSdjm0bgjRigI+G1HpF+tI+9rE5LLzOg8HmY= -github.com/josharian/intern v1.0.0/go.mod h1:5DoeVV0s6jJacbCEi61lwdGj/aVlrQvzHFFd8Hwg//Y= +github.com/jonboulle/clockwork v0.5.0 h1:Hyh9A8u51kptdkR+cqRpT1EebBwTn1oK9YfGYbdFz6I= +github.com/jonboulle/clockwork v0.5.0/go.mod h1:3mZlmanh0g2NDKO5TWZVJAfofYk64M7XN3SzBPjZF60= github.com/json-iterator/go v1.1.12 h1:PV8peI4a0ysnczrg+LtxykD8LfKY9ML6u2jnxaEnrnM= github.com/json-iterator/go v1.1.12/go.mod h1:e30LSqwooZae/UwlEbR2852Gd8hjQvJoHmT4TnhNGBo= github.com/kevinburke/ssh_config v1.2.0 h1:x584FjTGwHzMwvHx18PXxbBVzfnxogHaAReU4gf13a4= github.com/kevinburke/ssh_config v1.2.0/go.mod h1:CT57kijsi8u/K/BOFA39wgDQJ9CxiF4nAY/ojJ6r6mM= github.com/kisielk/errcheck v1.5.0/go.mod h1:pFxgyoBC7bSaBwPgfKdkLd5X25qrDl4LWUI2bnpBCr8= github.com/kisielk/gotool v1.0.0/go.mod h1:XhKaO+MFFWcvkIS/tQcRk01m1F5IRFswLeQ+oQHNcck= -github.com/klauspost/compress v1.18.0 h1:c/Cqfb0r+Yi+JtIEq73FWXVkRonBlf0CRNYc8Zttxdo= -github.com/klauspost/compress v1.18.0/go.mod h1:2Pp+KzxcywXVXMr50+X0Q/Lsb43OQHYWRCY2AiWywWQ= +github.com/klauspost/compress v1.18.2 h1:iiPHWW0YrcFgpBYhsA6D1+fqHssJscY/Tm/y2Uqnapk= +github.com/klauspost/compress v1.18.2/go.mod h1:R0h/fSBs8DE4ENlcrlib3PsXS61voFxhIs2DeRhCvJ4= github.com/kr/pretty v0.1.0/go.mod h1:dAy3ld7l9f0ibDNOQOHHMYYIIbhfbHSm3C4ZsoJORNo= github.com/kr/pretty v0.3.1 h1:flRD4NNwYAUpkphVc1HcthR4KEIFJ65n8Mw5qdRn3LE= github.com/kr/pretty v0.3.1/go.mod h1:hoEshYVHaxMs3cyo3Yncou5ZscifuDolrwPKZanG3xk= @@ -177,15 +204,14 @@ github.com/kr/text v0.2.0 h1:5Nx0Ya0ZqY2ygV366QzturHI13Jq95ApcVaJBhpS+AY= github.com/kr/text v0.2.0/go.mod h1:eLer722TekiGuMkidMxC/pM04lWEeraHUUmBw8l2grE= github.com/kylelemons/godebug v1.1.0 h1:RPNrshWIDI6G2gRW9EHilWtl7Z6Sb1BR0xunSBf0SNc= github.com/kylelemons/godebug v1.1.0/go.mod h1:9/0rRGxNHcop5bhtWyNeEfOS8JIWk580+fNqagV/RAw= -github.com/mailru/easyjson v0.9.0 h1:PrnmzHw7262yW8sTBwxi1PdJA3Iw/EKBa8psRf7d9a4= -github.com/mailru/easyjson v0.9.0/go.mod h1:1+xMtQp2MRNVL/V1bOzuP3aP8VNwRW55fQUto+XFtTU= github.com/minio/highwayhash v1.0.2 h1:Aak5U0nElisjDCfPSG79Tgzkn2gl66NxOMspRrKnA/g= github.com/minio/highwayhash v1.0.2/go.mod h1:BQskDq+xkJ12lmlUUi7U0M5Swg3EWR+dLTk+kldvVxY= github.com/modern-go/concurrent v0.0.0-20180228061459-e0a39a4cb421/go.mod h1:6dJC0mAP4ikYIbvyc7fijjWJddQyLn8Ig3JB5CqoB9Q= github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd h1:TRLaZ9cD/w8PVh93nsPXa1VrQ6jlwL5oN8l14QlcNfg= github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd/go.mod h1:6dJC0mAP4ikYIbvyc7fijjWJddQyLn8Ig3JB5CqoB9Q= -github.com/modern-go/reflect2 v1.0.2 h1:xBagoLtFs94CBntxluKeaWgTMpvLxC4ur3nMaC9Gz0M= github.com/modern-go/reflect2 v1.0.2/go.mod h1:yWuevngMOJpCy52FWWMvUC8ws7m/LJsjYzDa0/r8luk= +github.com/modern-go/reflect2 v1.0.3-0.20250322232337-35a7c28c31ee h1:W5t00kpgFdJifH4BDsTlE89Zl93FEloxaWZfGcifgq8= +github.com/modern-go/reflect2 v1.0.3-0.20250322232337-35a7c28c31ee/go.mod h1:yWuevngMOJpCy52FWWMvUC8ws7m/LJsjYzDa0/r8luk= github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822 h1:C3w9PqII01/Oq1c1nUAm88MOHcQC9l5mIlSMApZMrHA= github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822/go.mod h1:+n7T8mK8HuQTcFwEeznm/DIxMOiR9yIdICNftLE1DvQ= github.com/nats-io/jwt/v2 v2.5.2 h1:DhGH+nKt+wIkDxM6qnVSKjokq5t59AZV5HRcFW0zJwU= @@ -202,10 +228,10 @@ github.com/nxadm/tail v1.4.8 h1:nPr65rt6Y5JFSKQO7qToXr7pePgD6Gwiw05lkbyAQTE= github.com/nxadm/tail v1.4.8/go.mod h1:+ncqLTQzXmGhMZNUePPaPqPvBxHAIsmXswZKocGu+AU= github.com/onsi/ginkgo v1.16.5 h1:8xi0RTUf59SOSfEtZMvwTvXYMzG4gV23XVHOZiXNtnE= github.com/onsi/ginkgo v1.16.5/go.mod h1:+E8gABHa3K6zRBolWtd+ROzc/U5bkGt0FwiG042wbpU= -github.com/onsi/ginkgo/v2 v2.22.2 h1:/3X8Panh8/WwhU/3Ssa6rCKqPLuAkVY2I0RoyDLySlU= -github.com/onsi/ginkgo/v2 v2.22.2/go.mod h1:oeMosUL+8LtarXBHu/c0bx2D/K9zyQ6uX3cTyztHwsk= -github.com/onsi/gomega v1.36.2 h1:koNYke6TVk6ZmnyHrCXba/T/MoLBXFjeC1PtvYgw0A8= -github.com/onsi/gomega v1.36.2/go.mod h1:DdwyADRjrc825LhMEkD76cHR5+pUnjhUN8GlHlRPHzY= +github.com/onsi/ginkgo/v2 v2.27.2 h1:LzwLj0b89qtIy6SSASkzlNvX6WktqurSHwkk2ipF/Ns= +github.com/onsi/ginkgo/v2 v2.27.2/go.mod h1:ArE1D/XhNXBXCBkKOLkbsb2c81dQHCRcF5zwn/ykDRo= +github.com/onsi/gomega v1.38.2 h1:eZCjf2xjZAqe+LeWvKb5weQ+NcPwX84kqJ0cZNxok2A= +github.com/onsi/gomega v1.38.2/go.mod h1:W2MJcYxRGV63b418Ai34Ud0hEdTVXq9NW9+Sx6uXf3k= github.com/openconfig/gnmi v0.14.1 h1:qKMuFvhIRR2/xxCOsStPQ25aKpbMDdWr3kI+nP9bhMs= github.com/openconfig/gnmi v0.14.1/go.mod h1:whr6zVq9PCU8mV1D0K9v7Ajd3+swoN6Yam9n8OH3eT0= github.com/openconfig/gnmic/pkg/api v0.1.9 h1:XPln4mDgC2Bjh9VqE+BY1LLvQrk1tGHZLivDnCR3Nbg= @@ -218,27 +244,27 @@ github.com/openconfig/grpctunnel v0.1.0 h1:EN99qtlExZczgQgp5ANnHRC/Rs62cAG+Tz2BQ github.com/openconfig/grpctunnel v0.1.0/go.mod h1:G04Pdu0pml98tdvXrvLaU+EBo3PxYfI9MYqpvdaEHLo= github.com/openconfig/ygot v0.29.20 h1:XHLpwCN91QuKc2LAvnEqtCmH8OuxgLlErDhrdl2mJw8= github.com/openconfig/ygot v0.29.20/go.mod h1:K8HbrPm/v8/emtGQ9+RsJXx6UPKC5JzS/FqK7pN+tMo= -github.com/otiai10/copy v1.14.0 h1:dCI/t1iTdYGtkvCuBG2BgR6KZa83PTclw4U5n2wAllU= -github.com/otiai10/copy v1.14.0/go.mod h1:ECfuL02W+/FkTWZWgQqXPWZgW9oeKCSQ5qVfSc4qc4w= -github.com/otiai10/mint v1.5.1 h1:XaPLeE+9vGbuyEHem1JNk3bYc7KKqyI/na0/mLd/Kks= -github.com/otiai10/mint v1.5.1/go.mod h1:MJm72SBthJjz8qhefc4z1PYEieWmy8Bku7CjcAqyUSM= -github.com/pjbgf/sha1cd v0.3.0 h1:4D5XXmUUBUl/xQ6IjCkEAbqXskkq/4O7LmGn0AqMDs4= -github.com/pjbgf/sha1cd v0.3.0/go.mod h1:nZ1rrWOcGJ5uZgEEVL1VUM9iRQiZvWdbZjkKyFzPPsI= +github.com/otiai10/copy v1.14.1 h1:5/7E6qsUMBaH5AnQ0sSLzzTg1oTECmcCmT6lvF45Na8= +github.com/otiai10/copy v1.14.1/go.mod h1:oQwrEDDOci3IM8dJF0d8+jnbfPDllW6vUjNc3DoZm9I= +github.com/otiai10/mint v1.6.3 h1:87qsV/aw1F5as1eH1zS/yqHY85ANKVMgkDrf9rcxbQs= +github.com/otiai10/mint v1.6.3/go.mod h1:MJm72SBthJjz8qhefc4z1PYEieWmy8Bku7CjcAqyUSM= +github.com/pjbgf/sha1cd v0.3.2 h1:a9wb0bp1oC2TGwStyn0Umc/IGKQnEgF0vVaZ8QF8eo4= +github.com/pjbgf/sha1cd v0.3.2/go.mod h1:zQWigSxVmsHEZow5qaLtPYxpcKMMQpa09ixqBxuCS6A= github.com/pkg/errors v0.9.1 h1:FEBLx1zS214owpjy7qsBeixbURkuhQAwrK5UwLGTwt4= github.com/pkg/errors v0.9.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4= github.com/pmezard/go-difflib v1.0.1-0.20181226105442-5d4384ee4fb2 h1:Jamvg5psRIccs7FGNTlIRMkT8wgtp5eCXdBlqhYGL6U= github.com/pmezard/go-difflib v1.0.1-0.20181226105442-5d4384ee4fb2/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4= -github.com/prometheus/client_golang v1.23.0 h1:ust4zpdl9r4trLY/gSjlm07PuiBq2ynaXXlptpfy8Uc= -github.com/prometheus/client_golang v1.23.0/go.mod h1:i/o0R9ByOnHX0McrTMTyhYvKE4haaf2mW08I+jGAjEE= +github.com/prometheus/client_golang v1.23.2 h1:Je96obch5RDVy3FDMndoUsjAhG5Edi49h0RJWRi/o0o= +github.com/prometheus/client_golang v1.23.2/go.mod h1:Tb1a6LWHB3/SPIzCoaDXI4I8UHKeFTEQ1YCr+0Gyqmg= github.com/prometheus/client_model v0.6.2 h1:oBsgwpGs7iVziMvrGhE53c/GrLUsZdHnqNwqPLxwZyk= github.com/prometheus/client_model v0.6.2/go.mod h1:y3m2F6Gdpfy6Ut/GBsUqTWZqCUvMVzSfMLjcu6wAwpE= -github.com/prometheus/common v0.65.0 h1:QDwzd+G1twt//Kwj/Ww6E9FQq1iVMmODnILtW1t2VzE= -github.com/prometheus/common v0.65.0/go.mod h1:0gZns+BLRQ3V6NdaerOhMbwwRbNh9hkGINtQAsP5GS8= +github.com/prometheus/common v0.67.4 h1:yR3NqWO1/UyO1w2PhUvXlGQs/PtFmoveVO0KZ4+Lvsc= +github.com/prometheus/common v0.67.4/go.mod h1:gP0fq6YjjNCLssJCQp0yk4M8W6ikLURwkdd/YKtTbyI= github.com/prometheus/procfs v0.16.1 h1:hZ15bTNuirocR6u0JZ6BAHHmwS1p8B4P6MRqxtzMyRg= github.com/prometheus/procfs v0.16.1/go.mod h1:teAbpZRB1iIAJYREa1LsoWUXykVXA1KlTmWl8x/U+Is= -github.com/prometheus/prometheus v0.300.1 h1:9KKcTTq80gkzmXW0Et/QCFSrBPgmwiS3Hlcxc6o8KlM= -github.com/prometheus/prometheus v0.300.1/go.mod h1:gtTPY/XVyCdqqnjA3NzDMb0/nc5H9hOu1RMame+gHyM= +github.com/prometheus/prometheus v0.309.1 h1:jutK6eCYDpWdPTUbVbkcQsNCMO9CCkSwjQRMLds4jSo= +github.com/prometheus/prometheus v0.309.1/go.mod h1:d+dOGiVhuNDa4MaFXHVdnUBy/CzqlcNTooR8oM1wdTU= github.com/rogpeppe/go-internal v1.14.1 h1:UQB4HGPB6osV0SQTLymcB4TgvyWu6ZyliaW0tI/otEQ= github.com/rogpeppe/go-internal v1.14.1/go.mod h1:MaRKkUm5W0goXpeCfT7UZI6fk/L7L7so1lCWt35ZSgc= github.com/russross/blackfriday/v2 v2.1.0/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM= @@ -251,14 +277,14 @@ github.com/sergi/go-diff v1.3.2-0.20230802210424-5b0b94c5c0d3/go.mod h1:A0bzQcvG github.com/sirupsen/logrus v1.7.0/go.mod h1:yWOB1SBYBC5VeMP7gHvWumXLIWorT60ONWic61uBYv0= github.com/sirupsen/logrus v1.9.3 h1:dueUQJ1C2q9oE3F7wvmSGAaVtTmUizReu6fjN8uqzbQ= github.com/sirupsen/logrus v1.9.3/go.mod h1:naHLuLoDiP4jHNo9R0sCBMtWGeIprob74mVsIT4qYEQ= -github.com/skeema/knownhosts v1.2.2 h1:Iug2P4fLmDw9f41PB6thxUkNUkJzB5i+1/exaj40L3A= -github.com/skeema/knownhosts v1.2.2/go.mod h1:xYbVRSPxqBZFrdmDyMmsOs+uX1UZC3nTN3ThzgDxUwo= +github.com/skeema/knownhosts v1.3.1 h1:X2osQ+RAjK76shCbvhHHHVl3ZlgDm8apHEHFqRjnBY8= +github.com/skeema/knownhosts v1.3.1/go.mod h1:r7KTdC8l4uxWRyK2TpQZ/1o5HaSzh06ePQNxPwTcfiY= github.com/soheilhy/cmux v0.1.5 h1:jjzc5WVemNEDTLwv9tlmemhC73tI08BNOIGwBOo10Js= github.com/soheilhy/cmux v0.1.5/go.mod h1:T7TcVDs9LWfQgPlPsdngu6I6QIoyIFZDDC6sNE1GqG0= -github.com/spf13/cobra v1.9.1 h1:CXSaggrXdbHK9CF+8ywj8Amf7PBRmPCOJugH954Nnlo= -github.com/spf13/cobra v1.9.1/go.mod h1:nDyEzZ8ogv936Cinf6g1RU9MRY64Ir93oCnqb9wxYW0= -github.com/spf13/pflag v1.0.6 h1:jFzHGLGAlb3ruxLB8MhbI6A8+AQX/2eW4qeyNZXNp2o= -github.com/spf13/pflag v1.0.6/go.mod h1:McXfInJRrz4CZXVZOBLb0bTZqETkiAhM9Iw0y3An2Bg= +github.com/spf13/cobra v1.10.2 h1:DMTTonx5m65Ic0GOoRY2c16WCbHxOOw6xxezuLaBpcU= +github.com/spf13/cobra v1.10.2/go.mod h1:7C1pvHqHw5A4vrJfjNwvOdzYu0Gml16OCs2GRiTUUS4= +github.com/spf13/pflag v1.0.9 h1:9exaQaMOCwffKiiiYk6/BndUBv+iRViNW+4lEMi0PvY= +github.com/spf13/pflag v1.0.9/go.mod h1:McXfInJRrz4CZXVZOBLb0bTZqETkiAhM9Iw0y3An2Bg= github.com/stoewer/go-strcase v1.3.0 h1:g0eASXYtp+yvN9fK8sH94oCIk0fau9uV1/ZdJ0AVEzs= github.com/stoewer/go-strcase v1.3.0/go.mod h1:fAH5hQ5pehh+j3nZfvwdk2RgEgQjAoM8wodgtPmh1xo= github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= @@ -284,93 +310,82 @@ github.com/xiang90/probing v0.0.0-20221125231312-a49e3df8f510 h1:S2dVYn90KE98chq github.com/xiang90/probing v0.0.0-20221125231312-a49e3df8f510/go.mod h1:UETIi67q53MR2AWcXfiuqkDkRtnGDLqkBTpCHuJHxtU= github.com/yuin/goldmark v1.1.27/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= github.com/yuin/goldmark v1.2.1/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= -github.com/yuin/goldmark v1.4.13/go.mod h1:6yULJ656Px+3vBD8DxQVa3kxgyrAnzto9xy5taEt/CY= -go.etcd.io/bbolt v1.3.11 h1:yGEzV1wPz2yVCLsD8ZAiGHhHVlczyC9d1rP43/VCRJ0= -go.etcd.io/bbolt v1.3.11/go.mod h1:dksAq7YMXoljX0xu6VF5DMZGbhYYoLUalEiSySYAS4I= -go.etcd.io/etcd/api/v3 v3.5.21 h1:A6O2/JDb3tvHhiIz3xf9nJ7REHvtEFJJ3veW3FbCnS8= -go.etcd.io/etcd/api/v3 v3.5.21/go.mod h1:c3aH5wcvXv/9dqIw2Y810LDXJfhSYdHQ0vxmP3CCHVY= -go.etcd.io/etcd/client/pkg/v3 v3.5.21 h1:lPBu71Y7osQmzlflM9OfeIV2JlmpBjqBNlLtcoBqUTc= -go.etcd.io/etcd/client/pkg/v3 v3.5.21/go.mod h1:BgqT/IXPjK9NkeSDjbzwsHySX3yIle2+ndz28nVsjUs= -go.etcd.io/etcd/client/v2 v2.305.21 h1:eLiFfexc2mE+pTLz9WwnoEsX5JTTpLCYVivKkmVXIRA= -go.etcd.io/etcd/client/v2 v2.305.21/go.mod h1:OKkn4hlYNf43hpjEM3Ke3aRdUkhSl8xjKjSf8eCq2J8= -go.etcd.io/etcd/client/v3 v3.5.21 h1:T6b1Ow6fNjOLOtM0xSoKNQt1ASPCLWrF9XMHcH9pEyY= -go.etcd.io/etcd/client/v3 v3.5.21/go.mod h1:mFYy67IOqmbRf/kRUvsHixzo3iG+1OF2W2+jVIQRAnU= -go.etcd.io/etcd/pkg/v3 v3.5.21 h1:jUItxeKyrDuVuWhdh0HtjUANwyuzcb7/FAeUfABmQsk= -go.etcd.io/etcd/pkg/v3 v3.5.21/go.mod h1:wpZx8Egv1g4y+N7JAsqi2zoUiBIUWznLjqJbylDjWgU= -go.etcd.io/etcd/raft/v3 v3.5.21 h1:dOmE0mT55dIUsX77TKBLq+RgyumsQuYeiRQnW/ylugk= -go.etcd.io/etcd/raft/v3 v3.5.21/go.mod h1:fmcuY5R2SNkklU4+fKVBQi2biVp5vafMrWUEj4TJ4Cs= -go.etcd.io/etcd/server/v3 v3.5.21 h1:9w0/k12majtgarGmlMVuhwXRI2ob3/d1Ik3X5TKo0yU= -go.etcd.io/etcd/server/v3 v3.5.21/go.mod h1:G1mOzdwuzKT1VRL7SqRchli/qcFrtLBTAQ4lV20sXXo= +go.etcd.io/bbolt v1.4.3 h1:dEadXpI6G79deX5prL3QRNP6JB8UxVkqo4UPnHaNXJo= +go.etcd.io/bbolt v1.4.3/go.mod h1:tKQlpPaYCVFctUIgFKFnAlvbmB3tpy1vkTnDWohtc0E= +go.etcd.io/etcd/api/v3 v3.6.5 h1:pMMc42276sgR1j1raO/Qv3QI9Af/AuyQUW6CBAWuntA= +go.etcd.io/etcd/api/v3 v3.6.5/go.mod h1:ob0/oWA/UQQlT1BmaEkWQzI0sJ1M0Et0mMpaABxguOQ= +go.etcd.io/etcd/client/pkg/v3 v3.6.5 h1:Duz9fAzIZFhYWgRjp/FgNq2gO1jId9Yae/rLn3RrBP8= +go.etcd.io/etcd/client/pkg/v3 v3.6.5/go.mod h1:8Wx3eGRPiy0qOFMZT/hfvdos+DjEaPxdIDiCDUv/FQk= +go.etcd.io/etcd/client/v3 v3.6.5 h1:yRwZNFBx/35VKHTcLDeO7XVLbCBFbPi+XV4OC3QJf2U= +go.etcd.io/etcd/client/v3 v3.6.5/go.mod h1:ZqwG/7TAFZ0BJ0jXRPoJjKQJtbFo/9NIY8uoFFKcCyo= +go.etcd.io/etcd/pkg/v3 v3.6.5 h1:byxWB4AqIKI4SBmquZUG1WGtvMfMaorXFoCcFbVeoxM= +go.etcd.io/etcd/pkg/v3 v3.6.5/go.mod h1:uqrXrzmMIJDEy5j00bCqhVLzR5jEJIwDp5wTlLwPGOU= +go.etcd.io/etcd/server/v3 v3.6.5 h1:4RbUb1Bd4y1WkBHmuF+cZII83JNQMuNXzyjwigQ06y0= +go.etcd.io/etcd/server/v3 v3.6.5/go.mod h1:PLuhyVXz8WWRhzXDsl3A3zv/+aK9e4A9lpQkqawIaH0= +go.etcd.io/raft/v3 v3.6.0 h1:5NtvbDVYpnfZWcIHgGRk9DyzkBIXOi8j+DDp1IcnUWQ= +go.etcd.io/raft/v3 v3.6.0/go.mod h1:nLvLevg6+xrVtHUmVaTcTz603gQPHfh7kUAwV6YpfGo= go.opentelemetry.io/auto/sdk v1.2.1 h1:jXsnJ4Lmnqd11kwkBV2LgLoFMZKizbCi5fNZ/ipaZ64= go.opentelemetry.io/auto/sdk v1.2.1/go.mod h1:KRTj+aOaElaLi+wW1kO/DZRXwkF4C5xPbEe3ZiIhN7Y= go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.60.0 h1:x7wzEgXfnzJcHDwStJT+mxOz4etr2EcexjqhBvmoakw= go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.60.0/go.mod h1:rg+RlpR5dKwaS95IyyZqj5Wd4E13lk/msnTS0Xl9lJM= -go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.60.0 h1:sbiXRNDSWJOTobXh5HyQKjq6wUC5tNybqjIqDpAY4CU= -go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.60.0/go.mod h1:69uWxva0WgAA/4bu2Yy70SLDBwZXuQ6PbBpbsa5iZrQ= -go.opentelemetry.io/otel v1.38.0 h1:RkfdswUDRimDg0m2Az18RKOsnI8UDzppJAtj01/Ymk8= -go.opentelemetry.io/otel v1.38.0/go.mod h1:zcmtmQ1+YmQM9wrNsTGV/q/uyusom3P8RxwExxkZhjM= -go.opentelemetry.io/otel/exporters/otlp/otlptrace v1.35.0 h1:1fTNlAIJZGWLP5FVu0fikVry1IsiUnXjf7QFvoNN3Xw= -go.opentelemetry.io/otel/exporters/otlp/otlptrace v1.35.0/go.mod h1:zjPK58DtkqQFn+YUMbx0M2XV3QgKU0gS9LeGohREyK4= -go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc v1.35.0 h1:m639+BofXTvcY1q8CGs4ItwQarYtJPOWmVobfM1HpVI= -go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc v1.35.0/go.mod h1:LjReUci/F4BUyv+y4dwnq3h/26iNOeC3wAIqgvTIZVo= -go.opentelemetry.io/otel/metric v1.38.0 h1:Kl6lzIYGAh5M159u9NgiRkmoMKjvbsKtYRwgfrA6WpA= -go.opentelemetry.io/otel/metric v1.38.0/go.mod h1:kB5n/QoRM8YwmUahxvI3bO34eVtQf2i4utNVLr9gEmI= -go.opentelemetry.io/otel/sdk v1.38.0 h1:l48sr5YbNf2hpCUj/FoGhW9yDkl+Ma+LrVl8qaM5b+E= -go.opentelemetry.io/otel/sdk v1.38.0/go.mod h1:ghmNdGlVemJI3+ZB5iDEuk4bWA3GkTpW+DOoZMYBVVg= -go.opentelemetry.io/otel/sdk/metric v1.38.0 h1:aSH66iL0aZqo//xXzQLYozmWrXxyFkBJ6qT5wthqPoM= -go.opentelemetry.io/otel/sdk/metric v1.38.0/go.mod h1:dg9PBnW9XdQ1Hd6ZnRz689CbtrUp0wMMs9iPcgT9EZA= -go.opentelemetry.io/otel/trace v1.38.0 h1:Fxk5bKrDZJUH+AMyyIXGcFAPah0oRcT+LuNtJrmcNLE= -go.opentelemetry.io/otel/trace v1.38.0/go.mod h1:j1P9ivuFsTceSWe1oY+EeW3sc+Pp42sO++GHkg4wwhs= -go.opentelemetry.io/proto/otlp v1.5.0 h1:xJvq7gMzB31/d406fB8U5CBdyQGw4P399D1aQWU/3i4= -go.opentelemetry.io/proto/otlp v1.5.0/go.mod h1:keN8WnHxOy8PG0rQZjJJ5A2ebUoafqWp0eVQ4yIXvJ4= +go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.64.0 h1:ssfIgGNANqpVFCndZvcuyKbl0g+UAVcbBcqGkG28H0Y= +go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.64.0/go.mod h1:GQ/474YrbE4Jx8gZ4q5I4hrhUzM6UPzyrqJYV2AqPoQ= +go.opentelemetry.io/otel v1.39.0 h1:8yPrr/S0ND9QEfTfdP9V+SiwT4E0G7Y5MO7p85nis48= +go.opentelemetry.io/otel v1.39.0/go.mod h1:kLlFTywNWrFyEdH0oj2xK0bFYZtHRYUdv1NklR/tgc8= +go.opentelemetry.io/otel/exporters/otlp/otlptrace v1.39.0 h1:f0cb2XPmrqn4XMy9PNliTgRKJgS5WcL/u0/WRYGz4t0= +go.opentelemetry.io/otel/exporters/otlp/otlptrace v1.39.0/go.mod h1:vnakAaFckOMiMtOIhFI2MNH4FYrZzXCYxmb1LlhoGz8= +go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc v1.39.0 h1:in9O8ESIOlwJAEGTkkf34DesGRAc/Pn8qJ7k3r/42LM= +go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc v1.39.0/go.mod h1:Rp0EXBm5tfnv0WL+ARyO/PHBEaEAT8UUHQ6AGJcSq6c= +go.opentelemetry.io/otel/metric v1.39.0 h1:d1UzonvEZriVfpNKEVmHXbdf909uGTOQjA0HF0Ls5Q0= +go.opentelemetry.io/otel/metric v1.39.0/go.mod h1:jrZSWL33sD7bBxg1xjrqyDjnuzTUB0x1nBERXd7Ftcs= +go.opentelemetry.io/otel/sdk v1.39.0 h1:nMLYcjVsvdui1B/4FRkwjzoRVsMK8uL/cj0OyhKzt18= +go.opentelemetry.io/otel/sdk v1.39.0/go.mod h1:vDojkC4/jsTJsE+kh+LXYQlbL8CgrEcwmt1ENZszdJE= +go.opentelemetry.io/otel/sdk/metric v1.39.0 h1:cXMVVFVgsIf2YL6QkRF4Urbr/aMInf+2WKg+sEJTtB8= +go.opentelemetry.io/otel/sdk/metric v1.39.0/go.mod h1:xq9HEVH7qeX69/JnwEfp6fVq5wosJsY1mt4lLfYdVew= +go.opentelemetry.io/otel/trace v1.39.0 h1:2d2vfpEDmCJ5zVYz7ijaJdOF59xLomrvj7bjt6/qCJI= +go.opentelemetry.io/otel/trace v1.39.0/go.mod h1:88w4/PnZSazkGzz/w84VHpQafiU4EtqqlVdxWy+rNOA= +go.opentelemetry.io/proto/otlp v1.9.0 h1:l706jCMITVouPOqEnii2fIAuO3IVGBRPV5ICjceRb/A= +go.opentelemetry.io/proto/otlp v1.9.0/go.mod h1:xE+Cx5E/eEHw+ISFkwPLwCZefwVjY+pqKg1qcK03+/4= go.starlark.net v0.0.0-20250205221240-492d3672b3f4 h1:eBP+boBfJoGU3irqbxGTcTlKcbNwJCOdbmsnDq56nak= go.starlark.net v0.0.0-20250205221240-492d3672b3f4/go.mod h1:YKMCv9b1WrfWmeqdV5MAuEHWsu5iC+fe6kYl2sQjdI8= go.uber.org/goleak v1.3.0 h1:2K3zAYmnTNqV73imy9J1T3WC+gmCePx2hEGkimedGto= go.uber.org/goleak v1.3.0/go.mod h1:CoHD4mav9JJNrW/WLlf7HGZPjdw8EucARQHekz1X6bE= go.uber.org/multierr v1.11.0 h1:blXXJkSxSSfBVBlC76pxqeO+LN3aDfLQo+309xJstO0= go.uber.org/multierr v1.11.0/go.mod h1:20+QtiLqy0Nd6FdQB9TLXag12DsQkrbs3htMFfDN80Y= -go.uber.org/zap v1.27.0 h1:aJMhYGrd5QSmlpLMr2MftRKl7t8J8PTZPA732ud/XR8= -go.uber.org/zap v1.27.0/go.mod h1:GB2qFLM7cTU87MWRP2mPIjqfIDnGu+VIO4V/SdhGo2E= +go.uber.org/zap v1.27.1 h1:08RqriUEv8+ArZRYSTXy1LeBScaMpVSTBhCeaZYfMYc= +go.uber.org/zap v1.27.1/go.mod h1:GB2qFLM7cTU87MWRP2mPIjqfIDnGu+VIO4V/SdhGo2E= +go.yaml.in/yaml/v2 v2.4.3 h1:6gvOSjQoTB3vt1l+CU+tSyi/HOjfOjRLJ4YwYZGwRO0= +go.yaml.in/yaml/v2 v2.4.3/go.mod h1:zSxWcmIDjOzPXpjlTTbAsKokqkDNAVtZO0WOMiT90s8= +go.yaml.in/yaml/v3 v3.0.4 h1:tfq32ie2Jv2UxXFdLJdh3jXuOzWiL1fo0bu/FbuKpbc= +go.yaml.in/yaml/v3 v3.0.4/go.mod h1:DhzuOOF2ATzADvBadXxruRBLzYTpT36CKvDb3+aBEFg= go4.org/netipx v0.0.0-20231129151722-fdeea329fbba h1:0b9z3AuHCjxk0x/opv64kcgZLBseWJUpBw5I82+2U4M= go4.org/netipx v0.0.0-20231129151722-fdeea329fbba/go.mod h1:PLyyIXexvUFg3Owu6p/WfdlivPbZJsZdgWZlrGope/Y= golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w= golang.org/x/crypto v0.0.0-20191011191535-87dc89f01550/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= -golang.org/x/crypto v0.0.0-20210921155107-089bfa567519/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc= golang.org/x/crypto v0.0.0-20220622213112-05595931fe9d/go.mod h1:IxCIyHEi3zRg3s0A5j5BB6A9Jmi73HwBIUl50j+osU4= -golang.org/x/crypto v0.3.1-0.20221117191849-2c476679df9a/go.mod h1:hebNnKkNXi2UzZN1eVRvBB7co0a+JxK6XbPiWVs/3J4= -golang.org/x/crypto v0.7.0/go.mod h1:pYwdfH91IfpZVANVyUOhSIPZaFoJGxTFbZhFTx+dXZU= -golang.org/x/crypto v0.44.0 h1:A97SsFvM3AIwEEmTBiaxPPTYpDC47w720rdiiUvgoAU= -golang.org/x/crypto v0.44.0/go.mod h1:013i+Nw79BMiQiMsOPcVCB5ZIJbYkerPrGnOa00tvmc= -golang.org/x/exp v0.0.0-20250408133849-7e4ce0ab07d0 h1:R84qjqJb5nVJMxqWYb3np9L5ZsaDtB+a39EqjV0JSUM= -golang.org/x/exp v0.0.0-20250408133849-7e4ce0ab07d0/go.mod h1:S9Xr4PYopiDyqSyp5NjCrhFrqg6A5zA2E/iPHPhqnS8= +golang.org/x/crypto v0.46.0 h1:cKRW/pmt1pKAfetfu+RCEvjvZkA9RimPbh7bhFjGVBU= +golang.org/x/crypto v0.46.0/go.mod h1:Evb/oLKmMraqjZ2iQTwDwvCtJkczlDuTmdJXoZVzqU0= +golang.org/x/exp v0.0.0-20250808145144-a408d31f581a h1:Y+7uR/b1Mw2iSXZ3G//1haIiSElDQZ8KWh0h+sZPG90= +golang.org/x/exp v0.0.0-20250808145144-a408d31f581a/go.mod h1:rT6SFzZ7oxADUDx58pcaKFTcZ+inxAa9fTrYx/uVYwg= golang.org/x/mod v0.2.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= golang.org/x/mod v0.3.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= -golang.org/x/mod v0.6.0-dev.0.20220419223038-86c51ed26bb4/go.mod h1:jJ57K6gSWd91VN4djpZkiMVwK6gcyfeH4XE8wZrZaV4= -golang.org/x/mod v0.8.0/go.mod h1:iBbtSCu2XBx23ZKBPSOrRkjjQPZFPuis4dIYUhu/chs= -golang.org/x/mod v0.29.0 h1:HV8lRxZC4l2cr3Zq1LvtOsi/ThTgWnUk/y64QSs8GwA= -golang.org/x/mod v0.29.0/go.mod h1:NyhrlYXJ2H4eJiRy/WDBO6HMqZQ6q9nk4JzS3NuCK+w= +golang.org/x/mod v0.30.0 h1:fDEXFVZ/fmCKProc/yAXXUijritrDzahmwwefnjoPFk= +golang.org/x/mod v0.30.0/go.mod h1:lAsf5O2EvJeSFMiBxXDki7sCgAxEUcZHXoXMKT4GJKc= golang.org/x/net v0.0.0-20190404232315-eb5bcb51f2a3/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= golang.org/x/net v0.0.0-20190620200207-3b0461eec859/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20200226121028-0de0cce0169b/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20201021035429-f5854403a974/go.mod h1:sp8m0HH+o8qH0wwXwYZr8TS3Oi6o0r6Gce1SSxlDquU= -golang.org/x/net v0.0.0-20210226172049-e18ecbb05110/go.mod h1:m0MpNAwzfU5UDzcl9v0D8zg8gWTRqZa9RBIspLL5mdg= golang.org/x/net v0.0.0-20211112202133-69e39bad7dc2/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y= -golang.org/x/net v0.0.0-20220722155237-a158d28d115b/go.mod h1:XRhObCWvk6IyKnWLug+ECip1KBveYUHfp+8e9klMJ9c= -golang.org/x/net v0.2.0/go.mod h1:KqCZLdyyvdV855qA2rE3GC2aiw5xGR5TEjj8smXukLY= -golang.org/x/net v0.6.0/go.mod h1:2Tu9+aMcznHK/AK1HMvgo6xiTLG5rD5rZLDS+rp2Bjs= -golang.org/x/net v0.8.0/go.mod h1:QVkue5JL9kW//ek3r6jTKnTFis1tRmNAW2P1shuFdJc= -golang.org/x/net v0.47.0 h1:Mx+4dIFzqraBXUugkia1OOvlD6LemFo1ALMHjrXDOhY= -golang.org/x/net v0.47.0/go.mod h1:/jNxtkgq5yWUGYkaZGqo27cfGZ1c5Nen03aYrrKpVRU= -golang.org/x/oauth2 v0.32.0 h1:jsCblLleRMDrxMN29H3z/k1KliIvpLgCkE6R8FXXNgY= -golang.org/x/oauth2 v0.32.0/go.mod h1:lzm5WQJQwKZ3nwavOZ3IS5Aulzxi68dUSgRHujetwEA= +golang.org/x/net v0.48.0 h1:zyQRTTrjc33Lhh0fBgT/H3oZq9WuvRR5gPC70xpDiQU= +golang.org/x/net v0.48.0/go.mod h1:+ndRgGjkh8FGtu1w1FGbEC31if4VrNVMuKTgcAAnQRY= +golang.org/x/oauth2 v0.34.0 h1:hqK/t4AKgbqWkdkcAeI8XLmbK+4m4G5YeQRrmiotGlw= +golang.org/x/oauth2 v0.34.0/go.mod h1:lzm5WQJQwKZ3nwavOZ3IS5Aulzxi68dUSgRHujetwEA= golang.org/x/sync v0.0.0-20190423024810-112230192c58/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20190911185100-cd5d95a43a6e/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20201020160332-67f06af15bc9/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= -golang.org/x/sync v0.0.0-20220722155255-886fb9371eb4/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= -golang.org/x/sync v0.1.0/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= -golang.org/x/sync v0.18.0 h1:kr88TuHDroi+UVf+0hZnirlk8o8T+4MrK6mr60WkH/I= -golang.org/x/sync v0.18.0/go.mod h1:9KTHXmSnoGruLpwFjVSX0lNNA75CykiMECbovNTZqGI= +golang.org/x/sync v0.19.0 h1:vV+1eWNmZ5geRlYjzm2adRgW2/mcpevXNg50YZtPCE4= +golang.org/x/sync v0.19.0/go.mod h1:9KTHXmSnoGruLpwFjVSX0lNNA75CykiMECbovNTZqGI= golang.org/x/sys v0.0.0-20190130150945-aca44879d564/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20190412213103-97732733099d/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= @@ -380,43 +395,27 @@ golang.org/x/sys v0.0.0-20201119102817-f84b799fce68/go.mod h1:h1NjWce9XRLGQEsW7w golang.org/x/sys v0.0.0-20210124154548-22da62e12c0c/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210423082822-04245dca01da/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210615035016-665e8c7367d1/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20220520151302-bc2c85ada10a/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220715151400-c0bba94af5f8/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20220722155257-8c9f86f7a55f/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.2.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.3.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.5.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.6.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.38.0 h1:3yZWxaJjBmCWXqhN1qh02AkOnCQ1poK6oF+a7xWL6Gc= -golang.org/x/sys v0.38.0/go.mod h1:OgkHotnGiDImocRcuBABYBEXf8A9a87e/uXjp9XT3ks= +golang.org/x/sys v0.39.0 h1:CvCKL8MeisomCi6qNZ+wbb0DN9E5AATixKsvNtMoMFk= +golang.org/x/sys v0.39.0/go.mod h1:OgkHotnGiDImocRcuBABYBEXf8A9a87e/uXjp9XT3ks= golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo= -golang.org/x/term v0.0.0-20210927222741-03fcf44c2211/go.mod h1:jbD1KX2456YbFQfuXm/mYQcufACuNUgVhRMnK/tPxf8= -golang.org/x/term v0.2.0/go.mod h1:TVmDHMZPmdnySmBfhjOoOdhjzdE1h4u1VwSiw2l1Nuc= -golang.org/x/term v0.5.0/go.mod h1:jMB1sMXY+tzblOD4FWmEbocvup2/aLOaQEp7JmGp78k= -golang.org/x/term v0.6.0/go.mod h1:m6U89DPEgQRMq3DNkDClhWw02AUbt2daBVO4cn4Hv9U= -golang.org/x/term v0.37.0 h1:8EGAD0qCmHYZg6J17DvsMy9/wJ7/D/4pV/wfnld5lTU= -golang.org/x/term v0.37.0/go.mod h1:5pB4lxRNYYVZuTLmy8oR2BH8dflOR+IbTYFD8fi3254= +golang.org/x/term v0.38.0 h1:PQ5pkm/rLO6HnxFR7N2lJHOZX6Kez5Y1gDSJla6jo7Q= +golang.org/x/term v0.38.0/go.mod h1:bSEAKrOT1W+VSu9TSCMtoGEOUcKxOKgl3LE5QEF/xVg= golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.3/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= golang.org/x/text v0.3.6/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= -golang.org/x/text v0.3.7/go.mod h1:u+2+/6zg+i71rQMx5EYifcz6MCKuco9NR6JIITiCfzQ= -golang.org/x/text v0.4.0/go.mod h1:mrYo+phRRbMaCq/xk9113O4dZlRixOauAjOtrjsXDZ8= -golang.org/x/text v0.7.0/go.mod h1:mrYo+phRRbMaCq/xk9113O4dZlRixOauAjOtrjsXDZ8= -golang.org/x/text v0.8.0/go.mod h1:e1OnstbJyHTd6l/uOt8jFFHp6TRDWZR/bV3emEE/zU8= -golang.org/x/text v0.31.0 h1:aC8ghyu4JhP8VojJ2lEHBnochRno1sgL6nEi9WGFGMM= -golang.org/x/text v0.31.0/go.mod h1:tKRAlv61yKIjGGHX/4tP1LTbc13YSec1pxVEWXzfoeM= -golang.org/x/time v0.11.0 h1:/bpjEDfN9tkoN/ryeYHnv5hcMlc8ncjMcM4XBk5NWV0= -golang.org/x/time v0.11.0/go.mod h1:CDIdPxbZBQxdj6cxyCIdrNogrJKMJ7pr37NYpMcMDSg= +golang.org/x/text v0.32.0 h1:ZD01bjUt1FQ9WJ0ClOL5vxgxOI/sVCNgX1YtKwcY0mU= +golang.org/x/text v0.32.0/go.mod h1:o/rUWzghvpD5TXrTIBuJU77MTaN0ljMWE47kxGJQ7jY= +golang.org/x/time v0.14.0 h1:MRx4UaLrDotUKUdCIqzPC48t1Y9hANFKIRpNx+Te8PI= +golang.org/x/time v0.14.0/go.mod h1:eL/Oa2bBBK0TkX57Fyni+NgnyQQN4LitPmob2Hjnqw4= golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= golang.org/x/tools v0.0.0-20191119224855-298f0cb1881e/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= golang.org/x/tools v0.0.0-20200619180055-7c47624df98f/go.mod h1:EkVYQZoAsY45+roYkvgYkIh4xh/qjgUK9TdY2XT94GE= golang.org/x/tools v0.0.0-20210106214847-113979e3529a/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA= -golang.org/x/tools v0.1.12/go.mod h1:hNGJHUnrk76NpqgfD5Aqm5Crs+Hm0VOH/i9J2+nxYbc= -golang.org/x/tools v0.6.0/go.mod h1:Xwgl3UAJ/d3gWutnCtw505GrjyAbvKui8lOU390QaIU= -golang.org/x/tools v0.38.0 h1:Hx2Xv8hISq8Lm16jvBZ2VQf+RLmbd7wVUsALibYI/IQ= -golang.org/x/tools v0.38.0/go.mod h1:yEsQ/d/YK8cjh0L6rZlY8tgtlKiBNTL14pGDJPJpYQs= -golang.org/x/tools/go/expect v0.1.0-deprecated h1:jY2C5HGYR5lqex3gEniOQL0r7Dq5+VGVgY1nudX5lXY= -golang.org/x/tools/go/expect v0.1.0-deprecated/go.mod h1:eihoPOH+FgIqa3FpoTwguz/bVUSGBlGQU67vpBeOrBY= +golang.org/x/tools v0.39.0 h1:ik4ho21kwuQln40uelmciQPp9SipgNDdrafrYA4TmQQ= +golang.org/x/tools v0.39.0/go.mod h1:JnefbkDPyD8UU2kI5fuf8ZX4/yUeh9W877ZeBONxUqQ= +golang.org/x/tools/go/expect v0.1.1-deprecated h1:jpBZDwmgPhXsKZC6WhL20P4b/wmnpsEAGHaNy0n/rJM= +golang.org/x/tools/go/expect v0.1.1-deprecated/go.mod h1:eihoPOH+FgIqa3FpoTwguz/bVUSGBlGQU67vpBeOrBY= golang.org/x/tools/go/packages/packagestest v0.1.1-deprecated h1:1h2MnaIAIXISqTFKdENegdpAgUXz6NrPEsbIeWaBRvM= golang.org/x/tools/go/packages/packagestest v0.1.1-deprecated/go.mod h1:RVAQXBGNv1ib0J382/DPCRS/BPnsGebyM1Gj5VSDpG8= golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= @@ -427,22 +426,20 @@ gomodules.xyz/jsonpatch/v2 v2.4.0 h1:Ci3iUJyx9UeRx7CeFN8ARgGbkESwJK+KB9lLcWxY/Zw gomodules.xyz/jsonpatch/v2 v2.4.0/go.mod h1:AH3dM2RI6uoBZxn3LVrfvJ3E0/9dG4cSrbuBJT4moAY= gonum.org/v1/gonum v0.16.0 h1:5+ul4Swaf3ESvrOnidPp4GZbzf0mxVQpDCYUQE7OJfk= gonum.org/v1/gonum v0.16.0/go.mod h1:fef3am4MQ93R2HHpKnLk4/Tbh/s0+wqD5nfa6Pnwy4E= -google.golang.org/genproto v0.0.0-20241118233622-e639e219e697 h1:ToEetK57OidYuqD4Q5w+vfEnPvPpuTwedCNVohYJfNk= -google.golang.org/genproto v0.0.0-20241118233622-e639e219e697/go.mod h1:JJrvXBWRZaFMxBufik1a4RpFw4HhgVtBBWQeQgUj2cc= -google.golang.org/genproto/googleapis/api v0.0.0-20251029180050-ab9386a59fda h1:+2XxjfsAu6vqFxwGBRcHiMaDCuZiqXGDUDVWVtrFAnE= -google.golang.org/genproto/googleapis/api v0.0.0-20251029180050-ab9386a59fda/go.mod h1:fDMmzKV90WSg1NbozdqrE64fkuTv6mlq2zxo9ad+3yo= -google.golang.org/genproto/googleapis/rpc v0.0.0-20251029180050-ab9386a59fda h1:i/Q+bfisr7gq6feoJnS/DlpdwEL4ihp41fvRiM3Ork0= -google.golang.org/genproto/googleapis/rpc v0.0.0-20251029180050-ab9386a59fda/go.mod h1:7i2o+ce6H/6BluujYR+kqX3GKH+dChPTQU19wjRPiGk= -google.golang.org/grpc v1.78.0 h1:K1XZG/yGDJnzMdd/uZHAkVqJE+xIDOcmdSFZkBUicNc= -google.golang.org/grpc v1.78.0/go.mod h1:I47qjTo4OKbMkjA/aOOwxDIiPSBofUtQUI5EfpWvW7U= +google.golang.org/genproto/googleapis/api v0.0.0-20251213004720-97cd9d5aeac2 h1:7LRqPCEdE4TP4/9psdaB7F2nhZFfBiGJomA5sojLWdU= +google.golang.org/genproto/googleapis/api v0.0.0-20251213004720-97cd9d5aeac2/go.mod h1:+rXWjjaukWZun3mLfjmVnQi18E1AsFbDN9QdJ5YXLto= +google.golang.org/genproto/googleapis/rpc v0.0.0-20251202230838-ff82c1b0f217 h1:gRkg/vSppuSQoDjxyiGfN4Upv/h/DQmIR10ZU8dh4Ww= +google.golang.org/genproto/googleapis/rpc v0.0.0-20251202230838-ff82c1b0f217/go.mod h1:7i2o+ce6H/6BluujYR+kqX3GKH+dChPTQU19wjRPiGk= +google.golang.org/grpc v1.79.1 h1:zGhSi45ODB9/p3VAawt9a+O/MULLl9dpizzNNpq7flY= +google.golang.org/grpc v1.79.1/go.mod h1:KmT0Kjez+0dde/v2j9vzwoAScgEPx/Bw1CYChhHLrHQ= google.golang.org/protobuf v1.36.11 h1:fV6ZwhNocDyBLK0dj+fg8ektcVegBBuEolpbTQyBNVE= google.golang.org/protobuf v1.36.11/go.mod h1:HTf+CrKn2C3g5S8VImy6tdcUvCska2kB7j23XfzDpco= gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= gopkg.in/check.v1 v1.0.0-20190902080502-41f04d3bba15/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c h1:Hei/4ADfdWqJk1ZMxUNpqntNwaWcugrBjAiHlqqRiVk= gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c/go.mod h1:JHkPIbrfpd72SG/EVd6muEfDQjcINNoR0C8j2r3qZ4Q= -gopkg.in/evanphx/json-patch.v4 v4.12.0 h1:n6jtcsulIzXPJaxegRbvFNNrZDjbij7ny3gmSPG+6V4= -gopkg.in/evanphx/json-patch.v4 v4.12.0/go.mod h1:p8EYWUEYMpynmqDbY58zCKCFZw8pRWMG4EsWvDvM72M= +gopkg.in/evanphx/json-patch.v4 v4.13.0 h1:czT3CmqEaQ1aanPc5SdlgQrrEIb8w/wwCvWWnfEbYzo= +gopkg.in/evanphx/json-patch.v4 v4.13.0/go.mod h1:p8EYWUEYMpynmqDbY58zCKCFZw8pRWMG4EsWvDvM72M= gopkg.in/inf.v0 v0.9.1 h1:73M5CoZyi3ZLMOyDlQh031Cx6N9NDJ2Vvfl76EDAgDc= gopkg.in/inf.v0 v0.9.1/go.mod h1:cWUDdTG/fYaXco+Dcufb5Vnc6Gp2YChqWtbxRZE0mXw= gopkg.in/natefinch/lumberjack.v2 v2.2.1 h1:bBRl1b0OH9s/DuPhuXpNl+VtCaJXFZ5/uEFST95x9zc= @@ -452,45 +449,43 @@ gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7/go.mod h1:dt/ZhP58zS4L8KSrWD gopkg.in/warnings.v0 v0.1.2 h1:wFXVbFY8DY5/xOe1ECiWdKCzZlxgshcYVNkBHstARME= gopkg.in/warnings.v0 v0.1.2/go.mod h1:jksf8JmL6Qr/oQM2OXTHunEvvTAsrWBLb6OOjuVWRNI= gopkg.in/yaml.v2 v2.2.2/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= -gopkg.in/yaml.v2 v2.4.0 h1:D8xgwECY7CYvx+Y2n4sBz93Jn9JRvxdiyyo8CTfuKaY= gopkg.in/yaml.v2 v2.4.0/go.mod h1:RDklbk79AGWmwhnvt/jBztapEOGDOx6ZbXqjP6csGnQ= gopkg.in/yaml.v3 v3.0.0-20200313102051-9f266ea9e77c/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= gopkg.in/yaml.v3 v3.0.1 h1:fxVm/GzAzEWqLHuvctI91KS9hhNmmWOoWu0XTYJS7CA= gopkg.in/yaml.v3 v3.0.1/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= -k8s.io/api v0.33.2 h1:YgwIS5jKfA+BZg//OQhkJNIfie/kmRsO0BmNaVSimvY= -k8s.io/api v0.33.2/go.mod h1:fhrbphQJSM2cXzCWgqU29xLDuks4mu7ti9vveEnpSXs= -k8s.io/apiextensions-apiserver v0.32.1 h1:hjkALhRUeCariC8DiVmb5jj0VjIc1N0DREP32+6UXZw= -k8s.io/apiextensions-apiserver v0.32.1/go.mod h1:sxWIGuGiYov7Io1fAS2X06NjMIk5CbRHc2StSmbaQto= -k8s.io/apimachinery v0.33.2 h1:IHFVhqg59mb8PJWTLi8m1mAoepkUNYmptHsV+Z1m5jY= -k8s.io/apimachinery v0.33.2/go.mod h1:BHW0YOu7n22fFv/JkYOEfkUYNRN0fj0BlvMFWA7b+SM= -k8s.io/apiserver v0.33.0 h1:QqcM6c+qEEjkOODHppFXRiw/cE2zP85704YrQ9YaBbc= -k8s.io/apiserver v0.33.0/go.mod h1:EixYOit0YTxt8zrO2kBU7ixAtxFce9gKGq367nFmqI8= -k8s.io/client-go v0.33.1 h1:ZZV/Ks2g92cyxWkRRnfUDsnhNn28eFpt26aGc8KbXF4= -k8s.io/client-go v0.33.1/go.mod h1:JAsUrl1ArO7uRVFWfcj6kOomSlCv+JpvIsp6usAGefA= -k8s.io/code-generator v0.33.1 h1:ZLzIRdMsh3Myfnx9BaooX6iQry29UJjVfVG+BuS+UMw= -k8s.io/code-generator v0.33.1/go.mod h1:HUKT7Ubp6bOgIbbaPIs9lpd2Q02uqkMCMx9/GjDrWpY= -k8s.io/component-base v0.33.1 h1:EoJ0xA+wr77T+G8p6T3l4efT2oNwbqBVKR71E0tBIaI= -k8s.io/component-base v0.33.1/go.mod h1:guT/w/6piyPfTgq7gfvgetyXMIh10zuXA6cRRm3rDuY= -k8s.io/gengo/v2 v2.0.0-20250207200755-1244d31929d7 h1:2OX19X59HxDprNCVrWi6jb7LW1PoqTlYqEq5H2oetog= -k8s.io/gengo/v2 v2.0.0-20250207200755-1244d31929d7/go.mod h1:EJykeLsmFC60UQbYJezXkEsG2FLrt0GPNkU5iK5GWxU= +k8s.io/api v0.35.1 h1:0PO/1FhlK/EQNVK5+txc4FuhQibV25VLSdLMmGpDE/Q= +k8s.io/api v0.35.1/go.mod h1:28uR9xlXWml9eT0uaGo6y71xK86JBELShLy4wR1XtxM= +k8s.io/apiextensions-apiserver v0.35.0 h1:3xHk2rTOdWXXJM+RDQZJvdx0yEOgC0FgQ1PlJatA5T4= +k8s.io/apiextensions-apiserver v0.35.0/go.mod h1:E1Ahk9SADaLQ4qtzYFkwUqusXTcaV2uw3l14aqpL2LU= +k8s.io/apimachinery v0.35.1 h1:yxO6gV555P1YV0SANtnTjXYfiivaTPvCTKX6w6qdDsU= +k8s.io/apimachinery v0.35.1/go.mod h1:jQCgFZFR1F4Ik7hvr2g84RTJSZegBc8yHgFWKn//hns= +k8s.io/apiserver v0.35.1 h1:potxdhhTL4i6AYAa2QCwtlhtB1eCdWQFvJV6fXgJzxs= +k8s.io/apiserver v0.35.1/go.mod h1:BiL6Dd3A2I/0lBnteXfWmCFobHM39vt5+hJQd7Lbpi4= +k8s.io/client-go v0.35.1 h1:+eSfZHwuo/I19PaSxqumjqZ9l5XiTEKbIaJ+j1wLcLM= +k8s.io/client-go v0.35.1/go.mod h1:1p1KxDt3a0ruRfc/pG4qT/3oHmUj1AhSHEcxNSGg+OA= +k8s.io/code-generator v0.35.1 h1:yLKR2la7Z9cWT5qmk67ayx8xXLM4RRKQMnC8YPvTWRI= +k8s.io/code-generator v0.35.1/go.mod h1:F2Fhm7aA69tC/VkMXLDokdovltXEF026Tb9yfQXQWKg= +k8s.io/component-base v0.35.1 h1:XgvpRf4srp037QWfGBLFsYMUQJkE5yMa94UsJU7pmcE= +k8s.io/component-base v0.35.1/go.mod h1:HI/6jXlwkiOL5zL9bqA3en1Ygv60F03oEpnuU1G56Bs= +k8s.io/gengo/v2 v2.0.0-20250922181213-ec3ebc5fd46b h1:gMplByicHV/TJBizHd9aVEsTYoJBnnUAT5MHlTkbjhQ= +k8s.io/gengo/v2 v2.0.0-20250922181213-ec3ebc5fd46b/go.mod h1:CgujABENc3KuTrcsdpGmrrASjtQsWCT7R99mEV4U/fM= k8s.io/klog/v2 v2.130.1 h1:n9Xl7H1Xvksem4KFG4PYbdQCQxqc/tTUyrgXaOhHSzk= k8s.io/klog/v2 v2.130.1/go.mod h1:3Jpz1GvMt720eyJH1ckRHK1EDfpxISzJ7I9OYgaDtPE= -k8s.io/kms v0.33.0 h1:fhQSW/vyaWDhMp0vDuO/sLg2RlGZf4F77beSXcB4/eE= -k8s.io/kms v0.33.0/go.mod h1:C1I8mjFFBNzfUZXYt9FZVJ8MJl7ynFbGgZFbBzkBJ3E= -k8s.io/kube-openapi v0.0.0-20250318190949-c8a335a9a2ff h1:/usPimJzUKKu+m+TE36gUyGcf03XZEP0ZIKgKj35LS4= -k8s.io/kube-openapi v0.0.0-20250318190949-c8a335a9a2ff/go.mod h1:5jIi+8yX4RIb8wk3XwBo5Pq2ccx4FP10ohkbSKCZoK8= -k8s.io/utils v0.0.0-20250321185631-1f6e0b77f77e h1:KqK5c/ghOm8xkHYhlodbp6i6+r+ChV2vuAuVRdFbLro= -k8s.io/utils v0.0.0-20250321185631-1f6e0b77f77e/go.mod h1:OLgZIPagt7ERELqWJFomSt595RzquPNLL48iOWgYOg0= +k8s.io/kms v0.35.1 h1:kjv2r9g1mY7uL+l1RhyAZvWVZIA/4qIfBHXyjFGLRhU= +k8s.io/kms v0.35.1/go.mod h1:VT+4ekZAdrZDMgShK37vvlyHUVhwI9t/9tvh0AyCWmQ= +k8s.io/kube-openapi v0.0.0-20250910181357-589584f1c912 h1:Y3gxNAuB0OBLImH611+UDZcmKS3g6CthxToOb37KgwE= +k8s.io/kube-openapi v0.0.0-20250910181357-589584f1c912/go.mod h1:kdmbQkyfwUagLfXIad1y2TdrjPFWp2Q89B3qkRwf/pQ= +k8s.io/utils v0.0.0-20251002143259-bc988d571ff4 h1:SjGebBtkBqHFOli+05xYbK8YF1Dzkbzn+gDM4X9T4Ck= +k8s.io/utils v0.0.0-20251002143259-bc988d571ff4/go.mod h1:OLgZIPagt7ERELqWJFomSt595RzquPNLL48iOWgYOg0= sigs.k8s.io/apiserver-network-proxy/konnectivity-client v0.32.0 h1:XotDXzqvJ8Nx5eiZZueLpTuafJz8SiodgOemI+w87QU= sigs.k8s.io/apiserver-network-proxy/konnectivity-client v0.32.0/go.mod h1:Ve9uj1L+deCXFrPOk1LpFXqTg7LCFzFso6PA48q/XZw= -sigs.k8s.io/controller-runtime v0.20.4 h1:X3c+Odnxz+iPTRobG4tp092+CvBU9UK0t/bRf+n0DGU= -sigs.k8s.io/controller-runtime v0.20.4/go.mod h1:xg2XB0K5ShQzAgsoujxuKN4LNXR2LfwwHsPj7Iaw+XY= -sigs.k8s.io/json v0.0.0-20241014173422-cfa47c3a1cc8 h1:gBQPwqORJ8d8/YNZWEjoZs7npUVDpVXUUOFfW6CgAqE= -sigs.k8s.io/json v0.0.0-20241014173422-cfa47c3a1cc8/go.mod h1:mdzfpAEoE6DHQEN0uh9ZbOCuHbLK5wOm7dK4ctXE9Tg= -sigs.k8s.io/randfill v0.0.0-20250304075658-069ef1bbf016/go.mod h1:XeLlZ/jmk4i1HRopwe7/aU3H5n1zNUcX6TM94b3QxOY= +sigs.k8s.io/controller-runtime v0.23.1 h1:TjJSM80Nf43Mg21+RCy3J70aj/W6KyvDtOlpKf+PupE= +sigs.k8s.io/controller-runtime v0.23.1/go.mod h1:B6COOxKptp+YaUT5q4l6LqUJTRpizbgf9KSRNdQGns0= +sigs.k8s.io/json v0.0.0-20250730193827-2d320260d730 h1:IpInykpT6ceI+QxKBbEflcR5EXP7sU1kvOlxwZh5txg= +sigs.k8s.io/json v0.0.0-20250730193827-2d320260d730/go.mod h1:mdzfpAEoE6DHQEN0uh9ZbOCuHbLK5wOm7dK4ctXE9Tg= sigs.k8s.io/randfill v1.0.0 h1:JfjMILfT8A6RbawdsK2JXGBR5AQVfd+9TbzrlneTyrU= sigs.k8s.io/randfill v1.0.0/go.mod h1:XeLlZ/jmk4i1HRopwe7/aU3H5n1zNUcX6TM94b3QxOY= -sigs.k8s.io/structured-merge-diff/v4 v4.7.0 h1:qPeWmscJcXP0snki5IYF79Z8xrl8ETFxgMd7wez1XkI= -sigs.k8s.io/structured-merge-diff/v4 v4.7.0/go.mod h1:dDy58f92j70zLsuZVuUX5Wp9vtxXpaZnkPGWeqDfCps= -sigs.k8s.io/yaml v1.4.0 h1:Mk1wCc2gy/F0THH0TAp1QYyJNzRm2KCLy3o5ASXVI5E= -sigs.k8s.io/yaml v1.4.0/go.mod h1:Ejl7/uTz7PSA4eKMyQCUTnhZYNmLIl+5c2lQPGR2BPY= +sigs.k8s.io/structured-merge-diff/v6 v6.3.2 h1:kwVWMx5yS1CrnFWA/2QHyRVJ8jM6dBA80uLmm0wJkk8= +sigs.k8s.io/structured-merge-diff/v6 v6.3.2/go.mod h1:M3W8sfWvn2HhQDIbGWj3S099YozAsymCo/wrT5ohRUE= +sigs.k8s.io/yaml v1.6.0 h1:G8fkbMSAFqgEFgh4b1wmtzDnioxFCUgTZhlbj5P9QYs= +sigs.k8s.io/yaml v1.6.0/go.mod h1:796bPqUfzR/0jLAl6XjHl3Ck7MiyVv8dbTdyT3/pMf4= diff --git a/pkg/reconcilers/resource/fake.go b/pkg/reconcilers/resource/fake.go index d9cb9e85..d0049e63 100644 --- a/pkg/reconcilers/resource/fake.go +++ b/pkg/reconcilers/resource/fake.go @@ -33,6 +33,9 @@ type MockGetFn func(ctx context.Context, key client.ObjectKey, obj client.Object // A MockListFn is used to mock client.Client's List implementation. type MockListFn func(ctx context.Context, list client.ObjectList, opts ...client.ListOption) error +// A MockApplyFn is used to mock client.Client's Apply implementation. +type MockApplyFn func(ctx context.Context, cfg runtime.ApplyConfiguration, opts ...client.ApplyOption) error + // A MockCreateFn is used to mock client.Client's Create implementation. type MockCreateFn func(ctx context.Context, obj client.Object, opts ...client.CreateOption) error @@ -60,6 +63,9 @@ type MockSubResourceUpdateFn func(ctx context.Context, obj client.Object, opts . // A MockSubResourcePatchFn is used to mock client.SubResourceClient's patch implementation. type MockSubResourcePatchFn func(ctx context.Context, obj client.Object, patch client.Patch, opts ...client.SubResourcePatchOption) error +// A MockSubResourceApplyFn is used to mock client.SubResourceClient's apply implementation. +type MockSubResourceApplyFn func(ctx context.Context, cfg runtime.ApplyConfiguration, opts ...client.SubResourceApplyOption) error + // A MockSchemeFn is used to mock client.Client's Scheme implementation. type MockSchemeFn func() *runtime.Scheme @@ -71,6 +77,21 @@ type ObjectFn func(obj client.Object) error // ObjectListFn to test or update the contents of an ObjectList. type ObjectListFn func(obj client.ObjectList) error +// An ApplyConfigurationFn operates on the supplied ApplyConfiguration. +type ApplyConfigurationFn func(cfg runtime.ApplyConfiguration) error + +// NewMockApplyFn returns a MockApplyFn that returns the supplied error. +func NewMockApplyFn(err error, afn ...ApplyConfigurationFn) MockApplyFn { + return func(_ context.Context, cfg runtime.ApplyConfiguration, _ ...client.ApplyOption) error { + for _, fn := range afn { + if err := fn(cfg); err != nil { + return err + } + } + return err + } +} + // NewMockGetFn returns a MockGetFn that returns the supplied error. func NewMockGetFn(err error, ofn ...ObjectFn) MockGetFn { return func(_ context.Context, _ client.ObjectKey, obj client.Object) error { @@ -191,6 +212,18 @@ func NewMockSubResourcePatchFn(err error, ofn ...ObjectFn) MockSubResourcePatchF } } +// NewMockSubResourceApplyFn returns a MockSubResourceApplyFn that returns the supplied error. +func NewMockSubResourceApplyFn(err error, afn ...ApplyConfigurationFn) MockSubResourceApplyFn { + return func(_ context.Context, cfg runtime.ApplyConfiguration, _ ...client.SubResourceApplyOption) error { + for _, fn := range afn { + if err := fn(cfg); err != nil { + return err + } + } + return err + } +} + // NewMockSchemeFn returns a MockSchemeFn that returns the scheme func NewMockSchemeFn(scheme *runtime.Scheme) MockSchemeFn { return func() *runtime.Scheme { @@ -205,6 +238,7 @@ func NewMockSchemeFn(scheme *runtime.Scheme) MockSchemeFn { type MockClient struct { MockGet MockGetFn MockList MockListFn + MockApply MockApplyFn MockCreate MockCreateFn MockDelete MockDeleteFn MockDeleteAllOf MockDeleteAllOfFn @@ -214,11 +248,13 @@ type MockClient struct { MockStatusCreate MockSubResourceCreateFn MockStatusUpdate MockSubResourceUpdateFn MockStatusPatch MockSubResourcePatchFn + MockStatusApply MockSubResourceApplyFn MockSubResourceGet MockSubResourceGetFn MockSubResourceCreate MockSubResourceCreateFn MockSubResourceUpdate MockSubResourceUpdateFn MockSubResourcePatch MockSubResourcePatchFn + MockSubResourceApply MockSubResourceApplyFn MockScheme MockSchemeFn } @@ -229,19 +265,33 @@ func NewMockClient() *MockClient { return &MockClient{ MockGet: NewMockGetFn(nil), MockList: NewMockListFn(nil), + MockApply: NewMockApplyFn(nil), MockCreate: NewMockCreateFn(nil), MockDelete: NewMockDeleteFn(nil), MockDeleteAllOf: NewMockDeleteAllOfFn(nil), MockUpdate: NewMockUpdateFn(nil), MockPatch: NewMockPatchFn(nil), + MockStatusCreate: NewMockSubResourceCreateFn(nil), MockStatusUpdate: NewMockSubResourceUpdateFn(nil), MockStatusPatch: NewMockSubResourcePatchFn(nil), + MockStatusApply: NewMockSubResourceApplyFn(nil), + + MockSubResourceGet: nil, // Initialize to nil as it's optional + MockSubResourceCreate: NewMockSubResourceCreateFn(nil), + MockSubResourceUpdate: NewMockSubResourceUpdateFn(nil), + MockSubResourcePatch: NewMockSubResourcePatchFn(nil), + MockSubResourceApply: NewMockSubResourceApplyFn(nil), MockScheme: NewMockSchemeFn(nil), } } +// Apply calls MockClient's MockApply function. +func (c *MockClient) Apply(ctx context.Context, cfg runtime.ApplyConfiguration, opts ...client.ApplyOption) error { + return c.MockApply(ctx, cfg, opts...) +} + // Get calls MockClient's MockGet function. func (c *MockClient) Get(ctx context.Context, key client.ObjectKey, obj client.Object, _ ...client.GetOption) error { return c.MockGet(ctx, key, obj) @@ -283,16 +333,18 @@ func (c *MockClient) Status() client.SubResourceWriter { MockCreate: c.MockStatusCreate, MockUpdate: c.MockStatusUpdate, MockPatch: c.MockStatusPatch, + MockApply: c.MockStatusApply, } } -// SubResource is unimplemented. It panics if called. -func (c *MockClient) SubResource(_ string) client.SubResourceClient { +// SubResource returns a client for the specified subresource +func (c *MockClient) SubResource(subResource string) client.SubResourceClient { return &MockSubResourceClient{ MockGet: c.MockSubResourceGet, MockCreate: c.MockSubResourceCreate, MockUpdate: c.MockSubResourceUpdate, MockPatch: c.MockSubResourcePatch, + MockApply: c.MockSubResourceApply, } } @@ -314,16 +366,20 @@ func (c *MockClient) IsObjectNamespaced(obj runtime.Object) (bool, error) { return false, nil } -// MockSubResourceClient provides mock functionality for status sub-resource +// MockSubResourceClient provides mock functionality for sub-resources type MockSubResourceClient struct { MockGet MockSubResourceGetFn MockCreate MockSubResourceCreateFn MockUpdate MockSubResourceUpdateFn MockPatch MockSubResourcePatchFn + MockApply MockSubResourceApplyFn } // Get a sub-resource func (m *MockSubResourceClient) Get(ctx context.Context, obj, subResource client.Object, opts ...client.SubResourceGetOption) error { + if m.MockGet == nil { + return nil + } return m.MockGet(ctx, obj, subResource, opts...) } @@ -341,3 +397,8 @@ func (m *MockSubResourceClient) Update(ctx context.Context, obj client.Object, o func (m *MockSubResourceClient) Patch(ctx context.Context, obj client.Object, patch client.Patch, opts ...client.SubResourcePatchOption) error { return m.MockPatch(ctx, obj, patch, opts...) } + +// Apply a sub-resource +func (m *MockSubResourceClient) Apply(ctx context.Context, cfg runtime.ApplyConfiguration, opts ...client.SubResourceApplyOption) error { + return m.MockApply(ctx, cfg, opts...) +} \ No newline at end of file diff --git a/pkg/registry/configblame/strategy_resource.go b/pkg/registry/configblame/strategy_resource.go index ac54c1c2..c09594f0 100644 --- a/pkg/registry/configblame/strategy_resource.go +++ b/pkg/registry/configblame/strategy_resource.go @@ -39,7 +39,7 @@ import ( genericapirequest "k8s.io/apiserver/pkg/endpoints/request" "k8s.io/apiserver/pkg/storage/names" "sigs.k8s.io/controller-runtime/pkg/client" - "sigs.k8s.io/structured-merge-diff/v4/fieldpath" + "sigs.k8s.io/structured-merge-diff/v6/fieldpath" dsclient "github.com/sdcio/config-server/pkg/sdc/dataserver/client" sdcpb "github.com/sdcio/sdc-protos/sdcpb" "google.golang.org/protobuf/encoding/protojson" diff --git a/pkg/registry/generic/strategy_resource.go b/pkg/registry/generic/strategy_resource.go index 49ec8e97..04526560 100644 --- a/pkg/registry/generic/strategy_resource.go +++ b/pkg/registry/generic/strategy_resource.go @@ -36,7 +36,7 @@ import ( "k8s.io/apimachinery/pkg/util/validation/field" "k8s.io/apimachinery/pkg/watch" "k8s.io/apiserver/pkg/storage/names" - "sigs.k8s.io/structured-merge-diff/v4/fieldpath" + "sigs.k8s.io/structured-merge-diff/v6/fieldpath" ) // NewStrategy creates and returns a strategy instance diff --git a/pkg/registry/generic/strategy_status.go b/pkg/registry/generic/strategy_status.go index e1d6c354..d809b296 100644 --- a/pkg/registry/generic/strategy_status.go +++ b/pkg/registry/generic/strategy_status.go @@ -33,7 +33,7 @@ import ( "k8s.io/apimachinery/pkg/util/validation/field" "k8s.io/apimachinery/pkg/watch" "k8s.io/apiserver/pkg/storage/names" - "sigs.k8s.io/structured-merge-diff/v4/fieldpath" + "sigs.k8s.io/structured-merge-diff/v6/fieldpath" ) // NewStatusStrategy creates and returns a sttaus strategy instance diff --git a/pkg/registry/runningconfig/strategy_resource.go b/pkg/registry/runningconfig/strategy_resource.go index 8851f76f..d345de36 100644 --- a/pkg/registry/runningconfig/strategy_resource.go +++ b/pkg/registry/runningconfig/strategy_resource.go @@ -42,7 +42,7 @@ import ( genericapirequest "k8s.io/apiserver/pkg/endpoints/request" "k8s.io/apiserver/pkg/storage/names" "sigs.k8s.io/controller-runtime/pkg/client" - "sigs.k8s.io/structured-merge-diff/v4/fieldpath" + "sigs.k8s.io/structured-merge-diff/v6/fieldpath" ) // NewStrategy creates and returns a strategy instance diff --git a/pkg/registry/store/store.go b/pkg/registry/store/store.go index eba3c196..2f005204 100644 --- a/pkg/registry/store/store.go +++ b/pkg/registry/store/store.go @@ -56,11 +56,11 @@ func CreateFileStore(scheme *runtime.Scheme, obj resource.Object, prefix string) return nil, err } - return file.NewStore(&storebackend.Config[runtime.Object]{ - GroupResource: gr, - Prefix: prefix, - Codec: codec, - NewFunc: obj.New, + return file.NewStore[runtime.Object](&storebackend.Config{ + GroupResource: gr, + Prefix: prefix, + Codec: codec, + NewFunc: obj.New, }) } @@ -76,7 +76,7 @@ func CreateKVStore(db *badger.DB, scheme *runtime.Scheme, obj resource.Object) ( if err != nil { return nil, err } - return badgerdb.NewStore(db, &storebackend.Config[runtime.Object]{ + return badgerdb.NewStore[runtime.Object](db, &storebackend.Config{ GroupResource: gr, Codec: codec, NewFunc: obj.New, From b129b8b1a408abfb2398ffeb37f9f8ed1d9922f3 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Wed, 18 Feb 2026 05:57:27 +0100 Subject: [PATCH 002/135] updated apiserver/builder --- apis/config/config_resource.go | 5 +++++ apis/config/config_types.go | 13 +++++++++---- go.mod | 4 ++-- go.sum | 8 ++++---- 4 files changed, 20 insertions(+), 10 deletions(-) diff --git a/apis/config/config_resource.go b/apis/config/config_resource.go index bc7fad0b..ceeb505d 100644 --- a/apis/config/config_resource.go +++ b/apis/config/config_resource.go @@ -52,6 +52,7 @@ var _ resource.InternalObject = &Config{} var _ resource.ObjectList = &ConfigList{} var _ resource.ObjectWithStatusSubResource = &Config{} var _ resource.StatusSubResource = &ConfigStatus{} +var _ resource.ArbitrarySubResource = &ClearDeviations{} func (Config) GetGroupVersionResource() schema.GroupVersionResource { return schema.GroupVersionResource{ @@ -149,6 +150,10 @@ func (r *Config) ValidateStatusUpdate(ctx context.Context, obj, old runtime.Obje return allErrs } +func (ClearDeviations) SubResourceName() string { + return fmt.Sprintf("%s/%s", ConfigPlural, "clearDeviations") +} + // SubResourceName resturns the name of the subresource // SubResourceName implements the resource.StatusSubResource func (ConfigStatus) SubResourceName() string { diff --git a/apis/config/config_types.go b/apis/config/config_types.go index 4f5eb6ce..0e41be2e 100644 --- a/apis/config/config_types.go +++ b/apis/config/config_types.go @@ -19,9 +19,9 @@ package config import ( "reflect" + "github.com/sdcio/config-server/apis/condition" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/apimachinery/pkg/runtime" - "github.com/sdcio/config-server/apis/condition" ) // ConfigSpec defines the desired state of Config @@ -67,6 +67,10 @@ type ConfigStatusLastKnownGoodSchema struct { Version string `json:"version,omitempty" protobuf:"bytes,3,opt,name=version"` } +type ClearDeviations struct { + Dummy string `json:"dummy,omitempty" protobuf:"bytes,1,opt,name=dummy"` +} + // +genclient // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object // +kubebuilder:object:root=true @@ -74,13 +78,14 @@ type ConfigStatusLastKnownGoodSchema struct { // +kubebuilder:subresource:status // +kubebuilder:resource:categories={sdc} -// Config defines the Schema for the Config API +// Config defines the Schema for the Config API type Config struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` - Spec ConfigSpec `json:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"` - Status ConfigStatus `json:"status,omitempty" protobuf:"bytes,3,opt,name=status"` + Spec ConfigSpec `json:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"` + Status ConfigStatus `json:"status,omitempty" protobuf:"bytes,3,opt,name=status"` + ClearDeviations ClearDeviations `json:"clearDeviations,omitempty" protobuf:"bytes,4,opt,name=clearDeviations"` } // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object diff --git a/go.mod b/go.mod index fc98a215..24fae46a 100644 --- a/go.mod +++ b/go.mod @@ -8,8 +8,8 @@ require ( github.com/gogo/protobuf v1.3.2 github.com/google/go-cmp v0.7.0 github.com/google/uuid v1.6.0 - github.com/henderiw/apiserver-builder v0.0.5-0.20260217153329-7417ac911bd8 - github.com/henderiw/apiserver-store v0.0.3-0.20260217161537-573fa9ffabd2 + github.com/henderiw/apiserver-builder v0.0.5 + github.com/henderiw/apiserver-store v0.0.3 github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c github.com/henderiw/logger v0.0.0-20230911123436-8655829b1abe github.com/henderiw/store v0.0.2-0.20241030044529-f6baff74eab3 diff --git a/go.sum b/go.sum index 68b6d3c2..0dbd4899 100644 --- a/go.sum +++ b/go.sum @@ -169,10 +169,10 @@ github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0 h1:Ovs26xHkKqVztRpIrF/92Bcuy github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0/go.mod h1:8NvIoxWQoOIhqOTXgfV/d3M/q6VIi02HzZEHgUlZvzk= github.com/grpc-ecosystem/grpc-gateway/v2 v2.27.3 h1:NmZ1PKzSTQbuGHw9DGPFomqkkLWMC+vZCkfs+FHv1Vg= github.com/grpc-ecosystem/grpc-gateway/v2 v2.27.3/go.mod h1:zQrxl1YP88HQlA6i9c63DSVPFklWpGX4OWAc9bFuaH4= -github.com/henderiw/apiserver-builder v0.0.5-0.20260217153329-7417ac911bd8 h1:7yl2k/Ikj0guao72jcP1vDD6lhu7R0FfBFH7VdVpY30= -github.com/henderiw/apiserver-builder v0.0.5-0.20260217153329-7417ac911bd8/go.mod h1:1Dhrku4EnByHETdZLZQ0bLK8Xd9Vmjuh22mf5Y+7hfw= -github.com/henderiw/apiserver-store v0.0.3-0.20260217161537-573fa9ffabd2 h1:shdijRNT8Ex13ibuHeKGbmDCt5Q2jvqRfdd7FWTFxiA= -github.com/henderiw/apiserver-store v0.0.3-0.20260217161537-573fa9ffabd2/go.mod h1:lGsqtfR6J/EFZfaww2CvCpD+6N/eRqWMK7wRSOTQM2c= +github.com/henderiw/apiserver-builder v0.0.5 h1:GsapN8eKTH1eiGW0S7FHLbQe1PQYs24C+pgxCZBZdKk= +github.com/henderiw/apiserver-builder v0.0.5/go.mod h1:YiEJtHwOq4CGQ0UqCRRxlt16g/wGgTMHbXQdEgZ30f8= +github.com/henderiw/apiserver-store v0.0.3 h1:cUNzimOvxVKsw+/kj+7IkI/GnRuFlziwCc3AsfYo9zM= +github.com/henderiw/apiserver-store v0.0.3/go.mod h1:RuXLMHJwszn6LXgL6fO9fxMC7AW5wAc4zOddnnZpkKI= github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c h1:nFnCNyRV1Ej/zqV/gn8UnFESkoPUXhwpUCZyhSYGSYA= github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c/go.mod h1:PrPJdVAwtl5tL323wykHZ5L/b7tfJJsjhegza/wq4fQ= github.com/henderiw/logger v0.0.0-20230911123436-8655829b1abe h1:+R53KH7fW+pmqlfSYVTCGPn8pj6gqBGcQ0nq7L1h8+g= From c686bc6cb0e973a31c0725a1be5a3fe9dfdc2432 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Wed, 18 Feb 2026 05:58:22 +0100 Subject: [PATCH 003/135] remove clear deviations --- apis/config/config_resource.go | 5 ----- apis/config/config_types.go | 5 ----- 2 files changed, 10 deletions(-) diff --git a/apis/config/config_resource.go b/apis/config/config_resource.go index ceeb505d..bc7fad0b 100644 --- a/apis/config/config_resource.go +++ b/apis/config/config_resource.go @@ -52,7 +52,6 @@ var _ resource.InternalObject = &Config{} var _ resource.ObjectList = &ConfigList{} var _ resource.ObjectWithStatusSubResource = &Config{} var _ resource.StatusSubResource = &ConfigStatus{} -var _ resource.ArbitrarySubResource = &ClearDeviations{} func (Config) GetGroupVersionResource() schema.GroupVersionResource { return schema.GroupVersionResource{ @@ -150,10 +149,6 @@ func (r *Config) ValidateStatusUpdate(ctx context.Context, obj, old runtime.Obje return allErrs } -func (ClearDeviations) SubResourceName() string { - return fmt.Sprintf("%s/%s", ConfigPlural, "clearDeviations") -} - // SubResourceName resturns the name of the subresource // SubResourceName implements the resource.StatusSubResource func (ConfigStatus) SubResourceName() string { diff --git a/apis/config/config_types.go b/apis/config/config_types.go index 0e41be2e..047e1504 100644 --- a/apis/config/config_types.go +++ b/apis/config/config_types.go @@ -67,10 +67,6 @@ type ConfigStatusLastKnownGoodSchema struct { Version string `json:"version,omitempty" protobuf:"bytes,3,opt,name=version"` } -type ClearDeviations struct { - Dummy string `json:"dummy,omitempty" protobuf:"bytes,1,opt,name=dummy"` -} - // +genclient // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object // +kubebuilder:object:root=true @@ -85,7 +81,6 @@ type Config struct { Spec ConfigSpec `json:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"` Status ConfigStatus `json:"status,omitempty" protobuf:"bytes,3,opt,name=status"` - ClearDeviations ClearDeviations `json:"clearDeviations,omitempty" protobuf:"bytes,4,opt,name=clearDeviations"` } // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object From 5e81364f155d45c6a60daaee7e3bb7e448cda468 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Wed, 18 Feb 2026 06:45:36 +0100 Subject: [PATCH 004/135] updated api depreciation/changes of k8s --- Makefile | 2 +- pkg/discovery/discoveryrule/target.go | 16 +++------------- pkg/reconcilers/configset/reconciler.go | 12 ++++++------ pkg/reconcilers/discoveryrule/reconciler.go | 18 +++++++++--------- pkg/reconcilers/rollout/reconciler.go | 14 +++++++------- pkg/reconcilers/schema/reconciler.go | 14 +++++++------- pkg/reconcilers/subscription/reconciler.go | 16 ++++++++-------- pkg/reconcilers/target/reconciler.go | 13 +++++++------ pkg/reconcilers/targetconfig/reconciler.go | 6 +++--- pkg/reconcilers/targetdatastore/reconciler.go | 18 +++++++++--------- pkg/reconcilers/targetrecovery/reconciler.go | 18 +++++++++--------- pkg/reconcilers/workspace/reconciler.go | 14 +++++++------- pkg/sdc/target/manager/runtime.go | 4 +++- 13 files changed, 79 insertions(+), 86 deletions(-) diff --git a/Makefile b/Makefile index 9c994ce6..f8eefb2f 100644 --- a/Makefile +++ b/Makefile @@ -102,7 +102,7 @@ tidy: go mod tidy .PHONY: lint -lint: +lint: golangci-lint $(GOLANGCILINT) run ./... .PHONY: test diff --git a/pkg/discovery/discoveryrule/target.go b/pkg/discovery/discoveryrule/target.go index f18c1f53..053e4e6e 100644 --- a/pkg/discovery/discoveryrule/target.go +++ b/pkg/discovery/discoveryrule/target.go @@ -143,18 +143,6 @@ func (r *dr) applyTarget(ctx context.Context, newTarget *invv1alpha1.Target) err return err } time.Sleep(500 * time.Millisecond) - - // we get the target again to get the latest update - /* - target = &invv1alpha1.Target{} - if err := r.client.Get(ctx, types.NamespacedName{ - Namespace: targetNew.Namespace, - Name: targetNew.Name, - }, target); err != nil { - // the resource should always exist - return err - } - */ } // set old condition to avoid updating the new status if not changed @@ -176,11 +164,13 @@ func (r *dr) applyTarget(ctx context.Context, newTarget *invv1alpha1.Target) err log.Info("newTarget", "target", newTarget) - err := r.client.Status().Patch(ctx, newTarget, client.Apply, &client.SubResourcePatchOptions{ + patch := client.MergeFrom(target.DeepCopy()) + err := r.client.Status().Patch(ctx, newTarget, patch, &client.SubResourcePatchOptions{ PatchOptions: client.PatchOptions{ FieldManager: reconcilerName, }, }) + if err != nil { log.Error("failed to patch target status", "err", err) return err diff --git a/pkg/reconcilers/configset/reconciler.go b/pkg/reconcilers/configset/reconciler.go index 81353dfb..7fa5d311 100644 --- a/pkg/reconcilers/configset/reconciler.go +++ b/pkg/reconcilers/configset/reconciler.go @@ -37,7 +37,7 @@ import ( metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/apimachinery/pkg/runtime/schema" "k8s.io/apimachinery/pkg/types" - "k8s.io/client-go/tools/record" + "k8s.io/client-go/tools/events" "k8s.io/utils/ptr" ctrl "sigs.k8s.io/controller-runtime" "sigs.k8s.io/controller-runtime/pkg/client" @@ -63,7 +63,7 @@ func (r *reconciler) SetupWithManager(ctx context.Context, mgr ctrl.Manager, c i r.client = mgr.GetClient() r.finalizer = resource.NewAPIFinalizer(mgr.GetClient(), finalizer, reconcilerName) - r.recorder = mgr.GetEventRecorderFor(reconcilerName) + r.recorder = mgr.GetEventRecorder(reconcilerName) return nil, ctrl.NewControllerManagedBy(mgr). Named(reconcilerName). @@ -74,9 +74,9 @@ func (r *reconciler) SetupWithManager(ctx context.Context, mgr ctrl.Manager, c i } type reconciler struct { - client client.Client + client client.Client finalizer *resource.APIFinalizer - recorder record.EventRecorder + recorder events.EventRecorder } func (r *reconciler) Reconcile(ctx context.Context, req ctrl.Request) (ctrl.Result, error) { @@ -339,7 +339,7 @@ func (r *reconciler) handleSuccess(ctx context.Context, configSetOrig, configSet patch := client.MergeFrom(configSetOrig) // update status configSet.SetConditions(condv1alpha1.Ready()) - r.recorder.Eventf(configSet, corev1.EventTypeNormal, configv1alpha1.ConfigSetKind, "ready") + r.recorder.Eventf(configSet, nil, corev1.EventTypeNormal, configv1alpha1.ConfigSetKind, "ready", "") log.Debug("handleSuccess", "key", configSet.GetNamespacedName(), "status new", configSet.Status) @@ -360,7 +360,7 @@ func (r *reconciler) handleError(ctx context.Context, configSetOrig, configSet * } configSet.SetConditions(condv1alpha1.Failed(msg)) log.Error(msg) - r.recorder.Eventf(configSet, corev1.EventTypeWarning, configv1alpha1.ConfigSetKind, msg) + r.recorder.Eventf(configSet, nil, corev1.EventTypeWarning, configv1alpha1.ConfigSetKind, msg, "") return r.client.Status().Patch(ctx, configSet, patch, &client.SubResourcePatchOptions{ PatchOptions: client.PatchOptions{ diff --git a/pkg/reconcilers/discoveryrule/reconciler.go b/pkg/reconcilers/discoveryrule/reconciler.go index 6d261010..c4a00a13 100644 --- a/pkg/reconcilers/discoveryrule/reconciler.go +++ b/pkg/reconcilers/discoveryrule/reconciler.go @@ -35,7 +35,7 @@ import ( corev1 "k8s.io/api/core/v1" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/apimachinery/pkg/runtime/schema" - "k8s.io/client-go/tools/record" + "k8s.io/client-go/tools/events" "k8s.io/utils/ptr" ctrl "sigs.k8s.io/controller-runtime" "sigs.k8s.io/controller-runtime/pkg/client" @@ -65,7 +65,7 @@ func (r *reconciler) SetupWithManager(ctx context.Context, mgr ctrl.Manager, c i r.client = mgr.GetClient() r.finalizer = resource.NewAPIFinalizer(mgr.GetClient(), finalizer, reconcilerName) r.discoveryStore = memstore.NewStore[discoveryrule.DiscoveryRule]() - r.recorder = mgr.GetEventRecorderFor(reconcilerName) + r.recorder = mgr.GetEventRecorder(reconcilerName) return nil, ctrl.NewControllerManagedBy(mgr). Named(reconcilerName). @@ -81,7 +81,7 @@ type reconciler struct { finalizer *resource.APIFinalizer discoveryStore storebackend.Storer[discoveryrule.DiscoveryRule] - recorder record.EventRecorder + recorder events.EventRecorder } func (r *reconciler) Reconcile(ctx context.Context, req ctrl.Request) (ctrl.Result, error) { @@ -259,18 +259,18 @@ func (r *reconciler) handleSuccess(ctx context.Context, discoveryRule *invv1alph log := log.FromContext(ctx) log.Debug("handleSuccess", "key", discoveryRule.GetNamespacedName(), "status old", discoveryRule.DeepCopy().Status) // take a snapshot of the current object - //patch := client.MergeFrom(discoveryRule.DeepCopy()) + patch := client.MergeFrom(discoveryRule.DeepCopy()) // update status discoveryRule.ManagedFields = nil discoveryRule.SetConditions(condv1alpha1.Ready()) if changed { discoveryRule.Status.StartTime = ptr.To(metav1.Now()) - r.recorder.Eventf(discoveryRule, corev1.EventTypeNormal, invv1alpha1.DiscoveryRuleKind, "ready") + r.recorder.Eventf(discoveryRule, nil, corev1.EventTypeNormal, invv1alpha1.DiscoveryRuleKind, "ready", "") } log.Debug("handleSuccess", "key", discoveryRule.GetNamespacedName(), "status new", discoveryRule.Status) - return r.client.Status().Patch(ctx, discoveryRule, client.Apply, &client.SubResourcePatchOptions{ + return r.client.Status().Patch(ctx, discoveryRule, patch, &client.SubResourcePatchOptions{ PatchOptions: client.PatchOptions{ FieldManager: reconcilerName, }, @@ -280,7 +280,7 @@ func (r *reconciler) handleSuccess(ctx context.Context, discoveryRule *invv1alph func (r *reconciler) handleError(ctx context.Context, discoveryRule *invv1alpha1.DiscoveryRule, msg string, err error) error { log := log.FromContext(ctx) // take a snapshot of the current object - //patch := client.MergeFrom(discoveryRule.DeepCopy()) + patch := client.MergeFrom(discoveryRule.DeepCopy()) if err != nil { msg = fmt.Sprintf("%s err %s", msg, err.Error()) @@ -289,9 +289,9 @@ func (r *reconciler) handleError(ctx context.Context, discoveryRule *invv1alpha1 discoveryRule.Status.StartTime = ptr.To(metav1.Now()) discoveryRule.SetConditions(condv1alpha1.Failed(msg)) log.Error(msg) - r.recorder.Eventf(discoveryRule, corev1.EventTypeWarning, invv1alpha1.DiscoveryRuleKind, msg) + r.recorder.Eventf(discoveryRule, nil, corev1.EventTypeWarning, invv1alpha1.DiscoveryRuleKind, msg, "") - return r.client.Status().Patch(ctx, discoveryRule, client.Apply, &client.SubResourcePatchOptions{ + return r.client.Status().Patch(ctx, discoveryRule, patch, &client.SubResourcePatchOptions{ PatchOptions: client.PatchOptions{ FieldManager: reconcilerName, }, diff --git a/pkg/reconcilers/rollout/reconciler.go b/pkg/reconcilers/rollout/reconciler.go index bd2e9fc5..11586198 100644 --- a/pkg/reconcilers/rollout/reconciler.go +++ b/pkg/reconcilers/rollout/reconciler.go @@ -41,7 +41,7 @@ import ( k8serrors "k8s.io/apimachinery/pkg/api/errors" "k8s.io/apimachinery/pkg/runtime/schema" "k8s.io/apimachinery/pkg/types" - "k8s.io/client-go/tools/record" + "k8s.io/client-go/tools/events" ctrl "sigs.k8s.io/controller-runtime" "sigs.k8s.io/controller-runtime/pkg/builder" "sigs.k8s.io/controller-runtime/pkg/client" @@ -82,7 +82,7 @@ func (r *reconciler) SetupWithManager(ctx context.Context, mgr ctrl.Manager, c i if err != nil { return nil, pkgerrors.Wrap(err, "cannot initialize RolloutController") } - r.recorder = mgr.GetEventRecorderFor(reconcilerName) + r.recorder = mgr.GetEventRecorder(reconcilerName) return nil, ctrl.NewControllerManagedBy(mgr). Named(reconcilerName). @@ -94,7 +94,7 @@ type reconciler struct { client client.Client finalizer *resource.APIFinalizer workspaceReader *workspacereader.Reader - recorder record.EventRecorder + recorder events.EventRecorder } func (r *reconciler) Reconcile(ctx context.Context, req ctrl.Request) (ctrl.Result, error) { @@ -325,7 +325,7 @@ func (r *reconciler) handleStatus( err error, ) (ctrl.Result, error) { log := log.FromContext(ctx).With("ref", rollout.Spec.Ref) - //patch := client.MergeFrom(rollout.DeepCopy()) + patch := client.MergeFrom(rollout.DeepCopy()) if err != nil { condition.Message = fmt.Sprintf("%s err %s", condition.Message, err.Error()) } @@ -334,13 +334,13 @@ func (r *reconciler) handleStatus( rollout.Status.Targets = getTargetStatus(ctx, targetStatus) if condition.Type == string(condv1alpha1.ConditionTypeReady) { - r.recorder.Eventf(rollout, corev1.EventTypeNormal, crName, fmt.Sprintf("ready ref %s", rollout.Spec.Ref)) + r.recorder.Eventf(rollout, nil, corev1.EventTypeNormal, crName, fmt.Sprintf("ready ref %s", rollout.Spec.Ref), "") } else { log.Error(condition.Message) - r.recorder.Eventf(rollout, corev1.EventTypeWarning, crName, condition.Message) + r.recorder.Eventf(rollout, nil, corev1.EventTypeWarning, crName, condition.Message, "") } result := ctrl.Result{Requeue: requeue} - return result, pkgerrors.Wrap(r.client.Status().Patch(ctx, rollout, client.Apply, &client.SubResourcePatchOptions{ + return result, pkgerrors.Wrap(r.client.Status().Patch(ctx, rollout, patch, &client.SubResourcePatchOptions{ PatchOptions: client.PatchOptions{ FieldManager: reconcilerName, }, diff --git a/pkg/reconcilers/schema/reconciler.go b/pkg/reconcilers/schema/reconciler.go index 904965ec..27995ff7 100644 --- a/pkg/reconcilers/schema/reconciler.go +++ b/pkg/reconcilers/schema/reconciler.go @@ -39,7 +39,7 @@ import ( corev1 "k8s.io/api/core/v1" k8serrors "k8s.io/apimachinery/pkg/api/errors" "k8s.io/apimachinery/pkg/runtime/schema" - "k8s.io/client-go/tools/record" + "k8s.io/client-go/tools/events" ctrl "sigs.k8s.io/controller-runtime" "sigs.k8s.io/controller-runtime/pkg/builder" "sigs.k8s.io/controller-runtime/pkg/client" @@ -84,7 +84,7 @@ func (r *reconciler) SetupWithManager(ctx context.Context, mgr ctrl.Manager, c i if err != nil { return nil, pkgerrors.Wrap(err, "cannot initialize schemaloader") } - r.recorder = mgr.GetEventRecorderFor(reconcilerName) + r.recorder = mgr.GetEventRecorder(reconcilerName) return nil, ctrl.NewControllerManagedBy(mgr). Named(reconcilerName). @@ -99,7 +99,7 @@ type reconciler struct { schemaLoader *schemaloader.Loader schemaBasePath string - recorder record.EventRecorder + recorder events.EventRecorder } func (r *reconciler) Reconcile(ctx context.Context, req ctrl.Request) (ctrl.Result, error) { @@ -183,8 +183,8 @@ func (r *reconciler) Reconcile(ctx context.Context, req ctrl.Request) (ctrl.Resu // we always retry when status fails -> optimistic concurrency return r.handleError(ctx, schemaOrig, "cannot update status", err) } - r.recorder.Eventf(schema, corev1.EventTypeNormal, - "schema", "loading") + r.recorder.Eventf(schema, nil, corev1.EventTypeNormal, + "schema", "loading", "") repoStatuses, err := r.schemaLoader.Load(ctx, spec.GetKey()) if err != nil { return r.handleError(ctx, schemaOrig, "cannot load schema", err) @@ -255,7 +255,7 @@ func (r *reconciler) handleSuccess(ctx context.Context, schema *invv1alpha1.Sche schema.Status = *updatedStatus //schema.ManagedFields = nil schema.SetConditions(condv1alpha1.Ready()) - r.recorder.Eventf(schema, corev1.EventTypeNormal, invv1alpha1.SchemaKind, "ready") + r.recorder.Eventf(schema, nil, corev1.EventTypeNormal, invv1alpha1.SchemaKind, "ready", "") log.Debug("handleSuccess", "key", schema.GetNamespacedName(), "status new", schema.Status) @@ -278,7 +278,7 @@ func (r *reconciler) handleError(ctx context.Context, schema *invv1alpha1.Schema schema.ManagedFields = nil schema.SetConditions(condv1alpha1.Failed(msg)) log.Error(msg) - r.recorder.Eventf(schema, corev1.EventTypeWarning, crName, msg) + r.recorder.Eventf(schema, nil, corev1.EventTypeWarning, crName, msg, "") var unrecoverableError *sdcerrors.UnrecoverableError result := ctrl.Result{} diff --git a/pkg/reconcilers/subscription/reconciler.go b/pkg/reconcilers/subscription/reconciler.go index 70febf6a..293266d0 100644 --- a/pkg/reconcilers/subscription/reconciler.go +++ b/pkg/reconcilers/subscription/reconciler.go @@ -31,7 +31,7 @@ import ( "github.com/sdcio/config-server/pkg/reconcilers/resource" corev1 "k8s.io/api/core/v1" "k8s.io/apimachinery/pkg/runtime/schema" - "k8s.io/client-go/tools/record" + "k8s.io/client-go/tools/events" ctrl "sigs.k8s.io/controller-runtime" "sigs.k8s.io/controller-runtime/pkg/client" "sigs.k8s.io/controller-runtime/pkg/event" @@ -62,7 +62,7 @@ func (r *reconciler) SetupWithManager(ctx context.Context, mgr ctrl.Manager, c i r.client = mgr.GetClient() r.finalizer = resource.NewAPIFinalizer(mgr.GetClient(), finalizer, reconcilerName) r.targetMgr = cfg.TargetManager - r.recorder = mgr.GetEventRecorderFor(reconcilerName) + r.recorder = mgr.GetEventRecorder(reconcilerName) return nil, ctrl.NewControllerManagedBy(mgr). Named(reconcilerName). @@ -75,7 +75,7 @@ type reconciler struct { client client.Client finalizer *resource.APIFinalizer targetMgr *targetmanager.TargetManager - recorder record.EventRecorder + recorder events.EventRecorder } func (r *reconciler) Reconcile(ctx context.Context, req ctrl.Request) (ctrl.Result, error) { @@ -126,15 +126,15 @@ func (r *reconciler) handleSuccess(ctx context.Context, state *invv1alpha1.Subsc log := log.FromContext(ctx) log.Debug("handleSuccess", "key", state.GetNamespacedName(), "status old", state.DeepCopy().Status) // take a snapshot of the current object - //patch := client.MergeFrom(state.DeepCopy()) + patch := client.MergeFrom(state.DeepCopy()) // update status state.SetConditions(condv1alpha1.Ready()) state.SetTargets(targets) - r.recorder.Eventf(state, corev1.EventTypeNormal, invv1alpha1.SubscriptionKind, "ready") + r.recorder.Eventf(state, nil, corev1.EventTypeNormal, invv1alpha1.SubscriptionKind, "ready", "") log.Debug("handleSuccess", "key", state.GetNamespacedName(), "status new", state.Status) - - return ctrl.Result{}, pkgerrors.Wrap(r.client.Status().Patch(ctx, state, client.Apply, &client.SubResourcePatchOptions{ + + return ctrl.Result{}, pkgerrors.Wrap(r.client.Status().Patch(ctx, state, patch, &client.SubResourcePatchOptions{ PatchOptions: client.PatchOptions{ FieldManager: reconcilerName, }, @@ -153,7 +153,7 @@ func (r *reconciler) handleError(ctx context.Context, state *invv1alpha1.Subscri state.ManagedFields = nil state.SetConditions(condv1alpha1.Failed(msg)) log.Error(msg) - r.recorder.Eventf(state, corev1.EventTypeWarning, crName, msg) + r.recorder.Eventf(state, nil, corev1.EventTypeWarning, crName, msg, "") return ctrl.Result{}, pkgerrors.Wrap(r.client.Status().Patch(ctx, state, patch, &client.SubResourcePatchOptions{ PatchOptions: client.PatchOptions{ diff --git a/pkg/reconcilers/target/reconciler.go b/pkg/reconcilers/target/reconciler.go index cbcbcc00..a3b340ad 100644 --- a/pkg/reconcilers/target/reconciler.go +++ b/pkg/reconcilers/target/reconciler.go @@ -30,7 +30,7 @@ import ( corev1 "k8s.io/api/core/v1" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/apimachinery/pkg/runtime/schema" - "k8s.io/client-go/tools/record" + "k8s.io/client-go/tools/events" ctrl "sigs.k8s.io/controller-runtime" "sigs.k8s.io/controller-runtime/pkg/client" "sigs.k8s.io/controller-runtime/pkg/event" @@ -54,7 +54,7 @@ const ( func (r *reconciler) SetupWithManager(ctx context.Context, mgr ctrl.Manager, c interface{}) (map[schema.GroupVersionKind]chan event.GenericEvent, error) { r.client = mgr.GetClient() r.finalizer = resource.NewAPIFinalizer(mgr.GetClient(), finalizer, reconcilerName) - r.recorder = mgr.GetEventRecorderFor(reconcilerName) + r.recorder = mgr.GetEventRecorder(reconcilerName) return nil, ctrl.NewControllerManagedBy(mgr). Named(reconcilerName). @@ -65,7 +65,7 @@ func (r *reconciler) SetupWithManager(ctx context.Context, mgr ctrl.Manager, c i type reconciler struct { client client.Client finalizer *resource.APIFinalizer - recorder record.EventRecorder + recorder events.EventRecorder } func (r *reconciler) Reconcile(ctx context.Context, req ctrl.Request) (ctrl.Result, error) { @@ -107,6 +107,7 @@ func (r *reconciler) updateCondition(ctx context.Context, target *invv1alpha1.Ta log := log.FromContext(ctx) log.Debug("handleSuccess", "key", target.GetNamespacedName(), "status old", target.DeepCopy().Status) + patch := client.MergeFrom(target.DeepCopy()) // Build SSA patch object for /status newTarget := invv1alpha1.BuildTarget( metav1.ObjectMeta{ @@ -134,12 +135,12 @@ func (r *reconciler) updateCondition(ctx context.Context, target *invv1alpha1.Ta // Optional: emit different event types if newReady { - r.recorder.Eventf(newTarget, corev1.EventTypeNormal, invv1alpha1.TargetKind, "ready") + r.recorder.Eventf(newTarget, nil, corev1.EventTypeNormal, invv1alpha1.TargetKind, "ready", "") } else { - r.recorder.Eventf(newTarget, corev1.EventTypeWarning, invv1alpha1.TargetKind, "not ready") + r.recorder.Eventf(newTarget, nil, corev1.EventTypeWarning, invv1alpha1.TargetKind, "not ready", "") } - if err := r.client.Status().Patch(ctx, newTarget, client.Apply, &client.SubResourcePatchOptions{ + if err := r.client.Status().Patch(ctx, newTarget, patch, &client.SubResourcePatchOptions{ PatchOptions: client.PatchOptions{ FieldManager: reconcilerName, }, diff --git a/pkg/reconcilers/targetconfig/reconciler.go b/pkg/reconcilers/targetconfig/reconciler.go index 2bde2002..b4f9cbbf 100644 --- a/pkg/reconcilers/targetconfig/reconciler.go +++ b/pkg/reconcilers/targetconfig/reconciler.go @@ -34,7 +34,7 @@ import ( targetmanager "github.com/sdcio/config-server/pkg/sdc/target/manager" "k8s.io/apimachinery/pkg/runtime/schema" "k8s.io/client-go/discovery" - "k8s.io/client-go/tools/record" + "k8s.io/client-go/tools/events" ctrl "sigs.k8s.io/controller-runtime" "sigs.k8s.io/controller-runtime/pkg/client" "sigs.k8s.io/controller-runtime/pkg/event" @@ -74,7 +74,7 @@ func (r *reconciler) SetupWithManager(ctx context.Context, mgr ctrl.Manager, c i r.client = mgr.GetClient() r.finalizer = resource.NewAPIFinalizer(mgr.GetClient(), finalizer, reconcilerName) r.targetMgr = cfg.TargetManager - r.recorder = mgr.GetEventRecorderFor(reconcilerName) + r.recorder = mgr.GetEventRecorder(reconcilerName) r.transactor = targetmanager.NewTransactor(r.client, "transactor") return nil, ctrl.NewControllerManagedBy(mgr). @@ -89,7 +89,7 @@ type reconciler struct { discoveryClient *discovery.DiscoveryClient finalizer *resource.APIFinalizer targetMgr *targetmanager.TargetManager - recorder record.EventRecorder + recorder events.EventRecorder transactor *targetmanager.Transactor } diff --git a/pkg/reconcilers/targetdatastore/reconciler.go b/pkg/reconcilers/targetdatastore/reconciler.go index 87d002ea..b4974c5d 100644 --- a/pkg/reconcilers/targetdatastore/reconciler.go +++ b/pkg/reconcilers/targetdatastore/reconciler.go @@ -38,7 +38,7 @@ import ( metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/apimachinery/pkg/runtime/schema" "k8s.io/apimachinery/pkg/types" - "k8s.io/client-go/tools/record" + "k8s.io/client-go/tools/events" ctrl "sigs.k8s.io/controller-runtime" "sigs.k8s.io/controller-runtime/pkg/client" "sigs.k8s.io/controller-runtime/pkg/event" @@ -75,7 +75,7 @@ func (r *reconciler) SetupWithManager(ctx context.Context, mgr ctrl.Manager, c i r.client = mgr.GetClient() r.finalizer = resource.NewAPIFinalizer(mgr.GetClient(), finalizer, reconcilerName) r.targetMgr = cfg.TargetManager - r.recorder = mgr.GetEventRecorderFor(reconcilerName) + r.recorder = mgr.GetEventRecorder(reconcilerName) return nil, ctrl.NewControllerManagedBy(mgr). Named(reconcilerName). @@ -91,7 +91,7 @@ type reconciler struct { client client.Client finalizer *resource.APIFinalizer targetMgr *targetmanager.TargetManager - recorder record.EventRecorder + recorder events.EventRecorder } func (r *reconciler) Reconcile(ctx context.Context, req ctrl.Request) (ctrl.Result, error) { @@ -212,7 +212,7 @@ func (r *reconciler) handleSuccess(ctx context.Context, target *invv1alpha1.Targ log := log.FromContext(ctx) //log.Info("handleSuccess", "key", target.GetNamespacedName(), "status old", target.DeepCopy().Status) // take a snapshot of the current object - //patch := client.MergeFrom(target.DeepCopy()) + patch := client.MergeFrom(target.DeepCopy()) // update status newTarget := invv1alpha1.BuildTarget( metav1.ObjectMeta{ @@ -242,11 +242,11 @@ func (r *reconciler) handleSuccess(ctx context.Context, target *invv1alpha1.Targ "shared ref change", equality.Semantic.DeepEqual(newTarget.Status.UsedReferences, target.Status.UsedReferences), ) - r.recorder.Eventf(newTarget, corev1.EventTypeNormal, invv1alpha1.TargetKind, "datastore ready") + r.recorder.Eventf(newTarget, nil, corev1.EventTypeNormal, invv1alpha1.TargetKind, "datastore ready", "") log.Debug("handleSuccess", "key", newTarget.GetNamespacedName(), "status new", target.Status) - return r.client.Status().Patch(ctx, newTarget, client.Apply, &client.SubResourcePatchOptions{ + return r.client.Status().Patch(ctx, newTarget, patch, &client.SubResourcePatchOptions{ PatchOptions: client.PatchOptions{ FieldManager: reconcilerName, }, @@ -256,7 +256,7 @@ func (r *reconciler) handleSuccess(ctx context.Context, target *invv1alpha1.Targ func (r *reconciler) handleError(ctx context.Context, target *invv1alpha1.Target, msg string, err error, resetUsedRefs bool) error { log := log.FromContext(ctx) // take a snapshot of the current object - //patch := client.MergeFrom(target.DeepCopy()) + patch := client.MergeFrom(target.DeepCopy()) if err != nil { msg = fmt.Sprintf("%s err %s", msg, err.Error()) @@ -294,9 +294,9 @@ func (r *reconciler) handleError(ctx context.Context, target *invv1alpha1.Target ) log.Error(msg, "error", err) - r.recorder.Eventf(newTarget, corev1.EventTypeWarning, invv1alpha1.TargetKind, msg) + r.recorder.Eventf(newTarget, nil, corev1.EventTypeWarning, invv1alpha1.TargetKind, msg, "") - return r.client.Status().Patch(ctx, newTarget, client.Apply, &client.SubResourcePatchOptions{ + return r.client.Status().Patch(ctx, newTarget, patch, &client.SubResourcePatchOptions{ PatchOptions: client.PatchOptions{ FieldManager: reconcilerName, }, diff --git a/pkg/reconcilers/targetrecovery/reconciler.go b/pkg/reconcilers/targetrecovery/reconciler.go index b9b64222..38ffb444 100644 --- a/pkg/reconcilers/targetrecovery/reconciler.go +++ b/pkg/reconcilers/targetrecovery/reconciler.go @@ -35,7 +35,7 @@ import ( metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/apimachinery/pkg/runtime/schema" "k8s.io/client-go/discovery" - "k8s.io/client-go/tools/record" + "k8s.io/client-go/tools/events" ctrl "sigs.k8s.io/controller-runtime" "sigs.k8s.io/controller-runtime/pkg/client" "sigs.k8s.io/controller-runtime/pkg/event" @@ -76,7 +76,7 @@ func (r *reconciler) SetupWithManager(ctx context.Context, mgr ctrl.Manager, c i r.client = mgr.GetClient() r.finalizer = resource.NewAPIFinalizer(mgr.GetClient(), finalizer, reconcilerName) r.targetMgr = cfg.TargetManager - r.recorder = mgr.GetEventRecorderFor(reconcilerName) + r.recorder = mgr.GetEventRecorder(reconcilerName) r.transactor = targetmanager.NewTransactor(r.client, "transactor") return nil, ctrl.NewControllerManagedBy(mgr). @@ -90,7 +90,7 @@ type reconciler struct { discoveryClient *discovery.DiscoveryClient finalizer *resource.APIFinalizer targetMgr *targetmanager.TargetManager - recorder record.EventRecorder + recorder events.EventRecorder transactor *targetmanager.Transactor } @@ -160,7 +160,7 @@ func (r *reconciler) handleSuccess(ctx context.Context, target *invv1alpha1.Targ log := log.FromContext(ctx) log.Debug("handleSuccess", "key", target.GetNamespacedName(), "status old", target.DeepCopy().Status) // take a snapshot of the current object - //patch := client.MergeFrom(target.DeepCopy()) + patch := client.MergeFrom(target.DeepCopy()) // update status newTarget := invv1alpha1.BuildTarget( metav1.ObjectMeta{ @@ -191,9 +191,9 @@ func (r *reconciler) handleSuccess(ctx context.Context, target *invv1alpha1.Targ log.Info("handleSuccess -> change", "condition change", newTarget.GetCondition(invv1alpha1.ConditionTypeConfigRecoveryReady).Equal(target.GetCondition(invv1alpha1.ConditionTypeConfigRecoveryReady))) - r.recorder.Eventf(newTarget, corev1.EventTypeNormal, invv1alpha1.TargetKind, "config recovery ready") + r.recorder.Eventf(newTarget, nil, corev1.EventTypeNormal, invv1alpha1.TargetKind, "config recovery ready", "") - return r.client.Status().Patch(ctx, newTarget, client.Apply, &client.SubResourcePatchOptions{ + return r.client.Status().Patch(ctx, newTarget, patch, &client.SubResourcePatchOptions{ PatchOptions: client.PatchOptions{ FieldManager: reconcilerName, }, @@ -203,7 +203,7 @@ func (r *reconciler) handleSuccess(ctx context.Context, target *invv1alpha1.Targ func (r *reconciler) handleError(ctx context.Context, target *invv1alpha1.Target, msg string, err error) error { log := log.FromContext(ctx) // take a snapshot of the current object - //patch := client.MergeFrom(target.DeepCopy()) + patch := client.MergeFrom(target.DeepCopy()) if err != nil { msg = fmt.Sprintf("%s err %s", msg, err.Error()) @@ -231,11 +231,11 @@ func (r *reconciler) handleError(ctx context.Context, target *invv1alpha1.Target return nil } - r.recorder.Eventf(newTarget, corev1.EventTypeWarning, invv1alpha1.TargetKind, msg) + r.recorder.Eventf(newTarget, nil, corev1.EventTypeWarning, invv1alpha1.TargetKind, msg, "") log.Info("handleError -> change", "condition change", newTarget.GetCondition(invv1alpha1.ConditionTypeConfigRecoveryReady).Equal(target.GetCondition(invv1alpha1.ConditionTypeConfigRecoveryReady))) - return r.client.Status().Patch(ctx, newTarget, client.Apply, &client.SubResourcePatchOptions{ + return r.client.Status().Patch(ctx, newTarget, patch, &client.SubResourcePatchOptions{ PatchOptions: client.PatchOptions{ FieldManager: reconcilerName, }, diff --git a/pkg/reconcilers/workspace/reconciler.go b/pkg/reconcilers/workspace/reconciler.go index bfca2247..9f424375 100644 --- a/pkg/reconcilers/workspace/reconciler.go +++ b/pkg/reconcilers/workspace/reconciler.go @@ -34,7 +34,7 @@ import ( corev1 "k8s.io/api/core/v1" k8serrors "k8s.io/apimachinery/pkg/api/errors" "k8s.io/apimachinery/pkg/runtime/schema" - "k8s.io/client-go/tools/record" + "k8s.io/client-go/tools/events" ctrl "sigs.k8s.io/controller-runtime" "sigs.k8s.io/controller-runtime/pkg/builder" "sigs.k8s.io/controller-runtime/pkg/client" @@ -76,7 +76,7 @@ func (r *reconciler) SetupWithManager(ctx context.Context, mgr ctrl.Manager, c i if err != nil { return nil, errors.Wrap(err, "cannot initialize WorkspaceController") } - r.recorder = mgr.GetEventRecorderFor(reconcilerName) + r.recorder = mgr.GetEventRecorder(reconcilerName) return nil, ctrl.NewControllerManagedBy(mgr). Named(reconcilerName). @@ -91,7 +91,7 @@ type reconciler struct { finalizer *resource.APIFinalizer workspaceLoader *workspaceloader.Loader - recorder record.EventRecorder + recorder events.EventRecorder } func (r *reconciler) Reconcile(ctx context.Context, req ctrl.Request) (ctrl.Result, error) { @@ -177,7 +177,7 @@ func (r *reconciler) handleStatus( ) (ctrl.Result, error) { log := log.FromContext(ctx) - //patch := client.MergeFrom(workspace.DeepCopy()) + patch := client.MergeFrom(workspace.DeepCopy()) if err != nil { condition.Message = fmt.Sprintf("%s err %s", condition.Message, err.Error()) @@ -188,14 +188,14 @@ func (r *reconciler) handleStatus( // Determine event type based on condition type if condition.Type == string(condv1alpha1.ConditionTypeReady) { - r.recorder.Eventf(workspace, corev1.EventTypeNormal, crName, fmt.Sprintf("ready ref %s", workspace.Spec.Ref)) + r.recorder.Eventf(workspace, nil, corev1.EventTypeNormal, crName, fmt.Sprintf("ready ref %s", workspace.Spec.Ref), "") } else { log.Error(condition.Message) - r.recorder.Eventf(workspace, corev1.EventTypeWarning, crName, condition.Message) + r.recorder.Eventf(workspace, nil, corev1.EventTypeWarning, crName, condition.Message, "") } result := ctrl.Result{Requeue: requeue} - return result, errors.Wrap(r.client.Status().Patch(ctx, workspace, client.Apply, &client.SubResourcePatchOptions{ + return result, errors.Wrap(r.client.Status().Patch(ctx, workspace, patch, &client.SubResourcePatchOptions{ PatchOptions: client.PatchOptions{ FieldManager: reconcilerName, }, diff --git a/pkg/sdc/target/manager/runtime.go b/pkg/sdc/target/manager/runtime.go index d9745bbe..6637cb61 100644 --- a/pkg/sdc/target/manager/runtime.go +++ b/pkg/sdc/target/manager/runtime.go @@ -631,7 +631,9 @@ func (r *TargetRuntime) pushConnIfChanged(ctx context.Context, connected bool, m } // PATCH /status using MergeFrom - if err := r.client.Status().Patch(ctx, newTarget, client.Apply, &client.SubResourcePatchOptions{ + + patch := client.MergeFrom(target.DeepCopy()) + if err := r.client.Status().Patch(ctx, newTarget, patch, &client.SubResourcePatchOptions{ PatchOptions: client.PatchOptions{ FieldManager: fieldManagerTargetRuntime, }, From 121cd7f2f82fbbc7eace333803d0405e10024b19 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Wed, 18 Feb 2026 07:42:15 +0100 Subject: [PATCH 005/135] updated api-builder --- apis/config/zz_generated.deepcopy.go | 127 +++++ go.mod | 6 +- go.sum | 12 +- .../versioned/fake/clientset_generated.go | 17 +- .../config/v1alpha1/config.go | 4 +- .../config/v1alpha1/configblame.go | 4 +- .../config/v1alpha1/configset.go | 4 +- .../config/v1alpha1/deviation.go | 4 +- .../config/v1alpha1/runningconfig.go | 4 +- .../config/v1alpha1/sensitiveconfig.go | 4 +- .../informers/externalversions/factory.go | 3 +- .../inv/v1alpha1/discoveryrule.go | 4 +- .../inv/v1alpha1/discoveryvendorprofile.go | 4 +- .../externalversions/inv/v1alpha1/rollout.go | 4 +- .../externalversions/inv/v1alpha1/schema.go | 4 +- .../inv/v1alpha1/subscription.go | 4 +- .../externalversions/inv/v1alpha1/target.go | 4 +- .../inv/v1alpha1/targetconnectionprofile.go | 4 +- .../inv/v1alpha1/targetsyncprofile.go | 4 +- .../inv/v1alpha1/workspace.go | 4 +- pkg/generated/openapi/zz_generated.openapi.go | 535 ++++++++++++++++-- 21 files changed, 670 insertions(+), 90 deletions(-) diff --git a/apis/config/zz_generated.deepcopy.go b/apis/config/zz_generated.deepcopy.go index 3a7efcbb..ea249c76 100644 --- a/apis/config/zz_generated.deepcopy.go +++ b/apis/config/zz_generated.deepcopy.go @@ -499,6 +499,133 @@ func (in *Deviation) DeepCopyObject() runtime.Object { return nil } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *DeviationClear) DeepCopyInto(out *DeviationClear) { + *out = *in + out.TypeMeta = in.TypeMeta + in.ObjectMeta.DeepCopyInto(&out.ObjectMeta) + in.Spec.DeepCopyInto(&out.Spec) + in.Status.DeepCopyInto(&out.Status) + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DeviationClear. +func (in *DeviationClear) DeepCopy() *DeviationClear { + if in == nil { + return nil + } + out := new(DeviationClear) + in.DeepCopyInto(out) + return out +} + +// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. +func (in *DeviationClear) DeepCopyObject() runtime.Object { + if c := in.DeepCopy(); c != nil { + return c + } + return nil +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *DeviationClearItem) DeepCopyInto(out *DeviationClearItem) { + *out = *in + if in.ConfigName != nil { + in, out := &in.ConfigName, &out.ConfigName + *out = new(string) + **out = **in + } + if in.Paths != nil { + in, out := &in.Paths, &out.Paths + *out = make([]string, len(*in)) + copy(*out, *in) + } + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DeviationClearItem. +func (in *DeviationClearItem) DeepCopy() *DeviationClearItem { + if in == nil { + return nil + } + out := new(DeviationClearItem) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *DeviationClearList) DeepCopyInto(out *DeviationClearList) { + *out = *in + out.TypeMeta = in.TypeMeta + in.ListMeta.DeepCopyInto(&out.ListMeta) + if in.Items != nil { + in, out := &in.Items, &out.Items + *out = make([]Deviation, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DeviationClearList. +func (in *DeviationClearList) DeepCopy() *DeviationClearList { + if in == nil { + return nil + } + out := new(DeviationClearList) + in.DeepCopyInto(out) + return out +} + +// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. +func (in *DeviationClearList) DeepCopyObject() runtime.Object { + if c := in.DeepCopy(); c != nil { + return c + } + return nil +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *DeviationClearSpec) DeepCopyInto(out *DeviationClearSpec) { + *out = *in + if in.Items != nil { + in, out := &in.Items, &out.Items + *out = make([]DeviationClearItem, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DeviationClearSpec. +func (in *DeviationClearSpec) DeepCopy() *DeviationClearSpec { + if in == nil { + return nil + } + out := new(DeviationClearSpec) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *DeviationClearStatus) DeepCopyInto(out *DeviationClearStatus) { + *out = *in + in.ConditionedStatus.DeepCopyInto(&out.ConditionedStatus) + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DeviationClearStatus. +func (in *DeviationClearStatus) DeepCopy() *DeviationClearStatus { + if in == nil { + return nil + } + out := new(DeviationClearStatus) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *DeviationFilter) DeepCopyInto(out *DeviationFilter) { *out = *in diff --git a/go.mod b/go.mod index 24fae46a..6ef0268c 100644 --- a/go.mod +++ b/go.mod @@ -8,7 +8,7 @@ require ( github.com/gogo/protobuf v1.3.2 github.com/google/go-cmp v0.7.0 github.com/google/uuid v1.6.0 - github.com/henderiw/apiserver-builder v0.0.5 + github.com/henderiw/apiserver-builder v0.0.6-0.20260218064045-beff0f08c914 github.com/henderiw/apiserver-store v0.0.3 github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c github.com/henderiw/logger v0.0.0-20230911123436-8655829b1abe @@ -37,7 +37,7 @@ require ( k8s.io/client-go v0.35.1 k8s.io/code-generator v0.35.1 k8s.io/component-base v0.35.1 - k8s.io/kube-openapi v0.0.0-20250910181357-589584f1c912 + k8s.io/kube-openapi v0.0.0-20260127142750-a19766b6e2d4 k8s.io/utils v0.0.0-20251002143259-bc988d571ff4 sigs.k8s.io/controller-runtime v0.23.1 sigs.k8s.io/structured-merge-diff/v6 v6.3.2 @@ -166,7 +166,7 @@ require ( gopkg.in/natefinch/lumberjack.v2 v2.2.1 // indirect gopkg.in/warnings.v0 v0.1.2 // indirect gopkg.in/yaml.v3 v3.0.1 // indirect - k8s.io/apiextensions-apiserver v0.35.0 // indirect + k8s.io/apiextensions-apiserver v0.35.1 // indirect k8s.io/gengo/v2 v2.0.0-20250922181213-ec3ebc5fd46b // indirect k8s.io/klog/v2 v2.130.1 // indirect k8s.io/kms v0.35.1 // indirect diff --git a/go.sum b/go.sum index 0dbd4899..922f4615 100644 --- a/go.sum +++ b/go.sum @@ -169,8 +169,8 @@ github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0 h1:Ovs26xHkKqVztRpIrF/92Bcuy github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0/go.mod h1:8NvIoxWQoOIhqOTXgfV/d3M/q6VIi02HzZEHgUlZvzk= github.com/grpc-ecosystem/grpc-gateway/v2 v2.27.3 h1:NmZ1PKzSTQbuGHw9DGPFomqkkLWMC+vZCkfs+FHv1Vg= github.com/grpc-ecosystem/grpc-gateway/v2 v2.27.3/go.mod h1:zQrxl1YP88HQlA6i9c63DSVPFklWpGX4OWAc9bFuaH4= -github.com/henderiw/apiserver-builder v0.0.5 h1:GsapN8eKTH1eiGW0S7FHLbQe1PQYs24C+pgxCZBZdKk= -github.com/henderiw/apiserver-builder v0.0.5/go.mod h1:YiEJtHwOq4CGQ0UqCRRxlt16g/wGgTMHbXQdEgZ30f8= +github.com/henderiw/apiserver-builder v0.0.6-0.20260218064045-beff0f08c914 h1:Xm7i7hLL+E7C92adVmi10bPewdX4Fkhi2+xGAQdfxDY= +github.com/henderiw/apiserver-builder v0.0.6-0.20260218064045-beff0f08c914/go.mod h1:n5ApsFfaK3h5B1WVEnZ29erGuMV0ovPA0/ErcXeQet0= github.com/henderiw/apiserver-store v0.0.3 h1:cUNzimOvxVKsw+/kj+7IkI/GnRuFlziwCc3AsfYo9zM= github.com/henderiw/apiserver-store v0.0.3/go.mod h1:RuXLMHJwszn6LXgL6fO9fxMC7AW5wAc4zOddnnZpkKI= github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c h1:nFnCNyRV1Ej/zqV/gn8UnFESkoPUXhwpUCZyhSYGSYA= @@ -455,8 +455,8 @@ gopkg.in/yaml.v3 v3.0.1 h1:fxVm/GzAzEWqLHuvctI91KS9hhNmmWOoWu0XTYJS7CA= gopkg.in/yaml.v3 v3.0.1/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= k8s.io/api v0.35.1 h1:0PO/1FhlK/EQNVK5+txc4FuhQibV25VLSdLMmGpDE/Q= k8s.io/api v0.35.1/go.mod h1:28uR9xlXWml9eT0uaGo6y71xK86JBELShLy4wR1XtxM= -k8s.io/apiextensions-apiserver v0.35.0 h1:3xHk2rTOdWXXJM+RDQZJvdx0yEOgC0FgQ1PlJatA5T4= -k8s.io/apiextensions-apiserver v0.35.0/go.mod h1:E1Ahk9SADaLQ4qtzYFkwUqusXTcaV2uw3l14aqpL2LU= +k8s.io/apiextensions-apiserver v0.35.1 h1:p5vvALkknlOcAqARwjS20kJffgzHqwyQRM8vHLwgU7w= +k8s.io/apiextensions-apiserver v0.35.1/go.mod h1:2CN4fe1GZ3HMe4wBr25qXyJnJyZaquy4nNlNmb3R7AQ= k8s.io/apimachinery v0.35.1 h1:yxO6gV555P1YV0SANtnTjXYfiivaTPvCTKX6w6qdDsU= k8s.io/apimachinery v0.35.1/go.mod h1:jQCgFZFR1F4Ik7hvr2g84RTJSZegBc8yHgFWKn//hns= k8s.io/apiserver v0.35.1 h1:potxdhhTL4i6AYAa2QCwtlhtB1eCdWQFvJV6fXgJzxs= @@ -473,8 +473,8 @@ k8s.io/klog/v2 v2.130.1 h1:n9Xl7H1Xvksem4KFG4PYbdQCQxqc/tTUyrgXaOhHSzk= k8s.io/klog/v2 v2.130.1/go.mod h1:3Jpz1GvMt720eyJH1ckRHK1EDfpxISzJ7I9OYgaDtPE= k8s.io/kms v0.35.1 h1:kjv2r9g1mY7uL+l1RhyAZvWVZIA/4qIfBHXyjFGLRhU= k8s.io/kms v0.35.1/go.mod h1:VT+4ekZAdrZDMgShK37vvlyHUVhwI9t/9tvh0AyCWmQ= -k8s.io/kube-openapi v0.0.0-20250910181357-589584f1c912 h1:Y3gxNAuB0OBLImH611+UDZcmKS3g6CthxToOb37KgwE= -k8s.io/kube-openapi v0.0.0-20250910181357-589584f1c912/go.mod h1:kdmbQkyfwUagLfXIad1y2TdrjPFWp2Q89B3qkRwf/pQ= +k8s.io/kube-openapi v0.0.0-20260127142750-a19766b6e2d4 h1:HhDfevmPS+OalTjQRKbTHppRIz01AWi8s45TMXStgYY= +k8s.io/kube-openapi v0.0.0-20260127142750-a19766b6e2d4/go.mod h1:kdmbQkyfwUagLfXIad1y2TdrjPFWp2Q89B3qkRwf/pQ= k8s.io/utils v0.0.0-20251002143259-bc988d571ff4 h1:SjGebBtkBqHFOli+05xYbK8YF1Dzkbzn+gDM4X9T4Ck= k8s.io/utils v0.0.0-20251002143259-bc988d571ff4/go.mod h1:OLgZIPagt7ERELqWJFomSt595RzquPNLL48iOWgYOg0= sigs.k8s.io/apiserver-network-proxy/konnectivity-client v0.32.0 h1:XotDXzqvJ8Nx5eiZZueLpTuafJz8SiodgOemI+w87QU= diff --git a/pkg/generated/clientset/versioned/fake/clientset_generated.go b/pkg/generated/clientset/versioned/fake/clientset_generated.go index 2d993dc0..18ed1dca 100644 --- a/pkg/generated/clientset/versioned/fake/clientset_generated.go +++ b/pkg/generated/clientset/versioned/fake/clientset_generated.go @@ -36,7 +36,7 @@ import ( // without applying any field management, validations and/or defaults. It shouldn't be considered a replacement // for a real clientset and is mostly useful in simple unit tests. // -// DEPRECATED: NewClientset replaces this with support for field management, which significantly improves +// Deprecated: NewClientset replaces this with support for field management, which significantly improves // server side apply testing. NewClientset is only available when apply configurations are generated (e.g. // via --with-applyconfig). func NewSimpleClientset(objects ...runtime.Object) *Clientset { @@ -52,8 +52,8 @@ func NewSimpleClientset(objects ...runtime.Object) *Clientset { cs.AddReactor("*", "*", testing.ObjectReaction(o)) cs.AddWatchReactor("*", func(action testing.Action) (handled bool, ret watch.Interface, err error) { var opts metav1.ListOptions - if watchActcion, ok := action.(testing.WatchActionImpl); ok { - opts = watchActcion.ListOptions + if watchAction, ok := action.(testing.WatchActionImpl); ok { + opts = watchAction.ListOptions } gvr := action.GetResource() ns := action.GetNamespace() @@ -84,6 +84,17 @@ func (c *Clientset) Tracker() testing.ObjectTracker { return c.tracker } +// IsWatchListSemanticsSupported informs the reflector that this client +// doesn't support WatchList semantics. +// +// This is a synthetic method whose sole purpose is to satisfy the optional +// interface check performed by the reflector. +// Returning true signals that WatchList can NOT be used. +// No additional logic is implemented here. +func (c *Clientset) IsWatchListSemanticsUnSupported() bool { + return true +} + var ( _ clientset.Interface = &Clientset{} _ testing.FakeClient = &Clientset{} diff --git a/pkg/generated/informers/externalversions/config/v1alpha1/config.go b/pkg/generated/informers/externalversions/config/v1alpha1/config.go index 00943405..4c12fb74 100644 --- a/pkg/generated/informers/externalversions/config/v1alpha1/config.go +++ b/pkg/generated/informers/externalversions/config/v1alpha1/config.go @@ -56,7 +56,7 @@ func NewConfigInformer(client versioned.Interface, namespace string, resyncPerio // one. This reduces memory footprint and number of connections to the server. func NewFilteredConfigInformer(client versioned.Interface, namespace string, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer { return cache.NewSharedIndexInformer( - &cache.ListWatch{ + cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{ ListFunc: func(options v1.ListOptions) (runtime.Object, error) { if tweakListOptions != nil { tweakListOptions(&options) @@ -81,7 +81,7 @@ func NewFilteredConfigInformer(client versioned.Interface, namespace string, res } return client.ConfigV1alpha1().Configs(namespace).Watch(ctx, options) }, - }, + }, client), &apisconfigv1alpha1.Config{}, resyncPeriod, indexers, diff --git a/pkg/generated/informers/externalversions/config/v1alpha1/configblame.go b/pkg/generated/informers/externalversions/config/v1alpha1/configblame.go index a9bb7771..8a089dbe 100644 --- a/pkg/generated/informers/externalversions/config/v1alpha1/configblame.go +++ b/pkg/generated/informers/externalversions/config/v1alpha1/configblame.go @@ -56,7 +56,7 @@ func NewConfigBlameInformer(client versioned.Interface, namespace string, resync // one. This reduces memory footprint and number of connections to the server. func NewFilteredConfigBlameInformer(client versioned.Interface, namespace string, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer { return cache.NewSharedIndexInformer( - &cache.ListWatch{ + cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{ ListFunc: func(options v1.ListOptions) (runtime.Object, error) { if tweakListOptions != nil { tweakListOptions(&options) @@ -81,7 +81,7 @@ func NewFilteredConfigBlameInformer(client versioned.Interface, namespace string } return client.ConfigV1alpha1().ConfigBlames(namespace).Watch(ctx, options) }, - }, + }, client), &apisconfigv1alpha1.ConfigBlame{}, resyncPeriod, indexers, diff --git a/pkg/generated/informers/externalversions/config/v1alpha1/configset.go b/pkg/generated/informers/externalversions/config/v1alpha1/configset.go index 3e8be38a..807b698f 100644 --- a/pkg/generated/informers/externalversions/config/v1alpha1/configset.go +++ b/pkg/generated/informers/externalversions/config/v1alpha1/configset.go @@ -56,7 +56,7 @@ func NewConfigSetInformer(client versioned.Interface, namespace string, resyncPe // one. This reduces memory footprint and number of connections to the server. func NewFilteredConfigSetInformer(client versioned.Interface, namespace string, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer { return cache.NewSharedIndexInformer( - &cache.ListWatch{ + cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{ ListFunc: func(options v1.ListOptions) (runtime.Object, error) { if tweakListOptions != nil { tweakListOptions(&options) @@ -81,7 +81,7 @@ func NewFilteredConfigSetInformer(client versioned.Interface, namespace string, } return client.ConfigV1alpha1().ConfigSets(namespace).Watch(ctx, options) }, - }, + }, client), &apisconfigv1alpha1.ConfigSet{}, resyncPeriod, indexers, diff --git a/pkg/generated/informers/externalversions/config/v1alpha1/deviation.go b/pkg/generated/informers/externalversions/config/v1alpha1/deviation.go index 711ded29..a6195d69 100644 --- a/pkg/generated/informers/externalversions/config/v1alpha1/deviation.go +++ b/pkg/generated/informers/externalversions/config/v1alpha1/deviation.go @@ -56,7 +56,7 @@ func NewDeviationInformer(client versioned.Interface, namespace string, resyncPe // one. This reduces memory footprint and number of connections to the server. func NewFilteredDeviationInformer(client versioned.Interface, namespace string, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer { return cache.NewSharedIndexInformer( - &cache.ListWatch{ + cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{ ListFunc: func(options v1.ListOptions) (runtime.Object, error) { if tweakListOptions != nil { tweakListOptions(&options) @@ -81,7 +81,7 @@ func NewFilteredDeviationInformer(client versioned.Interface, namespace string, } return client.ConfigV1alpha1().Deviations(namespace).Watch(ctx, options) }, - }, + }, client), &apisconfigv1alpha1.Deviation{}, resyncPeriod, indexers, diff --git a/pkg/generated/informers/externalversions/config/v1alpha1/runningconfig.go b/pkg/generated/informers/externalversions/config/v1alpha1/runningconfig.go index 1b4909ea..e2e94346 100644 --- a/pkg/generated/informers/externalversions/config/v1alpha1/runningconfig.go +++ b/pkg/generated/informers/externalversions/config/v1alpha1/runningconfig.go @@ -56,7 +56,7 @@ func NewRunningConfigInformer(client versioned.Interface, namespace string, resy // one. This reduces memory footprint and number of connections to the server. func NewFilteredRunningConfigInformer(client versioned.Interface, namespace string, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer { return cache.NewSharedIndexInformer( - &cache.ListWatch{ + cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{ ListFunc: func(options v1.ListOptions) (runtime.Object, error) { if tweakListOptions != nil { tweakListOptions(&options) @@ -81,7 +81,7 @@ func NewFilteredRunningConfigInformer(client versioned.Interface, namespace stri } return client.ConfigV1alpha1().RunningConfigs(namespace).Watch(ctx, options) }, - }, + }, client), &apisconfigv1alpha1.RunningConfig{}, resyncPeriod, indexers, diff --git a/pkg/generated/informers/externalversions/config/v1alpha1/sensitiveconfig.go b/pkg/generated/informers/externalversions/config/v1alpha1/sensitiveconfig.go index ce95036d..5fe40ba3 100644 --- a/pkg/generated/informers/externalversions/config/v1alpha1/sensitiveconfig.go +++ b/pkg/generated/informers/externalversions/config/v1alpha1/sensitiveconfig.go @@ -56,7 +56,7 @@ func NewSensitiveConfigInformer(client versioned.Interface, namespace string, re // one. This reduces memory footprint and number of connections to the server. func NewFilteredSensitiveConfigInformer(client versioned.Interface, namespace string, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer { return cache.NewSharedIndexInformer( - &cache.ListWatch{ + cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{ ListFunc: func(options v1.ListOptions) (runtime.Object, error) { if tweakListOptions != nil { tweakListOptions(&options) @@ -81,7 +81,7 @@ func NewFilteredSensitiveConfigInformer(client versioned.Interface, namespace st } return client.ConfigV1alpha1().SensitiveConfigs(namespace).Watch(ctx, options) }, - }, + }, client), &apisconfigv1alpha1.SensitiveConfig{}, resyncPeriod, indexers, diff --git a/pkg/generated/informers/externalversions/factory.go b/pkg/generated/informers/externalversions/factory.go index 5c03885a..0336c541 100644 --- a/pkg/generated/informers/externalversions/factory.go +++ b/pkg/generated/informers/externalversions/factory.go @@ -97,6 +97,7 @@ func NewSharedInformerFactory(client versioned.Interface, defaultResync time.Dur // NewFilteredSharedInformerFactory constructs a new instance of sharedInformerFactory. // Listers obtained via this SharedInformerFactory will be subject to the same filters // as specified here. +// // Deprecated: Please use NewSharedInformerFactoryWithOptions instead func NewFilteredSharedInformerFactory(client versioned.Interface, defaultResync time.Duration, namespace string, tweakListOptions internalinterfaces.TweakListOptionsFunc) SharedInformerFactory { return NewSharedInformerFactoryWithOptions(client, defaultResync, WithNamespace(namespace), WithTweakListOptions(tweakListOptions)) @@ -204,7 +205,7 @@ func (f *sharedInformerFactory) InformerFor(obj runtime.Object, newFunc internal // // It is typically used like this: // -// ctx, cancel := context.Background() +// ctx, cancel := context.WithCancel(context.Background()) // defer cancel() // factory := NewSharedInformerFactory(client, resyncPeriod) // defer factory.WaitForStop() // Returns immediately if nothing was started. diff --git a/pkg/generated/informers/externalversions/inv/v1alpha1/discoveryrule.go b/pkg/generated/informers/externalversions/inv/v1alpha1/discoveryrule.go index fa1b1f08..2bca165e 100644 --- a/pkg/generated/informers/externalversions/inv/v1alpha1/discoveryrule.go +++ b/pkg/generated/informers/externalversions/inv/v1alpha1/discoveryrule.go @@ -56,7 +56,7 @@ func NewDiscoveryRuleInformer(client versioned.Interface, namespace string, resy // one. This reduces memory footprint and number of connections to the server. func NewFilteredDiscoveryRuleInformer(client versioned.Interface, namespace string, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer { return cache.NewSharedIndexInformer( - &cache.ListWatch{ + cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{ ListFunc: func(options v1.ListOptions) (runtime.Object, error) { if tweakListOptions != nil { tweakListOptions(&options) @@ -81,7 +81,7 @@ func NewFilteredDiscoveryRuleInformer(client versioned.Interface, namespace stri } return client.InvV1alpha1().DiscoveryRules(namespace).Watch(ctx, options) }, - }, + }, client), &apisinvv1alpha1.DiscoveryRule{}, resyncPeriod, indexers, diff --git a/pkg/generated/informers/externalversions/inv/v1alpha1/discoveryvendorprofile.go b/pkg/generated/informers/externalversions/inv/v1alpha1/discoveryvendorprofile.go index 0b488531..c7755f45 100644 --- a/pkg/generated/informers/externalversions/inv/v1alpha1/discoveryvendorprofile.go +++ b/pkg/generated/informers/externalversions/inv/v1alpha1/discoveryvendorprofile.go @@ -56,7 +56,7 @@ func NewDiscoveryVendorProfileInformer(client versioned.Interface, namespace str // one. This reduces memory footprint and number of connections to the server. func NewFilteredDiscoveryVendorProfileInformer(client versioned.Interface, namespace string, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer { return cache.NewSharedIndexInformer( - &cache.ListWatch{ + cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{ ListFunc: func(options v1.ListOptions) (runtime.Object, error) { if tweakListOptions != nil { tweakListOptions(&options) @@ -81,7 +81,7 @@ func NewFilteredDiscoveryVendorProfileInformer(client versioned.Interface, names } return client.InvV1alpha1().DiscoveryVendorProfiles(namespace).Watch(ctx, options) }, - }, + }, client), &apisinvv1alpha1.DiscoveryVendorProfile{}, resyncPeriod, indexers, diff --git a/pkg/generated/informers/externalversions/inv/v1alpha1/rollout.go b/pkg/generated/informers/externalversions/inv/v1alpha1/rollout.go index 7fecf46f..38004822 100644 --- a/pkg/generated/informers/externalversions/inv/v1alpha1/rollout.go +++ b/pkg/generated/informers/externalversions/inv/v1alpha1/rollout.go @@ -56,7 +56,7 @@ func NewRolloutInformer(client versioned.Interface, namespace string, resyncPeri // one. This reduces memory footprint and number of connections to the server. func NewFilteredRolloutInformer(client versioned.Interface, namespace string, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer { return cache.NewSharedIndexInformer( - &cache.ListWatch{ + cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{ ListFunc: func(options v1.ListOptions) (runtime.Object, error) { if tweakListOptions != nil { tweakListOptions(&options) @@ -81,7 +81,7 @@ func NewFilteredRolloutInformer(client versioned.Interface, namespace string, re } return client.InvV1alpha1().Rollouts(namespace).Watch(ctx, options) }, - }, + }, client), &apisinvv1alpha1.Rollout{}, resyncPeriod, indexers, diff --git a/pkg/generated/informers/externalversions/inv/v1alpha1/schema.go b/pkg/generated/informers/externalversions/inv/v1alpha1/schema.go index 314c15ac..0bf0ee3e 100644 --- a/pkg/generated/informers/externalversions/inv/v1alpha1/schema.go +++ b/pkg/generated/informers/externalversions/inv/v1alpha1/schema.go @@ -56,7 +56,7 @@ func NewSchemaInformer(client versioned.Interface, namespace string, resyncPerio // one. This reduces memory footprint and number of connections to the server. func NewFilteredSchemaInformer(client versioned.Interface, namespace string, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer { return cache.NewSharedIndexInformer( - &cache.ListWatch{ + cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{ ListFunc: func(options v1.ListOptions) (runtime.Object, error) { if tweakListOptions != nil { tweakListOptions(&options) @@ -81,7 +81,7 @@ func NewFilteredSchemaInformer(client versioned.Interface, namespace string, res } return client.InvV1alpha1().Schemas(namespace).Watch(ctx, options) }, - }, + }, client), &apisinvv1alpha1.Schema{}, resyncPeriod, indexers, diff --git a/pkg/generated/informers/externalversions/inv/v1alpha1/subscription.go b/pkg/generated/informers/externalversions/inv/v1alpha1/subscription.go index a6b7b1b3..772fc387 100644 --- a/pkg/generated/informers/externalversions/inv/v1alpha1/subscription.go +++ b/pkg/generated/informers/externalversions/inv/v1alpha1/subscription.go @@ -56,7 +56,7 @@ func NewSubscriptionInformer(client versioned.Interface, namespace string, resyn // one. This reduces memory footprint and number of connections to the server. func NewFilteredSubscriptionInformer(client versioned.Interface, namespace string, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer { return cache.NewSharedIndexInformer( - &cache.ListWatch{ + cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{ ListFunc: func(options v1.ListOptions) (runtime.Object, error) { if tweakListOptions != nil { tweakListOptions(&options) @@ -81,7 +81,7 @@ func NewFilteredSubscriptionInformer(client versioned.Interface, namespace strin } return client.InvV1alpha1().Subscriptions(namespace).Watch(ctx, options) }, - }, + }, client), &apisinvv1alpha1.Subscription{}, resyncPeriod, indexers, diff --git a/pkg/generated/informers/externalversions/inv/v1alpha1/target.go b/pkg/generated/informers/externalversions/inv/v1alpha1/target.go index b230503e..ffe7c925 100644 --- a/pkg/generated/informers/externalversions/inv/v1alpha1/target.go +++ b/pkg/generated/informers/externalversions/inv/v1alpha1/target.go @@ -56,7 +56,7 @@ func NewTargetInformer(client versioned.Interface, namespace string, resyncPerio // one. This reduces memory footprint and number of connections to the server. func NewFilteredTargetInformer(client versioned.Interface, namespace string, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer { return cache.NewSharedIndexInformer( - &cache.ListWatch{ + cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{ ListFunc: func(options v1.ListOptions) (runtime.Object, error) { if tweakListOptions != nil { tweakListOptions(&options) @@ -81,7 +81,7 @@ func NewFilteredTargetInformer(client versioned.Interface, namespace string, res } return client.InvV1alpha1().Targets(namespace).Watch(ctx, options) }, - }, + }, client), &apisinvv1alpha1.Target{}, resyncPeriod, indexers, diff --git a/pkg/generated/informers/externalversions/inv/v1alpha1/targetconnectionprofile.go b/pkg/generated/informers/externalversions/inv/v1alpha1/targetconnectionprofile.go index 6828c266..94cefe76 100644 --- a/pkg/generated/informers/externalversions/inv/v1alpha1/targetconnectionprofile.go +++ b/pkg/generated/informers/externalversions/inv/v1alpha1/targetconnectionprofile.go @@ -56,7 +56,7 @@ func NewTargetConnectionProfileInformer(client versioned.Interface, namespace st // one. This reduces memory footprint and number of connections to the server. func NewFilteredTargetConnectionProfileInformer(client versioned.Interface, namespace string, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer { return cache.NewSharedIndexInformer( - &cache.ListWatch{ + cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{ ListFunc: func(options v1.ListOptions) (runtime.Object, error) { if tweakListOptions != nil { tweakListOptions(&options) @@ -81,7 +81,7 @@ func NewFilteredTargetConnectionProfileInformer(client versioned.Interface, name } return client.InvV1alpha1().TargetConnectionProfiles(namespace).Watch(ctx, options) }, - }, + }, client), &apisinvv1alpha1.TargetConnectionProfile{}, resyncPeriod, indexers, diff --git a/pkg/generated/informers/externalversions/inv/v1alpha1/targetsyncprofile.go b/pkg/generated/informers/externalversions/inv/v1alpha1/targetsyncprofile.go index 94322e5a..1eb03e9f 100644 --- a/pkg/generated/informers/externalversions/inv/v1alpha1/targetsyncprofile.go +++ b/pkg/generated/informers/externalversions/inv/v1alpha1/targetsyncprofile.go @@ -56,7 +56,7 @@ func NewTargetSyncProfileInformer(client versioned.Interface, namespace string, // one. This reduces memory footprint and number of connections to the server. func NewFilteredTargetSyncProfileInformer(client versioned.Interface, namespace string, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer { return cache.NewSharedIndexInformer( - &cache.ListWatch{ + cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{ ListFunc: func(options v1.ListOptions) (runtime.Object, error) { if tweakListOptions != nil { tweakListOptions(&options) @@ -81,7 +81,7 @@ func NewFilteredTargetSyncProfileInformer(client versioned.Interface, namespace } return client.InvV1alpha1().TargetSyncProfiles(namespace).Watch(ctx, options) }, - }, + }, client), &apisinvv1alpha1.TargetSyncProfile{}, resyncPeriod, indexers, diff --git a/pkg/generated/informers/externalversions/inv/v1alpha1/workspace.go b/pkg/generated/informers/externalversions/inv/v1alpha1/workspace.go index 1e3dadfa..8726b0dd 100644 --- a/pkg/generated/informers/externalversions/inv/v1alpha1/workspace.go +++ b/pkg/generated/informers/externalversions/inv/v1alpha1/workspace.go @@ -56,7 +56,7 @@ func NewWorkspaceInformer(client versioned.Interface, namespace string, resyncPe // one. This reduces memory footprint and number of connections to the server. func NewFilteredWorkspaceInformer(client versioned.Interface, namespace string, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer { return cache.NewSharedIndexInformer( - &cache.ListWatch{ + cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{ ListFunc: func(options v1.ListOptions) (runtime.Object, error) { if tweakListOptions != nil { tweakListOptions(&options) @@ -81,7 +81,7 @@ func NewFilteredWorkspaceInformer(client versioned.Interface, namespace string, } return client.InvV1alpha1().Workspaces(namespace).Watch(ctx, options) }, - }, + }, client), &apisinvv1alpha1.Workspace{}, resyncPeriod, indexers, diff --git a/pkg/generated/openapi/zz_generated.openapi.go b/pkg/generated/openapi/zz_generated.openapi.go index 916c1c33..75f6c38a 100644 --- a/pkg/generated/openapi/zz_generated.openapi.go +++ b/pkg/generated/openapi/zz_generated.openapi.go @@ -147,9 +147,12 @@ func GetOpenAPIDefinitions(ref common.ReferenceCallback) map[string]common.OpenA "k8s.io/api/core/v1.ConfigMapProjection": schema_k8sio_api_core_v1_ConfigMapProjection(ref), "k8s.io/api/core/v1.ConfigMapVolumeSource": schema_k8sio_api_core_v1_ConfigMapVolumeSource(ref), "k8s.io/api/core/v1.Container": schema_k8sio_api_core_v1_Container(ref), + "k8s.io/api/core/v1.ContainerExtendedResourceRequest": schema_k8sio_api_core_v1_ContainerExtendedResourceRequest(ref), "k8s.io/api/core/v1.ContainerImage": schema_k8sio_api_core_v1_ContainerImage(ref), "k8s.io/api/core/v1.ContainerPort": schema_k8sio_api_core_v1_ContainerPort(ref), "k8s.io/api/core/v1.ContainerResizePolicy": schema_k8sio_api_core_v1_ContainerResizePolicy(ref), + "k8s.io/api/core/v1.ContainerRestartRule": schema_k8sio_api_core_v1_ContainerRestartRule(ref), + "k8s.io/api/core/v1.ContainerRestartRuleOnExitCodes": schema_k8sio_api_core_v1_ContainerRestartRuleOnExitCodes(ref), "k8s.io/api/core/v1.ContainerState": schema_k8sio_api_core_v1_ContainerState(ref), "k8s.io/api/core/v1.ContainerStateRunning": schema_k8sio_api_core_v1_ContainerStateRunning(ref), "k8s.io/api/core/v1.ContainerStateTerminated": schema_k8sio_api_core_v1_ContainerStateTerminated(ref), @@ -178,6 +181,7 @@ func GetOpenAPIDefinitions(ref common.ReferenceCallback) map[string]common.OpenA "k8s.io/api/core/v1.EventSource": schema_k8sio_api_core_v1_EventSource(ref), "k8s.io/api/core/v1.ExecAction": schema_k8sio_api_core_v1_ExecAction(ref), "k8s.io/api/core/v1.FCVolumeSource": schema_k8sio_api_core_v1_FCVolumeSource(ref), + "k8s.io/api/core/v1.FileKeySelector": schema_k8sio_api_core_v1_FileKeySelector(ref), "k8s.io/api/core/v1.FlexPersistentVolumeSource": schema_k8sio_api_core_v1_FlexPersistentVolumeSource(ref), "k8s.io/api/core/v1.FlexVolumeSource": schema_k8sio_api_core_v1_FlexVolumeSource(ref), "k8s.io/api/core/v1.FlockerVolumeSource": schema_k8sio_api_core_v1_FlockerVolumeSource(ref), @@ -253,10 +257,12 @@ func GetOpenAPIDefinitions(ref common.ReferenceCallback) map[string]common.OpenA "k8s.io/api/core/v1.PodAffinityTerm": schema_k8sio_api_core_v1_PodAffinityTerm(ref), "k8s.io/api/core/v1.PodAntiAffinity": schema_k8sio_api_core_v1_PodAntiAffinity(ref), "k8s.io/api/core/v1.PodAttachOptions": schema_k8sio_api_core_v1_PodAttachOptions(ref), + "k8s.io/api/core/v1.PodCertificateProjection": schema_k8sio_api_core_v1_PodCertificateProjection(ref), "k8s.io/api/core/v1.PodCondition": schema_k8sio_api_core_v1_PodCondition(ref), "k8s.io/api/core/v1.PodDNSConfig": schema_k8sio_api_core_v1_PodDNSConfig(ref), "k8s.io/api/core/v1.PodDNSConfigOption": schema_k8sio_api_core_v1_PodDNSConfigOption(ref), "k8s.io/api/core/v1.PodExecOptions": schema_k8sio_api_core_v1_PodExecOptions(ref), + "k8s.io/api/core/v1.PodExtendedResourceClaimStatus": schema_k8sio_api_core_v1_PodExtendedResourceClaimStatus(ref), "k8s.io/api/core/v1.PodIP": schema_k8sio_api_core_v1_PodIP(ref), "k8s.io/api/core/v1.PodList": schema_k8sio_api_core_v1_PodList(ref), "k8s.io/api/core/v1.PodLogOptions": schema_k8sio_api_core_v1_PodLogOptions(ref), @@ -348,6 +354,7 @@ func GetOpenAPIDefinitions(ref common.ReferenceCallback) map[string]common.OpenA "k8s.io/api/core/v1.VsphereVirtualDiskVolumeSource": schema_k8sio_api_core_v1_VsphereVirtualDiskVolumeSource(ref), "k8s.io/api/core/v1.WeightedPodAffinityTerm": schema_k8sio_api_core_v1_WeightedPodAffinityTerm(ref), "k8s.io/api/core/v1.WindowsSecurityContextOptions": schema_k8sio_api_core_v1_WindowsSecurityContextOptions(ref), + "k8s.io/api/core/v1.WorkloadReference": schema_k8sio_api_core_v1_WorkloadReference(ref), "k8s.io/apimachinery/pkg/api/resource.Quantity": schema_apimachinery_pkg_api_resource_Quantity(ref), "k8s.io/apimachinery/pkg/api/resource.int64Amount": schema_apimachinery_pkg_api_resource_int64Amount(ref), "k8s.io/apimachinery/pkg/apis/meta/v1.APIGroup": schema_pkg_apis_meta_v1_APIGroup(ref), @@ -5962,7 +5969,7 @@ func schema_k8sio_api_core_v1_Container(ref common.ReferenceCallback) common.Ope }, }, SchemaProps: spec.SchemaProps{ - Description: "List of sources to populate environment variables in the container. The keys defined within a source must be a C_IDENTIFIER. All invalid keys will be reported as an event when the container is starting. When a key exists in multiple sources, the value associated with the last source will take precedence. Values defined by an Env with a duplicate key will take precedence. Cannot be updated.", + Description: "List of sources to populate environment variables in the container. The keys defined within a source may consist of any printable ASCII characters except '='. When a key exists in multiple sources, the value associated with the last source will take precedence. Values defined by an Env with a duplicate key will take precedence. Cannot be updated.", Type: []string{"array"}, Items: &spec.SchemaOrArray{ Schema: &spec.Schema{ @@ -6012,7 +6019,7 @@ func schema_k8sio_api_core_v1_Container(ref common.ReferenceCallback) common.Ope }, }, SchemaProps: spec.SchemaProps{ - Description: "Resources resize policy for the container.", + Description: "Resources resize policy for the container. This field cannot be set on ephemeral containers.", Type: []string{"array"}, Items: &spec.SchemaOrArray{ Schema: &spec.Schema{ @@ -6026,11 +6033,30 @@ func schema_k8sio_api_core_v1_Container(ref common.ReferenceCallback) common.Ope }, "restartPolicy": { SchemaProps: spec.SchemaProps{ - Description: "RestartPolicy defines the restart behavior of individual containers in a pod. This field may only be set for init containers, and the only allowed value is \"Always\". For non-init containers or when this field is not specified, the restart behavior is defined by the Pod's restart policy and the container type. Setting the RestartPolicy as \"Always\" for the init container will have the following effect: this init container will be continually restarted on exit until all regular containers have terminated. Once all regular containers have completed, all init containers with restartPolicy \"Always\" will be shut down. This lifecycle differs from normal init containers and is often referred to as a \"sidecar\" container. Although this init container still starts in the init container sequence, it does not wait for the container to complete before proceeding to the next init container. Instead, the next init container starts immediately after this init container is started, or after any startupProbe has successfully completed.", + Description: "RestartPolicy defines the restart behavior of individual containers in a pod. This overrides the pod-level restart policy. When this field is not specified, the restart behavior is defined by the Pod's restart policy and the container type. Additionally, setting the RestartPolicy as \"Always\" for the init container will have the following effect: this init container will be continually restarted on exit until all regular containers have terminated. Once all regular containers have completed, all init containers with restartPolicy \"Always\" will be shut down. This lifecycle differs from normal init containers and is often referred to as a \"sidecar\" container. Although this init container still starts in the init container sequence, it does not wait for the container to complete before proceeding to the next init container. Instead, the next init container starts immediately after this init container is started, or after any startupProbe has successfully completed.", Type: []string{"string"}, Format: "", }, }, + "restartPolicyRules": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "Represents a list of rules to be checked to determine if the container should be restarted on exit. The rules are evaluated in order. Once a rule matches a container exit condition, the remaining rules are ignored. If no rule matches the container exit condition, the Container-level restart policy determines the whether the container is restarted or not. Constraints on the rules: - At most 20 rules are allowed. - Rules can have the same action. - Identical rules are not forbidden in validations. When rules are specified, container MUST set RestartPolicy explicitly even it if matches the Pod's RestartPolicy.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("k8s.io/api/core/v1.ContainerRestartRule"), + }, + }, + }, + }, + }, "volumeMounts": { VendorExtensible: spec.VendorExtensible{ Extensions: spec.Extensions{ @@ -6158,7 +6184,45 @@ func schema_k8sio_api_core_v1_Container(ref common.ReferenceCallback) common.Ope }, }, Dependencies: []string{ - "k8s.io/api/core/v1.ContainerPort", "k8s.io/api/core/v1.ContainerResizePolicy", "k8s.io/api/core/v1.EnvFromSource", "k8s.io/api/core/v1.EnvVar", "k8s.io/api/core/v1.Lifecycle", "k8s.io/api/core/v1.Probe", "k8s.io/api/core/v1.ResourceRequirements", "k8s.io/api/core/v1.SecurityContext", "k8s.io/api/core/v1.VolumeDevice", "k8s.io/api/core/v1.VolumeMount"}, + "k8s.io/api/core/v1.ContainerPort", "k8s.io/api/core/v1.ContainerResizePolicy", "k8s.io/api/core/v1.ContainerRestartRule", "k8s.io/api/core/v1.EnvFromSource", "k8s.io/api/core/v1.EnvVar", "k8s.io/api/core/v1.Lifecycle", "k8s.io/api/core/v1.Probe", "k8s.io/api/core/v1.ResourceRequirements", "k8s.io/api/core/v1.SecurityContext", "k8s.io/api/core/v1.VolumeDevice", "k8s.io/api/core/v1.VolumeMount"}, + } +} + +func schema_k8sio_api_core_v1_ContainerExtendedResourceRequest(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "ContainerExtendedResourceRequest has the mapping of container name, extended resource name to the device request name.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "containerName": { + SchemaProps: spec.SchemaProps{ + Description: "The name of the container requesting resources.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "resourceName": { + SchemaProps: spec.SchemaProps{ + Description: "The name of the extended resource in that container which gets backed by DRA.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "requestName": { + SchemaProps: spec.SchemaProps{ + Description: "The name of the request in the special ResourceClaim which corresponds to the extended resource.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"containerName", "resourceName", "requestName"}, + }, + }, } } @@ -6284,6 +6348,76 @@ func schema_k8sio_api_core_v1_ContainerResizePolicy(ref common.ReferenceCallback } } +func schema_k8sio_api_core_v1_ContainerRestartRule(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "ContainerRestartRule describes how a container exit is handled.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "action": { + SchemaProps: spec.SchemaProps{ + Description: "Specifies the action taken on a container exit if the requirements are satisfied. The only possible value is \"Restart\" to restart the container.", + Type: []string{"string"}, + Format: "", + }, + }, + "exitCodes": { + SchemaProps: spec.SchemaProps{ + Description: "Represents the exit codes to check on container exits.", + Ref: ref("k8s.io/api/core/v1.ContainerRestartRuleOnExitCodes"), + }, + }, + }, + Required: []string{"action"}, + }, + }, + Dependencies: []string{ + "k8s.io/api/core/v1.ContainerRestartRuleOnExitCodes"}, + } +} + +func schema_k8sio_api_core_v1_ContainerRestartRuleOnExitCodes(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "ContainerRestartRuleOnExitCodes describes the condition for handling an exited container based on its exit codes.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "operator": { + SchemaProps: spec.SchemaProps{ + Description: "Represents the relationship between the container exit code(s) and the specified values. Possible values are: - In: the requirement is satisfied if the container exit code is in the\n set of specified values.\n- NotIn: the requirement is satisfied if the container exit code is\n not in the set of specified values.", + Type: []string{"string"}, + Format: "", + }, + }, + "values": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "set", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "Specifies the set of values to check for container exit codes. At most 255 elements are allowed.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: 0, + Type: []string{"integer"}, + Format: "int32", + }, + }, + }, + }, + }, + }, + Required: []string{"operator"}, + }, + }, + } +} + func schema_k8sio_api_core_v1_ContainerState(ref common.ReferenceCallback) common.OpenAPIDefinition { return common.OpenAPIDefinition{ Schema: spec.Schema{ @@ -7069,7 +7203,7 @@ func schema_k8sio_api_core_v1_EnvFromSource(ref common.ReferenceCallback) common Properties: map[string]spec.Schema{ "prefix": { SchemaProps: spec.SchemaProps{ - Description: "Optional text to prepend to the name of each environment variable. Must be a C_IDENTIFIER.", + Description: "Optional text to prepend to the name of each environment variable. May consist of any printable ASCII characters except '='.", Type: []string{"string"}, Format: "", }, @@ -7103,7 +7237,7 @@ func schema_k8sio_api_core_v1_EnvVar(ref common.ReferenceCallback) common.OpenAP Properties: map[string]spec.Schema{ "name": { SchemaProps: spec.SchemaProps{ - Description: "Name of the environment variable. Must be a C_IDENTIFIER.", + Description: "Name of the environment variable. May consist of any printable ASCII characters except '='.", Default: "", Type: []string{"string"}, Format: "", @@ -7162,11 +7296,17 @@ func schema_k8sio_api_core_v1_EnvVarSource(ref common.ReferenceCallback) common. Ref: ref("k8s.io/api/core/v1.SecretKeySelector"), }, }, + "fileKeyRef": { + SchemaProps: spec.SchemaProps{ + Description: "FileKeyRef selects a key of the env file. Requires the EnvFiles feature gate to be enabled.", + Ref: ref("k8s.io/api/core/v1.FileKeySelector"), + }, + }, }, }, }, Dependencies: []string{ - "k8s.io/api/core/v1.ConfigMapKeySelector", "k8s.io/api/core/v1.ObjectFieldSelector", "k8s.io/api/core/v1.ResourceFieldSelector", "k8s.io/api/core/v1.SecretKeySelector"}, + "k8s.io/api/core/v1.ConfigMapKeySelector", "k8s.io/api/core/v1.FileKeySelector", "k8s.io/api/core/v1.ObjectFieldSelector", "k8s.io/api/core/v1.ResourceFieldSelector", "k8s.io/api/core/v1.SecretKeySelector"}, } } @@ -7271,7 +7411,7 @@ func schema_k8sio_api_core_v1_EphemeralContainer(ref common.ReferenceCallback) c }, }, SchemaProps: spec.SchemaProps{ - Description: "List of sources to populate environment variables in the container. The keys defined within a source must be a C_IDENTIFIER. All invalid keys will be reported as an event when the container is starting. When a key exists in multiple sources, the value associated with the last source will take precedence. Values defined by an Env with a duplicate key will take precedence. Cannot be updated.", + Description: "List of sources to populate environment variables in the container. The keys defined within a source may consist of any printable ASCII characters except '='. When a key exists in multiple sources, the value associated with the last source will take precedence. Values defined by an Env with a duplicate key will take precedence. Cannot be updated.", Type: []string{"array"}, Items: &spec.SchemaOrArray{ Schema: &spec.Schema{ @@ -7335,11 +7475,30 @@ func schema_k8sio_api_core_v1_EphemeralContainer(ref common.ReferenceCallback) c }, "restartPolicy": { SchemaProps: spec.SchemaProps{ - Description: "Restart policy for the container to manage the restart behavior of each container within a pod. This may only be set for init containers. You cannot set this field on ephemeral containers.", + Description: "Restart policy for the container to manage the restart behavior of each container within a pod. You cannot set this field on ephemeral containers.", Type: []string{"string"}, Format: "", }, }, + "restartPolicyRules": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "Represents a list of rules to be checked to determine if the container should be restarted on exit. You cannot set this field on ephemeral containers.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("k8s.io/api/core/v1.ContainerRestartRule"), + }, + }, + }, + }, + }, "volumeMounts": { VendorExtensible: spec.VendorExtensible{ Extensions: spec.Extensions{ @@ -7474,7 +7633,7 @@ func schema_k8sio_api_core_v1_EphemeralContainer(ref common.ReferenceCallback) c }, }, Dependencies: []string{ - "k8s.io/api/core/v1.ContainerPort", "k8s.io/api/core/v1.ContainerResizePolicy", "k8s.io/api/core/v1.EnvFromSource", "k8s.io/api/core/v1.EnvVar", "k8s.io/api/core/v1.Lifecycle", "k8s.io/api/core/v1.Probe", "k8s.io/api/core/v1.ResourceRequirements", "k8s.io/api/core/v1.SecurityContext", "k8s.io/api/core/v1.VolumeDevice", "k8s.io/api/core/v1.VolumeMount"}, + "k8s.io/api/core/v1.ContainerPort", "k8s.io/api/core/v1.ContainerResizePolicy", "k8s.io/api/core/v1.ContainerRestartRule", "k8s.io/api/core/v1.EnvFromSource", "k8s.io/api/core/v1.EnvVar", "k8s.io/api/core/v1.Lifecycle", "k8s.io/api/core/v1.Probe", "k8s.io/api/core/v1.ResourceRequirements", "k8s.io/api/core/v1.SecurityContext", "k8s.io/api/core/v1.VolumeDevice", "k8s.io/api/core/v1.VolumeMount"}, } } @@ -7579,7 +7738,7 @@ func schema_k8sio_api_core_v1_EphemeralContainerCommon(ref common.ReferenceCallb }, }, SchemaProps: spec.SchemaProps{ - Description: "List of sources to populate environment variables in the container. The keys defined within a source must be a C_IDENTIFIER. All invalid keys will be reported as an event when the container is starting. When a key exists in multiple sources, the value associated with the last source will take precedence. Values defined by an Env with a duplicate key will take precedence. Cannot be updated.", + Description: "List of sources to populate environment variables in the container. The keys defined within a source may consist of any printable ASCII characters except '='. When a key exists in multiple sources, the value associated with the last source will take precedence. Values defined by an Env with a duplicate key will take precedence. Cannot be updated.", Type: []string{"array"}, Items: &spec.SchemaOrArray{ Schema: &spec.Schema{ @@ -7643,11 +7802,30 @@ func schema_k8sio_api_core_v1_EphemeralContainerCommon(ref common.ReferenceCallb }, "restartPolicy": { SchemaProps: spec.SchemaProps{ - Description: "Restart policy for the container to manage the restart behavior of each container within a pod. This may only be set for init containers. You cannot set this field on ephemeral containers.", + Description: "Restart policy for the container to manage the restart behavior of each container within a pod. You cannot set this field on ephemeral containers.", Type: []string{"string"}, Format: "", }, }, + "restartPolicyRules": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "Represents a list of rules to be checked to determine if the container should be restarted on exit. You cannot set this field on ephemeral containers.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("k8s.io/api/core/v1.ContainerRestartRule"), + }, + }, + }, + }, + }, "volumeMounts": { VendorExtensible: spec.VendorExtensible{ Extensions: spec.Extensions{ @@ -7775,7 +7953,7 @@ func schema_k8sio_api_core_v1_EphemeralContainerCommon(ref common.ReferenceCallb }, }, Dependencies: []string{ - "k8s.io/api/core/v1.ContainerPort", "k8s.io/api/core/v1.ContainerResizePolicy", "k8s.io/api/core/v1.EnvFromSource", "k8s.io/api/core/v1.EnvVar", "k8s.io/api/core/v1.Lifecycle", "k8s.io/api/core/v1.Probe", "k8s.io/api/core/v1.ResourceRequirements", "k8s.io/api/core/v1.SecurityContext", "k8s.io/api/core/v1.VolumeDevice", "k8s.io/api/core/v1.VolumeMount"}, + "k8s.io/api/core/v1.ContainerPort", "k8s.io/api/core/v1.ContainerResizePolicy", "k8s.io/api/core/v1.ContainerRestartRule", "k8s.io/api/core/v1.EnvFromSource", "k8s.io/api/core/v1.EnvVar", "k8s.io/api/core/v1.Lifecycle", "k8s.io/api/core/v1.Probe", "k8s.io/api/core/v1.ResourceRequirements", "k8s.io/api/core/v1.SecurityContext", "k8s.io/api/core/v1.VolumeDevice", "k8s.io/api/core/v1.VolumeMount"}, } } @@ -8145,6 +8323,57 @@ func schema_k8sio_api_core_v1_FCVolumeSource(ref common.ReferenceCallback) commo } } +func schema_k8sio_api_core_v1_FileKeySelector(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "FileKeySelector selects a key of the env file.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "volumeName": { + SchemaProps: spec.SchemaProps{ + Description: "The name of the volume mount containing the env file.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "path": { + SchemaProps: spec.SchemaProps{ + Description: "The path within the volume from which to select the file. Must be relative and may not contain the '..' path or start with '..'.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "key": { + SchemaProps: spec.SchemaProps{ + Description: "The key within the env file. An invalid key will prevent the pod from starting. The keys defined within a source may consist of any printable ASCII characters except '='. During Alpha stage of the EnvFiles feature gate, the key size is limited to 128 characters.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "optional": { + SchemaProps: spec.SchemaProps{ + Description: "Specify whether the file or its key must be defined. If the file or key does not exist, then the env var is not published. If optional is set to true and the specified key does not exist, the environment variable will not be set in the Pod's containers.\n\nIf optional is set to false and the specified key does not exist, an error will be returned during Pod creation.", + Default: false, + Type: []string{"boolean"}, + Format: "", + }, + }, + }, + Required: []string{"volumeName", "path", "key"}, + }, + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-map-type": "atomic", + }, + }, + }, + } +} + func schema_k8sio_api_core_v1_FlexPersistentVolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { return common.OpenAPIDefinition{ Schema: spec.Schema{ @@ -8454,7 +8683,7 @@ func schema_k8sio_api_core_v1_GlusterfsVolumeSource(ref common.ReferenceCallback Properties: map[string]spec.Schema{ "endpoints": { SchemaProps: spec.SchemaProps{ - Description: "endpoints is the endpoint name that details Glusterfs topology. More info: https://examples.k8s.io/volumes/glusterfs/README.md#create-a-pod", + Description: "endpoints is the endpoint name that details Glusterfs topology.", Default: "", Type: []string{"string"}, Format: "", @@ -10647,6 +10876,26 @@ func schema_k8sio_api_core_v1_NodeStatus(ref common.ReferenceCallback) common.Op Ref: ref("k8s.io/api/core/v1.NodeFeatures"), }, }, + "declaredFeatures": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "DeclaredFeatures represents the features related to feature gates that are declared by the node.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, }, }, }, @@ -11123,7 +11372,7 @@ func schema_k8sio_api_core_v1_PersistentVolumeClaimSpec(ref common.ReferenceCall }, "resources": { SchemaProps: spec.SchemaProps{ - Description: "resources represents the minimum resources the volume should have. If RecoverVolumeExpansionFailure feature is enabled users are allowed to specify resource requirements that are lower than previous value but must still be higher than capacity recorded in the status field of the claim. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#resources", + Description: "resources represents the minimum resources the volume should have. Users are allowed to specify resource requirements that are lower than previous value but must still be higher than capacity recorded in the status field of the claim. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#resources", Default: map[string]interface{}{}, Ref: ref("k8s.io/api/core/v1.VolumeResourceRequirements"), }, @@ -11164,7 +11413,7 @@ func schema_k8sio_api_core_v1_PersistentVolumeClaimSpec(ref common.ReferenceCall }, "volumeAttributesClassName": { SchemaProps: spec.SchemaProps{ - Description: "volumeAttributesClassName may be used to set the VolumeAttributesClass used by this claim. If specified, the CSI driver will create or update the volume with the attributes defined in the corresponding VolumeAttributesClass. This has a different purpose than storageClassName, it can be changed after the claim is created. An empty string value means that no VolumeAttributesClass will be applied to the claim but it's not allowed to reset this field to empty string once it is set. If unspecified and the PersistentVolumeClaim is unbound, the default VolumeAttributesClass will be set by the persistentvolume controller if it exists. If the resource referred to by volumeAttributesClass does not exist, this PersistentVolumeClaim will be set to a Pending state, as reflected by the modifyVolumeStatus field, until such as a resource exists. More info: https://kubernetes.io/docs/concepts/storage/volume-attributes-classes/ (Beta) Using this field requires the VolumeAttributesClass feature gate to be enabled (off by default).", + Description: "volumeAttributesClassName may be used to set the VolumeAttributesClass used by this claim. If specified, the CSI driver will create or update the volume with the attributes defined in the corresponding VolumeAttributesClass. This has a different purpose than storageClassName, it can be changed after the claim is created. An empty string or nil value indicates that no VolumeAttributesClass will be applied to the claim. If the claim enters an Infeasible error state, this field can be reset to its previous value (including nil) to cancel the modification. If the resource referred to by volumeAttributesClass does not exist, this PersistentVolumeClaim will be set to a Pending state, as reflected by the modifyVolumeStatus field, until such as a resource exists. More info: https://kubernetes.io/docs/concepts/storage/volume-attributes-classes/", Type: []string{"string"}, Format: "", }, @@ -11253,7 +11502,7 @@ func schema_k8sio_api_core_v1_PersistentVolumeClaimStatus(ref common.ReferenceCa }, "allocatedResources": { SchemaProps: spec.SchemaProps{ - Description: "allocatedResources tracks the resources allocated to a PVC including its capacity. Key names follow standard Kubernetes label syntax. Valid values are either:\n\t* Un-prefixed keys:\n\t\t- storage - the capacity of the volume.\n\t* Custom resources must use implementation-defined prefixed names such as \"example.com/my-custom-resource\"\nApart from above values - keys that are unprefixed or have kubernetes.io prefix are considered reserved and hence may not be used.\n\nCapacity reported here may be larger than the actual capacity when a volume expansion operation is requested. For storage quota, the larger value from allocatedResources and PVC.spec.resources is used. If allocatedResources is not set, PVC.spec.resources alone is used for quota calculation. If a volume expansion capacity request is lowered, allocatedResources is only lowered if there are no expansion operations in progress and if the actual volume capacity is equal or lower than the requested capacity.\n\nA controller that receives PVC update with previously unknown resourceName should ignore the update for the purpose it was designed. For example - a controller that only is responsible for resizing capacity of the volume, should ignore PVC updates that change other valid resources associated with PVC.\n\nThis is an alpha field and requires enabling RecoverVolumeExpansionFailure feature.", + Description: "allocatedResources tracks the resources allocated to a PVC including its capacity. Key names follow standard Kubernetes label syntax. Valid values are either:\n\t* Un-prefixed keys:\n\t\t- storage - the capacity of the volume.\n\t* Custom resources must use implementation-defined prefixed names such as \"example.com/my-custom-resource\"\nApart from above values - keys that are unprefixed or have kubernetes.io prefix are considered reserved and hence may not be used.\n\nCapacity reported here may be larger than the actual capacity when a volume expansion operation is requested. For storage quota, the larger value from allocatedResources and PVC.spec.resources is used. If allocatedResources is not set, PVC.spec.resources alone is used for quota calculation. If a volume expansion capacity request is lowered, allocatedResources is only lowered if there are no expansion operations in progress and if the actual volume capacity is equal or lower than the requested capacity.\n\nA controller that receives PVC update with previously unknown resourceName should ignore the update for the purpose it was designed. For example - a controller that only is responsible for resizing capacity of the volume, should ignore PVC updates that change other valid resources associated with PVC.", Type: []string{"object"}, AdditionalProperties: &spec.SchemaOrBool{ Allows: true, @@ -11272,7 +11521,7 @@ func schema_k8sio_api_core_v1_PersistentVolumeClaimStatus(ref common.ReferenceCa }, }, SchemaProps: spec.SchemaProps{ - Description: "allocatedResourceStatuses stores status of resource being resized for the given PVC. Key names follow standard Kubernetes label syntax. Valid values are either:\n\t* Un-prefixed keys:\n\t\t- storage - the capacity of the volume.\n\t* Custom resources must use implementation-defined prefixed names such as \"example.com/my-custom-resource\"\nApart from above values - keys that are unprefixed or have kubernetes.io prefix are considered reserved and hence may not be used.\n\nClaimResourceStatus can be in any of following states:\n\t- ControllerResizeInProgress:\n\t\tState set when resize controller starts resizing the volume in control-plane.\n\t- ControllerResizeFailed:\n\t\tState set when resize has failed in resize controller with a terminal error.\n\t- NodeResizePending:\n\t\tState set when resize controller has finished resizing the volume but further resizing of\n\t\tvolume is needed on the node.\n\t- NodeResizeInProgress:\n\t\tState set when kubelet starts resizing the volume.\n\t- NodeResizeFailed:\n\t\tState set when resizing has failed in kubelet with a terminal error. Transient errors don't set\n\t\tNodeResizeFailed.\nFor example: if expanding a PVC for more capacity - this field can be one of the following states:\n\t- pvc.status.allocatedResourceStatus['storage'] = \"ControllerResizeInProgress\"\n - pvc.status.allocatedResourceStatus['storage'] = \"ControllerResizeFailed\"\n - pvc.status.allocatedResourceStatus['storage'] = \"NodeResizePending\"\n - pvc.status.allocatedResourceStatus['storage'] = \"NodeResizeInProgress\"\n - pvc.status.allocatedResourceStatus['storage'] = \"NodeResizeFailed\"\nWhen this field is not set, it means that no resize operation is in progress for the given PVC.\n\nA controller that receives PVC update with previously unknown resourceName or ClaimResourceStatus should ignore the update for the purpose it was designed. For example - a controller that only is responsible for resizing capacity of the volume, should ignore PVC updates that change other valid resources associated with PVC.\n\nThis is an alpha field and requires enabling RecoverVolumeExpansionFailure feature.", + Description: "allocatedResourceStatuses stores status of resource being resized for the given PVC. Key names follow standard Kubernetes label syntax. Valid values are either:\n\t* Un-prefixed keys:\n\t\t- storage - the capacity of the volume.\n\t* Custom resources must use implementation-defined prefixed names such as \"example.com/my-custom-resource\"\nApart from above values - keys that are unprefixed or have kubernetes.io prefix are considered reserved and hence may not be used.\n\nClaimResourceStatus can be in any of following states:\n\t- ControllerResizeInProgress:\n\t\tState set when resize controller starts resizing the volume in control-plane.\n\t- ControllerResizeFailed:\n\t\tState set when resize has failed in resize controller with a terminal error.\n\t- NodeResizePending:\n\t\tState set when resize controller has finished resizing the volume but further resizing of\n\t\tvolume is needed on the node.\n\t- NodeResizeInProgress:\n\t\tState set when kubelet starts resizing the volume.\n\t- NodeResizeFailed:\n\t\tState set when resizing has failed in kubelet with a terminal error. Transient errors don't set\n\t\tNodeResizeFailed.\nFor example: if expanding a PVC for more capacity - this field can be one of the following states:\n\t- pvc.status.allocatedResourceStatus['storage'] = \"ControllerResizeInProgress\"\n - pvc.status.allocatedResourceStatus['storage'] = \"ControllerResizeFailed\"\n - pvc.status.allocatedResourceStatus['storage'] = \"NodeResizePending\"\n - pvc.status.allocatedResourceStatus['storage'] = \"NodeResizeInProgress\"\n - pvc.status.allocatedResourceStatus['storage'] = \"NodeResizeFailed\"\nWhen this field is not set, it means that no resize operation is in progress for the given PVC.\n\nA controller that receives PVC update with previously unknown resourceName or ClaimResourceStatus should ignore the update for the purpose it was designed. For example - a controller that only is responsible for resizing capacity of the volume, should ignore PVC updates that change other valid resources associated with PVC.", Type: []string{"object"}, AdditionalProperties: &spec.SchemaOrBool{ Allows: true, @@ -11289,14 +11538,14 @@ func schema_k8sio_api_core_v1_PersistentVolumeClaimStatus(ref common.ReferenceCa }, "currentVolumeAttributesClassName": { SchemaProps: spec.SchemaProps{ - Description: "currentVolumeAttributesClassName is the current name of the VolumeAttributesClass the PVC is using. When unset, there is no VolumeAttributeClass applied to this PersistentVolumeClaim This is a beta field and requires enabling VolumeAttributesClass feature (off by default).", + Description: "currentVolumeAttributesClassName is the current name of the VolumeAttributesClass the PVC is using. When unset, there is no VolumeAttributeClass applied to this PersistentVolumeClaim", Type: []string{"string"}, Format: "", }, }, "modifyVolumeStatus": { SchemaProps: spec.SchemaProps{ - Description: "ModifyVolumeStatus represents the status object of ControllerModifyVolume operation. When this is unset, there is no ModifyVolume operation being attempted. This is a beta field and requires enabling VolumeAttributesClass feature (off by default).", + Description: "ModifyVolumeStatus represents the status object of ControllerModifyVolume operation. When this is unset, there is no ModifyVolume operation being attempted.", Ref: ref("k8s.io/api/core/v1.ModifyVolumeStatus"), }, }, @@ -11795,13 +12044,13 @@ func schema_k8sio_api_core_v1_PersistentVolumeSpec(ref common.ReferenceCallback) }, "nodeAffinity": { SchemaProps: spec.SchemaProps{ - Description: "nodeAffinity defines constraints that limit what nodes this volume can be accessed from. This field influences the scheduling of pods that use this volume.", + Description: "nodeAffinity defines constraints that limit what nodes this volume can be accessed from. This field influences the scheduling of pods that use this volume. This field is mutable if MutablePVNodeAffinity feature gate is enabled.", Ref: ref("k8s.io/api/core/v1.VolumeNodeAffinity"), }, }, "volumeAttributesClassName": { SchemaProps: spec.SchemaProps{ - Description: "Name of VolumeAttributesClass to which this persistent volume belongs. Empty value is not allowed. When this field is not set, it indicates that this volume does not belong to any VolumeAttributesClass. This field is mutable and can be changed by the CSI driver after a volume has been updated successfully to a new class. For an unbound PersistentVolume, the volumeAttributesClassName will be matched with unbound PersistentVolumeClaims during the binding process. This is a beta field and requires enabling VolumeAttributesClass feature (off by default).", + Description: "Name of VolumeAttributesClass to which this persistent volume belongs. Empty value is not allowed. When this field is not set, it indicates that this volume does not belong to any VolumeAttributesClass. This field is mutable and can be changed by the CSI driver after a volume has been updated successfully to a new class. For an unbound PersistentVolume, the volumeAttributesClassName will be matched with unbound PersistentVolumeClaims during the binding process.", Type: []string{"string"}, Format: "", }, @@ -12118,7 +12367,7 @@ func schema_k8sio_api_core_v1_PodAntiAffinity(ref common.ReferenceCallback) comm }, }, SchemaProps: spec.SchemaProps{ - Description: "The scheduler will prefer to schedule pods to nodes that satisfy the anti-affinity expressions specified by this field, but it may choose a node that violates one or more of the expressions. The node that is most preferred is the one with the greatest sum of weights, i.e. for each node that meets all of the scheduling requirements (resource request, requiredDuringScheduling anti-affinity expressions, etc.), compute a sum by iterating through the elements of this field and adding \"weight\" to the sum if the node has pods which matches the corresponding podAffinityTerm; the node(s) with the highest sum are the most preferred.", + Description: "The scheduler will prefer to schedule pods to nodes that satisfy the anti-affinity expressions specified by this field, but it may choose a node that violates one or more of the expressions. The node that is most preferred is the one with the greatest sum of weights, i.e. for each node that meets all of the scheduling requirements (resource request, requiredDuringScheduling anti-affinity expressions, etc.), compute a sum by iterating through the elements of this field and subtracting \"weight\" from the sum if the node has pods which matches the corresponding podAffinityTerm; the node(s) with the highest sum are the most preferred.", Type: []string{"array"}, Items: &spec.SchemaOrArray{ Schema: &spec.Schema{ @@ -12200,6 +12449,78 @@ func schema_k8sio_api_core_v1_PodAttachOptions(ref common.ReferenceCallback) com } } +func schema_k8sio_api_core_v1_PodCertificateProjection(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "PodCertificateProjection provides a private key and X.509 certificate in the pod filesystem.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "signerName": { + SchemaProps: spec.SchemaProps{ + Description: "Kubelet's generated CSRs will be addressed to this signer.", + Type: []string{"string"}, + Format: "", + }, + }, + "keyType": { + SchemaProps: spec.SchemaProps{ + Description: "The type of keypair Kubelet will generate for the pod.\n\nValid values are \"RSA3072\", \"RSA4096\", \"ECDSAP256\", \"ECDSAP384\", \"ECDSAP521\", and \"ED25519\".", + Type: []string{"string"}, + Format: "", + }, + }, + "maxExpirationSeconds": { + SchemaProps: spec.SchemaProps{ + Description: "maxExpirationSeconds is the maximum lifetime permitted for the certificate.\n\nKubelet copies this value verbatim into the PodCertificateRequests it generates for this projection.\n\nIf omitted, kube-apiserver will set it to 86400(24 hours). kube-apiserver will reject values shorter than 3600 (1 hour). The maximum allowable value is 7862400 (91 days).\n\nThe signer implementation is then free to issue a certificate with any lifetime *shorter* than MaxExpirationSeconds, but no shorter than 3600 seconds (1 hour). This constraint is enforced by kube-apiserver. `kubernetes.io` signers will never issue certificates with a lifetime longer than 24 hours.", + Type: []string{"integer"}, + Format: "int32", + }, + }, + "credentialBundlePath": { + SchemaProps: spec.SchemaProps{ + Description: "Write the credential bundle at this path in the projected volume.\n\nThe credential bundle is a single file that contains multiple PEM blocks. The first PEM block is a PRIVATE KEY block, containing a PKCS#8 private key.\n\nThe remaining blocks are CERTIFICATE blocks, containing the issued certificate chain from the signer (leaf and any intermediates).\n\nUsing credentialBundlePath lets your Pod's application code make a single atomic read that retrieves a consistent key and certificate chain. If you project them to separate files, your application code will need to additionally check that the leaf certificate was issued to the key.", + Type: []string{"string"}, + Format: "", + }, + }, + "keyPath": { + SchemaProps: spec.SchemaProps{ + Description: "Write the key at this path in the projected volume.\n\nMost applications should use credentialBundlePath. When using keyPath and certificateChainPath, your application needs to check that the key and leaf certificate are consistent, because it is possible to read the files mid-rotation.", + Type: []string{"string"}, + Format: "", + }, + }, + "certificateChainPath": { + SchemaProps: spec.SchemaProps{ + Description: "Write the certificate chain at this path in the projected volume.\n\nMost applications should use credentialBundlePath. When using keyPath and certificateChainPath, your application needs to check that the key and leaf certificate are consistent, because it is possible to read the files mid-rotation.", + Type: []string{"string"}, + Format: "", + }, + }, + "userAnnotations": { + SchemaProps: spec.SchemaProps{ + Description: "userAnnotations allow pod authors to pass additional information to the signer implementation. Kubernetes does not restrict or validate this metadata in any way.\n\nThese values are copied verbatim into the `spec.unverifiedUserAnnotations` field of the PodCertificateRequest objects that Kubelet creates.\n\nEntries are subject to the same validation as object metadata annotations, with the addition that all keys must be domain-prefixed. No restrictions are placed on values, except an overall size limitation on the entire field.\n\nSigners should document the keys and values they support. Signers should deny requests that contain keys they do not recognize.", + Type: []string{"object"}, + AdditionalProperties: &spec.SchemaOrBool{ + Allows: true, + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + }, + Required: []string{"signerName", "keyType"}, + }, + }, + } +} + func schema_k8sio_api_core_v1_PodCondition(ref common.ReferenceCallback) common.OpenAPIDefinition { return common.OpenAPIDefinition{ Schema: spec.Schema{ @@ -12217,7 +12538,7 @@ func schema_k8sio_api_core_v1_PodCondition(ref common.ReferenceCallback) common. }, "observedGeneration": { SchemaProps: spec.SchemaProps{ - Description: "If set, this represents the .metadata.generation that the pod condition was set based upon. This is an alpha field. Enable PodObservedGenerationTracking to be able to use this field.", + Description: "If set, this represents the .metadata.generation that the pod condition was set based upon. The PodObservedGenerationTracking feature gate must be enabled to use this field.", Type: []string{"integer"}, Format: "int64", }, @@ -12449,6 +12770,49 @@ func schema_k8sio_api_core_v1_PodExecOptions(ref common.ReferenceCallback) commo } } +func schema_k8sio_api_core_v1_PodExtendedResourceClaimStatus(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "PodExtendedResourceClaimStatus is stored in the PodStatus for the extended resource requests backed by DRA. It stores the generated name for the corresponding special ResourceClaim created by the scheduler.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "requestMappings": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "RequestMappings identifies the mapping of to device request in the generated ResourceClaim.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("k8s.io/api/core/v1.ContainerExtendedResourceRequest"), + }, + }, + }, + }, + }, + "resourceClaimName": { + SchemaProps: spec.SchemaProps{ + Description: "ResourceClaimName is the name of the ResourceClaim that was generated for the Pod in the namespace of the Pod.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"requestMappings", "resourceClaimName"}, + }, + }, + Dependencies: []string{ + "k8s.io/api/core/v1.ContainerExtendedResourceRequest"}, + } +} + func schema_k8sio_api_core_v1_PodIP(ref common.ReferenceCallback) common.OpenAPIDefinition { return common.OpenAPIDefinition{ Schema: spec.Schema{ @@ -13166,7 +13530,7 @@ func schema_k8sio_api_core_v1_PodSpec(ref common.ReferenceCallback) common.OpenA }, "hostNetwork": { SchemaProps: spec.SchemaProps{ - Description: "Host networking requested for this pod. Use the host's network namespace. If this option is set, the ports that will be used must be specified. Default to false.", + Description: "Host networking requested for this pod. Use the host's network namespace. When using HostNetwork you should specify ports so the scheduler is aware. When `hostNetwork` is true, specified `hostPort` fields in port definitions must match `containerPort`, and unspecified `hostPort` fields in port definitions are defaulted to match `containerPort`. Default to false.", Type: []string{"boolean"}, Format: "", }, @@ -13401,7 +13765,7 @@ func schema_k8sio_api_core_v1_PodSpec(ref common.ReferenceCallback) common.OpenA }, "os": { SchemaProps: spec.SchemaProps{ - Description: "Specifies the OS of the containers in the pod. Some pod and container fields are restricted if this is set.\n\nIf the OS field is set to linux, the following fields must be unset: -securityContext.windowsOptions\n\nIf the OS field is set to windows, following fields must be unset: - spec.hostPID - spec.hostIPC - spec.hostUsers - spec.securityContext.appArmorProfile - spec.securityContext.seLinuxOptions - spec.securityContext.seccompProfile - spec.securityContext.fsGroup - spec.securityContext.fsGroupChangePolicy - spec.securityContext.sysctls - spec.shareProcessNamespace - spec.securityContext.runAsUser - spec.securityContext.runAsGroup - spec.securityContext.supplementalGroups - spec.securityContext.supplementalGroupsPolicy - spec.containers[*].securityContext.appArmorProfile - spec.containers[*].securityContext.seLinuxOptions - spec.containers[*].securityContext.seccompProfile - spec.containers[*].securityContext.capabilities - spec.containers[*].securityContext.readOnlyRootFilesystem - spec.containers[*].securityContext.privileged - spec.containers[*].securityContext.allowPrivilegeEscalation - spec.containers[*].securityContext.procMount - spec.containers[*].securityContext.runAsUser - spec.containers[*].securityContext.runAsGroup", + Description: "Specifies the OS of the containers in the pod. Some pod and container fields are restricted if this is set.\n\nIf the OS field is set to linux, the following fields must be unset: -securityContext.windowsOptions\n\nIf the OS field is set to windows, following fields must be unset: - spec.hostPID - spec.hostIPC - spec.hostUsers - spec.resources - spec.securityContext.appArmorProfile - spec.securityContext.seLinuxOptions - spec.securityContext.seccompProfile - spec.securityContext.fsGroup - spec.securityContext.fsGroupChangePolicy - spec.securityContext.sysctls - spec.shareProcessNamespace - spec.securityContext.runAsUser - spec.securityContext.runAsGroup - spec.securityContext.supplementalGroups - spec.securityContext.supplementalGroupsPolicy - spec.containers[*].securityContext.appArmorProfile - spec.containers[*].securityContext.seLinuxOptions - spec.containers[*].securityContext.seccompProfile - spec.containers[*].securityContext.capabilities - spec.containers[*].securityContext.readOnlyRootFilesystem - spec.containers[*].securityContext.privileged - spec.containers[*].securityContext.allowPrivilegeEscalation - spec.containers[*].securityContext.procMount - spec.containers[*].securityContext.runAsUser - spec.containers[*].securityContext.runAsGroup", Ref: ref("k8s.io/api/core/v1.PodOS"), }, }, @@ -13448,7 +13812,7 @@ func schema_k8sio_api_core_v1_PodSpec(ref common.ReferenceCallback) common.OpenA }, }, SchemaProps: spec.SchemaProps{ - Description: "ResourceClaims defines which ResourceClaims must be allocated and reserved before the Pod is allowed to start. The resources will be made available to those containers which consume them by name.\n\nThis is an alpha field and requires enabling the DynamicResourceAllocation feature gate.\n\nThis field is immutable.", + Description: "ResourceClaims defines which ResourceClaims must be allocated and reserved before the Pod is allowed to start. The resources will be made available to those containers which consume them by name.\n\nThis is a stable field but requires that the DynamicResourceAllocation feature gate is enabled.\n\nThis field is immutable.", Type: []string{"array"}, Items: &spec.SchemaOrArray{ Schema: &spec.Schema{ @@ -13462,16 +13826,29 @@ func schema_k8sio_api_core_v1_PodSpec(ref common.ReferenceCallback) common.OpenA }, "resources": { SchemaProps: spec.SchemaProps{ - Description: "Resources is the total amount of CPU and Memory resources required by all containers in the pod. It supports specifying Requests and Limits for \"cpu\" and \"memory\" resource names only. ResourceClaims are not supported.\n\nThis field enables fine-grained control over resource allocation for the entire pod, allowing resource sharing among containers in a pod.\n\nThis is an alpha field and requires enabling the PodLevelResources feature gate.", + Description: "Resources is the total amount of CPU and Memory resources required by all containers in the pod. It supports specifying Requests and Limits for \"cpu\", \"memory\" and \"hugepages-\" resource names only. ResourceClaims are not supported.\n\nThis field enables fine-grained control over resource allocation for the entire pod, allowing resource sharing among containers in a pod.\n\nThis is an alpha field and requires enabling the PodLevelResources feature gate.", Ref: ref("k8s.io/api/core/v1.ResourceRequirements"), }, }, + "hostnameOverride": { + SchemaProps: spec.SchemaProps{ + Description: "HostnameOverride specifies an explicit override for the pod's hostname as perceived by the pod. This field only specifies the pod's hostname and does not affect its DNS records. When this field is set to a non-empty string: - It takes precedence over the values set in `hostname` and `subdomain`. - The Pod's hostname will be set to this value. - `setHostnameAsFQDN` must be nil or set to false. - `hostNetwork` must be set to false.\n\nThis field must be a valid DNS subdomain as defined in RFC 1123 and contain at most 64 characters. Requires the HostnameOverride feature gate to be enabled.", + Type: []string{"string"}, + Format: "", + }, + }, + "workloadRef": { + SchemaProps: spec.SchemaProps{ + Description: "WorkloadRef provides a reference to the Workload object that this Pod belongs to. This field is used by the scheduler to identify the PodGroup and apply the correct group scheduling policies. The Workload object referenced by this field may not exist at the time the Pod is created. This field is immutable, but a Workload object with the same name may be recreated with different policies. Doing this during pod scheduling may result in the placement not conforming to the expected policies.", + Ref: ref("k8s.io/api/core/v1.WorkloadReference"), + }, + }, }, Required: []string{"containers"}, }, }, Dependencies: []string{ - "k8s.io/api/core/v1.Affinity", "k8s.io/api/core/v1.Container", "k8s.io/api/core/v1.EphemeralContainer", "k8s.io/api/core/v1.HostAlias", "k8s.io/api/core/v1.LocalObjectReference", "k8s.io/api/core/v1.PodDNSConfig", "k8s.io/api/core/v1.PodOS", "k8s.io/api/core/v1.PodReadinessGate", "k8s.io/api/core/v1.PodResourceClaim", "k8s.io/api/core/v1.PodSchedulingGate", "k8s.io/api/core/v1.PodSecurityContext", "k8s.io/api/core/v1.ResourceRequirements", "k8s.io/api/core/v1.Toleration", "k8s.io/api/core/v1.TopologySpreadConstraint", "k8s.io/api/core/v1.Volume", "k8s.io/apimachinery/pkg/api/resource.Quantity"}, + "k8s.io/api/core/v1.Affinity", "k8s.io/api/core/v1.Container", "k8s.io/api/core/v1.EphemeralContainer", "k8s.io/api/core/v1.HostAlias", "k8s.io/api/core/v1.LocalObjectReference", "k8s.io/api/core/v1.PodDNSConfig", "k8s.io/api/core/v1.PodOS", "k8s.io/api/core/v1.PodReadinessGate", "k8s.io/api/core/v1.PodResourceClaim", "k8s.io/api/core/v1.PodSchedulingGate", "k8s.io/api/core/v1.PodSecurityContext", "k8s.io/api/core/v1.ResourceRequirements", "k8s.io/api/core/v1.Toleration", "k8s.io/api/core/v1.TopologySpreadConstraint", "k8s.io/api/core/v1.Volume", "k8s.io/api/core/v1.WorkloadReference", "k8s.io/apimachinery/pkg/api/resource.Quantity"}, } } @@ -13484,7 +13861,7 @@ func schema_k8sio_api_core_v1_PodStatus(ref common.ReferenceCallback) common.Ope Properties: map[string]spec.Schema{ "observedGeneration": { SchemaProps: spec.SchemaProps{ - Description: "If set, this represents the .metadata.generation that the pod status was set based upon. This is an alpha field. Enable PodObservedGenerationTracking to be able to use this field.", + Description: "If set, this represents the .metadata.generation that the pod status was set based upon. The PodObservedGenerationTracking feature gate must be enabled to use this field.", Type: []string{"integer"}, Format: "int64", }, @@ -13703,11 +14080,37 @@ func schema_k8sio_api_core_v1_PodStatus(ref common.ReferenceCallback) common.Ope }, }, }, + "extendedResourceClaimStatus": { + SchemaProps: spec.SchemaProps{ + Description: "Status of extended resource claim backed by DRA.", + Ref: ref("k8s.io/api/core/v1.PodExtendedResourceClaimStatus"), + }, + }, + "allocatedResources": { + SchemaProps: spec.SchemaProps{ + Description: "AllocatedResources is the total requests allocated for this pod by the node. If pod-level requests are not set, this will be the total requests aggregated across containers in the pod.", + Type: []string{"object"}, + AdditionalProperties: &spec.SchemaOrBool{ + Allows: true, + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Ref: ref("k8s.io/apimachinery/pkg/api/resource.Quantity"), + }, + }, + }, + }, + }, + "resources": { + SchemaProps: spec.SchemaProps{ + Description: "Resources represents the compute resource requests and limits that have been applied at the pod level if pod-level requests or limits are set in PodSpec.Resources", + Ref: ref("k8s.io/api/core/v1.ResourceRequirements"), + }, + }, }, }, }, Dependencies: []string{ - "k8s.io/api/core/v1.ContainerStatus", "k8s.io/api/core/v1.HostIP", "k8s.io/api/core/v1.PodCondition", "k8s.io/api/core/v1.PodIP", "k8s.io/api/core/v1.PodResourceClaimStatus", "k8s.io/apimachinery/pkg/apis/meta/v1.Time"}, + "k8s.io/api/core/v1.ContainerStatus", "k8s.io/api/core/v1.HostIP", "k8s.io/api/core/v1.PodCondition", "k8s.io/api/core/v1.PodExtendedResourceClaimStatus", "k8s.io/api/core/v1.PodIP", "k8s.io/api/core/v1.PodResourceClaimStatus", "k8s.io/api/core/v1.ResourceRequirements", "k8s.io/apimachinery/pkg/api/resource.Quantity", "k8s.io/apimachinery/pkg/apis/meta/v1.Time"}, } } @@ -15104,7 +15507,7 @@ func schema_k8sio_api_core_v1_ResourceRequirements(ref common.ReferenceCallback) }, }, SchemaProps: spec.SchemaProps{ - Description: "Claims lists the names of resources, defined in spec.resourceClaims, that are used by this container.\n\nThis is an alpha field and requires enabling the DynamicResourceAllocation feature gate.\n\nThis field is immutable. It can only be set for containers.", + Description: "Claims lists the names of resources, defined in spec.resourceClaims, that are used by this container.\n\nThis field depends on the DynamicResourceAllocation feature gate.\n\nThis field is immutable. It can only be set for containers.", Type: []string{"array"}, Items: &spec.SchemaOrArray{ Schema: &spec.Schema{ @@ -16882,7 +17285,7 @@ func schema_k8sio_api_core_v1_Taint(ref common.ReferenceCallback) common.OpenAPI }, "timeAdded": { SchemaProps: spec.SchemaProps{ - Description: "TimeAdded represents the time at which the taint was added. It is only written for NoExecute taints.", + Description: "TimeAdded represents the time at which the taint was added.", Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.Time"), }, }, @@ -16911,10 +17314,10 @@ func schema_k8sio_api_core_v1_Toleration(ref common.ReferenceCallback) common.Op }, "operator": { SchemaProps: spec.SchemaProps{ - Description: "Operator represents a key's relationship to the value. Valid operators are Exists and Equal. Defaults to Equal. Exists is equivalent to wildcard for value, so that a pod can tolerate all taints of a particular category.\n\nPossible enum values:\n - `\"Equal\"`\n - `\"Exists\"`", + Description: "Operator represents a key's relationship to the value. Valid operators are Exists, Equal, Lt, and Gt. Defaults to Equal. Exists is equivalent to wildcard for value, so that a pod can tolerate all taints of a particular category. Lt and Gt perform numeric comparisons (requires feature gate TaintTolerationComparisonOperators).\n\nPossible enum values:\n - `\"Equal\"`\n - `\"Exists\"`\n - `\"Gt\"`\n - `\"Lt\"`", Type: []string{"string"}, Format: "", - Enum: []interface{}{"Equal", "Exists"}, + Enum: []interface{}{"Equal", "Exists", "Gt", "Lt"}, }, }, "value": { @@ -17261,13 +17664,13 @@ func schema_k8sio_api_core_v1_Volume(ref common.ReferenceCallback) common.OpenAP }, "iscsi": { SchemaProps: spec.SchemaProps{ - Description: "iscsi represents an ISCSI Disk resource that is attached to a kubelet's host machine and then exposed to the pod. More info: https://examples.k8s.io/volumes/iscsi/README.md", + Description: "iscsi represents an ISCSI Disk resource that is attached to a kubelet's host machine and then exposed to the pod. More info: https://kubernetes.io/docs/concepts/storage/volumes/#iscsi", Ref: ref("k8s.io/api/core/v1.ISCSIVolumeSource"), }, }, "glusterfs": { SchemaProps: spec.SchemaProps{ - Description: "glusterfs represents a Glusterfs mount on the host that shares a pod's lifetime. Deprecated: Glusterfs is deprecated and the in-tree glusterfs type is no longer supported. More info: https://examples.k8s.io/volumes/glusterfs/README.md", + Description: "glusterfs represents a Glusterfs mount on the host that shares a pod's lifetime. Deprecated: Glusterfs is deprecated and the in-tree glusterfs type is no longer supported.", Ref: ref("k8s.io/api/core/v1.GlusterfsVolumeSource"), }, }, @@ -17279,7 +17682,7 @@ func schema_k8sio_api_core_v1_Volume(ref common.ReferenceCallback) common.OpenAP }, "rbd": { SchemaProps: spec.SchemaProps{ - Description: "rbd represents a Rados Block Device mount on the host that shares a pod's lifetime. Deprecated: RBD is deprecated and the in-tree rbd type is no longer supported. More info: https://examples.k8s.io/volumes/rbd/README.md", + Description: "rbd represents a Rados Block Device mount on the host that shares a pod's lifetime. Deprecated: RBD is deprecated and the in-tree rbd type is no longer supported.", Ref: ref("k8s.io/api/core/v1.RBDVolumeSource"), }, }, @@ -17604,11 +18007,17 @@ func schema_k8sio_api_core_v1_VolumeProjection(ref common.ReferenceCallback) com Ref: ref("k8s.io/api/core/v1.ClusterTrustBundleProjection"), }, }, + "podCertificate": { + SchemaProps: spec.SchemaProps{ + Description: "Projects an auto-rotating credential bundle (private key and certificate chain) that the pod can use either as a TLS client or server.\n\nKubelet generates a private key and uses it to send a PodCertificateRequest to the named signer. Once the signer approves the request and issues a certificate chain, Kubelet writes the key and certificate chain to the pod filesystem. The pod does not start until certificates have been issued for each podCertificate projected volume source in its spec.\n\nKubelet will begin trying to rotate the certificate at the time indicated by the signer using the PodCertificateRequest.Status.BeginRefreshAt timestamp.\n\nKubelet can write a single file, indicated by the credentialBundlePath field, or separate files, indicated by the keyPath and certificateChainPath fields.\n\nThe credential bundle is a single file in PEM format. The first PEM entry is the private key (in PKCS#8 format), and the remaining PEM entries are the certificate chain issued by the signer (typically, signers will return their certificate chain in leaf-to-root order).\n\nPrefer using the credential bundle format, since your application code can read it atomically. If you use keyPath and certificateChainPath, your application must make two separate file reads. If these coincide with a certificate rotation, it is possible that the private key and leaf certificate you read may not correspond to each other. Your application will need to check for this condition, and re-read until they are consistent.\n\nThe named signer controls chooses the format of the certificate it issues; consult the signer implementation's documentation to learn how to use the certificates it issues.", + Ref: ref("k8s.io/api/core/v1.PodCertificateProjection"), + }, + }, }, }, }, Dependencies: []string{ - "k8s.io/api/core/v1.ClusterTrustBundleProjection", "k8s.io/api/core/v1.ConfigMapProjection", "k8s.io/api/core/v1.DownwardAPIProjection", "k8s.io/api/core/v1.SecretProjection", "k8s.io/api/core/v1.ServiceAccountTokenProjection"}, + "k8s.io/api/core/v1.ClusterTrustBundleProjection", "k8s.io/api/core/v1.ConfigMapProjection", "k8s.io/api/core/v1.DownwardAPIProjection", "k8s.io/api/core/v1.PodCertificateProjection", "k8s.io/api/core/v1.SecretProjection", "k8s.io/api/core/v1.ServiceAccountTokenProjection"}, } } @@ -17706,13 +18115,13 @@ func schema_k8sio_api_core_v1_VolumeSource(ref common.ReferenceCallback) common. }, "iscsi": { SchemaProps: spec.SchemaProps{ - Description: "iscsi represents an ISCSI Disk resource that is attached to a kubelet's host machine and then exposed to the pod. More info: https://examples.k8s.io/volumes/iscsi/README.md", + Description: "iscsi represents an ISCSI Disk resource that is attached to a kubelet's host machine and then exposed to the pod. More info: https://kubernetes.io/docs/concepts/storage/volumes/#iscsi", Ref: ref("k8s.io/api/core/v1.ISCSIVolumeSource"), }, }, "glusterfs": { SchemaProps: spec.SchemaProps{ - Description: "glusterfs represents a Glusterfs mount on the host that shares a pod's lifetime. Deprecated: Glusterfs is deprecated and the in-tree glusterfs type is no longer supported. More info: https://examples.k8s.io/volumes/glusterfs/README.md", + Description: "glusterfs represents a Glusterfs mount on the host that shares a pod's lifetime. Deprecated: Glusterfs is deprecated and the in-tree glusterfs type is no longer supported.", Ref: ref("k8s.io/api/core/v1.GlusterfsVolumeSource"), }, }, @@ -17724,7 +18133,7 @@ func schema_k8sio_api_core_v1_VolumeSource(ref common.ReferenceCallback) common. }, "rbd": { SchemaProps: spec.SchemaProps{ - Description: "rbd represents a Rados Block Device mount on the host that shares a pod's lifetime. Deprecated: RBD is deprecated and the in-tree rbd type is no longer supported. More info: https://examples.k8s.io/volumes/rbd/README.md", + Description: "rbd represents a Rados Block Device mount on the host that shares a pod's lifetime. Deprecated: RBD is deprecated and the in-tree rbd type is no longer supported.", Ref: ref("k8s.io/api/core/v1.RBDVolumeSource"), }, }, @@ -17965,6 +18374,43 @@ func schema_k8sio_api_core_v1_WindowsSecurityContextOptions(ref common.Reference } } +func schema_k8sio_api_core_v1_WorkloadReference(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "WorkloadReference identifies the Workload object and PodGroup membership that a Pod belongs to. The scheduler uses this information to apply workload-aware scheduling semantics.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "name": { + SchemaProps: spec.SchemaProps{ + Description: "Name defines the name of the Workload object this Pod belongs to. Workload must be in the same namespace as the Pod. If it doesn't match any existing Workload, the Pod will remain unschedulable until a Workload object is created and observed by the kube-scheduler. It must be a DNS subdomain.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "podGroup": { + SchemaProps: spec.SchemaProps{ + Description: "PodGroup is the name of the PodGroup within the Workload that this Pod belongs to. If it doesn't match any existing PodGroup within the Workload, the Pod will remain unschedulable until the Workload object is recreated and observed by the kube-scheduler. It must be a DNS label.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "podGroupReplicaKey": { + SchemaProps: spec.SchemaProps{ + Description: "PodGroupReplicaKey specifies the replica key of the PodGroup to which this Pod belongs. It is used to distinguish pods belonging to different replicas of the same pod group. The pod group policy is applied separately to each replica. When set, it must be a DNS label.", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"name", "podGroup"}, + }, + }, + } +} + func schema_apimachinery_pkg_api_resource_Quantity(ref common.ReferenceCallback) common.OpenAPIDefinition { return common.EmbedOpenAPIDefinitionIntoV2Extension(common.OpenAPIDefinition{ Schema: spec.Schema{ @@ -19900,11 +20346,6 @@ func schema_pkg_apis_meta_v1_Status(ref common.ReferenceCallback) common.OpenAPI }, }, "details": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, SchemaProps: spec.SchemaProps{ Description: "Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type.", Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.StatusDetails"), From 61c7e622f6c82c351a3329e9f19cc696629ee0ea Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Wed, 18 Feb 2026 10:25:52 +0100 Subject: [PATCH 006/135] rework ssa --- Makefile | 1 + apis/config/v1alpha1/config_helpers.go | 33 +++ apis/inv/v1alpha1/target_helpers.go | 26 ++ pkg/discovery/discoveryrule/target.go | 151 +++-------- .../config/v1alpha1/config.go | 244 +++++++++++++++++ .../config/v1alpha1/configblame.go | 245 ++++++++++++++++++ .../config/v1alpha1/configblamestatus.go | 44 ++++ .../config/v1alpha1/configblob.go | 52 ++++ .../config/v1alpha1/configdeviation.go | 70 +++++ .../config/v1alpha1/configset.go | 244 +++++++++++++++++ .../config/v1alpha1/configsetspec.go | 87 +++++++ .../config/v1alpha1/configsetstatus.go | 63 +++++ .../config/v1alpha1/configspec.go | 77 ++++++ .../config/v1alpha1/configstatus.go | 78 ++++++ .../configstatuslastknowngoodschema.go | 59 +++++ .../config/v1alpha1/deviation.go | 244 +++++++++++++++++ .../config/v1alpha1/deviationspec.go | 59 +++++ .../config/v1alpha1/deviationstatus.go | 48 ++++ .../config/v1alpha1/lifecycle.go | 45 ++++ .../config/v1alpha1/runningconfig.go | 245 ++++++++++++++++++ .../config/v1alpha1/runningconfigstatus.go | 44 ++++ .../config/v1alpha1/sensitiveconfig.go | 244 +++++++++++++++++ .../config/v1alpha1/sensitiveconfigdata.go | 53 ++++ .../config/v1alpha1/sensitiveconfigspec.go | 77 ++++++ .../config/v1alpha1/sensitiveconfigstatus.go | 78 ++++++ .../config/v1alpha1/target.go | 43 +++ .../config/v1alpha1/targetstatus.go | 46 ++++ .../applyconfiguration/internal/internal.go | 61 +++++ .../inv/v1alpha1/discoveryinfo.go | 111 ++++++++ .../inv/v1alpha1/discoveryparameters.go | 100 +++++++ .../inv/v1alpha1/discoverypathdefinition.go | 69 +++++ .../inv/v1alpha1/discoveryprofile.go | 62 +++++ .../inv/v1alpha1/discoveryrule.go | 244 +++++++++++++++++ .../inv/v1alpha1/discoveryruleaddress.go | 49 ++++ .../inv/v1alpha1/discoveryruleprefix.go | 51 ++++ .../inv/v1alpha1/discoveryrulespec.go | 152 +++++++++++ .../inv/v1alpha1/discoveryrulestatus.go | 62 +++++ .../inv/v1alpha1/discoveryvendorprofile.go | 235 +++++++++++++++++ .../v1alpha1/discoveryvendorprofilespec.go | 40 +++ .../gnmidiscoveryvendorprofileparameters.go | 84 ++++++ .../applyconfiguration/inv/v1alpha1/proxy.go | 49 ++++ .../inv/v1alpha1/repository.go | 84 ++++++ .../inv/v1alpha1/rollout.go | 244 +++++++++++++++++ .../inv/v1alpha1/rolloutspec.go | 94 +++++++ .../inv/v1alpha1/rolloutstatus.go | 62 +++++ .../inv/v1alpha1/rollouttargetstatus.go | 54 ++++ .../applyconfiguration/inv/v1alpha1/schema.go | 244 +++++++++++++++++ .../inv/v1alpha1/schemakey.go | 49 ++++ .../inv/v1alpha1/schemarepositorystatus.go | 51 ++++ .../inv/v1alpha1/schemaspec.go | 70 +++++ .../inv/v1alpha1/schemaspecrepository.go | 101 ++++++++ .../inv/v1alpha1/schemaspecschema.go | 65 +++++ .../inv/v1alpha1/schemastatus.go | 62 +++++ .../inv/v1alpha1/srcdstpath.go | 52 ++++ .../inv/v1alpha1/subscription.go | 244 +++++++++++++++++ .../inv/v1alpha1/subscriptionparameters.go | 111 ++++++++ .../inv/v1alpha1/subscriptionspec.go | 87 +++++++ .../inv/v1alpha1/subscriptionstatus.go | 57 ++++ .../inv/v1alpha1/subscriptiontarget.go | 43 +++ .../applyconfiguration/inv/v1alpha1/target.go | 244 +++++++++++++++++ .../inv/v1alpha1/targetconnectionprofile.go | 235 +++++++++++++++++ .../v1alpha1/targetconnectionprofilespec.go | 156 +++++++++++ .../inv/v1alpha1/targetprofile.go | 69 +++++ .../inv/v1alpha1/targetspec.go | 85 ++++++ .../inv/v1alpha1/targetstatus.go | 67 +++++ .../v1alpha1/targetstatususedreferences.go | 65 +++++ .../inv/v1alpha1/targetsyncprofile.go | 235 +++++++++++++++++ .../inv/v1alpha1/targetsyncprofilespec.go | 72 +++++ .../inv/v1alpha1/targetsyncprofilesync.go | 102 ++++++++ .../inv/v1alpha1/targettemplate.go | 73 ++++++ .../inv/v1alpha1/workspace.go | 244 +++++++++++++++++ .../inv/v1alpha1/workspacespec.go | 76 ++++++ .../inv/v1alpha1/workspacestatus.go | 68 +++++ pkg/generated/applyconfiguration/utils.go | 181 +++++++++++++ pkg/reconcilers/configset/reconciler.go | 61 ++++- pkg/reconcilers/discoveryrule/reconciler.go | 52 ++-- pkg/reconcilers/rollout/reconciler.go | 36 ++- pkg/reconcilers/schema/reconciler.go | 73 ++++-- pkg/reconcilers/subscription/reconciler.go | 51 ++-- pkg/reconcilers/target/reconciler.go | 31 +-- pkg/reconcilers/targetdatastore/reconciler.go | 107 ++++---- pkg/reconcilers/targetrecovery/reconciler.go | 75 ++---- pkg/reconcilers/workspace/reconciler.go | 100 +------ pkg/sdc/ctx/schemaserver_context.go | 152 ----------- pkg/sdc/target/manager/deviation_watcher.go | 45 ++-- pkg/sdc/target/manager/runtime.go | 36 +-- pkg/sdc/target/manager/transactor.go | 203 +++++++++------ tools/apiserver-runtime-gen/main.go | 14 +- 88 files changed, 8184 insertions(+), 667 deletions(-) create mode 100644 pkg/generated/applyconfiguration/config/v1alpha1/config.go create mode 100644 pkg/generated/applyconfiguration/config/v1alpha1/configblame.go create mode 100644 pkg/generated/applyconfiguration/config/v1alpha1/configblamestatus.go create mode 100644 pkg/generated/applyconfiguration/config/v1alpha1/configblob.go create mode 100644 pkg/generated/applyconfiguration/config/v1alpha1/configdeviation.go create mode 100644 pkg/generated/applyconfiguration/config/v1alpha1/configset.go create mode 100644 pkg/generated/applyconfiguration/config/v1alpha1/configsetspec.go create mode 100644 pkg/generated/applyconfiguration/config/v1alpha1/configsetstatus.go create mode 100644 pkg/generated/applyconfiguration/config/v1alpha1/configspec.go create mode 100644 pkg/generated/applyconfiguration/config/v1alpha1/configstatus.go create mode 100644 pkg/generated/applyconfiguration/config/v1alpha1/configstatuslastknowngoodschema.go create mode 100644 pkg/generated/applyconfiguration/config/v1alpha1/deviation.go create mode 100644 pkg/generated/applyconfiguration/config/v1alpha1/deviationspec.go create mode 100644 pkg/generated/applyconfiguration/config/v1alpha1/deviationstatus.go create mode 100644 pkg/generated/applyconfiguration/config/v1alpha1/lifecycle.go create mode 100644 pkg/generated/applyconfiguration/config/v1alpha1/runningconfig.go create mode 100644 pkg/generated/applyconfiguration/config/v1alpha1/runningconfigstatus.go create mode 100644 pkg/generated/applyconfiguration/config/v1alpha1/sensitiveconfig.go create mode 100644 pkg/generated/applyconfiguration/config/v1alpha1/sensitiveconfigdata.go create mode 100644 pkg/generated/applyconfiguration/config/v1alpha1/sensitiveconfigspec.go create mode 100644 pkg/generated/applyconfiguration/config/v1alpha1/sensitiveconfigstatus.go create mode 100644 pkg/generated/applyconfiguration/config/v1alpha1/target.go create mode 100644 pkg/generated/applyconfiguration/config/v1alpha1/targetstatus.go create mode 100644 pkg/generated/applyconfiguration/internal/internal.go create mode 100644 pkg/generated/applyconfiguration/inv/v1alpha1/discoveryinfo.go create mode 100644 pkg/generated/applyconfiguration/inv/v1alpha1/discoveryparameters.go create mode 100644 pkg/generated/applyconfiguration/inv/v1alpha1/discoverypathdefinition.go create mode 100644 pkg/generated/applyconfiguration/inv/v1alpha1/discoveryprofile.go create mode 100644 pkg/generated/applyconfiguration/inv/v1alpha1/discoveryrule.go create mode 100644 pkg/generated/applyconfiguration/inv/v1alpha1/discoveryruleaddress.go create mode 100644 pkg/generated/applyconfiguration/inv/v1alpha1/discoveryruleprefix.go create mode 100644 pkg/generated/applyconfiguration/inv/v1alpha1/discoveryrulespec.go create mode 100644 pkg/generated/applyconfiguration/inv/v1alpha1/discoveryrulestatus.go create mode 100644 pkg/generated/applyconfiguration/inv/v1alpha1/discoveryvendorprofile.go create mode 100644 pkg/generated/applyconfiguration/inv/v1alpha1/discoveryvendorprofilespec.go create mode 100644 pkg/generated/applyconfiguration/inv/v1alpha1/gnmidiscoveryvendorprofileparameters.go create mode 100644 pkg/generated/applyconfiguration/inv/v1alpha1/proxy.go create mode 100644 pkg/generated/applyconfiguration/inv/v1alpha1/repository.go create mode 100644 pkg/generated/applyconfiguration/inv/v1alpha1/rollout.go create mode 100644 pkg/generated/applyconfiguration/inv/v1alpha1/rolloutspec.go create mode 100644 pkg/generated/applyconfiguration/inv/v1alpha1/rolloutstatus.go create mode 100644 pkg/generated/applyconfiguration/inv/v1alpha1/rollouttargetstatus.go create mode 100644 pkg/generated/applyconfiguration/inv/v1alpha1/schema.go create mode 100644 pkg/generated/applyconfiguration/inv/v1alpha1/schemakey.go create mode 100644 pkg/generated/applyconfiguration/inv/v1alpha1/schemarepositorystatus.go create mode 100644 pkg/generated/applyconfiguration/inv/v1alpha1/schemaspec.go create mode 100644 pkg/generated/applyconfiguration/inv/v1alpha1/schemaspecrepository.go create mode 100644 pkg/generated/applyconfiguration/inv/v1alpha1/schemaspecschema.go create mode 100644 pkg/generated/applyconfiguration/inv/v1alpha1/schemastatus.go create mode 100644 pkg/generated/applyconfiguration/inv/v1alpha1/srcdstpath.go create mode 100644 pkg/generated/applyconfiguration/inv/v1alpha1/subscription.go create mode 100644 pkg/generated/applyconfiguration/inv/v1alpha1/subscriptionparameters.go create mode 100644 pkg/generated/applyconfiguration/inv/v1alpha1/subscriptionspec.go create mode 100644 pkg/generated/applyconfiguration/inv/v1alpha1/subscriptionstatus.go create mode 100644 pkg/generated/applyconfiguration/inv/v1alpha1/subscriptiontarget.go create mode 100644 pkg/generated/applyconfiguration/inv/v1alpha1/target.go create mode 100644 pkg/generated/applyconfiguration/inv/v1alpha1/targetconnectionprofile.go create mode 100644 pkg/generated/applyconfiguration/inv/v1alpha1/targetconnectionprofilespec.go create mode 100644 pkg/generated/applyconfiguration/inv/v1alpha1/targetprofile.go create mode 100644 pkg/generated/applyconfiguration/inv/v1alpha1/targetspec.go create mode 100644 pkg/generated/applyconfiguration/inv/v1alpha1/targetstatus.go create mode 100644 pkg/generated/applyconfiguration/inv/v1alpha1/targetstatususedreferences.go create mode 100644 pkg/generated/applyconfiguration/inv/v1alpha1/targetsyncprofile.go create mode 100644 pkg/generated/applyconfiguration/inv/v1alpha1/targetsyncprofilespec.go create mode 100644 pkg/generated/applyconfiguration/inv/v1alpha1/targetsyncprofilesync.go create mode 100644 pkg/generated/applyconfiguration/inv/v1alpha1/targettemplate.go create mode 100644 pkg/generated/applyconfiguration/inv/v1alpha1/workspace.go create mode 100644 pkg/generated/applyconfiguration/inv/v1alpha1/workspacespec.go create mode 100644 pkg/generated/applyconfiguration/inv/v1alpha1/workspacestatus.go create mode 100644 pkg/generated/applyconfiguration/utils.go delete mode 100644 pkg/sdc/ctx/schemaserver_context.go diff --git a/Makefile b/Makefile index f8eefb2f..127e2e29 100644 --- a/Makefile +++ b/Makefile @@ -63,6 +63,7 @@ genclients: -g openapi-gen \ -g defaulter-gen \ -g conversion-gen \ + -g applyconfiguration-gen \ --module $(REPO) \ .PHONY: genproto diff --git a/apis/config/v1alpha1/config_helpers.go b/apis/config/v1alpha1/config_helpers.go index 571636e4..f69e85a9 100644 --- a/apis/config/v1alpha1/config_helpers.go +++ b/apis/config/v1alpha1/config_helpers.go @@ -306,3 +306,36 @@ func (r *Config) SetOverallStatus() { r.Status.SetConditions(condv1alpha1.Failed(msg)) } + + +func GetOverallCondition(r *Config) condv1alpha1.Condition { + cfgC := r.GetCondition(ConditionTypeConfigReady) + tgtC := r.GetCondition(ConditionTypeTargetReady) + + ready := cfgC.IsTrue() && tgtC.IsTrue() + + if ready { + return condv1alpha1.ReadyWithMsg("applied") + } + + // pick a useful message + msg := "" + switch { + case !cfgC.IsTrue(): + if cfgC.Message != "" { + msg = cfgC.Message + } else { + msg = "config not applied" + } + case !tgtC.IsTrue(): + if tgtC.Message != "" { + msg = tgtC.Message + } else { + msg = "target not ready" + } + default: + msg = "not ready" + } + + return condv1alpha1.Failed(msg) +} \ No newline at end of file diff --git a/apis/inv/v1alpha1/target_helpers.go b/apis/inv/v1alpha1/target_helpers.go index f136f426..aef722e7 100644 --- a/apis/inv/v1alpha1/target_helpers.go +++ b/apis/inv/v1alpha1/target_helpers.go @@ -67,6 +67,32 @@ func (r *Target) SetOverallStatus(target *Target) { } } + +func GetOverallStatus(target *Target) condv1alpha1.Condition { + ready := true + msg := "target ready" + if ready && !target.GetCondition(ConditionTypeDiscoveryReady).IsTrue() { + ready = false + msg = "discovery not ready" // target.GetCondition(ConditionTypeDiscoveryReady).Message) + } + if ready && !target.GetCondition(ConditionTypeDatastoreReady).IsTrue() { + ready = false + msg = "datastore not ready" // target.GetCondition(ConditionTypeDatastoreReady).Message) + } + if ready && !target.GetCondition(ConditionTypeConfigRecoveryReady).IsTrue() { + ready = false + msg = "config not ready" //, target.GetCondition(ConditionTypeConfigReady).Message) + } + if ready && !target.GetCondition(ConditionTypeTargetConnectionReady).IsTrue() { + ready = false + msg = "datastore connection not ready" // target.GetCondition(ConditionTypeTargetConnectionReady).Message) + } + if !ready { + return condv1alpha1.Failed(msg) + } + return condv1alpha1.Ready() +} + func (r *Target) IsDatastoreReady() bool { return r.GetCondition(ConditionTypeDiscoveryReady).Status == metav1.ConditionTrue && r.GetCondition(ConditionTypeDatastoreReady).Status == metav1.ConditionTrue && diff --git a/pkg/discovery/discoveryrule/target.go b/pkg/discovery/discoveryrule/target.go index 053e4e6e..46477234 100644 --- a/pkg/discovery/discoveryrule/target.go +++ b/pkg/discovery/discoveryrule/target.go @@ -26,6 +26,7 @@ import ( //condv1alpha1 "github.com/sdcio/config-server/apis/condition/v1alpha1" invv1alpha1 "github.com/sdcio/config-server/apis/inv/v1alpha1" + invv1alpha1apply "github.com/sdcio/config-server/pkg/generated/applyconfiguration/inv/v1alpha1" "github.com/sdcio/config-server/pkg/reconcilers/resource" "k8s.io/apimachinery/pkg/api/equality" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" @@ -145,143 +146,71 @@ func (r *dr) applyTarget(ctx context.Context, newTarget *invv1alpha1.Target) err time.Sleep(500 * time.Millisecond) } - // set old condition to avoid updating the new status if not changed - newTarget.SetConditions(target.GetCondition(invv1alpha1.ConditionTypeDiscoveryReady)) - // set new conditions - newTarget.SetConditions(invv1alpha1.DiscoveryReady()) + newCond := invv1alpha1.DiscoveryReady() + oldCond := target.GetCondition(invv1alpha1.ConditionTypeDiscoveryReady) - if newTarget.GetCondition(invv1alpha1.ConditionTypeDiscoveryReady).Equal(target.GetCondition(invv1alpha1.ConditionTypeDiscoveryReady)) && + if newCond.Equal(oldCond) && equality.Semantic.DeepEqual(newTarget.Spec, target.Spec) && equality.Semantic.DeepEqual(newTarget.Status.DiscoveryInfo, target.Status.DiscoveryInfo) { log.Info("handleSuccess -> no change") return nil } + log.Info("handleSuccess", - "condition change", newTarget.GetCondition(invv1alpha1.ConditionTypeDiscoveryReady).Equal(target.GetCondition(invv1alpha1.ConditionTypeDiscoveryReady)), - "spec change", equality.Semantic.DeepEqual(newTarget.Spec, target.Spec), - "discovery info change", equality.Semantic.DeepEqual(newTarget.Status.DiscoveryInfo, target.Status.DiscoveryInfo), + "condition change", !newCond.Equal(oldCond), + "spec change", !equality.Semantic.DeepEqual(newTarget.Spec, target.Spec), + "discovery info change", !equality.Semantic.DeepEqual(newTarget.Status.DiscoveryInfo, target.Status.DiscoveryInfo), ) - log.Info("newTarget", "target", newTarget) + statusApply := invv1alpha1apply.TargetStatus(). + WithConditions(newCond) + + if newTarget.Status.DiscoveryInfo != nil { + statusApply = statusApply.WithDiscoveryInfo(discoveryInfoToApply(newTarget.Status.DiscoveryInfo)) + } + + applyConfig := invv1alpha1apply.Target(newTarget.Name, newTarget.Namespace). + WithStatus(statusApply) - patch := client.MergeFrom(target.DeepCopy()) - err := r.client.Status().Patch(ctx, newTarget, patch, &client.SubResourcePatchOptions{ - PatchOptions: client.PatchOptions{ + if err := r.client.Status().Apply(ctx, applyConfig, &client.SubResourceApplyOptions{ + ApplyOptions: client.ApplyOptions{ FieldManager: reconcilerName, }, - }) - - if err != nil { + }); err != nil { log.Error("failed to patch target status", "err", err) return err } - /* - //targetPatch := targetCurrent.DeepCopy() - //targetPatch.Status.SetConditions(invv1alpha1.DiscoveryReady()) - //targetPatch.Status.DiscoveryInfo = di - - log.Info("discovery target apply", - "Ready", targetPatch.GetCondition(condv1alpha1.ConditionTypeReady).Status, - "DSReady", targetPatch.GetCondition(invv1alpha1.ConditionTypeDatastoreReady).Status, - "ConfigReady", targetPatch.GetCondition(invv1alpha1.ConditionTypeConfigReady).Status, - "DiscoveryInfo", targetPatch.Status.DiscoveryInfo, - ) - - // Apply the patch - err := r.client.Status().Patch(ctx, targetPatch, client.Apply, &client.SubResourcePatchOptions{ - PatchOptions: client.PatchOptions{ - FieldManager: reconcilerName, - }, - }) - if err != nil { - log.Error("failed to patch target status", "err", err) - return err - } - */ - return nil } -/* -func hasChanged(ctx context.Context, curTargetCR, newTargetCR *invv1alpha1.Target) bool { - log := log.FromContext(ctx).With("target", newTargetCR.GetName(), "address", newTargetCR.Spec.Address) - - log.Info("validateDataStoreChanges", "current target status", curTargetCR.Status.GetCondition(condv1alpha1.ConditionTypeReady).Status) - if curTargetCR.Status.GetCondition(condv1alpha1.ConditionTypeReady).Status == metav1.ConditionFalse { - return true +func discoveryInfoToApply(di *invv1alpha1.DiscoveryInfo) *invv1alpha1apply.DiscoveryInfoApplyConfiguration { + if di == nil { + return nil } - - if curTargetCR.Spec.SyncProfile != nil && newTargetCR.Spec.SyncProfile != nil { - log.Info("validateDataStoreChanges", - "Provider", fmt.Sprintf("%s/%s", curTargetCR.Spec.Provider, newTargetCR.Spec.Provider), - "Address", fmt.Sprintf("%s/%s", curTargetCR.Spec.Address, newTargetCR.Spec.Address), - "connectionProfile", fmt.Sprintf("%s/%s", curTargetCR.Spec.ConnectionProfile, newTargetCR.Spec.ConnectionProfile), - "SyncProfile", fmt.Sprintf("%s/%s", *curTargetCR.Spec.SyncProfile, *newTargetCR.Spec.SyncProfile), - "Secret", fmt.Sprintf("%s/%s", curTargetCR.Spec.Credentials, newTargetCR.Spec.Credentials), - //"TLSSecret", fmt.Sprintf("%s/%s", *curTargetCR.Spec.TLSSecret, *newTargetCR.Spec.TLSSecret), - ) - if curTargetCR.Spec.Address != newTargetCR.Spec.Address || - curTargetCR.Spec.Provider != newTargetCR.Spec.Provider || - curTargetCR.Spec.ConnectionProfile != newTargetCR.Spec.ConnectionProfile || - *curTargetCR.Spec.SyncProfile != *newTargetCR.Spec.SyncProfile || - curTargetCR.Spec.Credentials != newTargetCR.Spec.Credentials { // TODO TLS Secret - return true - } - } else { - log.Info("validateDataStoreChanges", - "Provider", fmt.Sprintf("%s/%s", curTargetCR.Spec.Provider, newTargetCR.Spec.Provider), - "Address", fmt.Sprintf("%s/%s", curTargetCR.Spec.Address, newTargetCR.Spec.Address), - "connectionProfile", fmt.Sprintf("%s/%s", curTargetCR.Spec.ConnectionProfile, newTargetCR.Spec.ConnectionProfile), - "Secret", fmt.Sprintf("%s/%s", curTargetCR.Spec.Credentials, newTargetCR.Spec.Credentials), - //"TLSSecret", fmt.Sprintf("%s/%s", *curTargetCR.Spec.TLSSecret, *newTargetCR.Spec.TLSSecret), - ) - - if curTargetCR.Spec.Address != newTargetCR.Spec.Address || - curTargetCR.Spec.Provider != newTargetCR.Spec.Provider || - curTargetCR.Spec.ConnectionProfile != newTargetCR.Spec.ConnectionProfile || - curTargetCR.Spec.Credentials != newTargetCR.Spec.Credentials { // TODO TLS Secret - return true - } + a := invv1alpha1apply.DiscoveryInfo() + if di.Protocol != "" { + a.WithProtocol(di.Protocol) } - - if curTargetCR.Status.DiscoveryInfo == nil { - log.Info("validateDataStoreChanges", "DiscoveryInfo", "nil") - return true + if di.Provider != "" { + a.WithProvider(di.Provider) } - - log.Info("validateDataStoreChanges", - "Protocol", fmt.Sprintf("%s/%s", curTargetCR.Status.DiscoveryInfo.Protocol, newTargetCR.Status.DiscoveryInfo.Protocol), - "Provider", fmt.Sprintf("%s/%s", curTargetCR.Status.DiscoveryInfo.Provider, newTargetCR.Status.DiscoveryInfo.Provider), - "Version", fmt.Sprintf("%s/%s", curTargetCR.Status.DiscoveryInfo.Version, newTargetCR.Status.DiscoveryInfo.Version), - "HostName", fmt.Sprintf("%s/%s", curTargetCR.Status.DiscoveryInfo.HostName, newTargetCR.Status.DiscoveryInfo.HostName), - "Platform", fmt.Sprintf("%s/%s", curTargetCR.Status.DiscoveryInfo.Platform, newTargetCR.Status.DiscoveryInfo.Platform), - "MacAddress", fmt.Sprintf("%s/%s", curTargetCR.Status.DiscoveryInfo.MacAddress, newTargetCR.Status.DiscoveryInfo.MacAddress), - "SerialNumber", fmt.Sprintf("%s/%s", curTargetCR.Status.DiscoveryInfo.SerialNumber, newTargetCR.Status.DiscoveryInfo.SerialNumber), - ) - - if curTargetCR.Status.DiscoveryInfo.Protocol != newTargetCR.Status.DiscoveryInfo.Protocol || - curTargetCR.Status.DiscoveryInfo.Provider != newTargetCR.Status.DiscoveryInfo.Provider || - curTargetCR.Status.DiscoveryInfo.Version != newTargetCR.Status.DiscoveryInfo.Version || - curTargetCR.Status.DiscoveryInfo.HostName != newTargetCR.Status.DiscoveryInfo.HostName || - curTargetCR.Status.DiscoveryInfo.Platform != newTargetCR.Status.DiscoveryInfo.Platform { - return true + if di.Version != "" { + a.WithVersion(di.Version) } - - if newTargetCR.Status.DiscoveryInfo.SerialNumber != "" && (curTargetCR.Status.DiscoveryInfo.SerialNumber != newTargetCR.Status.DiscoveryInfo.SerialNumber) { - return true + if di.HostName != "" { + a.WithHostName(di.HostName) } - - if newTargetCR.Status.DiscoveryInfo.MacAddress != "" && (curTargetCR.Status.DiscoveryInfo.MacAddress != newTargetCR.Status.DiscoveryInfo.MacAddress) { - return true + if di.Platform != "" { + a.WithPlatform(di.Platform) } - - if newTargetCR.Status.DiscoveryInfo.Platform != "" && (curTargetCR.Status.DiscoveryInfo.Platform != newTargetCR.Status.DiscoveryInfo.Platform) { - return true + if di.MacAddress != "" { + a.WithMacAddress(di.MacAddress) } - - return false + if di.SerialNumber != "" { + a.WithSerialNumber(di.SerialNumber) + } + return a } -*/ func getTargetName(s string) string { targetName := strings.ReplaceAll(s, ":", "-") diff --git a/pkg/generated/applyconfiguration/config/v1alpha1/config.go b/pkg/generated/applyconfiguration/config/v1alpha1/config.go new file mode 100644 index 00000000..c0411794 --- /dev/null +++ b/pkg/generated/applyconfiguration/config/v1alpha1/config.go @@ -0,0 +1,244 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ +// Code generated by applyconfiguration-gen. DO NOT EDIT. + +package v1alpha1 + +import ( + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + types "k8s.io/apimachinery/pkg/types" + v1 "k8s.io/client-go/applyconfigurations/meta/v1" +) + +// ConfigApplyConfiguration represents a declarative configuration of the Config type for use +// with apply. +// +// Config defines the Schema for the Config API +type ConfigApplyConfiguration struct { + v1.TypeMetaApplyConfiguration `json:",inline"` + *v1.ObjectMetaApplyConfiguration `json:"metadata,omitempty"` + Spec *ConfigSpecApplyConfiguration `json:"spec,omitempty"` + Status *ConfigStatusApplyConfiguration `json:"status,omitempty"` +} + +// Config constructs a declarative configuration of the Config type for use with +// apply. +func Config(name, namespace string) *ConfigApplyConfiguration { + b := &ConfigApplyConfiguration{} + b.WithName(name) + b.WithNamespace(namespace) + b.WithKind("Config") + b.WithAPIVersion("config.sdcio.dev/v1alpha1") + return b +} + +func (b ConfigApplyConfiguration) IsApplyConfiguration() {} + +// WithKind sets the Kind field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Kind field is set to the value of the last call. +func (b *ConfigApplyConfiguration) WithKind(value string) *ConfigApplyConfiguration { + b.TypeMetaApplyConfiguration.Kind = &value + return b +} + +// WithAPIVersion sets the APIVersion field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the APIVersion field is set to the value of the last call. +func (b *ConfigApplyConfiguration) WithAPIVersion(value string) *ConfigApplyConfiguration { + b.TypeMetaApplyConfiguration.APIVersion = &value + return b +} + +// WithName sets the Name field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Name field is set to the value of the last call. +func (b *ConfigApplyConfiguration) WithName(value string) *ConfigApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.Name = &value + return b +} + +// WithGenerateName sets the GenerateName field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the GenerateName field is set to the value of the last call. +func (b *ConfigApplyConfiguration) WithGenerateName(value string) *ConfigApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.GenerateName = &value + return b +} + +// WithNamespace sets the Namespace field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Namespace field is set to the value of the last call. +func (b *ConfigApplyConfiguration) WithNamespace(value string) *ConfigApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.Namespace = &value + return b +} + +// WithUID sets the UID field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the UID field is set to the value of the last call. +func (b *ConfigApplyConfiguration) WithUID(value types.UID) *ConfigApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.UID = &value + return b +} + +// WithResourceVersion sets the ResourceVersion field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the ResourceVersion field is set to the value of the last call. +func (b *ConfigApplyConfiguration) WithResourceVersion(value string) *ConfigApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.ResourceVersion = &value + return b +} + +// WithGeneration sets the Generation field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Generation field is set to the value of the last call. +func (b *ConfigApplyConfiguration) WithGeneration(value int64) *ConfigApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.Generation = &value + return b +} + +// WithCreationTimestamp sets the CreationTimestamp field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the CreationTimestamp field is set to the value of the last call. +func (b *ConfigApplyConfiguration) WithCreationTimestamp(value metav1.Time) *ConfigApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.CreationTimestamp = &value + return b +} + +// WithDeletionTimestamp sets the DeletionTimestamp field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the DeletionTimestamp field is set to the value of the last call. +func (b *ConfigApplyConfiguration) WithDeletionTimestamp(value metav1.Time) *ConfigApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.DeletionTimestamp = &value + return b +} + +// WithDeletionGracePeriodSeconds sets the DeletionGracePeriodSeconds field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the DeletionGracePeriodSeconds field is set to the value of the last call. +func (b *ConfigApplyConfiguration) WithDeletionGracePeriodSeconds(value int64) *ConfigApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.DeletionGracePeriodSeconds = &value + return b +} + +// WithLabels puts the entries into the Labels field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, the entries provided by each call will be put on the Labels field, +// overwriting an existing map entries in Labels field with the same key. +func (b *ConfigApplyConfiguration) WithLabels(entries map[string]string) *ConfigApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + if b.ObjectMetaApplyConfiguration.Labels == nil && len(entries) > 0 { + b.ObjectMetaApplyConfiguration.Labels = make(map[string]string, len(entries)) + } + for k, v := range entries { + b.ObjectMetaApplyConfiguration.Labels[k] = v + } + return b +} + +// WithAnnotations puts the entries into the Annotations field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, the entries provided by each call will be put on the Annotations field, +// overwriting an existing map entries in Annotations field with the same key. +func (b *ConfigApplyConfiguration) WithAnnotations(entries map[string]string) *ConfigApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + if b.ObjectMetaApplyConfiguration.Annotations == nil && len(entries) > 0 { + b.ObjectMetaApplyConfiguration.Annotations = make(map[string]string, len(entries)) + } + for k, v := range entries { + b.ObjectMetaApplyConfiguration.Annotations[k] = v + } + return b +} + +// WithOwnerReferences adds the given value to the OwnerReferences field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, values provided by each call will be appended to the OwnerReferences field. +func (b *ConfigApplyConfiguration) WithOwnerReferences(values ...*v1.OwnerReferenceApplyConfiguration) *ConfigApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + for i := range values { + if values[i] == nil { + panic("nil value passed to WithOwnerReferences") + } + b.ObjectMetaApplyConfiguration.OwnerReferences = append(b.ObjectMetaApplyConfiguration.OwnerReferences, *values[i]) + } + return b +} + +// WithFinalizers adds the given value to the Finalizers field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, values provided by each call will be appended to the Finalizers field. +func (b *ConfigApplyConfiguration) WithFinalizers(values ...string) *ConfigApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + for i := range values { + b.ObjectMetaApplyConfiguration.Finalizers = append(b.ObjectMetaApplyConfiguration.Finalizers, values[i]) + } + return b +} + +func (b *ConfigApplyConfiguration) ensureObjectMetaApplyConfigurationExists() { + if b.ObjectMetaApplyConfiguration == nil { + b.ObjectMetaApplyConfiguration = &v1.ObjectMetaApplyConfiguration{} + } +} + +// WithSpec sets the Spec field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Spec field is set to the value of the last call. +func (b *ConfigApplyConfiguration) WithSpec(value *ConfigSpecApplyConfiguration) *ConfigApplyConfiguration { + b.Spec = value + return b +} + +// WithStatus sets the Status field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Status field is set to the value of the last call. +func (b *ConfigApplyConfiguration) WithStatus(value *ConfigStatusApplyConfiguration) *ConfigApplyConfiguration { + b.Status = value + return b +} + +// GetKind retrieves the value of the Kind field in the declarative configuration. +func (b *ConfigApplyConfiguration) GetKind() *string { + return b.TypeMetaApplyConfiguration.Kind +} + +// GetAPIVersion retrieves the value of the APIVersion field in the declarative configuration. +func (b *ConfigApplyConfiguration) GetAPIVersion() *string { + return b.TypeMetaApplyConfiguration.APIVersion +} + +// GetName retrieves the value of the Name field in the declarative configuration. +func (b *ConfigApplyConfiguration) GetName() *string { + b.ensureObjectMetaApplyConfigurationExists() + return b.ObjectMetaApplyConfiguration.Name +} + +// GetNamespace retrieves the value of the Namespace field in the declarative configuration. +func (b *ConfigApplyConfiguration) GetNamespace() *string { + b.ensureObjectMetaApplyConfigurationExists() + return b.ObjectMetaApplyConfiguration.Namespace +} diff --git a/pkg/generated/applyconfiguration/config/v1alpha1/configblame.go b/pkg/generated/applyconfiguration/config/v1alpha1/configblame.go new file mode 100644 index 00000000..8e5ca4ee --- /dev/null +++ b/pkg/generated/applyconfiguration/config/v1alpha1/configblame.go @@ -0,0 +1,245 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ +// Code generated by applyconfiguration-gen. DO NOT EDIT. + +package v1alpha1 + +import ( + configv1alpha1 "github.com/sdcio/config-server/apis/config/v1alpha1" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + types "k8s.io/apimachinery/pkg/types" + v1 "k8s.io/client-go/applyconfigurations/meta/v1" +) + +// ConfigBlameApplyConfiguration represents a declarative configuration of the ConfigBlame type for use +// with apply. +// +// ConfigBlame is the Schema for the ConfigBlame API +type ConfigBlameApplyConfiguration struct { + v1.TypeMetaApplyConfiguration `json:",inline"` + *v1.ObjectMetaApplyConfiguration `json:"metadata,omitempty"` + Spec *configv1alpha1.ConfigBlameSpec `json:"spec,omitempty"` + Status *ConfigBlameStatusApplyConfiguration `json:"status,omitempty"` +} + +// ConfigBlame constructs a declarative configuration of the ConfigBlame type for use with +// apply. +func ConfigBlame(name, namespace string) *ConfigBlameApplyConfiguration { + b := &ConfigBlameApplyConfiguration{} + b.WithName(name) + b.WithNamespace(namespace) + b.WithKind("ConfigBlame") + b.WithAPIVersion("config.sdcio.dev/v1alpha1") + return b +} + +func (b ConfigBlameApplyConfiguration) IsApplyConfiguration() {} + +// WithKind sets the Kind field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Kind field is set to the value of the last call. +func (b *ConfigBlameApplyConfiguration) WithKind(value string) *ConfigBlameApplyConfiguration { + b.TypeMetaApplyConfiguration.Kind = &value + return b +} + +// WithAPIVersion sets the APIVersion field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the APIVersion field is set to the value of the last call. +func (b *ConfigBlameApplyConfiguration) WithAPIVersion(value string) *ConfigBlameApplyConfiguration { + b.TypeMetaApplyConfiguration.APIVersion = &value + return b +} + +// WithName sets the Name field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Name field is set to the value of the last call. +func (b *ConfigBlameApplyConfiguration) WithName(value string) *ConfigBlameApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.Name = &value + return b +} + +// WithGenerateName sets the GenerateName field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the GenerateName field is set to the value of the last call. +func (b *ConfigBlameApplyConfiguration) WithGenerateName(value string) *ConfigBlameApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.GenerateName = &value + return b +} + +// WithNamespace sets the Namespace field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Namespace field is set to the value of the last call. +func (b *ConfigBlameApplyConfiguration) WithNamespace(value string) *ConfigBlameApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.Namespace = &value + return b +} + +// WithUID sets the UID field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the UID field is set to the value of the last call. +func (b *ConfigBlameApplyConfiguration) WithUID(value types.UID) *ConfigBlameApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.UID = &value + return b +} + +// WithResourceVersion sets the ResourceVersion field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the ResourceVersion field is set to the value of the last call. +func (b *ConfigBlameApplyConfiguration) WithResourceVersion(value string) *ConfigBlameApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.ResourceVersion = &value + return b +} + +// WithGeneration sets the Generation field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Generation field is set to the value of the last call. +func (b *ConfigBlameApplyConfiguration) WithGeneration(value int64) *ConfigBlameApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.Generation = &value + return b +} + +// WithCreationTimestamp sets the CreationTimestamp field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the CreationTimestamp field is set to the value of the last call. +func (b *ConfigBlameApplyConfiguration) WithCreationTimestamp(value metav1.Time) *ConfigBlameApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.CreationTimestamp = &value + return b +} + +// WithDeletionTimestamp sets the DeletionTimestamp field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the DeletionTimestamp field is set to the value of the last call. +func (b *ConfigBlameApplyConfiguration) WithDeletionTimestamp(value metav1.Time) *ConfigBlameApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.DeletionTimestamp = &value + return b +} + +// WithDeletionGracePeriodSeconds sets the DeletionGracePeriodSeconds field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the DeletionGracePeriodSeconds field is set to the value of the last call. +func (b *ConfigBlameApplyConfiguration) WithDeletionGracePeriodSeconds(value int64) *ConfigBlameApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.DeletionGracePeriodSeconds = &value + return b +} + +// WithLabels puts the entries into the Labels field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, the entries provided by each call will be put on the Labels field, +// overwriting an existing map entries in Labels field with the same key. +func (b *ConfigBlameApplyConfiguration) WithLabels(entries map[string]string) *ConfigBlameApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + if b.ObjectMetaApplyConfiguration.Labels == nil && len(entries) > 0 { + b.ObjectMetaApplyConfiguration.Labels = make(map[string]string, len(entries)) + } + for k, v := range entries { + b.ObjectMetaApplyConfiguration.Labels[k] = v + } + return b +} + +// WithAnnotations puts the entries into the Annotations field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, the entries provided by each call will be put on the Annotations field, +// overwriting an existing map entries in Annotations field with the same key. +func (b *ConfigBlameApplyConfiguration) WithAnnotations(entries map[string]string) *ConfigBlameApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + if b.ObjectMetaApplyConfiguration.Annotations == nil && len(entries) > 0 { + b.ObjectMetaApplyConfiguration.Annotations = make(map[string]string, len(entries)) + } + for k, v := range entries { + b.ObjectMetaApplyConfiguration.Annotations[k] = v + } + return b +} + +// WithOwnerReferences adds the given value to the OwnerReferences field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, values provided by each call will be appended to the OwnerReferences field. +func (b *ConfigBlameApplyConfiguration) WithOwnerReferences(values ...*v1.OwnerReferenceApplyConfiguration) *ConfigBlameApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + for i := range values { + if values[i] == nil { + panic("nil value passed to WithOwnerReferences") + } + b.ObjectMetaApplyConfiguration.OwnerReferences = append(b.ObjectMetaApplyConfiguration.OwnerReferences, *values[i]) + } + return b +} + +// WithFinalizers adds the given value to the Finalizers field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, values provided by each call will be appended to the Finalizers field. +func (b *ConfigBlameApplyConfiguration) WithFinalizers(values ...string) *ConfigBlameApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + for i := range values { + b.ObjectMetaApplyConfiguration.Finalizers = append(b.ObjectMetaApplyConfiguration.Finalizers, values[i]) + } + return b +} + +func (b *ConfigBlameApplyConfiguration) ensureObjectMetaApplyConfigurationExists() { + if b.ObjectMetaApplyConfiguration == nil { + b.ObjectMetaApplyConfiguration = &v1.ObjectMetaApplyConfiguration{} + } +} + +// WithSpec sets the Spec field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Spec field is set to the value of the last call. +func (b *ConfigBlameApplyConfiguration) WithSpec(value configv1alpha1.ConfigBlameSpec) *ConfigBlameApplyConfiguration { + b.Spec = &value + return b +} + +// WithStatus sets the Status field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Status field is set to the value of the last call. +func (b *ConfigBlameApplyConfiguration) WithStatus(value *ConfigBlameStatusApplyConfiguration) *ConfigBlameApplyConfiguration { + b.Status = value + return b +} + +// GetKind retrieves the value of the Kind field in the declarative configuration. +func (b *ConfigBlameApplyConfiguration) GetKind() *string { + return b.TypeMetaApplyConfiguration.Kind +} + +// GetAPIVersion retrieves the value of the APIVersion field in the declarative configuration. +func (b *ConfigBlameApplyConfiguration) GetAPIVersion() *string { + return b.TypeMetaApplyConfiguration.APIVersion +} + +// GetName retrieves the value of the Name field in the declarative configuration. +func (b *ConfigBlameApplyConfiguration) GetName() *string { + b.ensureObjectMetaApplyConfigurationExists() + return b.ObjectMetaApplyConfiguration.Name +} + +// GetNamespace retrieves the value of the Namespace field in the declarative configuration. +func (b *ConfigBlameApplyConfiguration) GetNamespace() *string { + b.ensureObjectMetaApplyConfigurationExists() + return b.ObjectMetaApplyConfiguration.Namespace +} diff --git a/pkg/generated/applyconfiguration/config/v1alpha1/configblamestatus.go b/pkg/generated/applyconfiguration/config/v1alpha1/configblamestatus.go new file mode 100644 index 00000000..5c78a925 --- /dev/null +++ b/pkg/generated/applyconfiguration/config/v1alpha1/configblamestatus.go @@ -0,0 +1,44 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ +// Code generated by applyconfiguration-gen. DO NOT EDIT. + +package v1alpha1 + +import ( + runtime "k8s.io/apimachinery/pkg/runtime" +) + +// ConfigBlameStatusApplyConfiguration represents a declarative configuration of the ConfigBlameStatus type for use +// with apply. +// +// ConfigBlameStatus defines the observed state of ConfigBlame +type ConfigBlameStatusApplyConfiguration struct { + Value *runtime.RawExtension `json:"value,omitempty"` +} + +// ConfigBlameStatusApplyConfiguration constructs a declarative configuration of the ConfigBlameStatus type for use with +// apply. +func ConfigBlameStatus() *ConfigBlameStatusApplyConfiguration { + return &ConfigBlameStatusApplyConfiguration{} +} + +// WithValue sets the Value field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Value field is set to the value of the last call. +func (b *ConfigBlameStatusApplyConfiguration) WithValue(value runtime.RawExtension) *ConfigBlameStatusApplyConfiguration { + b.Value = &value + return b +} diff --git a/pkg/generated/applyconfiguration/config/v1alpha1/configblob.go b/pkg/generated/applyconfiguration/config/v1alpha1/configblob.go new file mode 100644 index 00000000..353fbe72 --- /dev/null +++ b/pkg/generated/applyconfiguration/config/v1alpha1/configblob.go @@ -0,0 +1,52 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ +// Code generated by applyconfiguration-gen. DO NOT EDIT. + +package v1alpha1 + +import ( + runtime "k8s.io/apimachinery/pkg/runtime" +) + +// ConfigBlobApplyConfiguration represents a declarative configuration of the ConfigBlob type for use +// with apply. +type ConfigBlobApplyConfiguration struct { + // Path defines the path relative to which the value is applicable + Path *string `json:"path,omitempty"` + Value *runtime.RawExtension `json:"value,omitempty"` +} + +// ConfigBlobApplyConfiguration constructs a declarative configuration of the ConfigBlob type for use with +// apply. +func ConfigBlob() *ConfigBlobApplyConfiguration { + return &ConfigBlobApplyConfiguration{} +} + +// WithPath sets the Path field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Path field is set to the value of the last call. +func (b *ConfigBlobApplyConfiguration) WithPath(value string) *ConfigBlobApplyConfiguration { + b.Path = &value + return b +} + +// WithValue sets the Value field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Value field is set to the value of the last call. +func (b *ConfigBlobApplyConfiguration) WithValue(value runtime.RawExtension) *ConfigBlobApplyConfiguration { + b.Value = &value + return b +} diff --git a/pkg/generated/applyconfiguration/config/v1alpha1/configdeviation.go b/pkg/generated/applyconfiguration/config/v1alpha1/configdeviation.go new file mode 100644 index 00000000..5ce88117 --- /dev/null +++ b/pkg/generated/applyconfiguration/config/v1alpha1/configdeviation.go @@ -0,0 +1,70 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ +// Code generated by applyconfiguration-gen. DO NOT EDIT. + +package v1alpha1 + +// ConfigDeviationApplyConfiguration represents a declarative configuration of the ConfigDeviation type for use +// with apply. +type ConfigDeviationApplyConfiguration struct { + // Path of the config this deviation belongs to + Path *string `json:"path,omitempty"` + // DesiredValue is the desired value of the config belonging to the path + DesiredValue *string `json:"desiredValue,omitempty"` + // CurrentValue defines the current value of the config belonging to the path + // that is currently configured on the target + CurrentValue *string `json:"actualValue,omitempty"` + // Reason defines the reason of the deviation + Reason *string `json:"reason,omitempty"` +} + +// ConfigDeviationApplyConfiguration constructs a declarative configuration of the ConfigDeviation type for use with +// apply. +func ConfigDeviation() *ConfigDeviationApplyConfiguration { + return &ConfigDeviationApplyConfiguration{} +} + +// WithPath sets the Path field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Path field is set to the value of the last call. +func (b *ConfigDeviationApplyConfiguration) WithPath(value string) *ConfigDeviationApplyConfiguration { + b.Path = &value + return b +} + +// WithDesiredValue sets the DesiredValue field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the DesiredValue field is set to the value of the last call. +func (b *ConfigDeviationApplyConfiguration) WithDesiredValue(value string) *ConfigDeviationApplyConfiguration { + b.DesiredValue = &value + return b +} + +// WithCurrentValue sets the CurrentValue field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the CurrentValue field is set to the value of the last call. +func (b *ConfigDeviationApplyConfiguration) WithCurrentValue(value string) *ConfigDeviationApplyConfiguration { + b.CurrentValue = &value + return b +} + +// WithReason sets the Reason field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Reason field is set to the value of the last call. +func (b *ConfigDeviationApplyConfiguration) WithReason(value string) *ConfigDeviationApplyConfiguration { + b.Reason = &value + return b +} diff --git a/pkg/generated/applyconfiguration/config/v1alpha1/configset.go b/pkg/generated/applyconfiguration/config/v1alpha1/configset.go new file mode 100644 index 00000000..11739fed --- /dev/null +++ b/pkg/generated/applyconfiguration/config/v1alpha1/configset.go @@ -0,0 +1,244 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ +// Code generated by applyconfiguration-gen. DO NOT EDIT. + +package v1alpha1 + +import ( + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + types "k8s.io/apimachinery/pkg/types" + v1 "k8s.io/client-go/applyconfigurations/meta/v1" +) + +// ConfigSetApplyConfiguration represents a declarative configuration of the ConfigSet type for use +// with apply. +// +// ConfigSet is the Schema for the ConfigSet API +type ConfigSetApplyConfiguration struct { + v1.TypeMetaApplyConfiguration `json:",inline"` + *v1.ObjectMetaApplyConfiguration `json:"metadata,omitempty"` + Spec *ConfigSetSpecApplyConfiguration `json:"spec,omitempty"` + Status *ConfigSetStatusApplyConfiguration `json:"status,omitempty"` +} + +// ConfigSet constructs a declarative configuration of the ConfigSet type for use with +// apply. +func ConfigSet(name, namespace string) *ConfigSetApplyConfiguration { + b := &ConfigSetApplyConfiguration{} + b.WithName(name) + b.WithNamespace(namespace) + b.WithKind("ConfigSet") + b.WithAPIVersion("config.sdcio.dev/v1alpha1") + return b +} + +func (b ConfigSetApplyConfiguration) IsApplyConfiguration() {} + +// WithKind sets the Kind field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Kind field is set to the value of the last call. +func (b *ConfigSetApplyConfiguration) WithKind(value string) *ConfigSetApplyConfiguration { + b.TypeMetaApplyConfiguration.Kind = &value + return b +} + +// WithAPIVersion sets the APIVersion field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the APIVersion field is set to the value of the last call. +func (b *ConfigSetApplyConfiguration) WithAPIVersion(value string) *ConfigSetApplyConfiguration { + b.TypeMetaApplyConfiguration.APIVersion = &value + return b +} + +// WithName sets the Name field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Name field is set to the value of the last call. +func (b *ConfigSetApplyConfiguration) WithName(value string) *ConfigSetApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.Name = &value + return b +} + +// WithGenerateName sets the GenerateName field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the GenerateName field is set to the value of the last call. +func (b *ConfigSetApplyConfiguration) WithGenerateName(value string) *ConfigSetApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.GenerateName = &value + return b +} + +// WithNamespace sets the Namespace field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Namespace field is set to the value of the last call. +func (b *ConfigSetApplyConfiguration) WithNamespace(value string) *ConfigSetApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.Namespace = &value + return b +} + +// WithUID sets the UID field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the UID field is set to the value of the last call. +func (b *ConfigSetApplyConfiguration) WithUID(value types.UID) *ConfigSetApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.UID = &value + return b +} + +// WithResourceVersion sets the ResourceVersion field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the ResourceVersion field is set to the value of the last call. +func (b *ConfigSetApplyConfiguration) WithResourceVersion(value string) *ConfigSetApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.ResourceVersion = &value + return b +} + +// WithGeneration sets the Generation field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Generation field is set to the value of the last call. +func (b *ConfigSetApplyConfiguration) WithGeneration(value int64) *ConfigSetApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.Generation = &value + return b +} + +// WithCreationTimestamp sets the CreationTimestamp field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the CreationTimestamp field is set to the value of the last call. +func (b *ConfigSetApplyConfiguration) WithCreationTimestamp(value metav1.Time) *ConfigSetApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.CreationTimestamp = &value + return b +} + +// WithDeletionTimestamp sets the DeletionTimestamp field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the DeletionTimestamp field is set to the value of the last call. +func (b *ConfigSetApplyConfiguration) WithDeletionTimestamp(value metav1.Time) *ConfigSetApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.DeletionTimestamp = &value + return b +} + +// WithDeletionGracePeriodSeconds sets the DeletionGracePeriodSeconds field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the DeletionGracePeriodSeconds field is set to the value of the last call. +func (b *ConfigSetApplyConfiguration) WithDeletionGracePeriodSeconds(value int64) *ConfigSetApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.DeletionGracePeriodSeconds = &value + return b +} + +// WithLabels puts the entries into the Labels field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, the entries provided by each call will be put on the Labels field, +// overwriting an existing map entries in Labels field with the same key. +func (b *ConfigSetApplyConfiguration) WithLabels(entries map[string]string) *ConfigSetApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + if b.ObjectMetaApplyConfiguration.Labels == nil && len(entries) > 0 { + b.ObjectMetaApplyConfiguration.Labels = make(map[string]string, len(entries)) + } + for k, v := range entries { + b.ObjectMetaApplyConfiguration.Labels[k] = v + } + return b +} + +// WithAnnotations puts the entries into the Annotations field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, the entries provided by each call will be put on the Annotations field, +// overwriting an existing map entries in Annotations field with the same key. +func (b *ConfigSetApplyConfiguration) WithAnnotations(entries map[string]string) *ConfigSetApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + if b.ObjectMetaApplyConfiguration.Annotations == nil && len(entries) > 0 { + b.ObjectMetaApplyConfiguration.Annotations = make(map[string]string, len(entries)) + } + for k, v := range entries { + b.ObjectMetaApplyConfiguration.Annotations[k] = v + } + return b +} + +// WithOwnerReferences adds the given value to the OwnerReferences field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, values provided by each call will be appended to the OwnerReferences field. +func (b *ConfigSetApplyConfiguration) WithOwnerReferences(values ...*v1.OwnerReferenceApplyConfiguration) *ConfigSetApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + for i := range values { + if values[i] == nil { + panic("nil value passed to WithOwnerReferences") + } + b.ObjectMetaApplyConfiguration.OwnerReferences = append(b.ObjectMetaApplyConfiguration.OwnerReferences, *values[i]) + } + return b +} + +// WithFinalizers adds the given value to the Finalizers field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, values provided by each call will be appended to the Finalizers field. +func (b *ConfigSetApplyConfiguration) WithFinalizers(values ...string) *ConfigSetApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + for i := range values { + b.ObjectMetaApplyConfiguration.Finalizers = append(b.ObjectMetaApplyConfiguration.Finalizers, values[i]) + } + return b +} + +func (b *ConfigSetApplyConfiguration) ensureObjectMetaApplyConfigurationExists() { + if b.ObjectMetaApplyConfiguration == nil { + b.ObjectMetaApplyConfiguration = &v1.ObjectMetaApplyConfiguration{} + } +} + +// WithSpec sets the Spec field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Spec field is set to the value of the last call. +func (b *ConfigSetApplyConfiguration) WithSpec(value *ConfigSetSpecApplyConfiguration) *ConfigSetApplyConfiguration { + b.Spec = value + return b +} + +// WithStatus sets the Status field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Status field is set to the value of the last call. +func (b *ConfigSetApplyConfiguration) WithStatus(value *ConfigSetStatusApplyConfiguration) *ConfigSetApplyConfiguration { + b.Status = value + return b +} + +// GetKind retrieves the value of the Kind field in the declarative configuration. +func (b *ConfigSetApplyConfiguration) GetKind() *string { + return b.TypeMetaApplyConfiguration.Kind +} + +// GetAPIVersion retrieves the value of the APIVersion field in the declarative configuration. +func (b *ConfigSetApplyConfiguration) GetAPIVersion() *string { + return b.TypeMetaApplyConfiguration.APIVersion +} + +// GetName retrieves the value of the Name field in the declarative configuration. +func (b *ConfigSetApplyConfiguration) GetName() *string { + b.ensureObjectMetaApplyConfigurationExists() + return b.ObjectMetaApplyConfiguration.Name +} + +// GetNamespace retrieves the value of the Namespace field in the declarative configuration. +func (b *ConfigSetApplyConfiguration) GetNamespace() *string { + b.ensureObjectMetaApplyConfigurationExists() + return b.ObjectMetaApplyConfiguration.Namespace +} diff --git a/pkg/generated/applyconfiguration/config/v1alpha1/configsetspec.go b/pkg/generated/applyconfiguration/config/v1alpha1/configsetspec.go new file mode 100644 index 00000000..59b0ff2b --- /dev/null +++ b/pkg/generated/applyconfiguration/config/v1alpha1/configsetspec.go @@ -0,0 +1,87 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ +// Code generated by applyconfiguration-gen. DO NOT EDIT. + +package v1alpha1 + +// ConfigSetSpecApplyConfiguration represents a declarative configuration of the ConfigSetSpec type for use +// with apply. +// +// ConfigSetSpec defines the desired state of Config +type ConfigSetSpecApplyConfiguration struct { + // Targets defines the targets on which this configSet applies + Target *TargetApplyConfiguration `json:"target,omitempty"` + // Lifecycle determines the lifecycle policies the resource e.g. delete is orphan or delete + // will follow + Lifecycle *LifecycleApplyConfiguration `json:"lifecycle,omitempty"` + // Priority defines the priority of this config + Priority *int64 `json:"priority,omitempty"` + // Revertive defines if this CR is enabled for revertive or non revertve operation + Revertive *bool `json:"revertive,omitempty"` + // Config defines the configuration to be applied to a target device + Config []ConfigBlobApplyConfiguration `json:"config,omitempty"` +} + +// ConfigSetSpecApplyConfiguration constructs a declarative configuration of the ConfigSetSpec type for use with +// apply. +func ConfigSetSpec() *ConfigSetSpecApplyConfiguration { + return &ConfigSetSpecApplyConfiguration{} +} + +// WithTarget sets the Target field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Target field is set to the value of the last call. +func (b *ConfigSetSpecApplyConfiguration) WithTarget(value *TargetApplyConfiguration) *ConfigSetSpecApplyConfiguration { + b.Target = value + return b +} + +// WithLifecycle sets the Lifecycle field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Lifecycle field is set to the value of the last call. +func (b *ConfigSetSpecApplyConfiguration) WithLifecycle(value *LifecycleApplyConfiguration) *ConfigSetSpecApplyConfiguration { + b.Lifecycle = value + return b +} + +// WithPriority sets the Priority field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Priority field is set to the value of the last call. +func (b *ConfigSetSpecApplyConfiguration) WithPriority(value int64) *ConfigSetSpecApplyConfiguration { + b.Priority = &value + return b +} + +// WithRevertive sets the Revertive field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Revertive field is set to the value of the last call. +func (b *ConfigSetSpecApplyConfiguration) WithRevertive(value bool) *ConfigSetSpecApplyConfiguration { + b.Revertive = &value + return b +} + +// WithConfig adds the given value to the Config field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, values provided by each call will be appended to the Config field. +func (b *ConfigSetSpecApplyConfiguration) WithConfig(values ...*ConfigBlobApplyConfiguration) *ConfigSetSpecApplyConfiguration { + for i := range values { + if values[i] == nil { + panic("nil value passed to WithConfig") + } + b.Config = append(b.Config, *values[i]) + } + return b +} diff --git a/pkg/generated/applyconfiguration/config/v1alpha1/configsetstatus.go b/pkg/generated/applyconfiguration/config/v1alpha1/configsetstatus.go new file mode 100644 index 00000000..b6a52e7c --- /dev/null +++ b/pkg/generated/applyconfiguration/config/v1alpha1/configsetstatus.go @@ -0,0 +1,63 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ +// Code generated by applyconfiguration-gen. DO NOT EDIT. + +package v1alpha1 + +import ( + conditionv1alpha1 "github.com/sdcio/config-server/apis/condition/v1alpha1" +) + +// ConfigSetStatusApplyConfiguration represents a declarative configuration of the ConfigSetStatus type for use +// with apply. +// +// ConfigSetStatus defines the observed state of Config +type ConfigSetStatusApplyConfiguration struct { + // ConditionedStatus provides the status of the Readiness using conditions + // if the condition is true the other attributes in the status are meaningful + conditionv1alpha1.ConditionedStatus `json:",inline"` + // Targets defines the status of the configSet resource on the respective target + Targets []TargetStatusApplyConfiguration `json:"targets,omitempty"` +} + +// ConfigSetStatusApplyConfiguration constructs a declarative configuration of the ConfigSetStatus type for use with +// apply. +func ConfigSetStatus() *ConfigSetStatusApplyConfiguration { + return &ConfigSetStatusApplyConfiguration{} +} + +// WithConditions adds the given value to the Conditions field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, values provided by each call will be appended to the Conditions field. +func (b *ConfigSetStatusApplyConfiguration) WithConditions(values ...conditionv1alpha1.Condition) *ConfigSetStatusApplyConfiguration { + for i := range values { + b.ConditionedStatus.Conditions = append(b.ConditionedStatus.Conditions, values[i]) + } + return b +} + +// WithTargets adds the given value to the Targets field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, values provided by each call will be appended to the Targets field. +func (b *ConfigSetStatusApplyConfiguration) WithTargets(values ...*TargetStatusApplyConfiguration) *ConfigSetStatusApplyConfiguration { + for i := range values { + if values[i] == nil { + panic("nil value passed to WithTargets") + } + b.Targets = append(b.Targets, *values[i]) + } + return b +} diff --git a/pkg/generated/applyconfiguration/config/v1alpha1/configspec.go b/pkg/generated/applyconfiguration/config/v1alpha1/configspec.go new file mode 100644 index 00000000..21e1eec6 --- /dev/null +++ b/pkg/generated/applyconfiguration/config/v1alpha1/configspec.go @@ -0,0 +1,77 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ +// Code generated by applyconfiguration-gen. DO NOT EDIT. + +package v1alpha1 + +// ConfigSpecApplyConfiguration represents a declarative configuration of the ConfigSpec type for use +// with apply. +// +// ConfigSpec defines the desired state of Config +type ConfigSpecApplyConfiguration struct { + // Lifecycle determines the lifecycle policies the resource e.g. delete is orphan or delete + // will follow + Lifecycle *LifecycleApplyConfiguration `json:"lifecycle,omitempty"` + // Priority defines the priority of this config + Priority *int64 `json:"priority,omitempty"` + // Revertive defines if this CR is enabled for revertive or non revertve operation + Revertive *bool `json:"revertive,omitempty"` + // Config defines the configuration to be applied to a target device + Config []ConfigBlobApplyConfiguration `json:"config,omitempty"` +} + +// ConfigSpecApplyConfiguration constructs a declarative configuration of the ConfigSpec type for use with +// apply. +func ConfigSpec() *ConfigSpecApplyConfiguration { + return &ConfigSpecApplyConfiguration{} +} + +// WithLifecycle sets the Lifecycle field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Lifecycle field is set to the value of the last call. +func (b *ConfigSpecApplyConfiguration) WithLifecycle(value *LifecycleApplyConfiguration) *ConfigSpecApplyConfiguration { + b.Lifecycle = value + return b +} + +// WithPriority sets the Priority field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Priority field is set to the value of the last call. +func (b *ConfigSpecApplyConfiguration) WithPriority(value int64) *ConfigSpecApplyConfiguration { + b.Priority = &value + return b +} + +// WithRevertive sets the Revertive field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Revertive field is set to the value of the last call. +func (b *ConfigSpecApplyConfiguration) WithRevertive(value bool) *ConfigSpecApplyConfiguration { + b.Revertive = &value + return b +} + +// WithConfig adds the given value to the Config field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, values provided by each call will be appended to the Config field. +func (b *ConfigSpecApplyConfiguration) WithConfig(values ...*ConfigBlobApplyConfiguration) *ConfigSpecApplyConfiguration { + for i := range values { + if values[i] == nil { + panic("nil value passed to WithConfig") + } + b.Config = append(b.Config, *values[i]) + } + return b +} diff --git a/pkg/generated/applyconfiguration/config/v1alpha1/configstatus.go b/pkg/generated/applyconfiguration/config/v1alpha1/configstatus.go new file mode 100644 index 00000000..24f92d1c --- /dev/null +++ b/pkg/generated/applyconfiguration/config/v1alpha1/configstatus.go @@ -0,0 +1,78 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ +// Code generated by applyconfiguration-gen. DO NOT EDIT. + +package v1alpha1 + +import ( + conditionv1alpha1 "github.com/sdcio/config-server/apis/condition/v1alpha1" +) + +// ConfigStatusApplyConfiguration represents a declarative configuration of the ConfigStatus type for use +// with apply. +// +// ConfigStatus defines the observed state of Config +type ConfigStatusApplyConfiguration struct { + // ConditionedStatus provides the status of the Readiness using conditions + // if the condition is true the other attributes in the status are meaningful + conditionv1alpha1.ConditionedStatus `json:",inline"` + // LastKnownGoodSchema identifies the last known good schema used to apply the config successfully + LastKnownGoodSchema *ConfigStatusLastKnownGoodSchemaApplyConfiguration `json:"lastKnownGoodSchema,omitempty"` + // AppliedConfig defines the config applied to the target + AppliedConfig *ConfigSpecApplyConfiguration `json:"appliedConfig,omitempty"` + // Deviations generation used for the latest config apply + DeviationGeneration *int64 `json:"deviationGeneration,omitempty"` +} + +// ConfigStatusApplyConfiguration constructs a declarative configuration of the ConfigStatus type for use with +// apply. +func ConfigStatus() *ConfigStatusApplyConfiguration { + return &ConfigStatusApplyConfiguration{} +} + +// WithConditions adds the given value to the Conditions field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, values provided by each call will be appended to the Conditions field. +func (b *ConfigStatusApplyConfiguration) WithConditions(values ...conditionv1alpha1.Condition) *ConfigStatusApplyConfiguration { + for i := range values { + b.ConditionedStatus.Conditions = append(b.ConditionedStatus.Conditions, values[i]) + } + return b +} + +// WithLastKnownGoodSchema sets the LastKnownGoodSchema field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the LastKnownGoodSchema field is set to the value of the last call. +func (b *ConfigStatusApplyConfiguration) WithLastKnownGoodSchema(value *ConfigStatusLastKnownGoodSchemaApplyConfiguration) *ConfigStatusApplyConfiguration { + b.LastKnownGoodSchema = value + return b +} + +// WithAppliedConfig sets the AppliedConfig field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the AppliedConfig field is set to the value of the last call. +func (b *ConfigStatusApplyConfiguration) WithAppliedConfig(value *ConfigSpecApplyConfiguration) *ConfigStatusApplyConfiguration { + b.AppliedConfig = value + return b +} + +// WithDeviationGeneration sets the DeviationGeneration field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the DeviationGeneration field is set to the value of the last call. +func (b *ConfigStatusApplyConfiguration) WithDeviationGeneration(value int64) *ConfigStatusApplyConfiguration { + b.DeviationGeneration = &value + return b +} diff --git a/pkg/generated/applyconfiguration/config/v1alpha1/configstatuslastknowngoodschema.go b/pkg/generated/applyconfiguration/config/v1alpha1/configstatuslastknowngoodschema.go new file mode 100644 index 00000000..3f631e82 --- /dev/null +++ b/pkg/generated/applyconfiguration/config/v1alpha1/configstatuslastknowngoodschema.go @@ -0,0 +1,59 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ +// Code generated by applyconfiguration-gen. DO NOT EDIT. + +package v1alpha1 + +// ConfigStatusLastKnownGoodSchemaApplyConfiguration represents a declarative configuration of the ConfigStatusLastKnownGoodSchema type for use +// with apply. +type ConfigStatusLastKnownGoodSchemaApplyConfiguration struct { + // Schema Type + Type *string `json:"type,omitempty"` + // Schema Vendor + Vendor *string `json:"vendor,omitempty"` + // Schema Version + Version *string `json:"version,omitempty"` +} + +// ConfigStatusLastKnownGoodSchemaApplyConfiguration constructs a declarative configuration of the ConfigStatusLastKnownGoodSchema type for use with +// apply. +func ConfigStatusLastKnownGoodSchema() *ConfigStatusLastKnownGoodSchemaApplyConfiguration { + return &ConfigStatusLastKnownGoodSchemaApplyConfiguration{} +} + +// WithType sets the Type field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Type field is set to the value of the last call. +func (b *ConfigStatusLastKnownGoodSchemaApplyConfiguration) WithType(value string) *ConfigStatusLastKnownGoodSchemaApplyConfiguration { + b.Type = &value + return b +} + +// WithVendor sets the Vendor field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Vendor field is set to the value of the last call. +func (b *ConfigStatusLastKnownGoodSchemaApplyConfiguration) WithVendor(value string) *ConfigStatusLastKnownGoodSchemaApplyConfiguration { + b.Vendor = &value + return b +} + +// WithVersion sets the Version field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Version field is set to the value of the last call. +func (b *ConfigStatusLastKnownGoodSchemaApplyConfiguration) WithVersion(value string) *ConfigStatusLastKnownGoodSchemaApplyConfiguration { + b.Version = &value + return b +} diff --git a/pkg/generated/applyconfiguration/config/v1alpha1/deviation.go b/pkg/generated/applyconfiguration/config/v1alpha1/deviation.go new file mode 100644 index 00000000..abd04d44 --- /dev/null +++ b/pkg/generated/applyconfiguration/config/v1alpha1/deviation.go @@ -0,0 +1,244 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ +// Code generated by applyconfiguration-gen. DO NOT EDIT. + +package v1alpha1 + +import ( + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + types "k8s.io/apimachinery/pkg/types" + v1 "k8s.io/client-go/applyconfigurations/meta/v1" +) + +// DeviationApplyConfiguration represents a declarative configuration of the Deviation type for use +// with apply. +// +// Deviation is the Schema for the Deviation API +type DeviationApplyConfiguration struct { + v1.TypeMetaApplyConfiguration `json:",inline"` + *v1.ObjectMetaApplyConfiguration `json:"metadata,omitempty"` + Spec *DeviationSpecApplyConfiguration `json:"spec,omitempty"` + Status *DeviationStatusApplyConfiguration `json:"status,omitempty"` +} + +// Deviation constructs a declarative configuration of the Deviation type for use with +// apply. +func Deviation(name, namespace string) *DeviationApplyConfiguration { + b := &DeviationApplyConfiguration{} + b.WithName(name) + b.WithNamespace(namespace) + b.WithKind("Deviation") + b.WithAPIVersion("config.sdcio.dev/v1alpha1") + return b +} + +func (b DeviationApplyConfiguration) IsApplyConfiguration() {} + +// WithKind sets the Kind field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Kind field is set to the value of the last call. +func (b *DeviationApplyConfiguration) WithKind(value string) *DeviationApplyConfiguration { + b.TypeMetaApplyConfiguration.Kind = &value + return b +} + +// WithAPIVersion sets the APIVersion field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the APIVersion field is set to the value of the last call. +func (b *DeviationApplyConfiguration) WithAPIVersion(value string) *DeviationApplyConfiguration { + b.TypeMetaApplyConfiguration.APIVersion = &value + return b +} + +// WithName sets the Name field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Name field is set to the value of the last call. +func (b *DeviationApplyConfiguration) WithName(value string) *DeviationApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.Name = &value + return b +} + +// WithGenerateName sets the GenerateName field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the GenerateName field is set to the value of the last call. +func (b *DeviationApplyConfiguration) WithGenerateName(value string) *DeviationApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.GenerateName = &value + return b +} + +// WithNamespace sets the Namespace field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Namespace field is set to the value of the last call. +func (b *DeviationApplyConfiguration) WithNamespace(value string) *DeviationApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.Namespace = &value + return b +} + +// WithUID sets the UID field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the UID field is set to the value of the last call. +func (b *DeviationApplyConfiguration) WithUID(value types.UID) *DeviationApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.UID = &value + return b +} + +// WithResourceVersion sets the ResourceVersion field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the ResourceVersion field is set to the value of the last call. +func (b *DeviationApplyConfiguration) WithResourceVersion(value string) *DeviationApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.ResourceVersion = &value + return b +} + +// WithGeneration sets the Generation field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Generation field is set to the value of the last call. +func (b *DeviationApplyConfiguration) WithGeneration(value int64) *DeviationApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.Generation = &value + return b +} + +// WithCreationTimestamp sets the CreationTimestamp field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the CreationTimestamp field is set to the value of the last call. +func (b *DeviationApplyConfiguration) WithCreationTimestamp(value metav1.Time) *DeviationApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.CreationTimestamp = &value + return b +} + +// WithDeletionTimestamp sets the DeletionTimestamp field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the DeletionTimestamp field is set to the value of the last call. +func (b *DeviationApplyConfiguration) WithDeletionTimestamp(value metav1.Time) *DeviationApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.DeletionTimestamp = &value + return b +} + +// WithDeletionGracePeriodSeconds sets the DeletionGracePeriodSeconds field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the DeletionGracePeriodSeconds field is set to the value of the last call. +func (b *DeviationApplyConfiguration) WithDeletionGracePeriodSeconds(value int64) *DeviationApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.DeletionGracePeriodSeconds = &value + return b +} + +// WithLabels puts the entries into the Labels field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, the entries provided by each call will be put on the Labels field, +// overwriting an existing map entries in Labels field with the same key. +func (b *DeviationApplyConfiguration) WithLabels(entries map[string]string) *DeviationApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + if b.ObjectMetaApplyConfiguration.Labels == nil && len(entries) > 0 { + b.ObjectMetaApplyConfiguration.Labels = make(map[string]string, len(entries)) + } + for k, v := range entries { + b.ObjectMetaApplyConfiguration.Labels[k] = v + } + return b +} + +// WithAnnotations puts the entries into the Annotations field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, the entries provided by each call will be put on the Annotations field, +// overwriting an existing map entries in Annotations field with the same key. +func (b *DeviationApplyConfiguration) WithAnnotations(entries map[string]string) *DeviationApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + if b.ObjectMetaApplyConfiguration.Annotations == nil && len(entries) > 0 { + b.ObjectMetaApplyConfiguration.Annotations = make(map[string]string, len(entries)) + } + for k, v := range entries { + b.ObjectMetaApplyConfiguration.Annotations[k] = v + } + return b +} + +// WithOwnerReferences adds the given value to the OwnerReferences field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, values provided by each call will be appended to the OwnerReferences field. +func (b *DeviationApplyConfiguration) WithOwnerReferences(values ...*v1.OwnerReferenceApplyConfiguration) *DeviationApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + for i := range values { + if values[i] == nil { + panic("nil value passed to WithOwnerReferences") + } + b.ObjectMetaApplyConfiguration.OwnerReferences = append(b.ObjectMetaApplyConfiguration.OwnerReferences, *values[i]) + } + return b +} + +// WithFinalizers adds the given value to the Finalizers field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, values provided by each call will be appended to the Finalizers field. +func (b *DeviationApplyConfiguration) WithFinalizers(values ...string) *DeviationApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + for i := range values { + b.ObjectMetaApplyConfiguration.Finalizers = append(b.ObjectMetaApplyConfiguration.Finalizers, values[i]) + } + return b +} + +func (b *DeviationApplyConfiguration) ensureObjectMetaApplyConfigurationExists() { + if b.ObjectMetaApplyConfiguration == nil { + b.ObjectMetaApplyConfiguration = &v1.ObjectMetaApplyConfiguration{} + } +} + +// WithSpec sets the Spec field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Spec field is set to the value of the last call. +func (b *DeviationApplyConfiguration) WithSpec(value *DeviationSpecApplyConfiguration) *DeviationApplyConfiguration { + b.Spec = value + return b +} + +// WithStatus sets the Status field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Status field is set to the value of the last call. +func (b *DeviationApplyConfiguration) WithStatus(value *DeviationStatusApplyConfiguration) *DeviationApplyConfiguration { + b.Status = value + return b +} + +// GetKind retrieves the value of the Kind field in the declarative configuration. +func (b *DeviationApplyConfiguration) GetKind() *string { + return b.TypeMetaApplyConfiguration.Kind +} + +// GetAPIVersion retrieves the value of the APIVersion field in the declarative configuration. +func (b *DeviationApplyConfiguration) GetAPIVersion() *string { + return b.TypeMetaApplyConfiguration.APIVersion +} + +// GetName retrieves the value of the Name field in the declarative configuration. +func (b *DeviationApplyConfiguration) GetName() *string { + b.ensureObjectMetaApplyConfigurationExists() + return b.ObjectMetaApplyConfiguration.Name +} + +// GetNamespace retrieves the value of the Namespace field in the declarative configuration. +func (b *DeviationApplyConfiguration) GetNamespace() *string { + b.ensureObjectMetaApplyConfigurationExists() + return b.ObjectMetaApplyConfiguration.Namespace +} diff --git a/pkg/generated/applyconfiguration/config/v1alpha1/deviationspec.go b/pkg/generated/applyconfiguration/config/v1alpha1/deviationspec.go new file mode 100644 index 00000000..6a33fd38 --- /dev/null +++ b/pkg/generated/applyconfiguration/config/v1alpha1/deviationspec.go @@ -0,0 +1,59 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ +// Code generated by applyconfiguration-gen. DO NOT EDIT. + +package v1alpha1 + +import ( + configv1alpha1 "github.com/sdcio/config-server/apis/config/v1alpha1" +) + +// DeviationSpecApplyConfiguration represents a declarative configuration of the DeviationSpec type for use +// with apply. +// +// DeviationSpec defines the desired state of Deviation +type DeviationSpecApplyConfiguration struct { + DeviationType *configv1alpha1.DeviationType `json:"deviationType,omitempty"` + // Deviations identify the configuration deviation based on the last applied config CR + Deviations []ConfigDeviationApplyConfiguration `json:"deviations,omitempty"` +} + +// DeviationSpecApplyConfiguration constructs a declarative configuration of the DeviationSpec type for use with +// apply. +func DeviationSpec() *DeviationSpecApplyConfiguration { + return &DeviationSpecApplyConfiguration{} +} + +// WithDeviationType sets the DeviationType field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the DeviationType field is set to the value of the last call. +func (b *DeviationSpecApplyConfiguration) WithDeviationType(value configv1alpha1.DeviationType) *DeviationSpecApplyConfiguration { + b.DeviationType = &value + return b +} + +// WithDeviations adds the given value to the Deviations field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, values provided by each call will be appended to the Deviations field. +func (b *DeviationSpecApplyConfiguration) WithDeviations(values ...*ConfigDeviationApplyConfiguration) *DeviationSpecApplyConfiguration { + for i := range values { + if values[i] == nil { + panic("nil value passed to WithDeviations") + } + b.Deviations = append(b.Deviations, *values[i]) + } + return b +} diff --git a/pkg/generated/applyconfiguration/config/v1alpha1/deviationstatus.go b/pkg/generated/applyconfiguration/config/v1alpha1/deviationstatus.go new file mode 100644 index 00000000..832e5890 --- /dev/null +++ b/pkg/generated/applyconfiguration/config/v1alpha1/deviationstatus.go @@ -0,0 +1,48 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ +// Code generated by applyconfiguration-gen. DO NOT EDIT. + +package v1alpha1 + +import ( + conditionv1alpha1 "github.com/sdcio/config-server/apis/condition/v1alpha1" +) + +// DeviationStatusApplyConfiguration represents a declarative configuration of the DeviationStatus type for use +// with apply. +// +// DeviationStatus defines the observed state of Deviation +type DeviationStatusApplyConfiguration struct { + // ConditionedStatus provides the status of the Readiness using conditions + // if the condition is true the other attributes in the status are meaningful + conditionv1alpha1.ConditionedStatus `json:",inline"` +} + +// DeviationStatusApplyConfiguration constructs a declarative configuration of the DeviationStatus type for use with +// apply. +func DeviationStatus() *DeviationStatusApplyConfiguration { + return &DeviationStatusApplyConfiguration{} +} + +// WithConditions adds the given value to the Conditions field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, values provided by each call will be appended to the Conditions field. +func (b *DeviationStatusApplyConfiguration) WithConditions(values ...conditionv1alpha1.Condition) *DeviationStatusApplyConfiguration { + for i := range values { + b.ConditionedStatus.Conditions = append(b.ConditionedStatus.Conditions, values[i]) + } + return b +} diff --git a/pkg/generated/applyconfiguration/config/v1alpha1/lifecycle.go b/pkg/generated/applyconfiguration/config/v1alpha1/lifecycle.go new file mode 100644 index 00000000..166e9f58 --- /dev/null +++ b/pkg/generated/applyconfiguration/config/v1alpha1/lifecycle.go @@ -0,0 +1,45 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ +// Code generated by applyconfiguration-gen. DO NOT EDIT. + +package v1alpha1 + +import ( + configv1alpha1 "github.com/sdcio/config-server/apis/config/v1alpha1" +) + +// LifecycleApplyConfiguration represents a declarative configuration of the Lifecycle type for use +// with apply. +type LifecycleApplyConfiguration struct { + // DeletionPolicy specifies what will happen to the underlying resource + // when this resource is deleted - either "delete" or "orphan" the + // resource. + DeletionPolicy *configv1alpha1.DeletionPolicy `json:"deletionPolicy,omitempty"` +} + +// LifecycleApplyConfiguration constructs a declarative configuration of the Lifecycle type for use with +// apply. +func Lifecycle() *LifecycleApplyConfiguration { + return &LifecycleApplyConfiguration{} +} + +// WithDeletionPolicy sets the DeletionPolicy field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the DeletionPolicy field is set to the value of the last call. +func (b *LifecycleApplyConfiguration) WithDeletionPolicy(value configv1alpha1.DeletionPolicy) *LifecycleApplyConfiguration { + b.DeletionPolicy = &value + return b +} diff --git a/pkg/generated/applyconfiguration/config/v1alpha1/runningconfig.go b/pkg/generated/applyconfiguration/config/v1alpha1/runningconfig.go new file mode 100644 index 00000000..ec42d5f6 --- /dev/null +++ b/pkg/generated/applyconfiguration/config/v1alpha1/runningconfig.go @@ -0,0 +1,245 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ +// Code generated by applyconfiguration-gen. DO NOT EDIT. + +package v1alpha1 + +import ( + configv1alpha1 "github.com/sdcio/config-server/apis/config/v1alpha1" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + types "k8s.io/apimachinery/pkg/types" + v1 "k8s.io/client-go/applyconfigurations/meta/v1" +) + +// RunningConfigApplyConfiguration represents a declarative configuration of the RunningConfig type for use +// with apply. +// +// RunningConfig is the Schema for the RunningConfig API +type RunningConfigApplyConfiguration struct { + v1.TypeMetaApplyConfiguration `json:",inline"` + *v1.ObjectMetaApplyConfiguration `json:"metadata,omitempty"` + Spec *configv1alpha1.RunningConfigSpec `json:"spec,omitempty"` + Status *RunningConfigStatusApplyConfiguration `json:"status,omitempty"` +} + +// RunningConfig constructs a declarative configuration of the RunningConfig type for use with +// apply. +func RunningConfig(name, namespace string) *RunningConfigApplyConfiguration { + b := &RunningConfigApplyConfiguration{} + b.WithName(name) + b.WithNamespace(namespace) + b.WithKind("RunningConfig") + b.WithAPIVersion("config.sdcio.dev/v1alpha1") + return b +} + +func (b RunningConfigApplyConfiguration) IsApplyConfiguration() {} + +// WithKind sets the Kind field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Kind field is set to the value of the last call. +func (b *RunningConfigApplyConfiguration) WithKind(value string) *RunningConfigApplyConfiguration { + b.TypeMetaApplyConfiguration.Kind = &value + return b +} + +// WithAPIVersion sets the APIVersion field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the APIVersion field is set to the value of the last call. +func (b *RunningConfigApplyConfiguration) WithAPIVersion(value string) *RunningConfigApplyConfiguration { + b.TypeMetaApplyConfiguration.APIVersion = &value + return b +} + +// WithName sets the Name field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Name field is set to the value of the last call. +func (b *RunningConfigApplyConfiguration) WithName(value string) *RunningConfigApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.Name = &value + return b +} + +// WithGenerateName sets the GenerateName field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the GenerateName field is set to the value of the last call. +func (b *RunningConfigApplyConfiguration) WithGenerateName(value string) *RunningConfigApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.GenerateName = &value + return b +} + +// WithNamespace sets the Namespace field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Namespace field is set to the value of the last call. +func (b *RunningConfigApplyConfiguration) WithNamespace(value string) *RunningConfigApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.Namespace = &value + return b +} + +// WithUID sets the UID field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the UID field is set to the value of the last call. +func (b *RunningConfigApplyConfiguration) WithUID(value types.UID) *RunningConfigApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.UID = &value + return b +} + +// WithResourceVersion sets the ResourceVersion field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the ResourceVersion field is set to the value of the last call. +func (b *RunningConfigApplyConfiguration) WithResourceVersion(value string) *RunningConfigApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.ResourceVersion = &value + return b +} + +// WithGeneration sets the Generation field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Generation field is set to the value of the last call. +func (b *RunningConfigApplyConfiguration) WithGeneration(value int64) *RunningConfigApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.Generation = &value + return b +} + +// WithCreationTimestamp sets the CreationTimestamp field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the CreationTimestamp field is set to the value of the last call. +func (b *RunningConfigApplyConfiguration) WithCreationTimestamp(value metav1.Time) *RunningConfigApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.CreationTimestamp = &value + return b +} + +// WithDeletionTimestamp sets the DeletionTimestamp field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the DeletionTimestamp field is set to the value of the last call. +func (b *RunningConfigApplyConfiguration) WithDeletionTimestamp(value metav1.Time) *RunningConfigApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.DeletionTimestamp = &value + return b +} + +// WithDeletionGracePeriodSeconds sets the DeletionGracePeriodSeconds field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the DeletionGracePeriodSeconds field is set to the value of the last call. +func (b *RunningConfigApplyConfiguration) WithDeletionGracePeriodSeconds(value int64) *RunningConfigApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.DeletionGracePeriodSeconds = &value + return b +} + +// WithLabels puts the entries into the Labels field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, the entries provided by each call will be put on the Labels field, +// overwriting an existing map entries in Labels field with the same key. +func (b *RunningConfigApplyConfiguration) WithLabels(entries map[string]string) *RunningConfigApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + if b.ObjectMetaApplyConfiguration.Labels == nil && len(entries) > 0 { + b.ObjectMetaApplyConfiguration.Labels = make(map[string]string, len(entries)) + } + for k, v := range entries { + b.ObjectMetaApplyConfiguration.Labels[k] = v + } + return b +} + +// WithAnnotations puts the entries into the Annotations field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, the entries provided by each call will be put on the Annotations field, +// overwriting an existing map entries in Annotations field with the same key. +func (b *RunningConfigApplyConfiguration) WithAnnotations(entries map[string]string) *RunningConfigApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + if b.ObjectMetaApplyConfiguration.Annotations == nil && len(entries) > 0 { + b.ObjectMetaApplyConfiguration.Annotations = make(map[string]string, len(entries)) + } + for k, v := range entries { + b.ObjectMetaApplyConfiguration.Annotations[k] = v + } + return b +} + +// WithOwnerReferences adds the given value to the OwnerReferences field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, values provided by each call will be appended to the OwnerReferences field. +func (b *RunningConfigApplyConfiguration) WithOwnerReferences(values ...*v1.OwnerReferenceApplyConfiguration) *RunningConfigApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + for i := range values { + if values[i] == nil { + panic("nil value passed to WithOwnerReferences") + } + b.ObjectMetaApplyConfiguration.OwnerReferences = append(b.ObjectMetaApplyConfiguration.OwnerReferences, *values[i]) + } + return b +} + +// WithFinalizers adds the given value to the Finalizers field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, values provided by each call will be appended to the Finalizers field. +func (b *RunningConfigApplyConfiguration) WithFinalizers(values ...string) *RunningConfigApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + for i := range values { + b.ObjectMetaApplyConfiguration.Finalizers = append(b.ObjectMetaApplyConfiguration.Finalizers, values[i]) + } + return b +} + +func (b *RunningConfigApplyConfiguration) ensureObjectMetaApplyConfigurationExists() { + if b.ObjectMetaApplyConfiguration == nil { + b.ObjectMetaApplyConfiguration = &v1.ObjectMetaApplyConfiguration{} + } +} + +// WithSpec sets the Spec field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Spec field is set to the value of the last call. +func (b *RunningConfigApplyConfiguration) WithSpec(value configv1alpha1.RunningConfigSpec) *RunningConfigApplyConfiguration { + b.Spec = &value + return b +} + +// WithStatus sets the Status field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Status field is set to the value of the last call. +func (b *RunningConfigApplyConfiguration) WithStatus(value *RunningConfigStatusApplyConfiguration) *RunningConfigApplyConfiguration { + b.Status = value + return b +} + +// GetKind retrieves the value of the Kind field in the declarative configuration. +func (b *RunningConfigApplyConfiguration) GetKind() *string { + return b.TypeMetaApplyConfiguration.Kind +} + +// GetAPIVersion retrieves the value of the APIVersion field in the declarative configuration. +func (b *RunningConfigApplyConfiguration) GetAPIVersion() *string { + return b.TypeMetaApplyConfiguration.APIVersion +} + +// GetName retrieves the value of the Name field in the declarative configuration. +func (b *RunningConfigApplyConfiguration) GetName() *string { + b.ensureObjectMetaApplyConfigurationExists() + return b.ObjectMetaApplyConfiguration.Name +} + +// GetNamespace retrieves the value of the Namespace field in the declarative configuration. +func (b *RunningConfigApplyConfiguration) GetNamespace() *string { + b.ensureObjectMetaApplyConfigurationExists() + return b.ObjectMetaApplyConfiguration.Namespace +} diff --git a/pkg/generated/applyconfiguration/config/v1alpha1/runningconfigstatus.go b/pkg/generated/applyconfiguration/config/v1alpha1/runningconfigstatus.go new file mode 100644 index 00000000..65d5f91c --- /dev/null +++ b/pkg/generated/applyconfiguration/config/v1alpha1/runningconfigstatus.go @@ -0,0 +1,44 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ +// Code generated by applyconfiguration-gen. DO NOT EDIT. + +package v1alpha1 + +import ( + runtime "k8s.io/apimachinery/pkg/runtime" +) + +// RunningConfigStatusApplyConfiguration represents a declarative configuration of the RunningConfigStatus type for use +// with apply. +// +// RunningConfigStatus defines the observed state of RunningConfig +type RunningConfigStatusApplyConfiguration struct { + Value *runtime.RawExtension `json:"value,omitempty"` +} + +// RunningConfigStatusApplyConfiguration constructs a declarative configuration of the RunningConfigStatus type for use with +// apply. +func RunningConfigStatus() *RunningConfigStatusApplyConfiguration { + return &RunningConfigStatusApplyConfiguration{} +} + +// WithValue sets the Value field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Value field is set to the value of the last call. +func (b *RunningConfigStatusApplyConfiguration) WithValue(value runtime.RawExtension) *RunningConfigStatusApplyConfiguration { + b.Value = &value + return b +} diff --git a/pkg/generated/applyconfiguration/config/v1alpha1/sensitiveconfig.go b/pkg/generated/applyconfiguration/config/v1alpha1/sensitiveconfig.go new file mode 100644 index 00000000..f0686683 --- /dev/null +++ b/pkg/generated/applyconfiguration/config/v1alpha1/sensitiveconfig.go @@ -0,0 +1,244 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ +// Code generated by applyconfiguration-gen. DO NOT EDIT. + +package v1alpha1 + +import ( + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + types "k8s.io/apimachinery/pkg/types" + v1 "k8s.io/client-go/applyconfigurations/meta/v1" +) + +// SensitiveConfigApplyConfiguration represents a declarative configuration of the SensitiveConfig type for use +// with apply. +// +// SensitiveConfig defines the Schema for the SensitiveConfig API +type SensitiveConfigApplyConfiguration struct { + v1.TypeMetaApplyConfiguration `json:",inline"` + *v1.ObjectMetaApplyConfiguration `json:"metadata,omitempty"` + Spec *SensitiveConfigSpecApplyConfiguration `json:"spec,omitempty"` + Status *SensitiveConfigStatusApplyConfiguration `json:"status,omitempty"` +} + +// SensitiveConfig constructs a declarative configuration of the SensitiveConfig type for use with +// apply. +func SensitiveConfig(name, namespace string) *SensitiveConfigApplyConfiguration { + b := &SensitiveConfigApplyConfiguration{} + b.WithName(name) + b.WithNamespace(namespace) + b.WithKind("SensitiveConfig") + b.WithAPIVersion("config.sdcio.dev/v1alpha1") + return b +} + +func (b SensitiveConfigApplyConfiguration) IsApplyConfiguration() {} + +// WithKind sets the Kind field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Kind field is set to the value of the last call. +func (b *SensitiveConfigApplyConfiguration) WithKind(value string) *SensitiveConfigApplyConfiguration { + b.TypeMetaApplyConfiguration.Kind = &value + return b +} + +// WithAPIVersion sets the APIVersion field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the APIVersion field is set to the value of the last call. +func (b *SensitiveConfigApplyConfiguration) WithAPIVersion(value string) *SensitiveConfigApplyConfiguration { + b.TypeMetaApplyConfiguration.APIVersion = &value + return b +} + +// WithName sets the Name field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Name field is set to the value of the last call. +func (b *SensitiveConfigApplyConfiguration) WithName(value string) *SensitiveConfigApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.Name = &value + return b +} + +// WithGenerateName sets the GenerateName field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the GenerateName field is set to the value of the last call. +func (b *SensitiveConfigApplyConfiguration) WithGenerateName(value string) *SensitiveConfigApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.GenerateName = &value + return b +} + +// WithNamespace sets the Namespace field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Namespace field is set to the value of the last call. +func (b *SensitiveConfigApplyConfiguration) WithNamespace(value string) *SensitiveConfigApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.Namespace = &value + return b +} + +// WithUID sets the UID field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the UID field is set to the value of the last call. +func (b *SensitiveConfigApplyConfiguration) WithUID(value types.UID) *SensitiveConfigApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.UID = &value + return b +} + +// WithResourceVersion sets the ResourceVersion field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the ResourceVersion field is set to the value of the last call. +func (b *SensitiveConfigApplyConfiguration) WithResourceVersion(value string) *SensitiveConfigApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.ResourceVersion = &value + return b +} + +// WithGeneration sets the Generation field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Generation field is set to the value of the last call. +func (b *SensitiveConfigApplyConfiguration) WithGeneration(value int64) *SensitiveConfigApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.Generation = &value + return b +} + +// WithCreationTimestamp sets the CreationTimestamp field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the CreationTimestamp field is set to the value of the last call. +func (b *SensitiveConfigApplyConfiguration) WithCreationTimestamp(value metav1.Time) *SensitiveConfigApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.CreationTimestamp = &value + return b +} + +// WithDeletionTimestamp sets the DeletionTimestamp field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the DeletionTimestamp field is set to the value of the last call. +func (b *SensitiveConfigApplyConfiguration) WithDeletionTimestamp(value metav1.Time) *SensitiveConfigApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.DeletionTimestamp = &value + return b +} + +// WithDeletionGracePeriodSeconds sets the DeletionGracePeriodSeconds field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the DeletionGracePeriodSeconds field is set to the value of the last call. +func (b *SensitiveConfigApplyConfiguration) WithDeletionGracePeriodSeconds(value int64) *SensitiveConfigApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.DeletionGracePeriodSeconds = &value + return b +} + +// WithLabels puts the entries into the Labels field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, the entries provided by each call will be put on the Labels field, +// overwriting an existing map entries in Labels field with the same key. +func (b *SensitiveConfigApplyConfiguration) WithLabels(entries map[string]string) *SensitiveConfigApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + if b.ObjectMetaApplyConfiguration.Labels == nil && len(entries) > 0 { + b.ObjectMetaApplyConfiguration.Labels = make(map[string]string, len(entries)) + } + for k, v := range entries { + b.ObjectMetaApplyConfiguration.Labels[k] = v + } + return b +} + +// WithAnnotations puts the entries into the Annotations field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, the entries provided by each call will be put on the Annotations field, +// overwriting an existing map entries in Annotations field with the same key. +func (b *SensitiveConfigApplyConfiguration) WithAnnotations(entries map[string]string) *SensitiveConfigApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + if b.ObjectMetaApplyConfiguration.Annotations == nil && len(entries) > 0 { + b.ObjectMetaApplyConfiguration.Annotations = make(map[string]string, len(entries)) + } + for k, v := range entries { + b.ObjectMetaApplyConfiguration.Annotations[k] = v + } + return b +} + +// WithOwnerReferences adds the given value to the OwnerReferences field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, values provided by each call will be appended to the OwnerReferences field. +func (b *SensitiveConfigApplyConfiguration) WithOwnerReferences(values ...*v1.OwnerReferenceApplyConfiguration) *SensitiveConfigApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + for i := range values { + if values[i] == nil { + panic("nil value passed to WithOwnerReferences") + } + b.ObjectMetaApplyConfiguration.OwnerReferences = append(b.ObjectMetaApplyConfiguration.OwnerReferences, *values[i]) + } + return b +} + +// WithFinalizers adds the given value to the Finalizers field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, values provided by each call will be appended to the Finalizers field. +func (b *SensitiveConfigApplyConfiguration) WithFinalizers(values ...string) *SensitiveConfigApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + for i := range values { + b.ObjectMetaApplyConfiguration.Finalizers = append(b.ObjectMetaApplyConfiguration.Finalizers, values[i]) + } + return b +} + +func (b *SensitiveConfigApplyConfiguration) ensureObjectMetaApplyConfigurationExists() { + if b.ObjectMetaApplyConfiguration == nil { + b.ObjectMetaApplyConfiguration = &v1.ObjectMetaApplyConfiguration{} + } +} + +// WithSpec sets the Spec field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Spec field is set to the value of the last call. +func (b *SensitiveConfigApplyConfiguration) WithSpec(value *SensitiveConfigSpecApplyConfiguration) *SensitiveConfigApplyConfiguration { + b.Spec = value + return b +} + +// WithStatus sets the Status field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Status field is set to the value of the last call. +func (b *SensitiveConfigApplyConfiguration) WithStatus(value *SensitiveConfigStatusApplyConfiguration) *SensitiveConfigApplyConfiguration { + b.Status = value + return b +} + +// GetKind retrieves the value of the Kind field in the declarative configuration. +func (b *SensitiveConfigApplyConfiguration) GetKind() *string { + return b.TypeMetaApplyConfiguration.Kind +} + +// GetAPIVersion retrieves the value of the APIVersion field in the declarative configuration. +func (b *SensitiveConfigApplyConfiguration) GetAPIVersion() *string { + return b.TypeMetaApplyConfiguration.APIVersion +} + +// GetName retrieves the value of the Name field in the declarative configuration. +func (b *SensitiveConfigApplyConfiguration) GetName() *string { + b.ensureObjectMetaApplyConfigurationExists() + return b.ObjectMetaApplyConfiguration.Name +} + +// GetNamespace retrieves the value of the Namespace field in the declarative configuration. +func (b *SensitiveConfigApplyConfiguration) GetNamespace() *string { + b.ensureObjectMetaApplyConfigurationExists() + return b.ObjectMetaApplyConfiguration.Namespace +} diff --git a/pkg/generated/applyconfiguration/config/v1alpha1/sensitiveconfigdata.go b/pkg/generated/applyconfiguration/config/v1alpha1/sensitiveconfigdata.go new file mode 100644 index 00000000..c857d842 --- /dev/null +++ b/pkg/generated/applyconfiguration/config/v1alpha1/sensitiveconfigdata.go @@ -0,0 +1,53 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ +// Code generated by applyconfiguration-gen. DO NOT EDIT. + +package v1alpha1 + +import ( + v1 "k8s.io/api/core/v1" +) + +// SensitiveConfigDataApplyConfiguration represents a declarative configuration of the SensitiveConfigData type for use +// with apply. +type SensitiveConfigDataApplyConfiguration struct { + // Path defines the path relative to which the value is applicable + Path *string `json:"path,omitempty"` + // SecretKeyRef refers to a secret in the same namesapce as the config + SecretKeyRef *v1.SecretKeySelector `json:"secretKeyRef,omitempty"` +} + +// SensitiveConfigDataApplyConfiguration constructs a declarative configuration of the SensitiveConfigData type for use with +// apply. +func SensitiveConfigData() *SensitiveConfigDataApplyConfiguration { + return &SensitiveConfigDataApplyConfiguration{} +} + +// WithPath sets the Path field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Path field is set to the value of the last call. +func (b *SensitiveConfigDataApplyConfiguration) WithPath(value string) *SensitiveConfigDataApplyConfiguration { + b.Path = &value + return b +} + +// WithSecretKeyRef sets the SecretKeyRef field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the SecretKeyRef field is set to the value of the last call. +func (b *SensitiveConfigDataApplyConfiguration) WithSecretKeyRef(value v1.SecretKeySelector) *SensitiveConfigDataApplyConfiguration { + b.SecretKeyRef = &value + return b +} diff --git a/pkg/generated/applyconfiguration/config/v1alpha1/sensitiveconfigspec.go b/pkg/generated/applyconfiguration/config/v1alpha1/sensitiveconfigspec.go new file mode 100644 index 00000000..42b76e73 --- /dev/null +++ b/pkg/generated/applyconfiguration/config/v1alpha1/sensitiveconfigspec.go @@ -0,0 +1,77 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ +// Code generated by applyconfiguration-gen. DO NOT EDIT. + +package v1alpha1 + +// SensitiveConfigSpecApplyConfiguration represents a declarative configuration of the SensitiveConfigSpec type for use +// with apply. +// +// SensitiveConfigSpec defines the desired state of SensitiveConfig +type SensitiveConfigSpecApplyConfiguration struct { + // Lifecycle determines the lifecycle policies the resource e.g. delete is orphan or delete + // will follow + Lifecycle *LifecycleApplyConfiguration `json:"lifecycle,omitempty"` + // Priority defines the priority of this SensitiveConfig + Priority *int64 `json:"priority,omitempty"` + // Revertive defines if this CR is enabled for revertive or non revertve operation + Revertive *bool `json:"revertive,omitempty"` + // SensitiveConfig defines the SensitiveConfiguration to be applied to a target device + Config []SensitiveConfigDataApplyConfiguration `json:"config,omitempty"` +} + +// SensitiveConfigSpecApplyConfiguration constructs a declarative configuration of the SensitiveConfigSpec type for use with +// apply. +func SensitiveConfigSpec() *SensitiveConfigSpecApplyConfiguration { + return &SensitiveConfigSpecApplyConfiguration{} +} + +// WithLifecycle sets the Lifecycle field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Lifecycle field is set to the value of the last call. +func (b *SensitiveConfigSpecApplyConfiguration) WithLifecycle(value *LifecycleApplyConfiguration) *SensitiveConfigSpecApplyConfiguration { + b.Lifecycle = value + return b +} + +// WithPriority sets the Priority field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Priority field is set to the value of the last call. +func (b *SensitiveConfigSpecApplyConfiguration) WithPriority(value int64) *SensitiveConfigSpecApplyConfiguration { + b.Priority = &value + return b +} + +// WithRevertive sets the Revertive field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Revertive field is set to the value of the last call. +func (b *SensitiveConfigSpecApplyConfiguration) WithRevertive(value bool) *SensitiveConfigSpecApplyConfiguration { + b.Revertive = &value + return b +} + +// WithConfig adds the given value to the Config field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, values provided by each call will be appended to the Config field. +func (b *SensitiveConfigSpecApplyConfiguration) WithConfig(values ...*SensitiveConfigDataApplyConfiguration) *SensitiveConfigSpecApplyConfiguration { + for i := range values { + if values[i] == nil { + panic("nil value passed to WithConfig") + } + b.Config = append(b.Config, *values[i]) + } + return b +} diff --git a/pkg/generated/applyconfiguration/config/v1alpha1/sensitiveconfigstatus.go b/pkg/generated/applyconfiguration/config/v1alpha1/sensitiveconfigstatus.go new file mode 100644 index 00000000..e43d6062 --- /dev/null +++ b/pkg/generated/applyconfiguration/config/v1alpha1/sensitiveconfigstatus.go @@ -0,0 +1,78 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ +// Code generated by applyconfiguration-gen. DO NOT EDIT. + +package v1alpha1 + +import ( + conditionv1alpha1 "github.com/sdcio/config-server/apis/condition/v1alpha1" +) + +// SensitiveConfigStatusApplyConfiguration represents a declarative configuration of the SensitiveConfigStatus type for use +// with apply. +// +// SensitiveConfigStatus defines the observed state of SensitiveConfig +type SensitiveConfigStatusApplyConfiguration struct { + // ConditionedStatus provides the status of the Readiness using conditions + // if the condition is true the other attributes in the status are meaningful + conditionv1alpha1.ConditionedStatus `json:",inline"` + // LastKnownGoodSchema identifies the last known good schema used to apply the SensitiveConfig successfully + LastKnownGoodSchema *ConfigStatusLastKnownGoodSchemaApplyConfiguration `json:"lastKnownGoodSchema,omitempty"` + // AppliedSensitiveConfig defines the SensitiveConfig applied to the target + AppliedSensitiveConfig *SensitiveConfigSpecApplyConfiguration `json:"appliedSensitiveConfig,omitempty"` + // Deviations generation used for the latest SensitiveConfig apply + DeviationGeneration *int64 `json:"deviationGeneration,omitempty"` +} + +// SensitiveConfigStatusApplyConfiguration constructs a declarative configuration of the SensitiveConfigStatus type for use with +// apply. +func SensitiveConfigStatus() *SensitiveConfigStatusApplyConfiguration { + return &SensitiveConfigStatusApplyConfiguration{} +} + +// WithConditions adds the given value to the Conditions field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, values provided by each call will be appended to the Conditions field. +func (b *SensitiveConfigStatusApplyConfiguration) WithConditions(values ...conditionv1alpha1.Condition) *SensitiveConfigStatusApplyConfiguration { + for i := range values { + b.ConditionedStatus.Conditions = append(b.ConditionedStatus.Conditions, values[i]) + } + return b +} + +// WithLastKnownGoodSchema sets the LastKnownGoodSchema field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the LastKnownGoodSchema field is set to the value of the last call. +func (b *SensitiveConfigStatusApplyConfiguration) WithLastKnownGoodSchema(value *ConfigStatusLastKnownGoodSchemaApplyConfiguration) *SensitiveConfigStatusApplyConfiguration { + b.LastKnownGoodSchema = value + return b +} + +// WithAppliedSensitiveConfig sets the AppliedSensitiveConfig field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the AppliedSensitiveConfig field is set to the value of the last call. +func (b *SensitiveConfigStatusApplyConfiguration) WithAppliedSensitiveConfig(value *SensitiveConfigSpecApplyConfiguration) *SensitiveConfigStatusApplyConfiguration { + b.AppliedSensitiveConfig = value + return b +} + +// WithDeviationGeneration sets the DeviationGeneration field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the DeviationGeneration field is set to the value of the last call. +func (b *SensitiveConfigStatusApplyConfiguration) WithDeviationGeneration(value int64) *SensitiveConfigStatusApplyConfiguration { + b.DeviationGeneration = &value + return b +} diff --git a/pkg/generated/applyconfiguration/config/v1alpha1/target.go b/pkg/generated/applyconfiguration/config/v1alpha1/target.go new file mode 100644 index 00000000..995ff82b --- /dev/null +++ b/pkg/generated/applyconfiguration/config/v1alpha1/target.go @@ -0,0 +1,43 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ +// Code generated by applyconfiguration-gen. DO NOT EDIT. + +package v1alpha1 + +import ( + v1 "k8s.io/client-go/applyconfigurations/meta/v1" +) + +// TargetApplyConfiguration represents a declarative configuration of the Target type for use +// with apply. +type TargetApplyConfiguration struct { + // TargetSelector defines the selector used to select the targets to which the config applies + TargetSelector *v1.LabelSelectorApplyConfiguration `json:"targetSelector,omitempty"` +} + +// TargetApplyConfiguration constructs a declarative configuration of the Target type for use with +// apply. +func Target() *TargetApplyConfiguration { + return &TargetApplyConfiguration{} +} + +// WithTargetSelector sets the TargetSelector field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the TargetSelector field is set to the value of the last call. +func (b *TargetApplyConfiguration) WithTargetSelector(value *v1.LabelSelectorApplyConfiguration) *TargetApplyConfiguration { + b.TargetSelector = value + return b +} diff --git a/pkg/generated/applyconfiguration/config/v1alpha1/targetstatus.go b/pkg/generated/applyconfiguration/config/v1alpha1/targetstatus.go new file mode 100644 index 00000000..8eb4a795 --- /dev/null +++ b/pkg/generated/applyconfiguration/config/v1alpha1/targetstatus.go @@ -0,0 +1,46 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ +// Code generated by applyconfiguration-gen. DO NOT EDIT. + +package v1alpha1 + +import ( + conditionv1alpha1 "github.com/sdcio/config-server/apis/condition/v1alpha1" +) + +// TargetStatusApplyConfiguration represents a declarative configuration of the TargetStatus type for use +// with apply. +type TargetStatusApplyConfiguration struct { + Name *string `json:"name,omitempty"` + // right now we assume the namespace of the config and target are aligned + // NameSpace string `json:"namespace" protobuf:"bytes,2,opt,name=name"` + // Condition of the configCR status + conditionv1alpha1.Condition `json:",inline"` +} + +// TargetStatusApplyConfiguration constructs a declarative configuration of the TargetStatus type for use with +// apply. +func TargetStatus() *TargetStatusApplyConfiguration { + return &TargetStatusApplyConfiguration{} +} + +// WithName sets the Name field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Name field is set to the value of the last call. +func (b *TargetStatusApplyConfiguration) WithName(value string) *TargetStatusApplyConfiguration { + b.Name = &value + return b +} diff --git a/pkg/generated/applyconfiguration/internal/internal.go b/pkg/generated/applyconfiguration/internal/internal.go new file mode 100644 index 00000000..897bb91b --- /dev/null +++ b/pkg/generated/applyconfiguration/internal/internal.go @@ -0,0 +1,61 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ +// Code generated by applyconfiguration-gen. DO NOT EDIT. + +package internal + +import ( + fmt "fmt" + sync "sync" + + typed "sigs.k8s.io/structured-merge-diff/v6/typed" +) + +func Parser() *typed.Parser { + parserOnce.Do(func() { + var err error + parser, err = typed.NewParser(schemaYAML) + if err != nil { + panic(fmt.Sprintf("Failed to parse schema: %v", err)) + } + }) + return parser +} + +var parserOnce sync.Once +var parser *typed.Parser +var schemaYAML = typed.YAMLObject(`types: +- name: __untyped_atomic_ + scalar: untyped + list: + elementType: + namedType: __untyped_atomic_ + elementRelationship: atomic + map: + elementType: + namedType: __untyped_atomic_ + elementRelationship: atomic +- name: __untyped_deduced_ + scalar: untyped + list: + elementType: + namedType: __untyped_atomic_ + elementRelationship: atomic + map: + elementType: + namedType: __untyped_deduced_ + elementRelationship: separable +`) diff --git a/pkg/generated/applyconfiguration/inv/v1alpha1/discoveryinfo.go b/pkg/generated/applyconfiguration/inv/v1alpha1/discoveryinfo.go new file mode 100644 index 00000000..17a36637 --- /dev/null +++ b/pkg/generated/applyconfiguration/inv/v1alpha1/discoveryinfo.go @@ -0,0 +1,111 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ +// Code generated by applyconfiguration-gen. DO NOT EDIT. + +package v1alpha1 + +// DiscoveryInfoApplyConfiguration represents a declarative configuration of the DiscoveryInfo type for use +// with apply. +type DiscoveryInfoApplyConfiguration struct { + // Protocol used for discovery + Protocol *string `json:"protocol,omitempty"` + // Type associated with the target + Provider *string `json:"provider,omitempty"` + // Version associated with the target + Version *string `json:"version,omitempty"` + // HostName associated with the target + HostName *string `json:"hostname,omitempty"` + // Platform associated with the target + Platform *string `json:"platform,omitempty"` + // MacAddress associated with the target + MacAddress *string `json:"macAddress,omitempty"` + // SerialNumber associated with the target + SerialNumber *string `json:"serialNumber,omitempty"` + // Supported Encodings of the target + SupportedEncodings []string `json:"supportedEncodings,omitempty"` +} + +// DiscoveryInfoApplyConfiguration constructs a declarative configuration of the DiscoveryInfo type for use with +// apply. +func DiscoveryInfo() *DiscoveryInfoApplyConfiguration { + return &DiscoveryInfoApplyConfiguration{} +} + +// WithProtocol sets the Protocol field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Protocol field is set to the value of the last call. +func (b *DiscoveryInfoApplyConfiguration) WithProtocol(value string) *DiscoveryInfoApplyConfiguration { + b.Protocol = &value + return b +} + +// WithProvider sets the Provider field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Provider field is set to the value of the last call. +func (b *DiscoveryInfoApplyConfiguration) WithProvider(value string) *DiscoveryInfoApplyConfiguration { + b.Provider = &value + return b +} + +// WithVersion sets the Version field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Version field is set to the value of the last call. +func (b *DiscoveryInfoApplyConfiguration) WithVersion(value string) *DiscoveryInfoApplyConfiguration { + b.Version = &value + return b +} + +// WithHostName sets the HostName field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the HostName field is set to the value of the last call. +func (b *DiscoveryInfoApplyConfiguration) WithHostName(value string) *DiscoveryInfoApplyConfiguration { + b.HostName = &value + return b +} + +// WithPlatform sets the Platform field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Platform field is set to the value of the last call. +func (b *DiscoveryInfoApplyConfiguration) WithPlatform(value string) *DiscoveryInfoApplyConfiguration { + b.Platform = &value + return b +} + +// WithMacAddress sets the MacAddress field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the MacAddress field is set to the value of the last call. +func (b *DiscoveryInfoApplyConfiguration) WithMacAddress(value string) *DiscoveryInfoApplyConfiguration { + b.MacAddress = &value + return b +} + +// WithSerialNumber sets the SerialNumber field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the SerialNumber field is set to the value of the last call. +func (b *DiscoveryInfoApplyConfiguration) WithSerialNumber(value string) *DiscoveryInfoApplyConfiguration { + b.SerialNumber = &value + return b +} + +// WithSupportedEncodings adds the given value to the SupportedEncodings field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, values provided by each call will be appended to the SupportedEncodings field. +func (b *DiscoveryInfoApplyConfiguration) WithSupportedEncodings(values ...string) *DiscoveryInfoApplyConfiguration { + for i := range values { + b.SupportedEncodings = append(b.SupportedEncodings, values[i]) + } + return b +} diff --git a/pkg/generated/applyconfiguration/inv/v1alpha1/discoveryparameters.go b/pkg/generated/applyconfiguration/inv/v1alpha1/discoveryparameters.go new file mode 100644 index 00000000..8924c7f4 --- /dev/null +++ b/pkg/generated/applyconfiguration/inv/v1alpha1/discoveryparameters.go @@ -0,0 +1,100 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ +// Code generated by applyconfiguration-gen. DO NOT EDIT. + +package v1alpha1 + +import ( + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" +) + +// DiscoveryParametersApplyConfiguration represents a declarative configuration of the DiscoveryParameters type for use +// with apply. +type DiscoveryParametersApplyConfiguration struct { + // DefaultSchema define the default schema used to connect to a target + // Indicates that discovery is disable; cannot be used for prefix based discovery rules + DefaultSchema *SchemaKeyApplyConfiguration `json:"defaultSchema,omitempty"` + // DiscoveryProfile define the profiles the discovery controller uses to discover targets + DiscoveryProfile *DiscoveryProfileApplyConfiguration `json:"discoveryProfile,omitempty"` + // TargetConnectionProfiles define the profile the discovery controller uses to create targets + // once discovered + TargetConnectionProfiles []TargetProfileApplyConfiguration `json:"targetConnectionProfiles,omitempty"` + // TargetTemplate defines the template the discovery controller uses to create the targets as a result of the discovery + TargetTemplate *TargetTemplateApplyConfiguration `json:"targetTemplate,omitempty"` + // Period defines the wait period between discovery rule runs + Period *v1.Duration `json:"period,omitempty"` + // number of concurrent IP scan + ConcurrentScans *int64 `json:"concurrentScans,omitempty"` +} + +// DiscoveryParametersApplyConfiguration constructs a declarative configuration of the DiscoveryParameters type for use with +// apply. +func DiscoveryParameters() *DiscoveryParametersApplyConfiguration { + return &DiscoveryParametersApplyConfiguration{} +} + +// WithDefaultSchema sets the DefaultSchema field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the DefaultSchema field is set to the value of the last call. +func (b *DiscoveryParametersApplyConfiguration) WithDefaultSchema(value *SchemaKeyApplyConfiguration) *DiscoveryParametersApplyConfiguration { + b.DefaultSchema = value + return b +} + +// WithDiscoveryProfile sets the DiscoveryProfile field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the DiscoveryProfile field is set to the value of the last call. +func (b *DiscoveryParametersApplyConfiguration) WithDiscoveryProfile(value *DiscoveryProfileApplyConfiguration) *DiscoveryParametersApplyConfiguration { + b.DiscoveryProfile = value + return b +} + +// WithTargetConnectionProfiles adds the given value to the TargetConnectionProfiles field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, values provided by each call will be appended to the TargetConnectionProfiles field. +func (b *DiscoveryParametersApplyConfiguration) WithTargetConnectionProfiles(values ...*TargetProfileApplyConfiguration) *DiscoveryParametersApplyConfiguration { + for i := range values { + if values[i] == nil { + panic("nil value passed to WithTargetConnectionProfiles") + } + b.TargetConnectionProfiles = append(b.TargetConnectionProfiles, *values[i]) + } + return b +} + +// WithTargetTemplate sets the TargetTemplate field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the TargetTemplate field is set to the value of the last call. +func (b *DiscoveryParametersApplyConfiguration) WithTargetTemplate(value *TargetTemplateApplyConfiguration) *DiscoveryParametersApplyConfiguration { + b.TargetTemplate = value + return b +} + +// WithPeriod sets the Period field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Period field is set to the value of the last call. +func (b *DiscoveryParametersApplyConfiguration) WithPeriod(value v1.Duration) *DiscoveryParametersApplyConfiguration { + b.Period = &value + return b +} + +// WithConcurrentScans sets the ConcurrentScans field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the ConcurrentScans field is set to the value of the last call. +func (b *DiscoveryParametersApplyConfiguration) WithConcurrentScans(value int64) *DiscoveryParametersApplyConfiguration { + b.ConcurrentScans = &value + return b +} diff --git a/pkg/generated/applyconfiguration/inv/v1alpha1/discoverypathdefinition.go b/pkg/generated/applyconfiguration/inv/v1alpha1/discoverypathdefinition.go new file mode 100644 index 00000000..9b3aa997 --- /dev/null +++ b/pkg/generated/applyconfiguration/inv/v1alpha1/discoverypathdefinition.go @@ -0,0 +1,69 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ +// Code generated by applyconfiguration-gen. DO NOT EDIT. + +package v1alpha1 + +// DiscoveryPathDefinitionApplyConfiguration represents a declarative configuration of the DiscoveryPathDefinition type for use +// with apply. +type DiscoveryPathDefinitionApplyConfiguration struct { + // Key defines the key of the path for fast lookup + Key *string `json:"key,omitempty"` + // Path associated with the key + Path *string `json:"path,omitempty"` + // Script defines the starlark script to transform the value + Script *string `json:"script,omitempty"` + // Regex defines the regex to transform the value + Regex *string `json:"regex,omitempty"` +} + +// DiscoveryPathDefinitionApplyConfiguration constructs a declarative configuration of the DiscoveryPathDefinition type for use with +// apply. +func DiscoveryPathDefinition() *DiscoveryPathDefinitionApplyConfiguration { + return &DiscoveryPathDefinitionApplyConfiguration{} +} + +// WithKey sets the Key field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Key field is set to the value of the last call. +func (b *DiscoveryPathDefinitionApplyConfiguration) WithKey(value string) *DiscoveryPathDefinitionApplyConfiguration { + b.Key = &value + return b +} + +// WithPath sets the Path field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Path field is set to the value of the last call. +func (b *DiscoveryPathDefinitionApplyConfiguration) WithPath(value string) *DiscoveryPathDefinitionApplyConfiguration { + b.Path = &value + return b +} + +// WithScript sets the Script field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Script field is set to the value of the last call. +func (b *DiscoveryPathDefinitionApplyConfiguration) WithScript(value string) *DiscoveryPathDefinitionApplyConfiguration { + b.Script = &value + return b +} + +// WithRegex sets the Regex field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Regex field is set to the value of the last call. +func (b *DiscoveryPathDefinitionApplyConfiguration) WithRegex(value string) *DiscoveryPathDefinitionApplyConfiguration { + b.Regex = &value + return b +} diff --git a/pkg/generated/applyconfiguration/inv/v1alpha1/discoveryprofile.go b/pkg/generated/applyconfiguration/inv/v1alpha1/discoveryprofile.go new file mode 100644 index 00000000..4cfa08c6 --- /dev/null +++ b/pkg/generated/applyconfiguration/inv/v1alpha1/discoveryprofile.go @@ -0,0 +1,62 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ +// Code generated by applyconfiguration-gen. DO NOT EDIT. + +package v1alpha1 + +// DiscoveryProfileApplyConfiguration represents a declarative configuration of the DiscoveryProfile type for use +// with apply. +type DiscoveryProfileApplyConfiguration struct { + // Credentials defines the name of the secret that holds the credentials to connect to the target + Credentials *string `json:"credentials,omitempty"` + // TLSSecret defines the name of the TLS secret to connect to the target if mtls is used + TLSSecret *string `json:"tlsSecret,omitempty"` + // ConnectionProfiles define the list of profiles the discovery controller uses to discover the target. + // The order in which they are specified is the order in which discovery is executed. + ConnectionProfiles []string `json:"connectionProfiles,omitempty"` +} + +// DiscoveryProfileApplyConfiguration constructs a declarative configuration of the DiscoveryProfile type for use with +// apply. +func DiscoveryProfile() *DiscoveryProfileApplyConfiguration { + return &DiscoveryProfileApplyConfiguration{} +} + +// WithCredentials sets the Credentials field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Credentials field is set to the value of the last call. +func (b *DiscoveryProfileApplyConfiguration) WithCredentials(value string) *DiscoveryProfileApplyConfiguration { + b.Credentials = &value + return b +} + +// WithTLSSecret sets the TLSSecret field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the TLSSecret field is set to the value of the last call. +func (b *DiscoveryProfileApplyConfiguration) WithTLSSecret(value string) *DiscoveryProfileApplyConfiguration { + b.TLSSecret = &value + return b +} + +// WithConnectionProfiles adds the given value to the ConnectionProfiles field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, values provided by each call will be appended to the ConnectionProfiles field. +func (b *DiscoveryProfileApplyConfiguration) WithConnectionProfiles(values ...string) *DiscoveryProfileApplyConfiguration { + for i := range values { + b.ConnectionProfiles = append(b.ConnectionProfiles, values[i]) + } + return b +} diff --git a/pkg/generated/applyconfiguration/inv/v1alpha1/discoveryrule.go b/pkg/generated/applyconfiguration/inv/v1alpha1/discoveryrule.go new file mode 100644 index 00000000..00266a33 --- /dev/null +++ b/pkg/generated/applyconfiguration/inv/v1alpha1/discoveryrule.go @@ -0,0 +1,244 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ +// Code generated by applyconfiguration-gen. DO NOT EDIT. + +package v1alpha1 + +import ( + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + types "k8s.io/apimachinery/pkg/types" + v1 "k8s.io/client-go/applyconfigurations/meta/v1" +) + +// DiscoveryRuleApplyConfiguration represents a declarative configuration of the DiscoveryRule type for use +// with apply. +// +// DiscoveryRule is the Schema for the DiscoveryRule API +type DiscoveryRuleApplyConfiguration struct { + v1.TypeMetaApplyConfiguration `json:",inline"` + *v1.ObjectMetaApplyConfiguration `json:"metadata,omitempty"` + Spec *DiscoveryRuleSpecApplyConfiguration `json:"spec,omitempty"` + Status *DiscoveryRuleStatusApplyConfiguration `json:"status,omitempty"` +} + +// DiscoveryRule constructs a declarative configuration of the DiscoveryRule type for use with +// apply. +func DiscoveryRule(name, namespace string) *DiscoveryRuleApplyConfiguration { + b := &DiscoveryRuleApplyConfiguration{} + b.WithName(name) + b.WithNamespace(namespace) + b.WithKind("DiscoveryRule") + b.WithAPIVersion("inv.sdcio.dev/v1alpha1") + return b +} + +func (b DiscoveryRuleApplyConfiguration) IsApplyConfiguration() {} + +// WithKind sets the Kind field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Kind field is set to the value of the last call. +func (b *DiscoveryRuleApplyConfiguration) WithKind(value string) *DiscoveryRuleApplyConfiguration { + b.TypeMetaApplyConfiguration.Kind = &value + return b +} + +// WithAPIVersion sets the APIVersion field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the APIVersion field is set to the value of the last call. +func (b *DiscoveryRuleApplyConfiguration) WithAPIVersion(value string) *DiscoveryRuleApplyConfiguration { + b.TypeMetaApplyConfiguration.APIVersion = &value + return b +} + +// WithName sets the Name field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Name field is set to the value of the last call. +func (b *DiscoveryRuleApplyConfiguration) WithName(value string) *DiscoveryRuleApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.Name = &value + return b +} + +// WithGenerateName sets the GenerateName field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the GenerateName field is set to the value of the last call. +func (b *DiscoveryRuleApplyConfiguration) WithGenerateName(value string) *DiscoveryRuleApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.GenerateName = &value + return b +} + +// WithNamespace sets the Namespace field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Namespace field is set to the value of the last call. +func (b *DiscoveryRuleApplyConfiguration) WithNamespace(value string) *DiscoveryRuleApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.Namespace = &value + return b +} + +// WithUID sets the UID field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the UID field is set to the value of the last call. +func (b *DiscoveryRuleApplyConfiguration) WithUID(value types.UID) *DiscoveryRuleApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.UID = &value + return b +} + +// WithResourceVersion sets the ResourceVersion field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the ResourceVersion field is set to the value of the last call. +func (b *DiscoveryRuleApplyConfiguration) WithResourceVersion(value string) *DiscoveryRuleApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.ResourceVersion = &value + return b +} + +// WithGeneration sets the Generation field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Generation field is set to the value of the last call. +func (b *DiscoveryRuleApplyConfiguration) WithGeneration(value int64) *DiscoveryRuleApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.Generation = &value + return b +} + +// WithCreationTimestamp sets the CreationTimestamp field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the CreationTimestamp field is set to the value of the last call. +func (b *DiscoveryRuleApplyConfiguration) WithCreationTimestamp(value metav1.Time) *DiscoveryRuleApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.CreationTimestamp = &value + return b +} + +// WithDeletionTimestamp sets the DeletionTimestamp field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the DeletionTimestamp field is set to the value of the last call. +func (b *DiscoveryRuleApplyConfiguration) WithDeletionTimestamp(value metav1.Time) *DiscoveryRuleApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.DeletionTimestamp = &value + return b +} + +// WithDeletionGracePeriodSeconds sets the DeletionGracePeriodSeconds field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the DeletionGracePeriodSeconds field is set to the value of the last call. +func (b *DiscoveryRuleApplyConfiguration) WithDeletionGracePeriodSeconds(value int64) *DiscoveryRuleApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.DeletionGracePeriodSeconds = &value + return b +} + +// WithLabels puts the entries into the Labels field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, the entries provided by each call will be put on the Labels field, +// overwriting an existing map entries in Labels field with the same key. +func (b *DiscoveryRuleApplyConfiguration) WithLabels(entries map[string]string) *DiscoveryRuleApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + if b.ObjectMetaApplyConfiguration.Labels == nil && len(entries) > 0 { + b.ObjectMetaApplyConfiguration.Labels = make(map[string]string, len(entries)) + } + for k, v := range entries { + b.ObjectMetaApplyConfiguration.Labels[k] = v + } + return b +} + +// WithAnnotations puts the entries into the Annotations field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, the entries provided by each call will be put on the Annotations field, +// overwriting an existing map entries in Annotations field with the same key. +func (b *DiscoveryRuleApplyConfiguration) WithAnnotations(entries map[string]string) *DiscoveryRuleApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + if b.ObjectMetaApplyConfiguration.Annotations == nil && len(entries) > 0 { + b.ObjectMetaApplyConfiguration.Annotations = make(map[string]string, len(entries)) + } + for k, v := range entries { + b.ObjectMetaApplyConfiguration.Annotations[k] = v + } + return b +} + +// WithOwnerReferences adds the given value to the OwnerReferences field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, values provided by each call will be appended to the OwnerReferences field. +func (b *DiscoveryRuleApplyConfiguration) WithOwnerReferences(values ...*v1.OwnerReferenceApplyConfiguration) *DiscoveryRuleApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + for i := range values { + if values[i] == nil { + panic("nil value passed to WithOwnerReferences") + } + b.ObjectMetaApplyConfiguration.OwnerReferences = append(b.ObjectMetaApplyConfiguration.OwnerReferences, *values[i]) + } + return b +} + +// WithFinalizers adds the given value to the Finalizers field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, values provided by each call will be appended to the Finalizers field. +func (b *DiscoveryRuleApplyConfiguration) WithFinalizers(values ...string) *DiscoveryRuleApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + for i := range values { + b.ObjectMetaApplyConfiguration.Finalizers = append(b.ObjectMetaApplyConfiguration.Finalizers, values[i]) + } + return b +} + +func (b *DiscoveryRuleApplyConfiguration) ensureObjectMetaApplyConfigurationExists() { + if b.ObjectMetaApplyConfiguration == nil { + b.ObjectMetaApplyConfiguration = &v1.ObjectMetaApplyConfiguration{} + } +} + +// WithSpec sets the Spec field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Spec field is set to the value of the last call. +func (b *DiscoveryRuleApplyConfiguration) WithSpec(value *DiscoveryRuleSpecApplyConfiguration) *DiscoveryRuleApplyConfiguration { + b.Spec = value + return b +} + +// WithStatus sets the Status field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Status field is set to the value of the last call. +func (b *DiscoveryRuleApplyConfiguration) WithStatus(value *DiscoveryRuleStatusApplyConfiguration) *DiscoveryRuleApplyConfiguration { + b.Status = value + return b +} + +// GetKind retrieves the value of the Kind field in the declarative configuration. +func (b *DiscoveryRuleApplyConfiguration) GetKind() *string { + return b.TypeMetaApplyConfiguration.Kind +} + +// GetAPIVersion retrieves the value of the APIVersion field in the declarative configuration. +func (b *DiscoveryRuleApplyConfiguration) GetAPIVersion() *string { + return b.TypeMetaApplyConfiguration.APIVersion +} + +// GetName retrieves the value of the Name field in the declarative configuration. +func (b *DiscoveryRuleApplyConfiguration) GetName() *string { + b.ensureObjectMetaApplyConfigurationExists() + return b.ObjectMetaApplyConfiguration.Name +} + +// GetNamespace retrieves the value of the Namespace field in the declarative configuration. +func (b *DiscoveryRuleApplyConfiguration) GetNamespace() *string { + b.ensureObjectMetaApplyConfigurationExists() + return b.ObjectMetaApplyConfiguration.Namespace +} diff --git a/pkg/generated/applyconfiguration/inv/v1alpha1/discoveryruleaddress.go b/pkg/generated/applyconfiguration/inv/v1alpha1/discoveryruleaddress.go new file mode 100644 index 00000000..c51af135 --- /dev/null +++ b/pkg/generated/applyconfiguration/inv/v1alpha1/discoveryruleaddress.go @@ -0,0 +1,49 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ +// Code generated by applyconfiguration-gen. DO NOT EDIT. + +package v1alpha1 + +// DiscoveryRuleAddressApplyConfiguration represents a declarative configuration of the DiscoveryRuleAddress type for use +// with apply. +type DiscoveryRuleAddressApplyConfiguration struct { + // Address (specified as IP or DNS name) of the target/target(s) + Address *string `json:"address,omitempty"` + // HostName of the ip prefix; used for /32 or /128 addresses with discovery disabled + HostName *string `json:"hostName,omitempty"` +} + +// DiscoveryRuleAddressApplyConfiguration constructs a declarative configuration of the DiscoveryRuleAddress type for use with +// apply. +func DiscoveryRuleAddress() *DiscoveryRuleAddressApplyConfiguration { + return &DiscoveryRuleAddressApplyConfiguration{} +} + +// WithAddress sets the Address field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Address field is set to the value of the last call. +func (b *DiscoveryRuleAddressApplyConfiguration) WithAddress(value string) *DiscoveryRuleAddressApplyConfiguration { + b.Address = &value + return b +} + +// WithHostName sets the HostName field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the HostName field is set to the value of the last call. +func (b *DiscoveryRuleAddressApplyConfiguration) WithHostName(value string) *DiscoveryRuleAddressApplyConfiguration { + b.HostName = &value + return b +} diff --git a/pkg/generated/applyconfiguration/inv/v1alpha1/discoveryruleprefix.go b/pkg/generated/applyconfiguration/inv/v1alpha1/discoveryruleprefix.go new file mode 100644 index 00000000..030bf86b --- /dev/null +++ b/pkg/generated/applyconfiguration/inv/v1alpha1/discoveryruleprefix.go @@ -0,0 +1,51 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ +// Code generated by applyconfiguration-gen. DO NOT EDIT. + +package v1alpha1 + +// DiscoveryRulePrefixApplyConfiguration represents a declarative configuration of the DiscoveryRulePrefix type for use +// with apply. +type DiscoveryRulePrefixApplyConfiguration struct { + // Prefix of the target/target(s) + Prefix *string `json:"prefix,omitempty"` + // IP Prefixes to be excluded + Excludes []string `json:"excludes,omitempty"` +} + +// DiscoveryRulePrefixApplyConfiguration constructs a declarative configuration of the DiscoveryRulePrefix type for use with +// apply. +func DiscoveryRulePrefix() *DiscoveryRulePrefixApplyConfiguration { + return &DiscoveryRulePrefixApplyConfiguration{} +} + +// WithPrefix sets the Prefix field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Prefix field is set to the value of the last call. +func (b *DiscoveryRulePrefixApplyConfiguration) WithPrefix(value string) *DiscoveryRulePrefixApplyConfiguration { + b.Prefix = &value + return b +} + +// WithExcludes adds the given value to the Excludes field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, values provided by each call will be appended to the Excludes field. +func (b *DiscoveryRulePrefixApplyConfiguration) WithExcludes(values ...string) *DiscoveryRulePrefixApplyConfiguration { + for i := range values { + b.Excludes = append(b.Excludes, values[i]) + } + return b +} diff --git a/pkg/generated/applyconfiguration/inv/v1alpha1/discoveryrulespec.go b/pkg/generated/applyconfiguration/inv/v1alpha1/discoveryrulespec.go new file mode 100644 index 00000000..66e76275 --- /dev/null +++ b/pkg/generated/applyconfiguration/inv/v1alpha1/discoveryrulespec.go @@ -0,0 +1,152 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ +// Code generated by applyconfiguration-gen. DO NOT EDIT. + +package v1alpha1 + +import ( + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + v1 "k8s.io/client-go/applyconfigurations/meta/v1" +) + +// DiscoveryRuleSpecApplyConfiguration represents a declarative configuration of the DiscoveryRuleSpec type for use +// with apply. +// +// DiscoveryRuleSpec defines the desired state of DiscoveryRule +type DiscoveryRuleSpecApplyConfiguration struct { + // IP Prefixes for which this discovery rule applies + Prefixes []DiscoveryRulePrefixApplyConfiguration `json:"prefixes,omitempty"` + // IP Prefixes for which this discovery rule applies + Addresses []DiscoveryRuleAddressApplyConfiguration `json:"addresses,omitempty"` + // PodSelector defines the pod selector for which this discovery rule applies + PodSelector *v1.LabelSelectorApplyConfiguration `json:"podSelector,omitempty"` + // ServiceSelector defines the service selector for which this discovery rule applies + ServiceSelector *v1.LabelSelectorApplyConfiguration `json:"serviceSelector,omitempty"` + // ServiceDomain defines the service domain of the cluster, used by svc discovery to identify the + // domain name in the k8s cluster where the service reside. + ServiceDomain *string `json:"serviceDomain,omitempty"` + // Discovery defines the generic parameters of the discovery rule + DiscoveryParametersApplyConfiguration `json:",inline"` +} + +// DiscoveryRuleSpecApplyConfiguration constructs a declarative configuration of the DiscoveryRuleSpec type for use with +// apply. +func DiscoveryRuleSpec() *DiscoveryRuleSpecApplyConfiguration { + return &DiscoveryRuleSpecApplyConfiguration{} +} + +// WithPrefixes adds the given value to the Prefixes field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, values provided by each call will be appended to the Prefixes field. +func (b *DiscoveryRuleSpecApplyConfiguration) WithPrefixes(values ...*DiscoveryRulePrefixApplyConfiguration) *DiscoveryRuleSpecApplyConfiguration { + for i := range values { + if values[i] == nil { + panic("nil value passed to WithPrefixes") + } + b.Prefixes = append(b.Prefixes, *values[i]) + } + return b +} + +// WithAddresses adds the given value to the Addresses field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, values provided by each call will be appended to the Addresses field. +func (b *DiscoveryRuleSpecApplyConfiguration) WithAddresses(values ...*DiscoveryRuleAddressApplyConfiguration) *DiscoveryRuleSpecApplyConfiguration { + for i := range values { + if values[i] == nil { + panic("nil value passed to WithAddresses") + } + b.Addresses = append(b.Addresses, *values[i]) + } + return b +} + +// WithPodSelector sets the PodSelector field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the PodSelector field is set to the value of the last call. +func (b *DiscoveryRuleSpecApplyConfiguration) WithPodSelector(value *v1.LabelSelectorApplyConfiguration) *DiscoveryRuleSpecApplyConfiguration { + b.PodSelector = value + return b +} + +// WithServiceSelector sets the ServiceSelector field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the ServiceSelector field is set to the value of the last call. +func (b *DiscoveryRuleSpecApplyConfiguration) WithServiceSelector(value *v1.LabelSelectorApplyConfiguration) *DiscoveryRuleSpecApplyConfiguration { + b.ServiceSelector = value + return b +} + +// WithServiceDomain sets the ServiceDomain field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the ServiceDomain field is set to the value of the last call. +func (b *DiscoveryRuleSpecApplyConfiguration) WithServiceDomain(value string) *DiscoveryRuleSpecApplyConfiguration { + b.ServiceDomain = &value + return b +} + +// WithDefaultSchema sets the DefaultSchema field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the DefaultSchema field is set to the value of the last call. +func (b *DiscoveryRuleSpecApplyConfiguration) WithDefaultSchema(value *SchemaKeyApplyConfiguration) *DiscoveryRuleSpecApplyConfiguration { + b.DiscoveryParametersApplyConfiguration.DefaultSchema = value + return b +} + +// WithDiscoveryProfile sets the DiscoveryProfile field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the DiscoveryProfile field is set to the value of the last call. +func (b *DiscoveryRuleSpecApplyConfiguration) WithDiscoveryProfile(value *DiscoveryProfileApplyConfiguration) *DiscoveryRuleSpecApplyConfiguration { + b.DiscoveryParametersApplyConfiguration.DiscoveryProfile = value + return b +} + +// WithTargetConnectionProfiles adds the given value to the TargetConnectionProfiles field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, values provided by each call will be appended to the TargetConnectionProfiles field. +func (b *DiscoveryRuleSpecApplyConfiguration) WithTargetConnectionProfiles(values ...*TargetProfileApplyConfiguration) *DiscoveryRuleSpecApplyConfiguration { + for i := range values { + if values[i] == nil { + panic("nil value passed to WithTargetConnectionProfiles") + } + b.DiscoveryParametersApplyConfiguration.TargetConnectionProfiles = append(b.DiscoveryParametersApplyConfiguration.TargetConnectionProfiles, *values[i]) + } + return b +} + +// WithTargetTemplate sets the TargetTemplate field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the TargetTemplate field is set to the value of the last call. +func (b *DiscoveryRuleSpecApplyConfiguration) WithTargetTemplate(value *TargetTemplateApplyConfiguration) *DiscoveryRuleSpecApplyConfiguration { + b.DiscoveryParametersApplyConfiguration.TargetTemplate = value + return b +} + +// WithPeriod sets the Period field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Period field is set to the value of the last call. +func (b *DiscoveryRuleSpecApplyConfiguration) WithPeriod(value metav1.Duration) *DiscoveryRuleSpecApplyConfiguration { + b.DiscoveryParametersApplyConfiguration.Period = &value + return b +} + +// WithConcurrentScans sets the ConcurrentScans field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the ConcurrentScans field is set to the value of the last call. +func (b *DiscoveryRuleSpecApplyConfiguration) WithConcurrentScans(value int64) *DiscoveryRuleSpecApplyConfiguration { + b.DiscoveryParametersApplyConfiguration.ConcurrentScans = &value + return b +} diff --git a/pkg/generated/applyconfiguration/inv/v1alpha1/discoveryrulestatus.go b/pkg/generated/applyconfiguration/inv/v1alpha1/discoveryrulestatus.go new file mode 100644 index 00000000..195fe786 --- /dev/null +++ b/pkg/generated/applyconfiguration/inv/v1alpha1/discoveryrulestatus.go @@ -0,0 +1,62 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ +// Code generated by applyconfiguration-gen. DO NOT EDIT. + +package v1alpha1 + +import ( + conditionv1alpha1 "github.com/sdcio/config-server/apis/condition/v1alpha1" + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" +) + +// DiscoveryRuleStatusApplyConfiguration represents a declarative configuration of the DiscoveryRuleStatus type for use +// with apply. +// +// DiscoveryRuleStatus defines the observed state of DiscoveryRule +type DiscoveryRuleStatusApplyConfiguration struct { + // ConditionedStatus provides the status of the Discovery using conditions + // 2 conditions are used: + // - a condition for the reconcilation status + // - a condition for the ready status + // if both are true the other attributes in the status are meaningful + conditionv1alpha1.ConditionedStatus `json:",inline"` + // StartTime identifies when the dr got started + StartTime *v1.Time `json:"startTime,omitempty"` +} + +// DiscoveryRuleStatusApplyConfiguration constructs a declarative configuration of the DiscoveryRuleStatus type for use with +// apply. +func DiscoveryRuleStatus() *DiscoveryRuleStatusApplyConfiguration { + return &DiscoveryRuleStatusApplyConfiguration{} +} + +// WithConditions adds the given value to the Conditions field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, values provided by each call will be appended to the Conditions field. +func (b *DiscoveryRuleStatusApplyConfiguration) WithConditions(values ...conditionv1alpha1.Condition) *DiscoveryRuleStatusApplyConfiguration { + for i := range values { + b.ConditionedStatus.Conditions = append(b.ConditionedStatus.Conditions, values[i]) + } + return b +} + +// WithStartTime sets the StartTime field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the StartTime field is set to the value of the last call. +func (b *DiscoveryRuleStatusApplyConfiguration) WithStartTime(value v1.Time) *DiscoveryRuleStatusApplyConfiguration { + b.StartTime = &value + return b +} diff --git a/pkg/generated/applyconfiguration/inv/v1alpha1/discoveryvendorprofile.go b/pkg/generated/applyconfiguration/inv/v1alpha1/discoveryvendorprofile.go new file mode 100644 index 00000000..c561ab9c --- /dev/null +++ b/pkg/generated/applyconfiguration/inv/v1alpha1/discoveryvendorprofile.go @@ -0,0 +1,235 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ +// Code generated by applyconfiguration-gen. DO NOT EDIT. + +package v1alpha1 + +import ( + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + types "k8s.io/apimachinery/pkg/types" + v1 "k8s.io/client-go/applyconfigurations/meta/v1" +) + +// DiscoveryVendorProfileApplyConfiguration represents a declarative configuration of the DiscoveryVendorProfile type for use +// with apply. +// +// DiscoveryVendorProfile is the Schema for the DiscoveryVendorProfile API +type DiscoveryVendorProfileApplyConfiguration struct { + v1.TypeMetaApplyConfiguration `json:",inline"` + *v1.ObjectMetaApplyConfiguration `json:"metadata,omitempty"` + Spec *DiscoveryVendorProfileSpecApplyConfiguration `json:"spec,omitempty"` +} + +// DiscoveryVendorProfile constructs a declarative configuration of the DiscoveryVendorProfile type for use with +// apply. +func DiscoveryVendorProfile(name, namespace string) *DiscoveryVendorProfileApplyConfiguration { + b := &DiscoveryVendorProfileApplyConfiguration{} + b.WithName(name) + b.WithNamespace(namespace) + b.WithKind("DiscoveryVendorProfile") + b.WithAPIVersion("inv.sdcio.dev/v1alpha1") + return b +} + +func (b DiscoveryVendorProfileApplyConfiguration) IsApplyConfiguration() {} + +// WithKind sets the Kind field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Kind field is set to the value of the last call. +func (b *DiscoveryVendorProfileApplyConfiguration) WithKind(value string) *DiscoveryVendorProfileApplyConfiguration { + b.TypeMetaApplyConfiguration.Kind = &value + return b +} + +// WithAPIVersion sets the APIVersion field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the APIVersion field is set to the value of the last call. +func (b *DiscoveryVendorProfileApplyConfiguration) WithAPIVersion(value string) *DiscoveryVendorProfileApplyConfiguration { + b.TypeMetaApplyConfiguration.APIVersion = &value + return b +} + +// WithName sets the Name field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Name field is set to the value of the last call. +func (b *DiscoveryVendorProfileApplyConfiguration) WithName(value string) *DiscoveryVendorProfileApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.Name = &value + return b +} + +// WithGenerateName sets the GenerateName field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the GenerateName field is set to the value of the last call. +func (b *DiscoveryVendorProfileApplyConfiguration) WithGenerateName(value string) *DiscoveryVendorProfileApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.GenerateName = &value + return b +} + +// WithNamespace sets the Namespace field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Namespace field is set to the value of the last call. +func (b *DiscoveryVendorProfileApplyConfiguration) WithNamespace(value string) *DiscoveryVendorProfileApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.Namespace = &value + return b +} + +// WithUID sets the UID field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the UID field is set to the value of the last call. +func (b *DiscoveryVendorProfileApplyConfiguration) WithUID(value types.UID) *DiscoveryVendorProfileApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.UID = &value + return b +} + +// WithResourceVersion sets the ResourceVersion field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the ResourceVersion field is set to the value of the last call. +func (b *DiscoveryVendorProfileApplyConfiguration) WithResourceVersion(value string) *DiscoveryVendorProfileApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.ResourceVersion = &value + return b +} + +// WithGeneration sets the Generation field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Generation field is set to the value of the last call. +func (b *DiscoveryVendorProfileApplyConfiguration) WithGeneration(value int64) *DiscoveryVendorProfileApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.Generation = &value + return b +} + +// WithCreationTimestamp sets the CreationTimestamp field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the CreationTimestamp field is set to the value of the last call. +func (b *DiscoveryVendorProfileApplyConfiguration) WithCreationTimestamp(value metav1.Time) *DiscoveryVendorProfileApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.CreationTimestamp = &value + return b +} + +// WithDeletionTimestamp sets the DeletionTimestamp field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the DeletionTimestamp field is set to the value of the last call. +func (b *DiscoveryVendorProfileApplyConfiguration) WithDeletionTimestamp(value metav1.Time) *DiscoveryVendorProfileApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.DeletionTimestamp = &value + return b +} + +// WithDeletionGracePeriodSeconds sets the DeletionGracePeriodSeconds field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the DeletionGracePeriodSeconds field is set to the value of the last call. +func (b *DiscoveryVendorProfileApplyConfiguration) WithDeletionGracePeriodSeconds(value int64) *DiscoveryVendorProfileApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.DeletionGracePeriodSeconds = &value + return b +} + +// WithLabels puts the entries into the Labels field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, the entries provided by each call will be put on the Labels field, +// overwriting an existing map entries in Labels field with the same key. +func (b *DiscoveryVendorProfileApplyConfiguration) WithLabels(entries map[string]string) *DiscoveryVendorProfileApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + if b.ObjectMetaApplyConfiguration.Labels == nil && len(entries) > 0 { + b.ObjectMetaApplyConfiguration.Labels = make(map[string]string, len(entries)) + } + for k, v := range entries { + b.ObjectMetaApplyConfiguration.Labels[k] = v + } + return b +} + +// WithAnnotations puts the entries into the Annotations field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, the entries provided by each call will be put on the Annotations field, +// overwriting an existing map entries in Annotations field with the same key. +func (b *DiscoveryVendorProfileApplyConfiguration) WithAnnotations(entries map[string]string) *DiscoveryVendorProfileApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + if b.ObjectMetaApplyConfiguration.Annotations == nil && len(entries) > 0 { + b.ObjectMetaApplyConfiguration.Annotations = make(map[string]string, len(entries)) + } + for k, v := range entries { + b.ObjectMetaApplyConfiguration.Annotations[k] = v + } + return b +} + +// WithOwnerReferences adds the given value to the OwnerReferences field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, values provided by each call will be appended to the OwnerReferences field. +func (b *DiscoveryVendorProfileApplyConfiguration) WithOwnerReferences(values ...*v1.OwnerReferenceApplyConfiguration) *DiscoveryVendorProfileApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + for i := range values { + if values[i] == nil { + panic("nil value passed to WithOwnerReferences") + } + b.ObjectMetaApplyConfiguration.OwnerReferences = append(b.ObjectMetaApplyConfiguration.OwnerReferences, *values[i]) + } + return b +} + +// WithFinalizers adds the given value to the Finalizers field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, values provided by each call will be appended to the Finalizers field. +func (b *DiscoveryVendorProfileApplyConfiguration) WithFinalizers(values ...string) *DiscoveryVendorProfileApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + for i := range values { + b.ObjectMetaApplyConfiguration.Finalizers = append(b.ObjectMetaApplyConfiguration.Finalizers, values[i]) + } + return b +} + +func (b *DiscoveryVendorProfileApplyConfiguration) ensureObjectMetaApplyConfigurationExists() { + if b.ObjectMetaApplyConfiguration == nil { + b.ObjectMetaApplyConfiguration = &v1.ObjectMetaApplyConfiguration{} + } +} + +// WithSpec sets the Spec field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Spec field is set to the value of the last call. +func (b *DiscoveryVendorProfileApplyConfiguration) WithSpec(value *DiscoveryVendorProfileSpecApplyConfiguration) *DiscoveryVendorProfileApplyConfiguration { + b.Spec = value + return b +} + +// GetKind retrieves the value of the Kind field in the declarative configuration. +func (b *DiscoveryVendorProfileApplyConfiguration) GetKind() *string { + return b.TypeMetaApplyConfiguration.Kind +} + +// GetAPIVersion retrieves the value of the APIVersion field in the declarative configuration. +func (b *DiscoveryVendorProfileApplyConfiguration) GetAPIVersion() *string { + return b.TypeMetaApplyConfiguration.APIVersion +} + +// GetName retrieves the value of the Name field in the declarative configuration. +func (b *DiscoveryVendorProfileApplyConfiguration) GetName() *string { + b.ensureObjectMetaApplyConfigurationExists() + return b.ObjectMetaApplyConfiguration.Name +} + +// GetNamespace retrieves the value of the Namespace field in the declarative configuration. +func (b *DiscoveryVendorProfileApplyConfiguration) GetNamespace() *string { + b.ensureObjectMetaApplyConfigurationExists() + return b.ObjectMetaApplyConfiguration.Namespace +} diff --git a/pkg/generated/applyconfiguration/inv/v1alpha1/discoveryvendorprofilespec.go b/pkg/generated/applyconfiguration/inv/v1alpha1/discoveryvendorprofilespec.go new file mode 100644 index 00000000..c1fe426a --- /dev/null +++ b/pkg/generated/applyconfiguration/inv/v1alpha1/discoveryvendorprofilespec.go @@ -0,0 +1,40 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ +// Code generated by applyconfiguration-gen. DO NOT EDIT. + +package v1alpha1 + +// DiscoveryVendorProfileSpecApplyConfiguration represents a declarative configuration of the DiscoveryVendorProfileSpec type for use +// with apply. +// +// DiscoveryProfileSpec defines the desired state of DiscoveryProfile +type DiscoveryVendorProfileSpecApplyConfiguration struct { + Gnmi *GnmiDiscoveryVendorProfileParametersApplyConfiguration `json:"gnmi,omitempty"` +} + +// DiscoveryVendorProfileSpecApplyConfiguration constructs a declarative configuration of the DiscoveryVendorProfileSpec type for use with +// apply. +func DiscoveryVendorProfileSpec() *DiscoveryVendorProfileSpecApplyConfiguration { + return &DiscoveryVendorProfileSpecApplyConfiguration{} +} + +// WithGnmi sets the Gnmi field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Gnmi field is set to the value of the last call. +func (b *DiscoveryVendorProfileSpecApplyConfiguration) WithGnmi(value *GnmiDiscoveryVendorProfileParametersApplyConfiguration) *DiscoveryVendorProfileSpecApplyConfiguration { + b.Gnmi = value + return b +} diff --git a/pkg/generated/applyconfiguration/inv/v1alpha1/gnmidiscoveryvendorprofileparameters.go b/pkg/generated/applyconfiguration/inv/v1alpha1/gnmidiscoveryvendorprofileparameters.go new file mode 100644 index 00000000..59dde6ca --- /dev/null +++ b/pkg/generated/applyconfiguration/inv/v1alpha1/gnmidiscoveryvendorprofileparameters.go @@ -0,0 +1,84 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ +// Code generated by applyconfiguration-gen. DO NOT EDIT. + +package v1alpha1 + +import ( + invv1alpha1 "github.com/sdcio/config-server/apis/inv/v1alpha1" +) + +// GnmiDiscoveryVendorProfileParametersApplyConfiguration represents a declarative configuration of the GnmiDiscoveryVendorProfileParameters type for use +// with apply. +type GnmiDiscoveryVendorProfileParametersApplyConfiguration struct { + Organization *string `json:"organization,omitempty"` + ModelMatch *string `json:"modelMatch,omitempty"` + // Paths DiscoveryPaths `json:"paths" protobuf:"bytes,3,opt,name=paths"` + Paths []DiscoveryPathDefinitionApplyConfiguration `json:"paths,omitempty"` + Encoding *invv1alpha1.Encoding `json:"encoding,omitempty"` + PreserveNamespace *bool `json:"preserveNamespace,omitempty"` +} + +// GnmiDiscoveryVendorProfileParametersApplyConfiguration constructs a declarative configuration of the GnmiDiscoveryVendorProfileParameters type for use with +// apply. +func GnmiDiscoveryVendorProfileParameters() *GnmiDiscoveryVendorProfileParametersApplyConfiguration { + return &GnmiDiscoveryVendorProfileParametersApplyConfiguration{} +} + +// WithOrganization sets the Organization field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Organization field is set to the value of the last call. +func (b *GnmiDiscoveryVendorProfileParametersApplyConfiguration) WithOrganization(value string) *GnmiDiscoveryVendorProfileParametersApplyConfiguration { + b.Organization = &value + return b +} + +// WithModelMatch sets the ModelMatch field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the ModelMatch field is set to the value of the last call. +func (b *GnmiDiscoveryVendorProfileParametersApplyConfiguration) WithModelMatch(value string) *GnmiDiscoveryVendorProfileParametersApplyConfiguration { + b.ModelMatch = &value + return b +} + +// WithPaths adds the given value to the Paths field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, values provided by each call will be appended to the Paths field. +func (b *GnmiDiscoveryVendorProfileParametersApplyConfiguration) WithPaths(values ...*DiscoveryPathDefinitionApplyConfiguration) *GnmiDiscoveryVendorProfileParametersApplyConfiguration { + for i := range values { + if values[i] == nil { + panic("nil value passed to WithPaths") + } + b.Paths = append(b.Paths, *values[i]) + } + return b +} + +// WithEncoding sets the Encoding field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Encoding field is set to the value of the last call. +func (b *GnmiDiscoveryVendorProfileParametersApplyConfiguration) WithEncoding(value invv1alpha1.Encoding) *GnmiDiscoveryVendorProfileParametersApplyConfiguration { + b.Encoding = &value + return b +} + +// WithPreserveNamespace sets the PreserveNamespace field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the PreserveNamespace field is set to the value of the last call. +func (b *GnmiDiscoveryVendorProfileParametersApplyConfiguration) WithPreserveNamespace(value bool) *GnmiDiscoveryVendorProfileParametersApplyConfiguration { + b.PreserveNamespace = &value + return b +} diff --git a/pkg/generated/applyconfiguration/inv/v1alpha1/proxy.go b/pkg/generated/applyconfiguration/inv/v1alpha1/proxy.go new file mode 100644 index 00000000..73a61b64 --- /dev/null +++ b/pkg/generated/applyconfiguration/inv/v1alpha1/proxy.go @@ -0,0 +1,49 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ +// Code generated by applyconfiguration-gen. DO NOT EDIT. + +package v1alpha1 + +// ProxyApplyConfiguration represents a declarative configuration of the Proxy type for use +// with apply. +type ProxyApplyConfiguration struct { + // URL specifies the base URL of the HTTP/HTTPS proxy server. + URL *string `json:"URL,omitempty"` + // Credentials defines the name of the secret that holds the credentials to connect to the proxy server + Credentials *string `json:"credentials,omitempty"` +} + +// ProxyApplyConfiguration constructs a declarative configuration of the Proxy type for use with +// apply. +func Proxy() *ProxyApplyConfiguration { + return &ProxyApplyConfiguration{} +} + +// WithURL sets the URL field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the URL field is set to the value of the last call. +func (b *ProxyApplyConfiguration) WithURL(value string) *ProxyApplyConfiguration { + b.URL = &value + return b +} + +// WithCredentials sets the Credentials field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Credentials field is set to the value of the last call. +func (b *ProxyApplyConfiguration) WithCredentials(value string) *ProxyApplyConfiguration { + b.Credentials = &value + return b +} diff --git a/pkg/generated/applyconfiguration/inv/v1alpha1/repository.go b/pkg/generated/applyconfiguration/inv/v1alpha1/repository.go new file mode 100644 index 00000000..73204afb --- /dev/null +++ b/pkg/generated/applyconfiguration/inv/v1alpha1/repository.go @@ -0,0 +1,84 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ +// Code generated by applyconfiguration-gen. DO NOT EDIT. + +package v1alpha1 + +import ( + invv1alpha1 "github.com/sdcio/config-server/apis/inv/v1alpha1" +) + +// RepositoryApplyConfiguration represents a declarative configuration of the Repository type for use +// with apply. +type RepositoryApplyConfiguration struct { + // RepositoryURL specifies the base URL for a given repository + RepositoryURL *string `json:"repoURL,omitempty"` + // Credentials defines the name of the secret that holds the credentials to connect to the repo + Credentials *string `json:"credentials,omitempty"` + // Proxy defines the HTTP/HTTPS proxy to be used to connect to the repo. + Proxy *ProxyApplyConfiguration `json:"proxy,omitempty"` + // Kind defines the that the BranchOrTag string is a repository branch or a tag + Kind *invv1alpha1.BranchTagKind `json:"kind,omitempty"` + // Ref defines the branch or tag of the repository corresponding to the + // provider schema version + Ref *string `json:"ref,omitempty"` +} + +// RepositoryApplyConfiguration constructs a declarative configuration of the Repository type for use with +// apply. +func Repository() *RepositoryApplyConfiguration { + return &RepositoryApplyConfiguration{} +} + +// WithRepositoryURL sets the RepositoryURL field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the RepositoryURL field is set to the value of the last call. +func (b *RepositoryApplyConfiguration) WithRepositoryURL(value string) *RepositoryApplyConfiguration { + b.RepositoryURL = &value + return b +} + +// WithCredentials sets the Credentials field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Credentials field is set to the value of the last call. +func (b *RepositoryApplyConfiguration) WithCredentials(value string) *RepositoryApplyConfiguration { + b.Credentials = &value + return b +} + +// WithProxy sets the Proxy field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Proxy field is set to the value of the last call. +func (b *RepositoryApplyConfiguration) WithProxy(value *ProxyApplyConfiguration) *RepositoryApplyConfiguration { + b.Proxy = value + return b +} + +// WithKind sets the Kind field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Kind field is set to the value of the last call. +func (b *RepositoryApplyConfiguration) WithKind(value invv1alpha1.BranchTagKind) *RepositoryApplyConfiguration { + b.Kind = &value + return b +} + +// WithRef sets the Ref field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Ref field is set to the value of the last call. +func (b *RepositoryApplyConfiguration) WithRef(value string) *RepositoryApplyConfiguration { + b.Ref = &value + return b +} diff --git a/pkg/generated/applyconfiguration/inv/v1alpha1/rollout.go b/pkg/generated/applyconfiguration/inv/v1alpha1/rollout.go new file mode 100644 index 00000000..5bda9028 --- /dev/null +++ b/pkg/generated/applyconfiguration/inv/v1alpha1/rollout.go @@ -0,0 +1,244 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ +// Code generated by applyconfiguration-gen. DO NOT EDIT. + +package v1alpha1 + +import ( + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + types "k8s.io/apimachinery/pkg/types" + v1 "k8s.io/client-go/applyconfigurations/meta/v1" +) + +// RolloutApplyConfiguration represents a declarative configuration of the Rollout type for use +// with apply. +// +// Rollout is the Rollout for the Rollout API +type RolloutApplyConfiguration struct { + v1.TypeMetaApplyConfiguration `json:",inline"` + *v1.ObjectMetaApplyConfiguration `json:"metadata,omitempty"` + Spec *RolloutSpecApplyConfiguration `json:"spec,omitempty"` + Status *RolloutStatusApplyConfiguration `json:"status,omitempty"` +} + +// Rollout constructs a declarative configuration of the Rollout type for use with +// apply. +func Rollout(name, namespace string) *RolloutApplyConfiguration { + b := &RolloutApplyConfiguration{} + b.WithName(name) + b.WithNamespace(namespace) + b.WithKind("Rollout") + b.WithAPIVersion("inv.sdcio.dev/v1alpha1") + return b +} + +func (b RolloutApplyConfiguration) IsApplyConfiguration() {} + +// WithKind sets the Kind field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Kind field is set to the value of the last call. +func (b *RolloutApplyConfiguration) WithKind(value string) *RolloutApplyConfiguration { + b.TypeMetaApplyConfiguration.Kind = &value + return b +} + +// WithAPIVersion sets the APIVersion field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the APIVersion field is set to the value of the last call. +func (b *RolloutApplyConfiguration) WithAPIVersion(value string) *RolloutApplyConfiguration { + b.TypeMetaApplyConfiguration.APIVersion = &value + return b +} + +// WithName sets the Name field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Name field is set to the value of the last call. +func (b *RolloutApplyConfiguration) WithName(value string) *RolloutApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.Name = &value + return b +} + +// WithGenerateName sets the GenerateName field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the GenerateName field is set to the value of the last call. +func (b *RolloutApplyConfiguration) WithGenerateName(value string) *RolloutApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.GenerateName = &value + return b +} + +// WithNamespace sets the Namespace field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Namespace field is set to the value of the last call. +func (b *RolloutApplyConfiguration) WithNamespace(value string) *RolloutApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.Namespace = &value + return b +} + +// WithUID sets the UID field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the UID field is set to the value of the last call. +func (b *RolloutApplyConfiguration) WithUID(value types.UID) *RolloutApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.UID = &value + return b +} + +// WithResourceVersion sets the ResourceVersion field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the ResourceVersion field is set to the value of the last call. +func (b *RolloutApplyConfiguration) WithResourceVersion(value string) *RolloutApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.ResourceVersion = &value + return b +} + +// WithGeneration sets the Generation field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Generation field is set to the value of the last call. +func (b *RolloutApplyConfiguration) WithGeneration(value int64) *RolloutApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.Generation = &value + return b +} + +// WithCreationTimestamp sets the CreationTimestamp field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the CreationTimestamp field is set to the value of the last call. +func (b *RolloutApplyConfiguration) WithCreationTimestamp(value metav1.Time) *RolloutApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.CreationTimestamp = &value + return b +} + +// WithDeletionTimestamp sets the DeletionTimestamp field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the DeletionTimestamp field is set to the value of the last call. +func (b *RolloutApplyConfiguration) WithDeletionTimestamp(value metav1.Time) *RolloutApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.DeletionTimestamp = &value + return b +} + +// WithDeletionGracePeriodSeconds sets the DeletionGracePeriodSeconds field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the DeletionGracePeriodSeconds field is set to the value of the last call. +func (b *RolloutApplyConfiguration) WithDeletionGracePeriodSeconds(value int64) *RolloutApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.DeletionGracePeriodSeconds = &value + return b +} + +// WithLabels puts the entries into the Labels field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, the entries provided by each call will be put on the Labels field, +// overwriting an existing map entries in Labels field with the same key. +func (b *RolloutApplyConfiguration) WithLabels(entries map[string]string) *RolloutApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + if b.ObjectMetaApplyConfiguration.Labels == nil && len(entries) > 0 { + b.ObjectMetaApplyConfiguration.Labels = make(map[string]string, len(entries)) + } + for k, v := range entries { + b.ObjectMetaApplyConfiguration.Labels[k] = v + } + return b +} + +// WithAnnotations puts the entries into the Annotations field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, the entries provided by each call will be put on the Annotations field, +// overwriting an existing map entries in Annotations field with the same key. +func (b *RolloutApplyConfiguration) WithAnnotations(entries map[string]string) *RolloutApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + if b.ObjectMetaApplyConfiguration.Annotations == nil && len(entries) > 0 { + b.ObjectMetaApplyConfiguration.Annotations = make(map[string]string, len(entries)) + } + for k, v := range entries { + b.ObjectMetaApplyConfiguration.Annotations[k] = v + } + return b +} + +// WithOwnerReferences adds the given value to the OwnerReferences field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, values provided by each call will be appended to the OwnerReferences field. +func (b *RolloutApplyConfiguration) WithOwnerReferences(values ...*v1.OwnerReferenceApplyConfiguration) *RolloutApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + for i := range values { + if values[i] == nil { + panic("nil value passed to WithOwnerReferences") + } + b.ObjectMetaApplyConfiguration.OwnerReferences = append(b.ObjectMetaApplyConfiguration.OwnerReferences, *values[i]) + } + return b +} + +// WithFinalizers adds the given value to the Finalizers field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, values provided by each call will be appended to the Finalizers field. +func (b *RolloutApplyConfiguration) WithFinalizers(values ...string) *RolloutApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + for i := range values { + b.ObjectMetaApplyConfiguration.Finalizers = append(b.ObjectMetaApplyConfiguration.Finalizers, values[i]) + } + return b +} + +func (b *RolloutApplyConfiguration) ensureObjectMetaApplyConfigurationExists() { + if b.ObjectMetaApplyConfiguration == nil { + b.ObjectMetaApplyConfiguration = &v1.ObjectMetaApplyConfiguration{} + } +} + +// WithSpec sets the Spec field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Spec field is set to the value of the last call. +func (b *RolloutApplyConfiguration) WithSpec(value *RolloutSpecApplyConfiguration) *RolloutApplyConfiguration { + b.Spec = value + return b +} + +// WithStatus sets the Status field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Status field is set to the value of the last call. +func (b *RolloutApplyConfiguration) WithStatus(value *RolloutStatusApplyConfiguration) *RolloutApplyConfiguration { + b.Status = value + return b +} + +// GetKind retrieves the value of the Kind field in the declarative configuration. +func (b *RolloutApplyConfiguration) GetKind() *string { + return b.TypeMetaApplyConfiguration.Kind +} + +// GetAPIVersion retrieves the value of the APIVersion field in the declarative configuration. +func (b *RolloutApplyConfiguration) GetAPIVersion() *string { + return b.TypeMetaApplyConfiguration.APIVersion +} + +// GetName retrieves the value of the Name field in the declarative configuration. +func (b *RolloutApplyConfiguration) GetName() *string { + b.ensureObjectMetaApplyConfigurationExists() + return b.ObjectMetaApplyConfiguration.Name +} + +// GetNamespace retrieves the value of the Namespace field in the declarative configuration. +func (b *RolloutApplyConfiguration) GetNamespace() *string { + b.ensureObjectMetaApplyConfigurationExists() + return b.ObjectMetaApplyConfiguration.Namespace +} diff --git a/pkg/generated/applyconfiguration/inv/v1alpha1/rolloutspec.go b/pkg/generated/applyconfiguration/inv/v1alpha1/rolloutspec.go new file mode 100644 index 00000000..b4356814 --- /dev/null +++ b/pkg/generated/applyconfiguration/inv/v1alpha1/rolloutspec.go @@ -0,0 +1,94 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ +// Code generated by applyconfiguration-gen. DO NOT EDIT. + +package v1alpha1 + +import ( + invv1alpha1 "github.com/sdcio/config-server/apis/inv/v1alpha1" +) + +// RolloutSpecApplyConfiguration represents a declarative configuration of the RolloutSpec type for use +// with apply. +// +// RolloutSpec defines the desired state of Rollout +type RolloutSpecApplyConfiguration struct { + RepositoryApplyConfiguration `json:",inline"` + Strategy *invv1alpha1.RolloutStrategy `json:"strategy,omitempty"` + SkipUnavailableTarget *bool `json:"skipUnavailableTarget,omitempty"` +} + +// RolloutSpecApplyConfiguration constructs a declarative configuration of the RolloutSpec type for use with +// apply. +func RolloutSpec() *RolloutSpecApplyConfiguration { + return &RolloutSpecApplyConfiguration{} +} + +// WithRepositoryURL sets the RepositoryURL field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the RepositoryURL field is set to the value of the last call. +func (b *RolloutSpecApplyConfiguration) WithRepositoryURL(value string) *RolloutSpecApplyConfiguration { + b.RepositoryApplyConfiguration.RepositoryURL = &value + return b +} + +// WithCredentials sets the Credentials field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Credentials field is set to the value of the last call. +func (b *RolloutSpecApplyConfiguration) WithCredentials(value string) *RolloutSpecApplyConfiguration { + b.RepositoryApplyConfiguration.Credentials = &value + return b +} + +// WithProxy sets the Proxy field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Proxy field is set to the value of the last call. +func (b *RolloutSpecApplyConfiguration) WithProxy(value *ProxyApplyConfiguration) *RolloutSpecApplyConfiguration { + b.RepositoryApplyConfiguration.Proxy = value + return b +} + +// WithKind sets the Kind field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Kind field is set to the value of the last call. +func (b *RolloutSpecApplyConfiguration) WithKind(value invv1alpha1.BranchTagKind) *RolloutSpecApplyConfiguration { + b.RepositoryApplyConfiguration.Kind = &value + return b +} + +// WithRef sets the Ref field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Ref field is set to the value of the last call. +func (b *RolloutSpecApplyConfiguration) WithRef(value string) *RolloutSpecApplyConfiguration { + b.RepositoryApplyConfiguration.Ref = &value + return b +} + +// WithStrategy sets the Strategy field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Strategy field is set to the value of the last call. +func (b *RolloutSpecApplyConfiguration) WithStrategy(value invv1alpha1.RolloutStrategy) *RolloutSpecApplyConfiguration { + b.Strategy = &value + return b +} + +// WithSkipUnavailableTarget sets the SkipUnavailableTarget field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the SkipUnavailableTarget field is set to the value of the last call. +func (b *RolloutSpecApplyConfiguration) WithSkipUnavailableTarget(value bool) *RolloutSpecApplyConfiguration { + b.SkipUnavailableTarget = &value + return b +} diff --git a/pkg/generated/applyconfiguration/inv/v1alpha1/rolloutstatus.go b/pkg/generated/applyconfiguration/inv/v1alpha1/rolloutstatus.go new file mode 100644 index 00000000..ea853ca7 --- /dev/null +++ b/pkg/generated/applyconfiguration/inv/v1alpha1/rolloutstatus.go @@ -0,0 +1,62 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ +// Code generated by applyconfiguration-gen. DO NOT EDIT. + +package v1alpha1 + +import ( + conditionv1alpha1 "github.com/sdcio/config-server/apis/condition/v1alpha1" +) + +// RolloutStatusApplyConfiguration represents a declarative configuration of the RolloutStatus type for use +// with apply. +// +// RolloutStatus defines the observed state of Rollout +type RolloutStatusApplyConfiguration struct { + // ConditionedStatus provides the status of the Rollout using conditions + conditionv1alpha1.ConditionedStatus `json:",inline"` + // Targets defines the status of the rollout on the respective target + Targets []RolloutTargetStatusApplyConfiguration `json:"targets,omitempty"` +} + +// RolloutStatusApplyConfiguration constructs a declarative configuration of the RolloutStatus type for use with +// apply. +func RolloutStatus() *RolloutStatusApplyConfiguration { + return &RolloutStatusApplyConfiguration{} +} + +// WithConditions adds the given value to the Conditions field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, values provided by each call will be appended to the Conditions field. +func (b *RolloutStatusApplyConfiguration) WithConditions(values ...conditionv1alpha1.Condition) *RolloutStatusApplyConfiguration { + for i := range values { + b.ConditionedStatus.Conditions = append(b.ConditionedStatus.Conditions, values[i]) + } + return b +} + +// WithTargets adds the given value to the Targets field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, values provided by each call will be appended to the Targets field. +func (b *RolloutStatusApplyConfiguration) WithTargets(values ...*RolloutTargetStatusApplyConfiguration) *RolloutStatusApplyConfiguration { + for i := range values { + if values[i] == nil { + panic("nil value passed to WithTargets") + } + b.Targets = append(b.Targets, *values[i]) + } + return b +} diff --git a/pkg/generated/applyconfiguration/inv/v1alpha1/rollouttargetstatus.go b/pkg/generated/applyconfiguration/inv/v1alpha1/rollouttargetstatus.go new file mode 100644 index 00000000..9a79bc5d --- /dev/null +++ b/pkg/generated/applyconfiguration/inv/v1alpha1/rollouttargetstatus.go @@ -0,0 +1,54 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ +// Code generated by applyconfiguration-gen. DO NOT EDIT. + +package v1alpha1 + +import ( + conditionv1alpha1 "github.com/sdcio/config-server/apis/condition/v1alpha1" +) + +// RolloutTargetStatusApplyConfiguration represents a declarative configuration of the RolloutTargetStatus type for use +// with apply. +type RolloutTargetStatusApplyConfiguration struct { + Name *string `json:"name,omitempty"` + // ConditionedStatus provides the status of the Rollout using conditions + conditionv1alpha1.ConditionedStatus `json:",inline"` +} + +// RolloutTargetStatusApplyConfiguration constructs a declarative configuration of the RolloutTargetStatus type for use with +// apply. +func RolloutTargetStatus() *RolloutTargetStatusApplyConfiguration { + return &RolloutTargetStatusApplyConfiguration{} +} + +// WithName sets the Name field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Name field is set to the value of the last call. +func (b *RolloutTargetStatusApplyConfiguration) WithName(value string) *RolloutTargetStatusApplyConfiguration { + b.Name = &value + return b +} + +// WithConditions adds the given value to the Conditions field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, values provided by each call will be appended to the Conditions field. +func (b *RolloutTargetStatusApplyConfiguration) WithConditions(values ...conditionv1alpha1.Condition) *RolloutTargetStatusApplyConfiguration { + for i := range values { + b.ConditionedStatus.Conditions = append(b.ConditionedStatus.Conditions, values[i]) + } + return b +} diff --git a/pkg/generated/applyconfiguration/inv/v1alpha1/schema.go b/pkg/generated/applyconfiguration/inv/v1alpha1/schema.go new file mode 100644 index 00000000..bba70e44 --- /dev/null +++ b/pkg/generated/applyconfiguration/inv/v1alpha1/schema.go @@ -0,0 +1,244 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ +// Code generated by applyconfiguration-gen. DO NOT EDIT. + +package v1alpha1 + +import ( + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + types "k8s.io/apimachinery/pkg/types" + v1 "k8s.io/client-go/applyconfigurations/meta/v1" +) + +// SchemaApplyConfiguration represents a declarative configuration of the Schema type for use +// with apply. +// +// Schema is the Schema for the Schema API +type SchemaApplyConfiguration struct { + v1.TypeMetaApplyConfiguration `json:",inline"` + *v1.ObjectMetaApplyConfiguration `json:"metadata,omitempty"` + Spec *SchemaSpecApplyConfiguration `json:"spec,omitempty"` + Status *SchemaStatusApplyConfiguration `json:"status,omitempty"` +} + +// Schema constructs a declarative configuration of the Schema type for use with +// apply. +func Schema(name, namespace string) *SchemaApplyConfiguration { + b := &SchemaApplyConfiguration{} + b.WithName(name) + b.WithNamespace(namespace) + b.WithKind("Schema") + b.WithAPIVersion("inv.sdcio.dev/v1alpha1") + return b +} + +func (b SchemaApplyConfiguration) IsApplyConfiguration() {} + +// WithKind sets the Kind field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Kind field is set to the value of the last call. +func (b *SchemaApplyConfiguration) WithKind(value string) *SchemaApplyConfiguration { + b.TypeMetaApplyConfiguration.Kind = &value + return b +} + +// WithAPIVersion sets the APIVersion field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the APIVersion field is set to the value of the last call. +func (b *SchemaApplyConfiguration) WithAPIVersion(value string) *SchemaApplyConfiguration { + b.TypeMetaApplyConfiguration.APIVersion = &value + return b +} + +// WithName sets the Name field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Name field is set to the value of the last call. +func (b *SchemaApplyConfiguration) WithName(value string) *SchemaApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.Name = &value + return b +} + +// WithGenerateName sets the GenerateName field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the GenerateName field is set to the value of the last call. +func (b *SchemaApplyConfiguration) WithGenerateName(value string) *SchemaApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.GenerateName = &value + return b +} + +// WithNamespace sets the Namespace field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Namespace field is set to the value of the last call. +func (b *SchemaApplyConfiguration) WithNamespace(value string) *SchemaApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.Namespace = &value + return b +} + +// WithUID sets the UID field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the UID field is set to the value of the last call. +func (b *SchemaApplyConfiguration) WithUID(value types.UID) *SchemaApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.UID = &value + return b +} + +// WithResourceVersion sets the ResourceVersion field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the ResourceVersion field is set to the value of the last call. +func (b *SchemaApplyConfiguration) WithResourceVersion(value string) *SchemaApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.ResourceVersion = &value + return b +} + +// WithGeneration sets the Generation field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Generation field is set to the value of the last call. +func (b *SchemaApplyConfiguration) WithGeneration(value int64) *SchemaApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.Generation = &value + return b +} + +// WithCreationTimestamp sets the CreationTimestamp field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the CreationTimestamp field is set to the value of the last call. +func (b *SchemaApplyConfiguration) WithCreationTimestamp(value metav1.Time) *SchemaApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.CreationTimestamp = &value + return b +} + +// WithDeletionTimestamp sets the DeletionTimestamp field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the DeletionTimestamp field is set to the value of the last call. +func (b *SchemaApplyConfiguration) WithDeletionTimestamp(value metav1.Time) *SchemaApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.DeletionTimestamp = &value + return b +} + +// WithDeletionGracePeriodSeconds sets the DeletionGracePeriodSeconds field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the DeletionGracePeriodSeconds field is set to the value of the last call. +func (b *SchemaApplyConfiguration) WithDeletionGracePeriodSeconds(value int64) *SchemaApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.DeletionGracePeriodSeconds = &value + return b +} + +// WithLabels puts the entries into the Labels field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, the entries provided by each call will be put on the Labels field, +// overwriting an existing map entries in Labels field with the same key. +func (b *SchemaApplyConfiguration) WithLabels(entries map[string]string) *SchemaApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + if b.ObjectMetaApplyConfiguration.Labels == nil && len(entries) > 0 { + b.ObjectMetaApplyConfiguration.Labels = make(map[string]string, len(entries)) + } + for k, v := range entries { + b.ObjectMetaApplyConfiguration.Labels[k] = v + } + return b +} + +// WithAnnotations puts the entries into the Annotations field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, the entries provided by each call will be put on the Annotations field, +// overwriting an existing map entries in Annotations field with the same key. +func (b *SchemaApplyConfiguration) WithAnnotations(entries map[string]string) *SchemaApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + if b.ObjectMetaApplyConfiguration.Annotations == nil && len(entries) > 0 { + b.ObjectMetaApplyConfiguration.Annotations = make(map[string]string, len(entries)) + } + for k, v := range entries { + b.ObjectMetaApplyConfiguration.Annotations[k] = v + } + return b +} + +// WithOwnerReferences adds the given value to the OwnerReferences field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, values provided by each call will be appended to the OwnerReferences field. +func (b *SchemaApplyConfiguration) WithOwnerReferences(values ...*v1.OwnerReferenceApplyConfiguration) *SchemaApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + for i := range values { + if values[i] == nil { + panic("nil value passed to WithOwnerReferences") + } + b.ObjectMetaApplyConfiguration.OwnerReferences = append(b.ObjectMetaApplyConfiguration.OwnerReferences, *values[i]) + } + return b +} + +// WithFinalizers adds the given value to the Finalizers field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, values provided by each call will be appended to the Finalizers field. +func (b *SchemaApplyConfiguration) WithFinalizers(values ...string) *SchemaApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + for i := range values { + b.ObjectMetaApplyConfiguration.Finalizers = append(b.ObjectMetaApplyConfiguration.Finalizers, values[i]) + } + return b +} + +func (b *SchemaApplyConfiguration) ensureObjectMetaApplyConfigurationExists() { + if b.ObjectMetaApplyConfiguration == nil { + b.ObjectMetaApplyConfiguration = &v1.ObjectMetaApplyConfiguration{} + } +} + +// WithSpec sets the Spec field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Spec field is set to the value of the last call. +func (b *SchemaApplyConfiguration) WithSpec(value *SchemaSpecApplyConfiguration) *SchemaApplyConfiguration { + b.Spec = value + return b +} + +// WithStatus sets the Status field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Status field is set to the value of the last call. +func (b *SchemaApplyConfiguration) WithStatus(value *SchemaStatusApplyConfiguration) *SchemaApplyConfiguration { + b.Status = value + return b +} + +// GetKind retrieves the value of the Kind field in the declarative configuration. +func (b *SchemaApplyConfiguration) GetKind() *string { + return b.TypeMetaApplyConfiguration.Kind +} + +// GetAPIVersion retrieves the value of the APIVersion field in the declarative configuration. +func (b *SchemaApplyConfiguration) GetAPIVersion() *string { + return b.TypeMetaApplyConfiguration.APIVersion +} + +// GetName retrieves the value of the Name field in the declarative configuration. +func (b *SchemaApplyConfiguration) GetName() *string { + b.ensureObjectMetaApplyConfigurationExists() + return b.ObjectMetaApplyConfiguration.Name +} + +// GetNamespace retrieves the value of the Namespace field in the declarative configuration. +func (b *SchemaApplyConfiguration) GetNamespace() *string { + b.ensureObjectMetaApplyConfigurationExists() + return b.ObjectMetaApplyConfiguration.Namespace +} diff --git a/pkg/generated/applyconfiguration/inv/v1alpha1/schemakey.go b/pkg/generated/applyconfiguration/inv/v1alpha1/schemakey.go new file mode 100644 index 00000000..52356b3f --- /dev/null +++ b/pkg/generated/applyconfiguration/inv/v1alpha1/schemakey.go @@ -0,0 +1,49 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ +// Code generated by applyconfiguration-gen. DO NOT EDIT. + +package v1alpha1 + +// SchemaKeyApplyConfiguration represents a declarative configuration of the SchemaKey type for use +// with apply. +type SchemaKeyApplyConfiguration struct { + // Provider specifies the provider of the schema. + Provider *string `json:"provider,omitempty"` + // Version defines the version of the schema + Version *string `json:"version,omitempty"` +} + +// SchemaKeyApplyConfiguration constructs a declarative configuration of the SchemaKey type for use with +// apply. +func SchemaKey() *SchemaKeyApplyConfiguration { + return &SchemaKeyApplyConfiguration{} +} + +// WithProvider sets the Provider field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Provider field is set to the value of the last call. +func (b *SchemaKeyApplyConfiguration) WithProvider(value string) *SchemaKeyApplyConfiguration { + b.Provider = &value + return b +} + +// WithVersion sets the Version field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Version field is set to the value of the last call. +func (b *SchemaKeyApplyConfiguration) WithVersion(value string) *SchemaKeyApplyConfiguration { + b.Version = &value + return b +} diff --git a/pkg/generated/applyconfiguration/inv/v1alpha1/schemarepositorystatus.go b/pkg/generated/applyconfiguration/inv/v1alpha1/schemarepositorystatus.go new file mode 100644 index 00000000..a349e436 --- /dev/null +++ b/pkg/generated/applyconfiguration/inv/v1alpha1/schemarepositorystatus.go @@ -0,0 +1,51 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ +// Code generated by applyconfiguration-gen. DO NOT EDIT. + +package v1alpha1 + +// SchemaRepositoryStatusApplyConfiguration represents a declarative configuration of the SchemaRepositoryStatus type for use +// with apply. +// +// SchemaRepositoryStatus provides the observed hash of a repository +type SchemaRepositoryStatusApplyConfiguration struct { + // RepoURL defines URL of the repository + RepoURL *string `json:"repoURL,omitempty"` + // Reference indicating version of loaded repository + Reference *string `json:"reference,omitempty"` +} + +// SchemaRepositoryStatusApplyConfiguration constructs a declarative configuration of the SchemaRepositoryStatus type for use with +// apply. +func SchemaRepositoryStatus() *SchemaRepositoryStatusApplyConfiguration { + return &SchemaRepositoryStatusApplyConfiguration{} +} + +// WithRepoURL sets the RepoURL field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the RepoURL field is set to the value of the last call. +func (b *SchemaRepositoryStatusApplyConfiguration) WithRepoURL(value string) *SchemaRepositoryStatusApplyConfiguration { + b.RepoURL = &value + return b +} + +// WithReference sets the Reference field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Reference field is set to the value of the last call. +func (b *SchemaRepositoryStatusApplyConfiguration) WithReference(value string) *SchemaRepositoryStatusApplyConfiguration { + b.Reference = &value + return b +} diff --git a/pkg/generated/applyconfiguration/inv/v1alpha1/schemaspec.go b/pkg/generated/applyconfiguration/inv/v1alpha1/schemaspec.go new file mode 100644 index 00000000..603a2e71 --- /dev/null +++ b/pkg/generated/applyconfiguration/inv/v1alpha1/schemaspec.go @@ -0,0 +1,70 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ +// Code generated by applyconfiguration-gen. DO NOT EDIT. + +package v1alpha1 + +import ( + invv1alpha1 "github.com/sdcio/config-server/apis/inv/v1alpha1" +) + +// SchemaSpecApplyConfiguration represents a declarative configuration of the SchemaSpec type for use +// with apply. +// +// SchemaSpec defines the desired state of Schema +type SchemaSpecApplyConfiguration struct { + // Provider specifies the provider of the schema. + Provider *string `json:"provider,omitempty"` + // Version defines the version of the schema + Version *string `json:"version,omitempty"` + // Repositories define the repositories used for building the provider schema + Repositories []*invv1alpha1.SchemaSpecRepository `json:"repositories,omitempty"` +} + +// SchemaSpecApplyConfiguration constructs a declarative configuration of the SchemaSpec type for use with +// apply. +func SchemaSpec() *SchemaSpecApplyConfiguration { + return &SchemaSpecApplyConfiguration{} +} + +// WithProvider sets the Provider field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Provider field is set to the value of the last call. +func (b *SchemaSpecApplyConfiguration) WithProvider(value string) *SchemaSpecApplyConfiguration { + b.Provider = &value + return b +} + +// WithVersion sets the Version field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Version field is set to the value of the last call. +func (b *SchemaSpecApplyConfiguration) WithVersion(value string) *SchemaSpecApplyConfiguration { + b.Version = &value + return b +} + +// WithRepositories adds the given value to the Repositories field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, values provided by each call will be appended to the Repositories field. +func (b *SchemaSpecApplyConfiguration) WithRepositories(values ...**invv1alpha1.SchemaSpecRepository) *SchemaSpecApplyConfiguration { + for i := range values { + if values[i] == nil { + panic("nil value passed to WithRepositories") + } + b.Repositories = append(b.Repositories, *values[i]) + } + return b +} diff --git a/pkg/generated/applyconfiguration/inv/v1alpha1/schemaspecrepository.go b/pkg/generated/applyconfiguration/inv/v1alpha1/schemaspecrepository.go new file mode 100644 index 00000000..1c643d35 --- /dev/null +++ b/pkg/generated/applyconfiguration/inv/v1alpha1/schemaspecrepository.go @@ -0,0 +1,101 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ +// Code generated by applyconfiguration-gen. DO NOT EDIT. + +package v1alpha1 + +import ( + invv1alpha1 "github.com/sdcio/config-server/apis/inv/v1alpha1" +) + +// SchemaSpecRepositoryApplyConfiguration represents a declarative configuration of the SchemaSpecRepository type for use +// with apply. +type SchemaSpecRepositoryApplyConfiguration struct { + RepositoryApplyConfiguration `json:",inline"` + // Dirs defines the list of directories that identified the provider schema in src/dst pairs + // relative within the repository + Dirs []SrcDstPathApplyConfiguration `json:"dirs,omitempty"` + // Schema provides the details of which files must be used for the models and which files/directories + // cana be excludes + Schema *SchemaSpecSchemaApplyConfiguration `json:"schema,omitempty"` +} + +// SchemaSpecRepositoryApplyConfiguration constructs a declarative configuration of the SchemaSpecRepository type for use with +// apply. +func SchemaSpecRepository() *SchemaSpecRepositoryApplyConfiguration { + return &SchemaSpecRepositoryApplyConfiguration{} +} + +// WithRepositoryURL sets the RepositoryURL field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the RepositoryURL field is set to the value of the last call. +func (b *SchemaSpecRepositoryApplyConfiguration) WithRepositoryURL(value string) *SchemaSpecRepositoryApplyConfiguration { + b.RepositoryApplyConfiguration.RepositoryURL = &value + return b +} + +// WithCredentials sets the Credentials field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Credentials field is set to the value of the last call. +func (b *SchemaSpecRepositoryApplyConfiguration) WithCredentials(value string) *SchemaSpecRepositoryApplyConfiguration { + b.RepositoryApplyConfiguration.Credentials = &value + return b +} + +// WithProxy sets the Proxy field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Proxy field is set to the value of the last call. +func (b *SchemaSpecRepositoryApplyConfiguration) WithProxy(value *ProxyApplyConfiguration) *SchemaSpecRepositoryApplyConfiguration { + b.RepositoryApplyConfiguration.Proxy = value + return b +} + +// WithKind sets the Kind field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Kind field is set to the value of the last call. +func (b *SchemaSpecRepositoryApplyConfiguration) WithKind(value invv1alpha1.BranchTagKind) *SchemaSpecRepositoryApplyConfiguration { + b.RepositoryApplyConfiguration.Kind = &value + return b +} + +// WithRef sets the Ref field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Ref field is set to the value of the last call. +func (b *SchemaSpecRepositoryApplyConfiguration) WithRef(value string) *SchemaSpecRepositoryApplyConfiguration { + b.RepositoryApplyConfiguration.Ref = &value + return b +} + +// WithDirs adds the given value to the Dirs field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, values provided by each call will be appended to the Dirs field. +func (b *SchemaSpecRepositoryApplyConfiguration) WithDirs(values ...*SrcDstPathApplyConfiguration) *SchemaSpecRepositoryApplyConfiguration { + for i := range values { + if values[i] == nil { + panic("nil value passed to WithDirs") + } + b.Dirs = append(b.Dirs, *values[i]) + } + return b +} + +// WithSchema sets the Schema field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Schema field is set to the value of the last call. +func (b *SchemaSpecRepositoryApplyConfiguration) WithSchema(value *SchemaSpecSchemaApplyConfiguration) *SchemaSpecRepositoryApplyConfiguration { + b.Schema = value + return b +} diff --git a/pkg/generated/applyconfiguration/inv/v1alpha1/schemaspecschema.go b/pkg/generated/applyconfiguration/inv/v1alpha1/schemaspecschema.go new file mode 100644 index 00000000..b9b8e896 --- /dev/null +++ b/pkg/generated/applyconfiguration/inv/v1alpha1/schemaspecschema.go @@ -0,0 +1,65 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ +// Code generated by applyconfiguration-gen. DO NOT EDIT. + +package v1alpha1 + +// SchemaSpecSchemaApplyConfiguration represents a declarative configuration of the SchemaSpecSchema type for use +// with apply. +type SchemaSpecSchemaApplyConfiguration struct { + // Models defines the list of files/directories to be used as a model + Models []string `json:"models,omitempty"` + // Excludes defines the list of files/directories to be excluded + Includes []string `json:"includes,omitempty"` + // Excludes defines the list of files/directories to be excluded + Excludes []string `json:"excludes,omitempty"` +} + +// SchemaSpecSchemaApplyConfiguration constructs a declarative configuration of the SchemaSpecSchema type for use with +// apply. +func SchemaSpecSchema() *SchemaSpecSchemaApplyConfiguration { + return &SchemaSpecSchemaApplyConfiguration{} +} + +// WithModels adds the given value to the Models field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, values provided by each call will be appended to the Models field. +func (b *SchemaSpecSchemaApplyConfiguration) WithModels(values ...string) *SchemaSpecSchemaApplyConfiguration { + for i := range values { + b.Models = append(b.Models, values[i]) + } + return b +} + +// WithIncludes adds the given value to the Includes field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, values provided by each call will be appended to the Includes field. +func (b *SchemaSpecSchemaApplyConfiguration) WithIncludes(values ...string) *SchemaSpecSchemaApplyConfiguration { + for i := range values { + b.Includes = append(b.Includes, values[i]) + } + return b +} + +// WithExcludes adds the given value to the Excludes field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, values provided by each call will be appended to the Excludes field. +func (b *SchemaSpecSchemaApplyConfiguration) WithExcludes(values ...string) *SchemaSpecSchemaApplyConfiguration { + for i := range values { + b.Excludes = append(b.Excludes, values[i]) + } + return b +} diff --git a/pkg/generated/applyconfiguration/inv/v1alpha1/schemastatus.go b/pkg/generated/applyconfiguration/inv/v1alpha1/schemastatus.go new file mode 100644 index 00000000..93d0e43b --- /dev/null +++ b/pkg/generated/applyconfiguration/inv/v1alpha1/schemastatus.go @@ -0,0 +1,62 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ +// Code generated by applyconfiguration-gen. DO NOT EDIT. + +package v1alpha1 + +import ( + conditionv1alpha1 "github.com/sdcio/config-server/apis/condition/v1alpha1" +) + +// SchemaStatusApplyConfiguration represents a declarative configuration of the SchemaStatus type for use +// with apply. +// +// SchemaStatus defines the observed state of Schema +type SchemaStatusApplyConfiguration struct { + // ConditionedStatus provides the status of the Schema using conditions + conditionv1alpha1.ConditionedStatus `json:",inline"` + // SchemaRepositoryStatus provides the array of repositories + Repositories []SchemaRepositoryStatusApplyConfiguration `json:"repositories,omitempty"` +} + +// SchemaStatusApplyConfiguration constructs a declarative configuration of the SchemaStatus type for use with +// apply. +func SchemaStatus() *SchemaStatusApplyConfiguration { + return &SchemaStatusApplyConfiguration{} +} + +// WithConditions adds the given value to the Conditions field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, values provided by each call will be appended to the Conditions field. +func (b *SchemaStatusApplyConfiguration) WithConditions(values ...conditionv1alpha1.Condition) *SchemaStatusApplyConfiguration { + for i := range values { + b.ConditionedStatus.Conditions = append(b.ConditionedStatus.Conditions, values[i]) + } + return b +} + +// WithRepositories adds the given value to the Repositories field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, values provided by each call will be appended to the Repositories field. +func (b *SchemaStatusApplyConfiguration) WithRepositories(values ...*SchemaRepositoryStatusApplyConfiguration) *SchemaStatusApplyConfiguration { + for i := range values { + if values[i] == nil { + panic("nil value passed to WithRepositories") + } + b.Repositories = append(b.Repositories, *values[i]) + } + return b +} diff --git a/pkg/generated/applyconfiguration/inv/v1alpha1/srcdstpath.go b/pkg/generated/applyconfiguration/inv/v1alpha1/srcdstpath.go new file mode 100644 index 00000000..e7077565 --- /dev/null +++ b/pkg/generated/applyconfiguration/inv/v1alpha1/srcdstpath.go @@ -0,0 +1,52 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ +// Code generated by applyconfiguration-gen. DO NOT EDIT. + +package v1alpha1 + +// SrcDstPathApplyConfiguration represents a declarative configuration of the SrcDstPath type for use +// with apply. +// +// SrcDstPath provide a src/dst pair for the loader to download the schema from a specific src +// in the repository to a given destination in the schema server +type SrcDstPathApplyConfiguration struct { + // Src is the relative directory in the repository URL + Src *string `json:"src,omitempty"` + // Dst is the relative directory in the schema server + Dst *string `json:"dst,omitempty"` +} + +// SrcDstPathApplyConfiguration constructs a declarative configuration of the SrcDstPath type for use with +// apply. +func SrcDstPath() *SrcDstPathApplyConfiguration { + return &SrcDstPathApplyConfiguration{} +} + +// WithSrc sets the Src field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Src field is set to the value of the last call. +func (b *SrcDstPathApplyConfiguration) WithSrc(value string) *SrcDstPathApplyConfiguration { + b.Src = &value + return b +} + +// WithDst sets the Dst field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Dst field is set to the value of the last call. +func (b *SrcDstPathApplyConfiguration) WithDst(value string) *SrcDstPathApplyConfiguration { + b.Dst = &value + return b +} diff --git a/pkg/generated/applyconfiguration/inv/v1alpha1/subscription.go b/pkg/generated/applyconfiguration/inv/v1alpha1/subscription.go new file mode 100644 index 00000000..5a573bf4 --- /dev/null +++ b/pkg/generated/applyconfiguration/inv/v1alpha1/subscription.go @@ -0,0 +1,244 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ +// Code generated by applyconfiguration-gen. DO NOT EDIT. + +package v1alpha1 + +import ( + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + types "k8s.io/apimachinery/pkg/types" + v1 "k8s.io/client-go/applyconfigurations/meta/v1" +) + +// SubscriptionApplyConfiguration represents a declarative configuration of the Subscription type for use +// with apply. +// +// Subscription is the Schema for the Subscription API +type SubscriptionApplyConfiguration struct { + v1.TypeMetaApplyConfiguration `json:",inline"` + *v1.ObjectMetaApplyConfiguration `json:"metadata,omitempty"` + Spec *SubscriptionSpecApplyConfiguration `json:"spec,omitempty"` + Status *SubscriptionStatusApplyConfiguration `json:"status,omitempty"` +} + +// Subscription constructs a declarative configuration of the Subscription type for use with +// apply. +func Subscription(name, namespace string) *SubscriptionApplyConfiguration { + b := &SubscriptionApplyConfiguration{} + b.WithName(name) + b.WithNamespace(namespace) + b.WithKind("Subscription") + b.WithAPIVersion("inv.sdcio.dev/v1alpha1") + return b +} + +func (b SubscriptionApplyConfiguration) IsApplyConfiguration() {} + +// WithKind sets the Kind field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Kind field is set to the value of the last call. +func (b *SubscriptionApplyConfiguration) WithKind(value string) *SubscriptionApplyConfiguration { + b.TypeMetaApplyConfiguration.Kind = &value + return b +} + +// WithAPIVersion sets the APIVersion field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the APIVersion field is set to the value of the last call. +func (b *SubscriptionApplyConfiguration) WithAPIVersion(value string) *SubscriptionApplyConfiguration { + b.TypeMetaApplyConfiguration.APIVersion = &value + return b +} + +// WithName sets the Name field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Name field is set to the value of the last call. +func (b *SubscriptionApplyConfiguration) WithName(value string) *SubscriptionApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.Name = &value + return b +} + +// WithGenerateName sets the GenerateName field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the GenerateName field is set to the value of the last call. +func (b *SubscriptionApplyConfiguration) WithGenerateName(value string) *SubscriptionApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.GenerateName = &value + return b +} + +// WithNamespace sets the Namespace field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Namespace field is set to the value of the last call. +func (b *SubscriptionApplyConfiguration) WithNamespace(value string) *SubscriptionApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.Namespace = &value + return b +} + +// WithUID sets the UID field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the UID field is set to the value of the last call. +func (b *SubscriptionApplyConfiguration) WithUID(value types.UID) *SubscriptionApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.UID = &value + return b +} + +// WithResourceVersion sets the ResourceVersion field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the ResourceVersion field is set to the value of the last call. +func (b *SubscriptionApplyConfiguration) WithResourceVersion(value string) *SubscriptionApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.ResourceVersion = &value + return b +} + +// WithGeneration sets the Generation field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Generation field is set to the value of the last call. +func (b *SubscriptionApplyConfiguration) WithGeneration(value int64) *SubscriptionApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.Generation = &value + return b +} + +// WithCreationTimestamp sets the CreationTimestamp field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the CreationTimestamp field is set to the value of the last call. +func (b *SubscriptionApplyConfiguration) WithCreationTimestamp(value metav1.Time) *SubscriptionApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.CreationTimestamp = &value + return b +} + +// WithDeletionTimestamp sets the DeletionTimestamp field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the DeletionTimestamp field is set to the value of the last call. +func (b *SubscriptionApplyConfiguration) WithDeletionTimestamp(value metav1.Time) *SubscriptionApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.DeletionTimestamp = &value + return b +} + +// WithDeletionGracePeriodSeconds sets the DeletionGracePeriodSeconds field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the DeletionGracePeriodSeconds field is set to the value of the last call. +func (b *SubscriptionApplyConfiguration) WithDeletionGracePeriodSeconds(value int64) *SubscriptionApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.DeletionGracePeriodSeconds = &value + return b +} + +// WithLabels puts the entries into the Labels field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, the entries provided by each call will be put on the Labels field, +// overwriting an existing map entries in Labels field with the same key. +func (b *SubscriptionApplyConfiguration) WithLabels(entries map[string]string) *SubscriptionApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + if b.ObjectMetaApplyConfiguration.Labels == nil && len(entries) > 0 { + b.ObjectMetaApplyConfiguration.Labels = make(map[string]string, len(entries)) + } + for k, v := range entries { + b.ObjectMetaApplyConfiguration.Labels[k] = v + } + return b +} + +// WithAnnotations puts the entries into the Annotations field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, the entries provided by each call will be put on the Annotations field, +// overwriting an existing map entries in Annotations field with the same key. +func (b *SubscriptionApplyConfiguration) WithAnnotations(entries map[string]string) *SubscriptionApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + if b.ObjectMetaApplyConfiguration.Annotations == nil && len(entries) > 0 { + b.ObjectMetaApplyConfiguration.Annotations = make(map[string]string, len(entries)) + } + for k, v := range entries { + b.ObjectMetaApplyConfiguration.Annotations[k] = v + } + return b +} + +// WithOwnerReferences adds the given value to the OwnerReferences field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, values provided by each call will be appended to the OwnerReferences field. +func (b *SubscriptionApplyConfiguration) WithOwnerReferences(values ...*v1.OwnerReferenceApplyConfiguration) *SubscriptionApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + for i := range values { + if values[i] == nil { + panic("nil value passed to WithOwnerReferences") + } + b.ObjectMetaApplyConfiguration.OwnerReferences = append(b.ObjectMetaApplyConfiguration.OwnerReferences, *values[i]) + } + return b +} + +// WithFinalizers adds the given value to the Finalizers field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, values provided by each call will be appended to the Finalizers field. +func (b *SubscriptionApplyConfiguration) WithFinalizers(values ...string) *SubscriptionApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + for i := range values { + b.ObjectMetaApplyConfiguration.Finalizers = append(b.ObjectMetaApplyConfiguration.Finalizers, values[i]) + } + return b +} + +func (b *SubscriptionApplyConfiguration) ensureObjectMetaApplyConfigurationExists() { + if b.ObjectMetaApplyConfiguration == nil { + b.ObjectMetaApplyConfiguration = &v1.ObjectMetaApplyConfiguration{} + } +} + +// WithSpec sets the Spec field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Spec field is set to the value of the last call. +func (b *SubscriptionApplyConfiguration) WithSpec(value *SubscriptionSpecApplyConfiguration) *SubscriptionApplyConfiguration { + b.Spec = value + return b +} + +// WithStatus sets the Status field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Status field is set to the value of the last call. +func (b *SubscriptionApplyConfiguration) WithStatus(value *SubscriptionStatusApplyConfiguration) *SubscriptionApplyConfiguration { + b.Status = value + return b +} + +// GetKind retrieves the value of the Kind field in the declarative configuration. +func (b *SubscriptionApplyConfiguration) GetKind() *string { + return b.TypeMetaApplyConfiguration.Kind +} + +// GetAPIVersion retrieves the value of the APIVersion field in the declarative configuration. +func (b *SubscriptionApplyConfiguration) GetAPIVersion() *string { + return b.TypeMetaApplyConfiguration.APIVersion +} + +// GetName retrieves the value of the Name field in the declarative configuration. +func (b *SubscriptionApplyConfiguration) GetName() *string { + b.ensureObjectMetaApplyConfigurationExists() + return b.ObjectMetaApplyConfiguration.Name +} + +// GetNamespace retrieves the value of the Namespace field in the declarative configuration. +func (b *SubscriptionApplyConfiguration) GetNamespace() *string { + b.ensureObjectMetaApplyConfigurationExists() + return b.ObjectMetaApplyConfiguration.Namespace +} diff --git a/pkg/generated/applyconfiguration/inv/v1alpha1/subscriptionparameters.go b/pkg/generated/applyconfiguration/inv/v1alpha1/subscriptionparameters.go new file mode 100644 index 00000000..f4083758 --- /dev/null +++ b/pkg/generated/applyconfiguration/inv/v1alpha1/subscriptionparameters.go @@ -0,0 +1,111 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ +// Code generated by applyconfiguration-gen. DO NOT EDIT. + +package v1alpha1 + +import ( + invv1alpha1 "github.com/sdcio/config-server/apis/inv/v1alpha1" + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" +) + +// SubscriptionParametersApplyConfiguration represents a declarative configuration of the SubscriptionParameters type for use +// with apply. +// +// SubscriptionSync defines the desired Subscription of SubscriptionSync +type SubscriptionParametersApplyConfiguration struct { + // Name defines the name of the group of the Subscription to be collected + Name *string `json:"name,omitempty"` + // Description details what the Subscription collection is about + Description *string `json:"description,omitempty"` + // Labels can be defined as user defined data to provide extra context + Labels map[string]string `json:"labels,omitempty"` + // AdminState allows to disable the subscription + AdminState *invv1alpha1.AdminState `json:"adminState,omitempty"` + Mode *invv1alpha1.SyncMode `json:"mode,omitempty"` + Interval *v1.Duration `json:"interval,omitempty"` + Paths []string `json:"paths,omitempty"` +} + +// SubscriptionParametersApplyConfiguration constructs a declarative configuration of the SubscriptionParameters type for use with +// apply. +func SubscriptionParameters() *SubscriptionParametersApplyConfiguration { + return &SubscriptionParametersApplyConfiguration{} +} + +// WithName sets the Name field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Name field is set to the value of the last call. +func (b *SubscriptionParametersApplyConfiguration) WithName(value string) *SubscriptionParametersApplyConfiguration { + b.Name = &value + return b +} + +// WithDescription sets the Description field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Description field is set to the value of the last call. +func (b *SubscriptionParametersApplyConfiguration) WithDescription(value string) *SubscriptionParametersApplyConfiguration { + b.Description = &value + return b +} + +// WithLabels puts the entries into the Labels field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, the entries provided by each call will be put on the Labels field, +// overwriting an existing map entries in Labels field with the same key. +func (b *SubscriptionParametersApplyConfiguration) WithLabels(entries map[string]string) *SubscriptionParametersApplyConfiguration { + if b.Labels == nil && len(entries) > 0 { + b.Labels = make(map[string]string, len(entries)) + } + for k, v := range entries { + b.Labels[k] = v + } + return b +} + +// WithAdminState sets the AdminState field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the AdminState field is set to the value of the last call. +func (b *SubscriptionParametersApplyConfiguration) WithAdminState(value invv1alpha1.AdminState) *SubscriptionParametersApplyConfiguration { + b.AdminState = &value + return b +} + +// WithMode sets the Mode field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Mode field is set to the value of the last call. +func (b *SubscriptionParametersApplyConfiguration) WithMode(value invv1alpha1.SyncMode) *SubscriptionParametersApplyConfiguration { + b.Mode = &value + return b +} + +// WithInterval sets the Interval field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Interval field is set to the value of the last call. +func (b *SubscriptionParametersApplyConfiguration) WithInterval(value v1.Duration) *SubscriptionParametersApplyConfiguration { + b.Interval = &value + return b +} + +// WithPaths adds the given value to the Paths field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, values provided by each call will be appended to the Paths field. +func (b *SubscriptionParametersApplyConfiguration) WithPaths(values ...string) *SubscriptionParametersApplyConfiguration { + for i := range values { + b.Paths = append(b.Paths, values[i]) + } + return b +} diff --git a/pkg/generated/applyconfiguration/inv/v1alpha1/subscriptionspec.go b/pkg/generated/applyconfiguration/inv/v1alpha1/subscriptionspec.go new file mode 100644 index 00000000..d8226f52 --- /dev/null +++ b/pkg/generated/applyconfiguration/inv/v1alpha1/subscriptionspec.go @@ -0,0 +1,87 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ +// Code generated by applyconfiguration-gen. DO NOT EDIT. + +package v1alpha1 + +import ( + invv1alpha1 "github.com/sdcio/config-server/apis/inv/v1alpha1" +) + +// SubscriptionSpecApplyConfiguration represents a declarative configuration of the SubscriptionSpec type for use +// with apply. +// +// SubscriptionSpec defines the desired Subscription of Subscription +type SubscriptionSpecApplyConfiguration struct { + // Targets defines the targets on which this Subscription applies + Target *SubscriptionTargetApplyConfiguration `json:"target,omitempty"` + Protocol *invv1alpha1.Protocol `json:"protocol,omitempty"` + // Port defines the port on which the scan runs + Port *uint32 `json:"port,omitempty"` + Encoding *invv1alpha1.Encoding `json:"encoding,omitempty"` + Subscriptions []SubscriptionParametersApplyConfiguration `json:"subscriptions,omitempty"` +} + +// SubscriptionSpecApplyConfiguration constructs a declarative configuration of the SubscriptionSpec type for use with +// apply. +func SubscriptionSpec() *SubscriptionSpecApplyConfiguration { + return &SubscriptionSpecApplyConfiguration{} +} + +// WithTarget sets the Target field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Target field is set to the value of the last call. +func (b *SubscriptionSpecApplyConfiguration) WithTarget(value *SubscriptionTargetApplyConfiguration) *SubscriptionSpecApplyConfiguration { + b.Target = value + return b +} + +// WithProtocol sets the Protocol field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Protocol field is set to the value of the last call. +func (b *SubscriptionSpecApplyConfiguration) WithProtocol(value invv1alpha1.Protocol) *SubscriptionSpecApplyConfiguration { + b.Protocol = &value + return b +} + +// WithPort sets the Port field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Port field is set to the value of the last call. +func (b *SubscriptionSpecApplyConfiguration) WithPort(value uint32) *SubscriptionSpecApplyConfiguration { + b.Port = &value + return b +} + +// WithEncoding sets the Encoding field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Encoding field is set to the value of the last call. +func (b *SubscriptionSpecApplyConfiguration) WithEncoding(value invv1alpha1.Encoding) *SubscriptionSpecApplyConfiguration { + b.Encoding = &value + return b +} + +// WithSubscriptions adds the given value to the Subscriptions field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, values provided by each call will be appended to the Subscriptions field. +func (b *SubscriptionSpecApplyConfiguration) WithSubscriptions(values ...*SubscriptionParametersApplyConfiguration) *SubscriptionSpecApplyConfiguration { + for i := range values { + if values[i] == nil { + panic("nil value passed to WithSubscriptions") + } + b.Subscriptions = append(b.Subscriptions, *values[i]) + } + return b +} diff --git a/pkg/generated/applyconfiguration/inv/v1alpha1/subscriptionstatus.go b/pkg/generated/applyconfiguration/inv/v1alpha1/subscriptionstatus.go new file mode 100644 index 00000000..420fad14 --- /dev/null +++ b/pkg/generated/applyconfiguration/inv/v1alpha1/subscriptionstatus.go @@ -0,0 +1,57 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ +// Code generated by applyconfiguration-gen. DO NOT EDIT. + +package v1alpha1 + +import ( + conditionv1alpha1 "github.com/sdcio/config-server/apis/condition/v1alpha1" +) + +// SubscriptionStatusApplyConfiguration represents a declarative configuration of the SubscriptionStatus type for use +// with apply. +type SubscriptionStatusApplyConfiguration struct { + // ConditionedStatus provides the status of the Schema using conditions + conditionv1alpha1.ConditionedStatus `json:",inline"` + // Targets defines the list of targets this resource applies to + Targets []string `json:"targets,omitempty"` +} + +// SubscriptionStatusApplyConfiguration constructs a declarative configuration of the SubscriptionStatus type for use with +// apply. +func SubscriptionStatus() *SubscriptionStatusApplyConfiguration { + return &SubscriptionStatusApplyConfiguration{} +} + +// WithConditions adds the given value to the Conditions field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, values provided by each call will be appended to the Conditions field. +func (b *SubscriptionStatusApplyConfiguration) WithConditions(values ...conditionv1alpha1.Condition) *SubscriptionStatusApplyConfiguration { + for i := range values { + b.ConditionedStatus.Conditions = append(b.ConditionedStatus.Conditions, values[i]) + } + return b +} + +// WithTargets adds the given value to the Targets field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, values provided by each call will be appended to the Targets field. +func (b *SubscriptionStatusApplyConfiguration) WithTargets(values ...string) *SubscriptionStatusApplyConfiguration { + for i := range values { + b.Targets = append(b.Targets, values[i]) + } + return b +} diff --git a/pkg/generated/applyconfiguration/inv/v1alpha1/subscriptiontarget.go b/pkg/generated/applyconfiguration/inv/v1alpha1/subscriptiontarget.go new file mode 100644 index 00000000..203eeeb7 --- /dev/null +++ b/pkg/generated/applyconfiguration/inv/v1alpha1/subscriptiontarget.go @@ -0,0 +1,43 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ +// Code generated by applyconfiguration-gen. DO NOT EDIT. + +package v1alpha1 + +import ( + v1 "k8s.io/client-go/applyconfigurations/meta/v1" +) + +// SubscriptionTargetApplyConfiguration represents a declarative configuration of the SubscriptionTarget type for use +// with apply. +type SubscriptionTargetApplyConfiguration struct { + // TargetSelector defines the selector used to select the targets to which the config applies + TargetSelector *v1.LabelSelectorApplyConfiguration `json:"targetSelector,omitempty"` +} + +// SubscriptionTargetApplyConfiguration constructs a declarative configuration of the SubscriptionTarget type for use with +// apply. +func SubscriptionTarget() *SubscriptionTargetApplyConfiguration { + return &SubscriptionTargetApplyConfiguration{} +} + +// WithTargetSelector sets the TargetSelector field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the TargetSelector field is set to the value of the last call. +func (b *SubscriptionTargetApplyConfiguration) WithTargetSelector(value *v1.LabelSelectorApplyConfiguration) *SubscriptionTargetApplyConfiguration { + b.TargetSelector = value + return b +} diff --git a/pkg/generated/applyconfiguration/inv/v1alpha1/target.go b/pkg/generated/applyconfiguration/inv/v1alpha1/target.go new file mode 100644 index 00000000..fe4c9b0a --- /dev/null +++ b/pkg/generated/applyconfiguration/inv/v1alpha1/target.go @@ -0,0 +1,244 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ +// Code generated by applyconfiguration-gen. DO NOT EDIT. + +package v1alpha1 + +import ( + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + types "k8s.io/apimachinery/pkg/types" + v1 "k8s.io/client-go/applyconfigurations/meta/v1" +) + +// TargetApplyConfiguration represents a declarative configuration of the Target type for use +// with apply. +// +// Target is the Schema for the Target API +type TargetApplyConfiguration struct { + v1.TypeMetaApplyConfiguration `json:",inline"` + *v1.ObjectMetaApplyConfiguration `json:"metadata,omitempty"` + Spec *TargetSpecApplyConfiguration `json:"spec,omitempty"` + Status *TargetStatusApplyConfiguration `json:"status,omitempty"` +} + +// Target constructs a declarative configuration of the Target type for use with +// apply. +func Target(name, namespace string) *TargetApplyConfiguration { + b := &TargetApplyConfiguration{} + b.WithName(name) + b.WithNamespace(namespace) + b.WithKind("Target") + b.WithAPIVersion("inv.sdcio.dev/v1alpha1") + return b +} + +func (b TargetApplyConfiguration) IsApplyConfiguration() {} + +// WithKind sets the Kind field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Kind field is set to the value of the last call. +func (b *TargetApplyConfiguration) WithKind(value string) *TargetApplyConfiguration { + b.TypeMetaApplyConfiguration.Kind = &value + return b +} + +// WithAPIVersion sets the APIVersion field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the APIVersion field is set to the value of the last call. +func (b *TargetApplyConfiguration) WithAPIVersion(value string) *TargetApplyConfiguration { + b.TypeMetaApplyConfiguration.APIVersion = &value + return b +} + +// WithName sets the Name field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Name field is set to the value of the last call. +func (b *TargetApplyConfiguration) WithName(value string) *TargetApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.Name = &value + return b +} + +// WithGenerateName sets the GenerateName field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the GenerateName field is set to the value of the last call. +func (b *TargetApplyConfiguration) WithGenerateName(value string) *TargetApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.GenerateName = &value + return b +} + +// WithNamespace sets the Namespace field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Namespace field is set to the value of the last call. +func (b *TargetApplyConfiguration) WithNamespace(value string) *TargetApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.Namespace = &value + return b +} + +// WithUID sets the UID field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the UID field is set to the value of the last call. +func (b *TargetApplyConfiguration) WithUID(value types.UID) *TargetApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.UID = &value + return b +} + +// WithResourceVersion sets the ResourceVersion field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the ResourceVersion field is set to the value of the last call. +func (b *TargetApplyConfiguration) WithResourceVersion(value string) *TargetApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.ResourceVersion = &value + return b +} + +// WithGeneration sets the Generation field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Generation field is set to the value of the last call. +func (b *TargetApplyConfiguration) WithGeneration(value int64) *TargetApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.Generation = &value + return b +} + +// WithCreationTimestamp sets the CreationTimestamp field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the CreationTimestamp field is set to the value of the last call. +func (b *TargetApplyConfiguration) WithCreationTimestamp(value metav1.Time) *TargetApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.CreationTimestamp = &value + return b +} + +// WithDeletionTimestamp sets the DeletionTimestamp field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the DeletionTimestamp field is set to the value of the last call. +func (b *TargetApplyConfiguration) WithDeletionTimestamp(value metav1.Time) *TargetApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.DeletionTimestamp = &value + return b +} + +// WithDeletionGracePeriodSeconds sets the DeletionGracePeriodSeconds field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the DeletionGracePeriodSeconds field is set to the value of the last call. +func (b *TargetApplyConfiguration) WithDeletionGracePeriodSeconds(value int64) *TargetApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.DeletionGracePeriodSeconds = &value + return b +} + +// WithLabels puts the entries into the Labels field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, the entries provided by each call will be put on the Labels field, +// overwriting an existing map entries in Labels field with the same key. +func (b *TargetApplyConfiguration) WithLabels(entries map[string]string) *TargetApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + if b.ObjectMetaApplyConfiguration.Labels == nil && len(entries) > 0 { + b.ObjectMetaApplyConfiguration.Labels = make(map[string]string, len(entries)) + } + for k, v := range entries { + b.ObjectMetaApplyConfiguration.Labels[k] = v + } + return b +} + +// WithAnnotations puts the entries into the Annotations field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, the entries provided by each call will be put on the Annotations field, +// overwriting an existing map entries in Annotations field with the same key. +func (b *TargetApplyConfiguration) WithAnnotations(entries map[string]string) *TargetApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + if b.ObjectMetaApplyConfiguration.Annotations == nil && len(entries) > 0 { + b.ObjectMetaApplyConfiguration.Annotations = make(map[string]string, len(entries)) + } + for k, v := range entries { + b.ObjectMetaApplyConfiguration.Annotations[k] = v + } + return b +} + +// WithOwnerReferences adds the given value to the OwnerReferences field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, values provided by each call will be appended to the OwnerReferences field. +func (b *TargetApplyConfiguration) WithOwnerReferences(values ...*v1.OwnerReferenceApplyConfiguration) *TargetApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + for i := range values { + if values[i] == nil { + panic("nil value passed to WithOwnerReferences") + } + b.ObjectMetaApplyConfiguration.OwnerReferences = append(b.ObjectMetaApplyConfiguration.OwnerReferences, *values[i]) + } + return b +} + +// WithFinalizers adds the given value to the Finalizers field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, values provided by each call will be appended to the Finalizers field. +func (b *TargetApplyConfiguration) WithFinalizers(values ...string) *TargetApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + for i := range values { + b.ObjectMetaApplyConfiguration.Finalizers = append(b.ObjectMetaApplyConfiguration.Finalizers, values[i]) + } + return b +} + +func (b *TargetApplyConfiguration) ensureObjectMetaApplyConfigurationExists() { + if b.ObjectMetaApplyConfiguration == nil { + b.ObjectMetaApplyConfiguration = &v1.ObjectMetaApplyConfiguration{} + } +} + +// WithSpec sets the Spec field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Spec field is set to the value of the last call. +func (b *TargetApplyConfiguration) WithSpec(value *TargetSpecApplyConfiguration) *TargetApplyConfiguration { + b.Spec = value + return b +} + +// WithStatus sets the Status field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Status field is set to the value of the last call. +func (b *TargetApplyConfiguration) WithStatus(value *TargetStatusApplyConfiguration) *TargetApplyConfiguration { + b.Status = value + return b +} + +// GetKind retrieves the value of the Kind field in the declarative configuration. +func (b *TargetApplyConfiguration) GetKind() *string { + return b.TypeMetaApplyConfiguration.Kind +} + +// GetAPIVersion retrieves the value of the APIVersion field in the declarative configuration. +func (b *TargetApplyConfiguration) GetAPIVersion() *string { + return b.TypeMetaApplyConfiguration.APIVersion +} + +// GetName retrieves the value of the Name field in the declarative configuration. +func (b *TargetApplyConfiguration) GetName() *string { + b.ensureObjectMetaApplyConfigurationExists() + return b.ObjectMetaApplyConfiguration.Name +} + +// GetNamespace retrieves the value of the Namespace field in the declarative configuration. +func (b *TargetApplyConfiguration) GetNamespace() *string { + b.ensureObjectMetaApplyConfigurationExists() + return b.ObjectMetaApplyConfiguration.Namespace +} diff --git a/pkg/generated/applyconfiguration/inv/v1alpha1/targetconnectionprofile.go b/pkg/generated/applyconfiguration/inv/v1alpha1/targetconnectionprofile.go new file mode 100644 index 00000000..12526701 --- /dev/null +++ b/pkg/generated/applyconfiguration/inv/v1alpha1/targetconnectionprofile.go @@ -0,0 +1,235 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ +// Code generated by applyconfiguration-gen. DO NOT EDIT. + +package v1alpha1 + +import ( + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + types "k8s.io/apimachinery/pkg/types" + v1 "k8s.io/client-go/applyconfigurations/meta/v1" +) + +// TargetConnectionProfileApplyConfiguration represents a declarative configuration of the TargetConnectionProfile type for use +// with apply. +// +// TargetConnectionProfile is the Schema for the TargetConnectionProfile API +type TargetConnectionProfileApplyConfiguration struct { + v1.TypeMetaApplyConfiguration `json:",inline"` + *v1.ObjectMetaApplyConfiguration `json:"metadata,omitempty"` + Spec *TargetConnectionProfileSpecApplyConfiguration `json:"spec,omitempty"` +} + +// TargetConnectionProfile constructs a declarative configuration of the TargetConnectionProfile type for use with +// apply. +func TargetConnectionProfile(name, namespace string) *TargetConnectionProfileApplyConfiguration { + b := &TargetConnectionProfileApplyConfiguration{} + b.WithName(name) + b.WithNamespace(namespace) + b.WithKind("TargetConnectionProfile") + b.WithAPIVersion("inv.sdcio.dev/v1alpha1") + return b +} + +func (b TargetConnectionProfileApplyConfiguration) IsApplyConfiguration() {} + +// WithKind sets the Kind field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Kind field is set to the value of the last call. +func (b *TargetConnectionProfileApplyConfiguration) WithKind(value string) *TargetConnectionProfileApplyConfiguration { + b.TypeMetaApplyConfiguration.Kind = &value + return b +} + +// WithAPIVersion sets the APIVersion field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the APIVersion field is set to the value of the last call. +func (b *TargetConnectionProfileApplyConfiguration) WithAPIVersion(value string) *TargetConnectionProfileApplyConfiguration { + b.TypeMetaApplyConfiguration.APIVersion = &value + return b +} + +// WithName sets the Name field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Name field is set to the value of the last call. +func (b *TargetConnectionProfileApplyConfiguration) WithName(value string) *TargetConnectionProfileApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.Name = &value + return b +} + +// WithGenerateName sets the GenerateName field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the GenerateName field is set to the value of the last call. +func (b *TargetConnectionProfileApplyConfiguration) WithGenerateName(value string) *TargetConnectionProfileApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.GenerateName = &value + return b +} + +// WithNamespace sets the Namespace field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Namespace field is set to the value of the last call. +func (b *TargetConnectionProfileApplyConfiguration) WithNamespace(value string) *TargetConnectionProfileApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.Namespace = &value + return b +} + +// WithUID sets the UID field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the UID field is set to the value of the last call. +func (b *TargetConnectionProfileApplyConfiguration) WithUID(value types.UID) *TargetConnectionProfileApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.UID = &value + return b +} + +// WithResourceVersion sets the ResourceVersion field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the ResourceVersion field is set to the value of the last call. +func (b *TargetConnectionProfileApplyConfiguration) WithResourceVersion(value string) *TargetConnectionProfileApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.ResourceVersion = &value + return b +} + +// WithGeneration sets the Generation field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Generation field is set to the value of the last call. +func (b *TargetConnectionProfileApplyConfiguration) WithGeneration(value int64) *TargetConnectionProfileApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.Generation = &value + return b +} + +// WithCreationTimestamp sets the CreationTimestamp field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the CreationTimestamp field is set to the value of the last call. +func (b *TargetConnectionProfileApplyConfiguration) WithCreationTimestamp(value metav1.Time) *TargetConnectionProfileApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.CreationTimestamp = &value + return b +} + +// WithDeletionTimestamp sets the DeletionTimestamp field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the DeletionTimestamp field is set to the value of the last call. +func (b *TargetConnectionProfileApplyConfiguration) WithDeletionTimestamp(value metav1.Time) *TargetConnectionProfileApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.DeletionTimestamp = &value + return b +} + +// WithDeletionGracePeriodSeconds sets the DeletionGracePeriodSeconds field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the DeletionGracePeriodSeconds field is set to the value of the last call. +func (b *TargetConnectionProfileApplyConfiguration) WithDeletionGracePeriodSeconds(value int64) *TargetConnectionProfileApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.DeletionGracePeriodSeconds = &value + return b +} + +// WithLabels puts the entries into the Labels field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, the entries provided by each call will be put on the Labels field, +// overwriting an existing map entries in Labels field with the same key. +func (b *TargetConnectionProfileApplyConfiguration) WithLabels(entries map[string]string) *TargetConnectionProfileApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + if b.ObjectMetaApplyConfiguration.Labels == nil && len(entries) > 0 { + b.ObjectMetaApplyConfiguration.Labels = make(map[string]string, len(entries)) + } + for k, v := range entries { + b.ObjectMetaApplyConfiguration.Labels[k] = v + } + return b +} + +// WithAnnotations puts the entries into the Annotations field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, the entries provided by each call will be put on the Annotations field, +// overwriting an existing map entries in Annotations field with the same key. +func (b *TargetConnectionProfileApplyConfiguration) WithAnnotations(entries map[string]string) *TargetConnectionProfileApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + if b.ObjectMetaApplyConfiguration.Annotations == nil && len(entries) > 0 { + b.ObjectMetaApplyConfiguration.Annotations = make(map[string]string, len(entries)) + } + for k, v := range entries { + b.ObjectMetaApplyConfiguration.Annotations[k] = v + } + return b +} + +// WithOwnerReferences adds the given value to the OwnerReferences field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, values provided by each call will be appended to the OwnerReferences field. +func (b *TargetConnectionProfileApplyConfiguration) WithOwnerReferences(values ...*v1.OwnerReferenceApplyConfiguration) *TargetConnectionProfileApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + for i := range values { + if values[i] == nil { + panic("nil value passed to WithOwnerReferences") + } + b.ObjectMetaApplyConfiguration.OwnerReferences = append(b.ObjectMetaApplyConfiguration.OwnerReferences, *values[i]) + } + return b +} + +// WithFinalizers adds the given value to the Finalizers field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, values provided by each call will be appended to the Finalizers field. +func (b *TargetConnectionProfileApplyConfiguration) WithFinalizers(values ...string) *TargetConnectionProfileApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + for i := range values { + b.ObjectMetaApplyConfiguration.Finalizers = append(b.ObjectMetaApplyConfiguration.Finalizers, values[i]) + } + return b +} + +func (b *TargetConnectionProfileApplyConfiguration) ensureObjectMetaApplyConfigurationExists() { + if b.ObjectMetaApplyConfiguration == nil { + b.ObjectMetaApplyConfiguration = &v1.ObjectMetaApplyConfiguration{} + } +} + +// WithSpec sets the Spec field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Spec field is set to the value of the last call. +func (b *TargetConnectionProfileApplyConfiguration) WithSpec(value *TargetConnectionProfileSpecApplyConfiguration) *TargetConnectionProfileApplyConfiguration { + b.Spec = value + return b +} + +// GetKind retrieves the value of the Kind field in the declarative configuration. +func (b *TargetConnectionProfileApplyConfiguration) GetKind() *string { + return b.TypeMetaApplyConfiguration.Kind +} + +// GetAPIVersion retrieves the value of the APIVersion field in the declarative configuration. +func (b *TargetConnectionProfileApplyConfiguration) GetAPIVersion() *string { + return b.TypeMetaApplyConfiguration.APIVersion +} + +// GetName retrieves the value of the Name field in the declarative configuration. +func (b *TargetConnectionProfileApplyConfiguration) GetName() *string { + b.ensureObjectMetaApplyConfigurationExists() + return b.ObjectMetaApplyConfiguration.Name +} + +// GetNamespace retrieves the value of the Namespace field in the declarative configuration. +func (b *TargetConnectionProfileApplyConfiguration) GetNamespace() *string { + b.ensureObjectMetaApplyConfigurationExists() + return b.ObjectMetaApplyConfiguration.Namespace +} diff --git a/pkg/generated/applyconfiguration/inv/v1alpha1/targetconnectionprofilespec.go b/pkg/generated/applyconfiguration/inv/v1alpha1/targetconnectionprofilespec.go new file mode 100644 index 00000000..f8a42e15 --- /dev/null +++ b/pkg/generated/applyconfiguration/inv/v1alpha1/targetconnectionprofilespec.go @@ -0,0 +1,156 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ +// Code generated by applyconfiguration-gen. DO NOT EDIT. + +package v1alpha1 + +import ( + invv1alpha1 "github.com/sdcio/config-server/apis/inv/v1alpha1" + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" +) + +// TargetConnectionProfileSpecApplyConfiguration represents a declarative configuration of the TargetConnectionProfileSpec type for use +// with apply. +// +// TargetConnectionProfileSpec defines the desired state of TargetConnectionProfile +type TargetConnectionProfileSpecApplyConfiguration struct { + ConnectRetry *v1.Duration `json:"connectRetry,omitempty"` + Timeout *v1.Duration `json:"timeout,omitempty"` + Protocol *invv1alpha1.Protocol `json:"protocol,omitempty"` + // Port defines the port on which the scan runs + Port *uint32 `json:"port,omitempty"` + Encoding *invv1alpha1.Encoding `json:"encoding,omitempty"` + PreferredNetconfVersion *string `json:"preferredNetconfVersion,omitempty"` + Insecure *bool `json:"insecure,omitempty"` + SkipVerify *bool `json:"skipVerify,omitempty"` + IncludeNS *bool `json:"includeNS,omitempty"` + OperationWithNS *bool `json:"operationWithNS,omitempty"` + UseOperationRemove *bool `json:"useOperationRemove,omitempty"` + CommitCandidate *invv1alpha1.CommitCandidate `json:"commitCandidate,omitempty"` + // TargetName specifies the target field value in gNMI Path prefix + // Examples: "OC-YANG" (SONiC), "openconfig" (some vendors), or empty + TargetName *string `json:"targetName,omitempty"` +} + +// TargetConnectionProfileSpecApplyConfiguration constructs a declarative configuration of the TargetConnectionProfileSpec type for use with +// apply. +func TargetConnectionProfileSpec() *TargetConnectionProfileSpecApplyConfiguration { + return &TargetConnectionProfileSpecApplyConfiguration{} +} + +// WithConnectRetry sets the ConnectRetry field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the ConnectRetry field is set to the value of the last call. +func (b *TargetConnectionProfileSpecApplyConfiguration) WithConnectRetry(value v1.Duration) *TargetConnectionProfileSpecApplyConfiguration { + b.ConnectRetry = &value + return b +} + +// WithTimeout sets the Timeout field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Timeout field is set to the value of the last call. +func (b *TargetConnectionProfileSpecApplyConfiguration) WithTimeout(value v1.Duration) *TargetConnectionProfileSpecApplyConfiguration { + b.Timeout = &value + return b +} + +// WithProtocol sets the Protocol field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Protocol field is set to the value of the last call. +func (b *TargetConnectionProfileSpecApplyConfiguration) WithProtocol(value invv1alpha1.Protocol) *TargetConnectionProfileSpecApplyConfiguration { + b.Protocol = &value + return b +} + +// WithPort sets the Port field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Port field is set to the value of the last call. +func (b *TargetConnectionProfileSpecApplyConfiguration) WithPort(value uint32) *TargetConnectionProfileSpecApplyConfiguration { + b.Port = &value + return b +} + +// WithEncoding sets the Encoding field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Encoding field is set to the value of the last call. +func (b *TargetConnectionProfileSpecApplyConfiguration) WithEncoding(value invv1alpha1.Encoding) *TargetConnectionProfileSpecApplyConfiguration { + b.Encoding = &value + return b +} + +// WithPreferredNetconfVersion sets the PreferredNetconfVersion field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the PreferredNetconfVersion field is set to the value of the last call. +func (b *TargetConnectionProfileSpecApplyConfiguration) WithPreferredNetconfVersion(value string) *TargetConnectionProfileSpecApplyConfiguration { + b.PreferredNetconfVersion = &value + return b +} + +// WithInsecure sets the Insecure field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Insecure field is set to the value of the last call. +func (b *TargetConnectionProfileSpecApplyConfiguration) WithInsecure(value bool) *TargetConnectionProfileSpecApplyConfiguration { + b.Insecure = &value + return b +} + +// WithSkipVerify sets the SkipVerify field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the SkipVerify field is set to the value of the last call. +func (b *TargetConnectionProfileSpecApplyConfiguration) WithSkipVerify(value bool) *TargetConnectionProfileSpecApplyConfiguration { + b.SkipVerify = &value + return b +} + +// WithIncludeNS sets the IncludeNS field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the IncludeNS field is set to the value of the last call. +func (b *TargetConnectionProfileSpecApplyConfiguration) WithIncludeNS(value bool) *TargetConnectionProfileSpecApplyConfiguration { + b.IncludeNS = &value + return b +} + +// WithOperationWithNS sets the OperationWithNS field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the OperationWithNS field is set to the value of the last call. +func (b *TargetConnectionProfileSpecApplyConfiguration) WithOperationWithNS(value bool) *TargetConnectionProfileSpecApplyConfiguration { + b.OperationWithNS = &value + return b +} + +// WithUseOperationRemove sets the UseOperationRemove field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the UseOperationRemove field is set to the value of the last call. +func (b *TargetConnectionProfileSpecApplyConfiguration) WithUseOperationRemove(value bool) *TargetConnectionProfileSpecApplyConfiguration { + b.UseOperationRemove = &value + return b +} + +// WithCommitCandidate sets the CommitCandidate field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the CommitCandidate field is set to the value of the last call. +func (b *TargetConnectionProfileSpecApplyConfiguration) WithCommitCandidate(value invv1alpha1.CommitCandidate) *TargetConnectionProfileSpecApplyConfiguration { + b.CommitCandidate = &value + return b +} + +// WithTargetName sets the TargetName field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the TargetName field is set to the value of the last call. +func (b *TargetConnectionProfileSpecApplyConfiguration) WithTargetName(value string) *TargetConnectionProfileSpecApplyConfiguration { + b.TargetName = &value + return b +} diff --git a/pkg/generated/applyconfiguration/inv/v1alpha1/targetprofile.go b/pkg/generated/applyconfiguration/inv/v1alpha1/targetprofile.go new file mode 100644 index 00000000..62c9f359 --- /dev/null +++ b/pkg/generated/applyconfiguration/inv/v1alpha1/targetprofile.go @@ -0,0 +1,69 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ +// Code generated by applyconfiguration-gen. DO NOT EDIT. + +package v1alpha1 + +// TargetProfileApplyConfiguration represents a declarative configuration of the TargetProfile type for use +// with apply. +type TargetProfileApplyConfiguration struct { + // Credentials defines the name of the secret that holds the credentials to connect to the target + Credentials *string `json:"credentials,omitempty"` + // TLSSecret defines the name of the TLS secret to connect to the target if mtls is used + TLSSecret *string `json:"tlsSecret,omitempty"` + // ConnectionProfile define the profile used to connect to the target once discovered + ConnectionProfile *string `json:"connectionProfile,omitempty"` + // SyncProfile define the profile used to sync to the target config once discovered + SyncProfile *string `json:"syncProfile,omitempty"` +} + +// TargetProfileApplyConfiguration constructs a declarative configuration of the TargetProfile type for use with +// apply. +func TargetProfile() *TargetProfileApplyConfiguration { + return &TargetProfileApplyConfiguration{} +} + +// WithCredentials sets the Credentials field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Credentials field is set to the value of the last call. +func (b *TargetProfileApplyConfiguration) WithCredentials(value string) *TargetProfileApplyConfiguration { + b.Credentials = &value + return b +} + +// WithTLSSecret sets the TLSSecret field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the TLSSecret field is set to the value of the last call. +func (b *TargetProfileApplyConfiguration) WithTLSSecret(value string) *TargetProfileApplyConfiguration { + b.TLSSecret = &value + return b +} + +// WithConnectionProfile sets the ConnectionProfile field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the ConnectionProfile field is set to the value of the last call. +func (b *TargetProfileApplyConfiguration) WithConnectionProfile(value string) *TargetProfileApplyConfiguration { + b.ConnectionProfile = &value + return b +} + +// WithSyncProfile sets the SyncProfile field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the SyncProfile field is set to the value of the last call. +func (b *TargetProfileApplyConfiguration) WithSyncProfile(value string) *TargetProfileApplyConfiguration { + b.SyncProfile = &value + return b +} diff --git a/pkg/generated/applyconfiguration/inv/v1alpha1/targetspec.go b/pkg/generated/applyconfiguration/inv/v1alpha1/targetspec.go new file mode 100644 index 00000000..f5d68aa7 --- /dev/null +++ b/pkg/generated/applyconfiguration/inv/v1alpha1/targetspec.go @@ -0,0 +1,85 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ +// Code generated by applyconfiguration-gen. DO NOT EDIT. + +package v1alpha1 + +// TargetSpecApplyConfiguration represents a declarative configuration of the TargetSpec type for use +// with apply. +// +// TargetSpec defines the desired state of Target +type TargetSpecApplyConfiguration struct { + // Provider specifies the provider using this target. + Provider *string `json:"provider,omitempty"` + // Address defines the address to connect to the target + Address *string `json:"address,omitempty"` + // TargetProfile defines the Credentials/TLSSecret and sync/connectivity profile to connect to the target + TargetProfileApplyConfiguration `json:",inline"` +} + +// TargetSpecApplyConfiguration constructs a declarative configuration of the TargetSpec type for use with +// apply. +func TargetSpec() *TargetSpecApplyConfiguration { + return &TargetSpecApplyConfiguration{} +} + +// WithProvider sets the Provider field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Provider field is set to the value of the last call. +func (b *TargetSpecApplyConfiguration) WithProvider(value string) *TargetSpecApplyConfiguration { + b.Provider = &value + return b +} + +// WithAddress sets the Address field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Address field is set to the value of the last call. +func (b *TargetSpecApplyConfiguration) WithAddress(value string) *TargetSpecApplyConfiguration { + b.Address = &value + return b +} + +// WithCredentials sets the Credentials field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Credentials field is set to the value of the last call. +func (b *TargetSpecApplyConfiguration) WithCredentials(value string) *TargetSpecApplyConfiguration { + b.TargetProfileApplyConfiguration.Credentials = &value + return b +} + +// WithTLSSecret sets the TLSSecret field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the TLSSecret field is set to the value of the last call. +func (b *TargetSpecApplyConfiguration) WithTLSSecret(value string) *TargetSpecApplyConfiguration { + b.TargetProfileApplyConfiguration.TLSSecret = &value + return b +} + +// WithConnectionProfile sets the ConnectionProfile field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the ConnectionProfile field is set to the value of the last call. +func (b *TargetSpecApplyConfiguration) WithConnectionProfile(value string) *TargetSpecApplyConfiguration { + b.TargetProfileApplyConfiguration.ConnectionProfile = &value + return b +} + +// WithSyncProfile sets the SyncProfile field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the SyncProfile field is set to the value of the last call. +func (b *TargetSpecApplyConfiguration) WithSyncProfile(value string) *TargetSpecApplyConfiguration { + b.TargetProfileApplyConfiguration.SyncProfile = &value + return b +} diff --git a/pkg/generated/applyconfiguration/inv/v1alpha1/targetstatus.go b/pkg/generated/applyconfiguration/inv/v1alpha1/targetstatus.go new file mode 100644 index 00000000..686f61df --- /dev/null +++ b/pkg/generated/applyconfiguration/inv/v1alpha1/targetstatus.go @@ -0,0 +1,67 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ +// Code generated by applyconfiguration-gen. DO NOT EDIT. + +package v1alpha1 + +import ( + conditionv1alpha1 "github.com/sdcio/config-server/apis/condition/v1alpha1" +) + +// TargetStatusApplyConfiguration represents a declarative configuration of the TargetStatus type for use +// with apply. +// +// TargetStatus defines the observed state of Target +type TargetStatusApplyConfiguration struct { + // ConditionedStatus provides the status of the Target using conditions + conditionv1alpha1.ConditionedStatus `json:",inline"` + // Discovery info defines the information retrieved during discovery + DiscoveryInfo *DiscoveryInfoApplyConfiguration `json:"discoveryInfo,omitempty"` + // UsedReferences track the resource used to reconcile the cr + UsedReferences *TargetStatusUsedReferencesApplyConfiguration `json:"usedReferences,omitempty"` +} + +// TargetStatusApplyConfiguration constructs a declarative configuration of the TargetStatus type for use with +// apply. +func TargetStatus() *TargetStatusApplyConfiguration { + return &TargetStatusApplyConfiguration{} +} + +// WithConditions adds the given value to the Conditions field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, values provided by each call will be appended to the Conditions field. +func (b *TargetStatusApplyConfiguration) WithConditions(values ...conditionv1alpha1.Condition) *TargetStatusApplyConfiguration { + for i := range values { + b.ConditionedStatus.Conditions = append(b.ConditionedStatus.Conditions, values[i]) + } + return b +} + +// WithDiscoveryInfo sets the DiscoveryInfo field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the DiscoveryInfo field is set to the value of the last call. +func (b *TargetStatusApplyConfiguration) WithDiscoveryInfo(value *DiscoveryInfoApplyConfiguration) *TargetStatusApplyConfiguration { + b.DiscoveryInfo = value + return b +} + +// WithUsedReferences sets the UsedReferences field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the UsedReferences field is set to the value of the last call. +func (b *TargetStatusApplyConfiguration) WithUsedReferences(value *TargetStatusUsedReferencesApplyConfiguration) *TargetStatusApplyConfiguration { + b.UsedReferences = value + return b +} diff --git a/pkg/generated/applyconfiguration/inv/v1alpha1/targetstatususedreferences.go b/pkg/generated/applyconfiguration/inv/v1alpha1/targetstatususedreferences.go new file mode 100644 index 00000000..958a4625 --- /dev/null +++ b/pkg/generated/applyconfiguration/inv/v1alpha1/targetstatususedreferences.go @@ -0,0 +1,65 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ +// Code generated by applyconfiguration-gen. DO NOT EDIT. + +package v1alpha1 + +// TargetStatusUsedReferencesApplyConfiguration represents a declarative configuration of the TargetStatusUsedReferences type for use +// with apply. +type TargetStatusUsedReferencesApplyConfiguration struct { + SecretResourceVersion *string `json:"secretResourceVersion,omitempty"` + TLSSecretResourceVersion *string `json:"tlsSecretResourceVersion,omitempty"` + ConnectionProfileResourceVersion *string `json:"connectionProfileResourceVersion,omitempty"` + SyncProfileResourceVersion *string `json:"syncProfileResourceVersion,omitempty"` +} + +// TargetStatusUsedReferencesApplyConfiguration constructs a declarative configuration of the TargetStatusUsedReferences type for use with +// apply. +func TargetStatusUsedReferences() *TargetStatusUsedReferencesApplyConfiguration { + return &TargetStatusUsedReferencesApplyConfiguration{} +} + +// WithSecretResourceVersion sets the SecretResourceVersion field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the SecretResourceVersion field is set to the value of the last call. +func (b *TargetStatusUsedReferencesApplyConfiguration) WithSecretResourceVersion(value string) *TargetStatusUsedReferencesApplyConfiguration { + b.SecretResourceVersion = &value + return b +} + +// WithTLSSecretResourceVersion sets the TLSSecretResourceVersion field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the TLSSecretResourceVersion field is set to the value of the last call. +func (b *TargetStatusUsedReferencesApplyConfiguration) WithTLSSecretResourceVersion(value string) *TargetStatusUsedReferencesApplyConfiguration { + b.TLSSecretResourceVersion = &value + return b +} + +// WithConnectionProfileResourceVersion sets the ConnectionProfileResourceVersion field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the ConnectionProfileResourceVersion field is set to the value of the last call. +func (b *TargetStatusUsedReferencesApplyConfiguration) WithConnectionProfileResourceVersion(value string) *TargetStatusUsedReferencesApplyConfiguration { + b.ConnectionProfileResourceVersion = &value + return b +} + +// WithSyncProfileResourceVersion sets the SyncProfileResourceVersion field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the SyncProfileResourceVersion field is set to the value of the last call. +func (b *TargetStatusUsedReferencesApplyConfiguration) WithSyncProfileResourceVersion(value string) *TargetStatusUsedReferencesApplyConfiguration { + b.SyncProfileResourceVersion = &value + return b +} diff --git a/pkg/generated/applyconfiguration/inv/v1alpha1/targetsyncprofile.go b/pkg/generated/applyconfiguration/inv/v1alpha1/targetsyncprofile.go new file mode 100644 index 00000000..1d3c47f3 --- /dev/null +++ b/pkg/generated/applyconfiguration/inv/v1alpha1/targetsyncprofile.go @@ -0,0 +1,235 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ +// Code generated by applyconfiguration-gen. DO NOT EDIT. + +package v1alpha1 + +import ( + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + types "k8s.io/apimachinery/pkg/types" + v1 "k8s.io/client-go/applyconfigurations/meta/v1" +) + +// TargetSyncProfileApplyConfiguration represents a declarative configuration of the TargetSyncProfile type for use +// with apply. +// +// TargetSyncProfile is the Schema for the TargetSyncProfile API +type TargetSyncProfileApplyConfiguration struct { + v1.TypeMetaApplyConfiguration `json:",inline"` + *v1.ObjectMetaApplyConfiguration `json:"metadata,omitempty"` + Spec *TargetSyncProfileSpecApplyConfiguration `json:"spec,omitempty"` +} + +// TargetSyncProfile constructs a declarative configuration of the TargetSyncProfile type for use with +// apply. +func TargetSyncProfile(name, namespace string) *TargetSyncProfileApplyConfiguration { + b := &TargetSyncProfileApplyConfiguration{} + b.WithName(name) + b.WithNamespace(namespace) + b.WithKind("TargetSyncProfile") + b.WithAPIVersion("inv.sdcio.dev/v1alpha1") + return b +} + +func (b TargetSyncProfileApplyConfiguration) IsApplyConfiguration() {} + +// WithKind sets the Kind field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Kind field is set to the value of the last call. +func (b *TargetSyncProfileApplyConfiguration) WithKind(value string) *TargetSyncProfileApplyConfiguration { + b.TypeMetaApplyConfiguration.Kind = &value + return b +} + +// WithAPIVersion sets the APIVersion field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the APIVersion field is set to the value of the last call. +func (b *TargetSyncProfileApplyConfiguration) WithAPIVersion(value string) *TargetSyncProfileApplyConfiguration { + b.TypeMetaApplyConfiguration.APIVersion = &value + return b +} + +// WithName sets the Name field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Name field is set to the value of the last call. +func (b *TargetSyncProfileApplyConfiguration) WithName(value string) *TargetSyncProfileApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.Name = &value + return b +} + +// WithGenerateName sets the GenerateName field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the GenerateName field is set to the value of the last call. +func (b *TargetSyncProfileApplyConfiguration) WithGenerateName(value string) *TargetSyncProfileApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.GenerateName = &value + return b +} + +// WithNamespace sets the Namespace field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Namespace field is set to the value of the last call. +func (b *TargetSyncProfileApplyConfiguration) WithNamespace(value string) *TargetSyncProfileApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.Namespace = &value + return b +} + +// WithUID sets the UID field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the UID field is set to the value of the last call. +func (b *TargetSyncProfileApplyConfiguration) WithUID(value types.UID) *TargetSyncProfileApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.UID = &value + return b +} + +// WithResourceVersion sets the ResourceVersion field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the ResourceVersion field is set to the value of the last call. +func (b *TargetSyncProfileApplyConfiguration) WithResourceVersion(value string) *TargetSyncProfileApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.ResourceVersion = &value + return b +} + +// WithGeneration sets the Generation field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Generation field is set to the value of the last call. +func (b *TargetSyncProfileApplyConfiguration) WithGeneration(value int64) *TargetSyncProfileApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.Generation = &value + return b +} + +// WithCreationTimestamp sets the CreationTimestamp field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the CreationTimestamp field is set to the value of the last call. +func (b *TargetSyncProfileApplyConfiguration) WithCreationTimestamp(value metav1.Time) *TargetSyncProfileApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.CreationTimestamp = &value + return b +} + +// WithDeletionTimestamp sets the DeletionTimestamp field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the DeletionTimestamp field is set to the value of the last call. +func (b *TargetSyncProfileApplyConfiguration) WithDeletionTimestamp(value metav1.Time) *TargetSyncProfileApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.DeletionTimestamp = &value + return b +} + +// WithDeletionGracePeriodSeconds sets the DeletionGracePeriodSeconds field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the DeletionGracePeriodSeconds field is set to the value of the last call. +func (b *TargetSyncProfileApplyConfiguration) WithDeletionGracePeriodSeconds(value int64) *TargetSyncProfileApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.DeletionGracePeriodSeconds = &value + return b +} + +// WithLabels puts the entries into the Labels field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, the entries provided by each call will be put on the Labels field, +// overwriting an existing map entries in Labels field with the same key. +func (b *TargetSyncProfileApplyConfiguration) WithLabels(entries map[string]string) *TargetSyncProfileApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + if b.ObjectMetaApplyConfiguration.Labels == nil && len(entries) > 0 { + b.ObjectMetaApplyConfiguration.Labels = make(map[string]string, len(entries)) + } + for k, v := range entries { + b.ObjectMetaApplyConfiguration.Labels[k] = v + } + return b +} + +// WithAnnotations puts the entries into the Annotations field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, the entries provided by each call will be put on the Annotations field, +// overwriting an existing map entries in Annotations field with the same key. +func (b *TargetSyncProfileApplyConfiguration) WithAnnotations(entries map[string]string) *TargetSyncProfileApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + if b.ObjectMetaApplyConfiguration.Annotations == nil && len(entries) > 0 { + b.ObjectMetaApplyConfiguration.Annotations = make(map[string]string, len(entries)) + } + for k, v := range entries { + b.ObjectMetaApplyConfiguration.Annotations[k] = v + } + return b +} + +// WithOwnerReferences adds the given value to the OwnerReferences field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, values provided by each call will be appended to the OwnerReferences field. +func (b *TargetSyncProfileApplyConfiguration) WithOwnerReferences(values ...*v1.OwnerReferenceApplyConfiguration) *TargetSyncProfileApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + for i := range values { + if values[i] == nil { + panic("nil value passed to WithOwnerReferences") + } + b.ObjectMetaApplyConfiguration.OwnerReferences = append(b.ObjectMetaApplyConfiguration.OwnerReferences, *values[i]) + } + return b +} + +// WithFinalizers adds the given value to the Finalizers field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, values provided by each call will be appended to the Finalizers field. +func (b *TargetSyncProfileApplyConfiguration) WithFinalizers(values ...string) *TargetSyncProfileApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + for i := range values { + b.ObjectMetaApplyConfiguration.Finalizers = append(b.ObjectMetaApplyConfiguration.Finalizers, values[i]) + } + return b +} + +func (b *TargetSyncProfileApplyConfiguration) ensureObjectMetaApplyConfigurationExists() { + if b.ObjectMetaApplyConfiguration == nil { + b.ObjectMetaApplyConfiguration = &v1.ObjectMetaApplyConfiguration{} + } +} + +// WithSpec sets the Spec field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Spec field is set to the value of the last call. +func (b *TargetSyncProfileApplyConfiguration) WithSpec(value *TargetSyncProfileSpecApplyConfiguration) *TargetSyncProfileApplyConfiguration { + b.Spec = value + return b +} + +// GetKind retrieves the value of the Kind field in the declarative configuration. +func (b *TargetSyncProfileApplyConfiguration) GetKind() *string { + return b.TypeMetaApplyConfiguration.Kind +} + +// GetAPIVersion retrieves the value of the APIVersion field in the declarative configuration. +func (b *TargetSyncProfileApplyConfiguration) GetAPIVersion() *string { + return b.TypeMetaApplyConfiguration.APIVersion +} + +// GetName retrieves the value of the Name field in the declarative configuration. +func (b *TargetSyncProfileApplyConfiguration) GetName() *string { + b.ensureObjectMetaApplyConfigurationExists() + return b.ObjectMetaApplyConfiguration.Name +} + +// GetNamespace retrieves the value of the Namespace field in the declarative configuration. +func (b *TargetSyncProfileApplyConfiguration) GetNamespace() *string { + b.ensureObjectMetaApplyConfigurationExists() + return b.ObjectMetaApplyConfiguration.Namespace +} diff --git a/pkg/generated/applyconfiguration/inv/v1alpha1/targetsyncprofilespec.go b/pkg/generated/applyconfiguration/inv/v1alpha1/targetsyncprofilespec.go new file mode 100644 index 00000000..5d3e4b2f --- /dev/null +++ b/pkg/generated/applyconfiguration/inv/v1alpha1/targetsyncprofilespec.go @@ -0,0 +1,72 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ +// Code generated by applyconfiguration-gen. DO NOT EDIT. + +package v1alpha1 + +// TargetSyncProfileSpecApplyConfiguration represents a declarative configuration of the TargetSyncProfileSpec type for use +// with apply. +// +// TargetSyncProfileSpec defines the desired state of TargetSyncProfile +type TargetSyncProfileSpecApplyConfiguration struct { + Validate *bool `json:"validate,omitempty"` + Buffer *int64 `json:"buffer,omitempty"` + Workers *int64 `json:"workers,omitempty"` + Sync []TargetSyncProfileSyncApplyConfiguration `json:"sync,omitempty"` +} + +// TargetSyncProfileSpecApplyConfiguration constructs a declarative configuration of the TargetSyncProfileSpec type for use with +// apply. +func TargetSyncProfileSpec() *TargetSyncProfileSpecApplyConfiguration { + return &TargetSyncProfileSpecApplyConfiguration{} +} + +// WithValidate sets the Validate field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Validate field is set to the value of the last call. +func (b *TargetSyncProfileSpecApplyConfiguration) WithValidate(value bool) *TargetSyncProfileSpecApplyConfiguration { + b.Validate = &value + return b +} + +// WithBuffer sets the Buffer field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Buffer field is set to the value of the last call. +func (b *TargetSyncProfileSpecApplyConfiguration) WithBuffer(value int64) *TargetSyncProfileSpecApplyConfiguration { + b.Buffer = &value + return b +} + +// WithWorkers sets the Workers field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Workers field is set to the value of the last call. +func (b *TargetSyncProfileSpecApplyConfiguration) WithWorkers(value int64) *TargetSyncProfileSpecApplyConfiguration { + b.Workers = &value + return b +} + +// WithSync adds the given value to the Sync field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, values provided by each call will be appended to the Sync field. +func (b *TargetSyncProfileSpecApplyConfiguration) WithSync(values ...*TargetSyncProfileSyncApplyConfiguration) *TargetSyncProfileSpecApplyConfiguration { + for i := range values { + if values[i] == nil { + panic("nil value passed to WithSync") + } + b.Sync = append(b.Sync, *values[i]) + } + return b +} diff --git a/pkg/generated/applyconfiguration/inv/v1alpha1/targetsyncprofilesync.go b/pkg/generated/applyconfiguration/inv/v1alpha1/targetsyncprofilesync.go new file mode 100644 index 00000000..a5aad98e --- /dev/null +++ b/pkg/generated/applyconfiguration/inv/v1alpha1/targetsyncprofilesync.go @@ -0,0 +1,102 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ +// Code generated by applyconfiguration-gen. DO NOT EDIT. + +package v1alpha1 + +import ( + invv1alpha1 "github.com/sdcio/config-server/apis/inv/v1alpha1" + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" +) + +// TargetSyncProfileSyncApplyConfiguration represents a declarative configuration of the TargetSyncProfileSync type for use +// with apply. +// +// TargetSyncProfileSync defines the desired state of TargetSyncProfileSync +type TargetSyncProfileSyncApplyConfiguration struct { + Name *string `json:"name,omitempty"` + Protocol *invv1alpha1.Protocol `json:"protocol,omitempty"` + // Port defines the port on which the scan runs + Port *uint32 `json:"port,omitempty"` + Paths []string `json:"paths,omitempty"` + Mode *invv1alpha1.SyncMode `json:"mode,omitempty"` + Encoding *invv1alpha1.Encoding `json:"encoding,omitempty"` + Interval *v1.Duration `json:"interval,omitempty"` +} + +// TargetSyncProfileSyncApplyConfiguration constructs a declarative configuration of the TargetSyncProfileSync type for use with +// apply. +func TargetSyncProfileSync() *TargetSyncProfileSyncApplyConfiguration { + return &TargetSyncProfileSyncApplyConfiguration{} +} + +// WithName sets the Name field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Name field is set to the value of the last call. +func (b *TargetSyncProfileSyncApplyConfiguration) WithName(value string) *TargetSyncProfileSyncApplyConfiguration { + b.Name = &value + return b +} + +// WithProtocol sets the Protocol field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Protocol field is set to the value of the last call. +func (b *TargetSyncProfileSyncApplyConfiguration) WithProtocol(value invv1alpha1.Protocol) *TargetSyncProfileSyncApplyConfiguration { + b.Protocol = &value + return b +} + +// WithPort sets the Port field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Port field is set to the value of the last call. +func (b *TargetSyncProfileSyncApplyConfiguration) WithPort(value uint32) *TargetSyncProfileSyncApplyConfiguration { + b.Port = &value + return b +} + +// WithPaths adds the given value to the Paths field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, values provided by each call will be appended to the Paths field. +func (b *TargetSyncProfileSyncApplyConfiguration) WithPaths(values ...string) *TargetSyncProfileSyncApplyConfiguration { + for i := range values { + b.Paths = append(b.Paths, values[i]) + } + return b +} + +// WithMode sets the Mode field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Mode field is set to the value of the last call. +func (b *TargetSyncProfileSyncApplyConfiguration) WithMode(value invv1alpha1.SyncMode) *TargetSyncProfileSyncApplyConfiguration { + b.Mode = &value + return b +} + +// WithEncoding sets the Encoding field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Encoding field is set to the value of the last call. +func (b *TargetSyncProfileSyncApplyConfiguration) WithEncoding(value invv1alpha1.Encoding) *TargetSyncProfileSyncApplyConfiguration { + b.Encoding = &value + return b +} + +// WithInterval sets the Interval field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Interval field is set to the value of the last call. +func (b *TargetSyncProfileSyncApplyConfiguration) WithInterval(value v1.Duration) *TargetSyncProfileSyncApplyConfiguration { + b.Interval = &value + return b +} diff --git a/pkg/generated/applyconfiguration/inv/v1alpha1/targettemplate.go b/pkg/generated/applyconfiguration/inv/v1alpha1/targettemplate.go new file mode 100644 index 00000000..788ba544 --- /dev/null +++ b/pkg/generated/applyconfiguration/inv/v1alpha1/targettemplate.go @@ -0,0 +1,73 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ +// Code generated by applyconfiguration-gen. DO NOT EDIT. + +package v1alpha1 + +// TargetTemplateApplyConfiguration represents a declarative configuration of the TargetTemplate type for use +// with apply. +// +// TargetTemplate defines the template of the target +type TargetTemplateApplyConfiguration struct { + // target name template + NameTemplate *string `json:"nameTemplate,omitempty"` + // Annotations is a key value map to be copied to the target CR. + Annotations map[string]string `json:"annotations,omitempty"` + // Labels is a key value map to be copied to the target CR. + Labels map[string]string `json:"labels,omitempty"` +} + +// TargetTemplateApplyConfiguration constructs a declarative configuration of the TargetTemplate type for use with +// apply. +func TargetTemplate() *TargetTemplateApplyConfiguration { + return &TargetTemplateApplyConfiguration{} +} + +// WithNameTemplate sets the NameTemplate field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the NameTemplate field is set to the value of the last call. +func (b *TargetTemplateApplyConfiguration) WithNameTemplate(value string) *TargetTemplateApplyConfiguration { + b.NameTemplate = &value + return b +} + +// WithAnnotations puts the entries into the Annotations field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, the entries provided by each call will be put on the Annotations field, +// overwriting an existing map entries in Annotations field with the same key. +func (b *TargetTemplateApplyConfiguration) WithAnnotations(entries map[string]string) *TargetTemplateApplyConfiguration { + if b.Annotations == nil && len(entries) > 0 { + b.Annotations = make(map[string]string, len(entries)) + } + for k, v := range entries { + b.Annotations[k] = v + } + return b +} + +// WithLabels puts the entries into the Labels field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, the entries provided by each call will be put on the Labels field, +// overwriting an existing map entries in Labels field with the same key. +func (b *TargetTemplateApplyConfiguration) WithLabels(entries map[string]string) *TargetTemplateApplyConfiguration { + if b.Labels == nil && len(entries) > 0 { + b.Labels = make(map[string]string, len(entries)) + } + for k, v := range entries { + b.Labels[k] = v + } + return b +} diff --git a/pkg/generated/applyconfiguration/inv/v1alpha1/workspace.go b/pkg/generated/applyconfiguration/inv/v1alpha1/workspace.go new file mode 100644 index 00000000..5a0e53fc --- /dev/null +++ b/pkg/generated/applyconfiguration/inv/v1alpha1/workspace.go @@ -0,0 +1,244 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ +// Code generated by applyconfiguration-gen. DO NOT EDIT. + +package v1alpha1 + +import ( + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + types "k8s.io/apimachinery/pkg/types" + v1 "k8s.io/client-go/applyconfigurations/meta/v1" +) + +// WorkspaceApplyConfiguration represents a declarative configuration of the Workspace type for use +// with apply. +// +// Workspace is the Workspace for the Workspace API +type WorkspaceApplyConfiguration struct { + v1.TypeMetaApplyConfiguration `json:",inline"` + *v1.ObjectMetaApplyConfiguration `json:"metadata,omitempty"` + Spec *WorkspaceSpecApplyConfiguration `json:"spec,omitempty"` + Status *WorkspaceStatusApplyConfiguration `json:"status,omitempty"` +} + +// Workspace constructs a declarative configuration of the Workspace type for use with +// apply. +func Workspace(name, namespace string) *WorkspaceApplyConfiguration { + b := &WorkspaceApplyConfiguration{} + b.WithName(name) + b.WithNamespace(namespace) + b.WithKind("Workspace") + b.WithAPIVersion("inv.sdcio.dev/v1alpha1") + return b +} + +func (b WorkspaceApplyConfiguration) IsApplyConfiguration() {} + +// WithKind sets the Kind field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Kind field is set to the value of the last call. +func (b *WorkspaceApplyConfiguration) WithKind(value string) *WorkspaceApplyConfiguration { + b.TypeMetaApplyConfiguration.Kind = &value + return b +} + +// WithAPIVersion sets the APIVersion field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the APIVersion field is set to the value of the last call. +func (b *WorkspaceApplyConfiguration) WithAPIVersion(value string) *WorkspaceApplyConfiguration { + b.TypeMetaApplyConfiguration.APIVersion = &value + return b +} + +// WithName sets the Name field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Name field is set to the value of the last call. +func (b *WorkspaceApplyConfiguration) WithName(value string) *WorkspaceApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.Name = &value + return b +} + +// WithGenerateName sets the GenerateName field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the GenerateName field is set to the value of the last call. +func (b *WorkspaceApplyConfiguration) WithGenerateName(value string) *WorkspaceApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.GenerateName = &value + return b +} + +// WithNamespace sets the Namespace field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Namespace field is set to the value of the last call. +func (b *WorkspaceApplyConfiguration) WithNamespace(value string) *WorkspaceApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.Namespace = &value + return b +} + +// WithUID sets the UID field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the UID field is set to the value of the last call. +func (b *WorkspaceApplyConfiguration) WithUID(value types.UID) *WorkspaceApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.UID = &value + return b +} + +// WithResourceVersion sets the ResourceVersion field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the ResourceVersion field is set to the value of the last call. +func (b *WorkspaceApplyConfiguration) WithResourceVersion(value string) *WorkspaceApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.ResourceVersion = &value + return b +} + +// WithGeneration sets the Generation field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Generation field is set to the value of the last call. +func (b *WorkspaceApplyConfiguration) WithGeneration(value int64) *WorkspaceApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.Generation = &value + return b +} + +// WithCreationTimestamp sets the CreationTimestamp field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the CreationTimestamp field is set to the value of the last call. +func (b *WorkspaceApplyConfiguration) WithCreationTimestamp(value metav1.Time) *WorkspaceApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.CreationTimestamp = &value + return b +} + +// WithDeletionTimestamp sets the DeletionTimestamp field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the DeletionTimestamp field is set to the value of the last call. +func (b *WorkspaceApplyConfiguration) WithDeletionTimestamp(value metav1.Time) *WorkspaceApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.DeletionTimestamp = &value + return b +} + +// WithDeletionGracePeriodSeconds sets the DeletionGracePeriodSeconds field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the DeletionGracePeriodSeconds field is set to the value of the last call. +func (b *WorkspaceApplyConfiguration) WithDeletionGracePeriodSeconds(value int64) *WorkspaceApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.DeletionGracePeriodSeconds = &value + return b +} + +// WithLabels puts the entries into the Labels field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, the entries provided by each call will be put on the Labels field, +// overwriting an existing map entries in Labels field with the same key. +func (b *WorkspaceApplyConfiguration) WithLabels(entries map[string]string) *WorkspaceApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + if b.ObjectMetaApplyConfiguration.Labels == nil && len(entries) > 0 { + b.ObjectMetaApplyConfiguration.Labels = make(map[string]string, len(entries)) + } + for k, v := range entries { + b.ObjectMetaApplyConfiguration.Labels[k] = v + } + return b +} + +// WithAnnotations puts the entries into the Annotations field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, the entries provided by each call will be put on the Annotations field, +// overwriting an existing map entries in Annotations field with the same key. +func (b *WorkspaceApplyConfiguration) WithAnnotations(entries map[string]string) *WorkspaceApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + if b.ObjectMetaApplyConfiguration.Annotations == nil && len(entries) > 0 { + b.ObjectMetaApplyConfiguration.Annotations = make(map[string]string, len(entries)) + } + for k, v := range entries { + b.ObjectMetaApplyConfiguration.Annotations[k] = v + } + return b +} + +// WithOwnerReferences adds the given value to the OwnerReferences field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, values provided by each call will be appended to the OwnerReferences field. +func (b *WorkspaceApplyConfiguration) WithOwnerReferences(values ...*v1.OwnerReferenceApplyConfiguration) *WorkspaceApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + for i := range values { + if values[i] == nil { + panic("nil value passed to WithOwnerReferences") + } + b.ObjectMetaApplyConfiguration.OwnerReferences = append(b.ObjectMetaApplyConfiguration.OwnerReferences, *values[i]) + } + return b +} + +// WithFinalizers adds the given value to the Finalizers field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, values provided by each call will be appended to the Finalizers field. +func (b *WorkspaceApplyConfiguration) WithFinalizers(values ...string) *WorkspaceApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + for i := range values { + b.ObjectMetaApplyConfiguration.Finalizers = append(b.ObjectMetaApplyConfiguration.Finalizers, values[i]) + } + return b +} + +func (b *WorkspaceApplyConfiguration) ensureObjectMetaApplyConfigurationExists() { + if b.ObjectMetaApplyConfiguration == nil { + b.ObjectMetaApplyConfiguration = &v1.ObjectMetaApplyConfiguration{} + } +} + +// WithSpec sets the Spec field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Spec field is set to the value of the last call. +func (b *WorkspaceApplyConfiguration) WithSpec(value *WorkspaceSpecApplyConfiguration) *WorkspaceApplyConfiguration { + b.Spec = value + return b +} + +// WithStatus sets the Status field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Status field is set to the value of the last call. +func (b *WorkspaceApplyConfiguration) WithStatus(value *WorkspaceStatusApplyConfiguration) *WorkspaceApplyConfiguration { + b.Status = value + return b +} + +// GetKind retrieves the value of the Kind field in the declarative configuration. +func (b *WorkspaceApplyConfiguration) GetKind() *string { + return b.TypeMetaApplyConfiguration.Kind +} + +// GetAPIVersion retrieves the value of the APIVersion field in the declarative configuration. +func (b *WorkspaceApplyConfiguration) GetAPIVersion() *string { + return b.TypeMetaApplyConfiguration.APIVersion +} + +// GetName retrieves the value of the Name field in the declarative configuration. +func (b *WorkspaceApplyConfiguration) GetName() *string { + b.ensureObjectMetaApplyConfigurationExists() + return b.ObjectMetaApplyConfiguration.Name +} + +// GetNamespace retrieves the value of the Namespace field in the declarative configuration. +func (b *WorkspaceApplyConfiguration) GetNamespace() *string { + b.ensureObjectMetaApplyConfigurationExists() + return b.ObjectMetaApplyConfiguration.Namespace +} diff --git a/pkg/generated/applyconfiguration/inv/v1alpha1/workspacespec.go b/pkg/generated/applyconfiguration/inv/v1alpha1/workspacespec.go new file mode 100644 index 00000000..cbaf7a3f --- /dev/null +++ b/pkg/generated/applyconfiguration/inv/v1alpha1/workspacespec.go @@ -0,0 +1,76 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ +// Code generated by applyconfiguration-gen. DO NOT EDIT. + +package v1alpha1 + +import ( + invv1alpha1 "github.com/sdcio/config-server/apis/inv/v1alpha1" +) + +// WorkspaceSpecApplyConfiguration represents a declarative configuration of the WorkspaceSpec type for use +// with apply. +// +// WorkspaceSpec defines the desired state of Workspace +type WorkspaceSpecApplyConfiguration struct { + RepositoryApplyConfiguration `json:",inline"` +} + +// WorkspaceSpecApplyConfiguration constructs a declarative configuration of the WorkspaceSpec type for use with +// apply. +func WorkspaceSpec() *WorkspaceSpecApplyConfiguration { + return &WorkspaceSpecApplyConfiguration{} +} + +// WithRepositoryURL sets the RepositoryURL field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the RepositoryURL field is set to the value of the last call. +func (b *WorkspaceSpecApplyConfiguration) WithRepositoryURL(value string) *WorkspaceSpecApplyConfiguration { + b.RepositoryApplyConfiguration.RepositoryURL = &value + return b +} + +// WithCredentials sets the Credentials field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Credentials field is set to the value of the last call. +func (b *WorkspaceSpecApplyConfiguration) WithCredentials(value string) *WorkspaceSpecApplyConfiguration { + b.RepositoryApplyConfiguration.Credentials = &value + return b +} + +// WithProxy sets the Proxy field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Proxy field is set to the value of the last call. +func (b *WorkspaceSpecApplyConfiguration) WithProxy(value *ProxyApplyConfiguration) *WorkspaceSpecApplyConfiguration { + b.RepositoryApplyConfiguration.Proxy = value + return b +} + +// WithKind sets the Kind field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Kind field is set to the value of the last call. +func (b *WorkspaceSpecApplyConfiguration) WithKind(value invv1alpha1.BranchTagKind) *WorkspaceSpecApplyConfiguration { + b.RepositoryApplyConfiguration.Kind = &value + return b +} + +// WithRef sets the Ref field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Ref field is set to the value of the last call. +func (b *WorkspaceSpecApplyConfiguration) WithRef(value string) *WorkspaceSpecApplyConfiguration { + b.RepositoryApplyConfiguration.Ref = &value + return b +} diff --git a/pkg/generated/applyconfiguration/inv/v1alpha1/workspacestatus.go b/pkg/generated/applyconfiguration/inv/v1alpha1/workspacestatus.go new file mode 100644 index 00000000..96453433 --- /dev/null +++ b/pkg/generated/applyconfiguration/inv/v1alpha1/workspacestatus.go @@ -0,0 +1,68 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ +// Code generated by applyconfiguration-gen. DO NOT EDIT. + +package v1alpha1 + +import ( + conditionv1alpha1 "github.com/sdcio/config-server/apis/condition/v1alpha1" + invv1alpha1 "github.com/sdcio/config-server/apis/inv/v1alpha1" +) + +// WorkspaceStatusApplyConfiguration represents a declarative configuration of the WorkspaceStatus type for use +// with apply. +// +// WorkspaceStatus defines the observed state of Workspace +type WorkspaceStatusApplyConfiguration struct { + // ConditionedStatus provides the status of the Workspace using conditions + conditionv1alpha1.ConditionedStatus `json:",inline"` + // Kind defines the that the BranchOrTag string is a repository branch or a tag + Kind *invv1alpha1.BranchTagKind `json:"kind,omitempty"` + // DeployedRef is the reference that is deployed + DeployedRef *string `json:"deployedRef,omitempty"` +} + +// WorkspaceStatusApplyConfiguration constructs a declarative configuration of the WorkspaceStatus type for use with +// apply. +func WorkspaceStatus() *WorkspaceStatusApplyConfiguration { + return &WorkspaceStatusApplyConfiguration{} +} + +// WithConditions adds the given value to the Conditions field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, values provided by each call will be appended to the Conditions field. +func (b *WorkspaceStatusApplyConfiguration) WithConditions(values ...conditionv1alpha1.Condition) *WorkspaceStatusApplyConfiguration { + for i := range values { + b.ConditionedStatus.Conditions = append(b.ConditionedStatus.Conditions, values[i]) + } + return b +} + +// WithKind sets the Kind field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Kind field is set to the value of the last call. +func (b *WorkspaceStatusApplyConfiguration) WithKind(value invv1alpha1.BranchTagKind) *WorkspaceStatusApplyConfiguration { + b.Kind = &value + return b +} + +// WithDeployedRef sets the DeployedRef field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the DeployedRef field is set to the value of the last call. +func (b *WorkspaceStatusApplyConfiguration) WithDeployedRef(value string) *WorkspaceStatusApplyConfiguration { + b.DeployedRef = &value + return b +} diff --git a/pkg/generated/applyconfiguration/utils.go b/pkg/generated/applyconfiguration/utils.go new file mode 100644 index 00000000..de3aad3f --- /dev/null +++ b/pkg/generated/applyconfiguration/utils.go @@ -0,0 +1,181 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ +// Code generated by applyconfiguration-gen. DO NOT EDIT. + +package applyconfiguration + +import ( + v1alpha1 "github.com/sdcio/config-server/apis/config/v1alpha1" + invv1alpha1 "github.com/sdcio/config-server/apis/inv/v1alpha1" + configv1alpha1 "github.com/sdcio/config-server/pkg/generated/applyconfiguration/config/v1alpha1" + internal "github.com/sdcio/config-server/pkg/generated/applyconfiguration/internal" + applyconfigurationinvv1alpha1 "github.com/sdcio/config-server/pkg/generated/applyconfiguration/inv/v1alpha1" + runtime "k8s.io/apimachinery/pkg/runtime" + schema "k8s.io/apimachinery/pkg/runtime/schema" + managedfields "k8s.io/apimachinery/pkg/util/managedfields" +) + +// ForKind returns an apply configuration type for the given GroupVersionKind, or nil if no +// apply configuration type exists for the given GroupVersionKind. +func ForKind(kind schema.GroupVersionKind) interface{} { + switch kind { + // Group=config.sdcio.dev, Version=v1alpha1 + case v1alpha1.SchemeGroupVersion.WithKind("Config"): + return &configv1alpha1.ConfigApplyConfiguration{} + case v1alpha1.SchemeGroupVersion.WithKind("ConfigBlame"): + return &configv1alpha1.ConfigBlameApplyConfiguration{} + case v1alpha1.SchemeGroupVersion.WithKind("ConfigBlameStatus"): + return &configv1alpha1.ConfigBlameStatusApplyConfiguration{} + case v1alpha1.SchemeGroupVersion.WithKind("ConfigBlob"): + return &configv1alpha1.ConfigBlobApplyConfiguration{} + case v1alpha1.SchemeGroupVersion.WithKind("ConfigDeviation"): + return &configv1alpha1.ConfigDeviationApplyConfiguration{} + case v1alpha1.SchemeGroupVersion.WithKind("ConfigSet"): + return &configv1alpha1.ConfigSetApplyConfiguration{} + case v1alpha1.SchemeGroupVersion.WithKind("ConfigSetSpec"): + return &configv1alpha1.ConfigSetSpecApplyConfiguration{} + case v1alpha1.SchemeGroupVersion.WithKind("ConfigSetStatus"): + return &configv1alpha1.ConfigSetStatusApplyConfiguration{} + case v1alpha1.SchemeGroupVersion.WithKind("ConfigSpec"): + return &configv1alpha1.ConfigSpecApplyConfiguration{} + case v1alpha1.SchemeGroupVersion.WithKind("ConfigStatus"): + return &configv1alpha1.ConfigStatusApplyConfiguration{} + case v1alpha1.SchemeGroupVersion.WithKind("ConfigStatusLastKnownGoodSchema"): + return &configv1alpha1.ConfigStatusLastKnownGoodSchemaApplyConfiguration{} + case v1alpha1.SchemeGroupVersion.WithKind("Deviation"): + return &configv1alpha1.DeviationApplyConfiguration{} + case v1alpha1.SchemeGroupVersion.WithKind("DeviationSpec"): + return &configv1alpha1.DeviationSpecApplyConfiguration{} + case v1alpha1.SchemeGroupVersion.WithKind("DeviationStatus"): + return &configv1alpha1.DeviationStatusApplyConfiguration{} + case v1alpha1.SchemeGroupVersion.WithKind("Lifecycle"): + return &configv1alpha1.LifecycleApplyConfiguration{} + case v1alpha1.SchemeGroupVersion.WithKind("RunningConfig"): + return &configv1alpha1.RunningConfigApplyConfiguration{} + case v1alpha1.SchemeGroupVersion.WithKind("RunningConfigStatus"): + return &configv1alpha1.RunningConfigStatusApplyConfiguration{} + case v1alpha1.SchemeGroupVersion.WithKind("SensitiveConfig"): + return &configv1alpha1.SensitiveConfigApplyConfiguration{} + case v1alpha1.SchemeGroupVersion.WithKind("SensitiveConfigData"): + return &configv1alpha1.SensitiveConfigDataApplyConfiguration{} + case v1alpha1.SchemeGroupVersion.WithKind("SensitiveConfigSpec"): + return &configv1alpha1.SensitiveConfigSpecApplyConfiguration{} + case v1alpha1.SchemeGroupVersion.WithKind("SensitiveConfigStatus"): + return &configv1alpha1.SensitiveConfigStatusApplyConfiguration{} + case v1alpha1.SchemeGroupVersion.WithKind("Target"): + return &configv1alpha1.TargetApplyConfiguration{} + case v1alpha1.SchemeGroupVersion.WithKind("TargetStatus"): + return &configv1alpha1.TargetStatusApplyConfiguration{} + + // Group=inv.sdcio.dev, Version=v1alpha1 + case invv1alpha1.SchemeGroupVersion.WithKind("DiscoveryInfo"): + return &applyconfigurationinvv1alpha1.DiscoveryInfoApplyConfiguration{} + case invv1alpha1.SchemeGroupVersion.WithKind("DiscoveryParameters"): + return &applyconfigurationinvv1alpha1.DiscoveryParametersApplyConfiguration{} + case invv1alpha1.SchemeGroupVersion.WithKind("DiscoveryPathDefinition"): + return &applyconfigurationinvv1alpha1.DiscoveryPathDefinitionApplyConfiguration{} + case invv1alpha1.SchemeGroupVersion.WithKind("DiscoveryProfile"): + return &applyconfigurationinvv1alpha1.DiscoveryProfileApplyConfiguration{} + case invv1alpha1.SchemeGroupVersion.WithKind("DiscoveryRule"): + return &applyconfigurationinvv1alpha1.DiscoveryRuleApplyConfiguration{} + case invv1alpha1.SchemeGroupVersion.WithKind("DiscoveryRuleAddress"): + return &applyconfigurationinvv1alpha1.DiscoveryRuleAddressApplyConfiguration{} + case invv1alpha1.SchemeGroupVersion.WithKind("DiscoveryRulePrefix"): + return &applyconfigurationinvv1alpha1.DiscoveryRulePrefixApplyConfiguration{} + case invv1alpha1.SchemeGroupVersion.WithKind("DiscoveryRuleSpec"): + return &applyconfigurationinvv1alpha1.DiscoveryRuleSpecApplyConfiguration{} + case invv1alpha1.SchemeGroupVersion.WithKind("DiscoveryRuleStatus"): + return &applyconfigurationinvv1alpha1.DiscoveryRuleStatusApplyConfiguration{} + case invv1alpha1.SchemeGroupVersion.WithKind("DiscoveryVendorProfile"): + return &applyconfigurationinvv1alpha1.DiscoveryVendorProfileApplyConfiguration{} + case invv1alpha1.SchemeGroupVersion.WithKind("DiscoveryVendorProfileSpec"): + return &applyconfigurationinvv1alpha1.DiscoveryVendorProfileSpecApplyConfiguration{} + case invv1alpha1.SchemeGroupVersion.WithKind("GnmiDiscoveryVendorProfileParameters"): + return &applyconfigurationinvv1alpha1.GnmiDiscoveryVendorProfileParametersApplyConfiguration{} + case invv1alpha1.SchemeGroupVersion.WithKind("Proxy"): + return &applyconfigurationinvv1alpha1.ProxyApplyConfiguration{} + case invv1alpha1.SchemeGroupVersion.WithKind("Repository"): + return &applyconfigurationinvv1alpha1.RepositoryApplyConfiguration{} + case invv1alpha1.SchemeGroupVersion.WithKind("Rollout"): + return &applyconfigurationinvv1alpha1.RolloutApplyConfiguration{} + case invv1alpha1.SchemeGroupVersion.WithKind("RolloutSpec"): + return &applyconfigurationinvv1alpha1.RolloutSpecApplyConfiguration{} + case invv1alpha1.SchemeGroupVersion.WithKind("RolloutStatus"): + return &applyconfigurationinvv1alpha1.RolloutStatusApplyConfiguration{} + case invv1alpha1.SchemeGroupVersion.WithKind("RolloutTargetStatus"): + return &applyconfigurationinvv1alpha1.RolloutTargetStatusApplyConfiguration{} + case invv1alpha1.SchemeGroupVersion.WithKind("Schema"): + return &applyconfigurationinvv1alpha1.SchemaApplyConfiguration{} + case invv1alpha1.SchemeGroupVersion.WithKind("SchemaKey"): + return &applyconfigurationinvv1alpha1.SchemaKeyApplyConfiguration{} + case invv1alpha1.SchemeGroupVersion.WithKind("SchemaRepositoryStatus"): + return &applyconfigurationinvv1alpha1.SchemaRepositoryStatusApplyConfiguration{} + case invv1alpha1.SchemeGroupVersion.WithKind("SchemaSpec"): + return &applyconfigurationinvv1alpha1.SchemaSpecApplyConfiguration{} + case invv1alpha1.SchemeGroupVersion.WithKind("SchemaSpecRepository"): + return &applyconfigurationinvv1alpha1.SchemaSpecRepositoryApplyConfiguration{} + case invv1alpha1.SchemeGroupVersion.WithKind("SchemaSpecSchema"): + return &applyconfigurationinvv1alpha1.SchemaSpecSchemaApplyConfiguration{} + case invv1alpha1.SchemeGroupVersion.WithKind("SchemaStatus"): + return &applyconfigurationinvv1alpha1.SchemaStatusApplyConfiguration{} + case invv1alpha1.SchemeGroupVersion.WithKind("SrcDstPath"): + return &applyconfigurationinvv1alpha1.SrcDstPathApplyConfiguration{} + case invv1alpha1.SchemeGroupVersion.WithKind("Subscription"): + return &applyconfigurationinvv1alpha1.SubscriptionApplyConfiguration{} + case invv1alpha1.SchemeGroupVersion.WithKind("SubscriptionParameters"): + return &applyconfigurationinvv1alpha1.SubscriptionParametersApplyConfiguration{} + case invv1alpha1.SchemeGroupVersion.WithKind("SubscriptionSpec"): + return &applyconfigurationinvv1alpha1.SubscriptionSpecApplyConfiguration{} + case invv1alpha1.SchemeGroupVersion.WithKind("SubscriptionStatus"): + return &applyconfigurationinvv1alpha1.SubscriptionStatusApplyConfiguration{} + case invv1alpha1.SchemeGroupVersion.WithKind("SubscriptionTarget"): + return &applyconfigurationinvv1alpha1.SubscriptionTargetApplyConfiguration{} + case invv1alpha1.SchemeGroupVersion.WithKind("Target"): + return &applyconfigurationinvv1alpha1.TargetApplyConfiguration{} + case invv1alpha1.SchemeGroupVersion.WithKind("TargetConnectionProfile"): + return &applyconfigurationinvv1alpha1.TargetConnectionProfileApplyConfiguration{} + case invv1alpha1.SchemeGroupVersion.WithKind("TargetConnectionProfileSpec"): + return &applyconfigurationinvv1alpha1.TargetConnectionProfileSpecApplyConfiguration{} + case invv1alpha1.SchemeGroupVersion.WithKind("TargetProfile"): + return &applyconfigurationinvv1alpha1.TargetProfileApplyConfiguration{} + case invv1alpha1.SchemeGroupVersion.WithKind("TargetSpec"): + return &applyconfigurationinvv1alpha1.TargetSpecApplyConfiguration{} + case invv1alpha1.SchemeGroupVersion.WithKind("TargetStatus"): + return &applyconfigurationinvv1alpha1.TargetStatusApplyConfiguration{} + case invv1alpha1.SchemeGroupVersion.WithKind("TargetStatusUsedReferences"): + return &applyconfigurationinvv1alpha1.TargetStatusUsedReferencesApplyConfiguration{} + case invv1alpha1.SchemeGroupVersion.WithKind("TargetSyncProfile"): + return &applyconfigurationinvv1alpha1.TargetSyncProfileApplyConfiguration{} + case invv1alpha1.SchemeGroupVersion.WithKind("TargetSyncProfileSpec"): + return &applyconfigurationinvv1alpha1.TargetSyncProfileSpecApplyConfiguration{} + case invv1alpha1.SchemeGroupVersion.WithKind("TargetSyncProfileSync"): + return &applyconfigurationinvv1alpha1.TargetSyncProfileSyncApplyConfiguration{} + case invv1alpha1.SchemeGroupVersion.WithKind("TargetTemplate"): + return &applyconfigurationinvv1alpha1.TargetTemplateApplyConfiguration{} + case invv1alpha1.SchemeGroupVersion.WithKind("Workspace"): + return &applyconfigurationinvv1alpha1.WorkspaceApplyConfiguration{} + case invv1alpha1.SchemeGroupVersion.WithKind("WorkspaceSpec"): + return &applyconfigurationinvv1alpha1.WorkspaceSpecApplyConfiguration{} + case invv1alpha1.SchemeGroupVersion.WithKind("WorkspaceStatus"): + return &applyconfigurationinvv1alpha1.WorkspaceStatusApplyConfiguration{} + + } + return nil +} + +func NewTypeConverter(scheme *runtime.Scheme) managedfields.TypeConverter { + return managedfields.NewSchemeTypeConverter(scheme, internal.Parser()) +} diff --git a/pkg/reconcilers/configset/reconciler.go b/pkg/reconcilers/configset/reconciler.go index 7fa5d311..865ca503 100644 --- a/pkg/reconcilers/configset/reconciler.go +++ b/pkg/reconcilers/configset/reconciler.go @@ -22,10 +22,12 @@ import ( "fmt" "sort" "strings" + "reflect" "github.com/henderiw/logger/log" "github.com/pkg/errors" condv1alpha1 "github.com/sdcio/config-server/apis/condition/v1alpha1" + configv1alpha1apply "github.com/sdcio/config-server/pkg/generated/applyconfiguration/config/v1alpha1" "github.com/sdcio/config-server/apis/config" configv1alpha1 "github.com/sdcio/config-server/apis/config/v1alpha1" invv1alpha1 "github.com/sdcio/config-server/apis/inv/v1alpha1" @@ -334,17 +336,25 @@ func buildConfig(_ context.Context, configSet *configv1alpha1.ConfigSet, target func (r *reconciler) handleSuccess(ctx context.Context, configSetOrig, configSet *configv1alpha1.ConfigSet) error { log := log.FromContext(ctx) - log.Debug("handleSuccess", "key", configSet.GetNamespacedName(), "status old", configSet.DeepCopy().Status) - // take a snapshot of the current object - patch := client.MergeFrom(configSetOrig) - // update status - configSet.SetConditions(condv1alpha1.Ready()) + newCond := condv1alpha1.Ready() + oldCond := configSetOrig.GetCondition(condv1alpha1.ConditionTypeReady) + + if newCond.Equal(oldCond) && reflect.DeepEqual(configSet.Status.Targets, configSetOrig.Status.Targets) { + log.Info("handleSuccess -> no change") + return nil + } + r.recorder.Eventf(configSet, nil, corev1.EventTypeNormal, configv1alpha1.ConfigSetKind, "ready", "") - log.Debug("handleSuccess", "key", configSet.GetNamespacedName(), "status new", configSet.Status) + statusApply := configv1alpha1apply.ConfigSetStatus(). + WithConditions(newCond). + WithTargets(targetStatusToApply(configSet.Status.Targets)...) + + applyConfig := configv1alpha1apply.ConfigSet(configSet.Name, configSet.Namespace). + WithStatus(statusApply) - return r.client.Status().Patch(ctx, configSet, patch, &client.SubResourcePatchOptions{ - PatchOptions: client.PatchOptions{ + return r.client.Status().Apply(ctx, applyConfig, &client.SubResourceApplyOptions{ + ApplyOptions: client.ApplyOptions{ FieldManager: reconcilerName, }, }) @@ -352,21 +362,34 @@ func (r *reconciler) handleSuccess(ctx context.Context, configSetOrig, configSet func (r *reconciler) handleError(ctx context.Context, configSetOrig, configSet *configv1alpha1.ConfigSet, msg string, err error) error { log := log.FromContext(ctx) - // take a snapshot of the current object - patch := client.MergeFrom(configSetOrig.DeepCopy()) - if err != nil { msg = fmt.Sprintf("%s err %s", msg, err.Error()) } - configSet.SetConditions(condv1alpha1.Failed(msg)) + + newCond := condv1alpha1.Failed(msg) + oldCond := configSetOrig.GetCondition(condv1alpha1.ConditionTypeReady) + + if newCond.Equal(oldCond) && reflect.DeepEqual(configSet.Status.Targets, configSetOrig.Status.Targets) { + log.Info("handleError -> no change") + return nil + } + log.Error(msg) r.recorder.Eventf(configSet, nil, corev1.EventTypeWarning, configv1alpha1.ConfigSetKind, msg, "") - return r.client.Status().Patch(ctx, configSet, patch, &client.SubResourcePatchOptions{ - PatchOptions: client.PatchOptions{ + statusApply := configv1alpha1apply.ConfigSetStatus(). + WithConditions(newCond). + WithTargets(targetStatusToApply(configSet.Status.Targets)...) + + applyConfig := configv1alpha1apply.ConfigSet(configSet.Name, configSet.Namespace). + WithStatus(statusApply) + + return r.client.Status().Apply(ctx, applyConfig, &client.SubResourceApplyOptions{ + ApplyOptions: client.ApplyOptions{ FieldManager: reconcilerName, }, }) + } func (r *reconciler) determineOverallStatus(_ context.Context, configSet *configv1alpha1.ConfigSet) string { @@ -378,3 +401,13 @@ func (r *reconciler) determineOverallStatus(_ context.Context, configSet *config } return sb.String() } + +func targetStatusToApply(targets []configv1alpha1.TargetStatus) []*configv1alpha1apply.TargetStatusApplyConfiguration { + result := make([]*configv1alpha1apply.TargetStatusApplyConfiguration, 0, len(targets)) + for _, t := range targets { + result = append(result, configv1alpha1apply.TargetStatus(). + WithName(t.Name), + ) + } + return result +} \ No newline at end of file diff --git a/pkg/reconcilers/discoveryrule/reconciler.go b/pkg/reconcilers/discoveryrule/reconciler.go index c4a00a13..504879e4 100644 --- a/pkg/reconcilers/discoveryrule/reconciler.go +++ b/pkg/reconcilers/discoveryrule/reconciler.go @@ -27,6 +27,7 @@ import ( errors "github.com/pkg/errors" condv1alpha1 "github.com/sdcio/config-server/apis/condition/v1alpha1" invv1alpha1 "github.com/sdcio/config-server/apis/inv/v1alpha1" + invv1alpha1apply "github.com/sdcio/config-server/pkg/generated/applyconfiguration/inv/v1alpha1" "github.com/sdcio/config-server/pkg/discovery/discoveryrule" "github.com/sdcio/config-server/pkg/reconcilers" "github.com/sdcio/config-server/pkg/reconcilers/ctrlconfig" @@ -36,7 +37,6 @@ import ( metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/apimachinery/pkg/runtime/schema" "k8s.io/client-go/tools/events" - "k8s.io/utils/ptr" ctrl "sigs.k8s.io/controller-runtime" "sigs.k8s.io/controller-runtime/pkg/client" "sigs.k8s.io/controller-runtime/pkg/event" @@ -258,20 +258,28 @@ func (r *reconciler) HasChanged(ctx context.Context, newDRConfig, currentDRConfi func (r *reconciler) handleSuccess(ctx context.Context, discoveryRule *invv1alpha1.DiscoveryRule, changed bool) error { log := log.FromContext(ctx) log.Debug("handleSuccess", "key", discoveryRule.GetNamespacedName(), "status old", discoveryRule.DeepCopy().Status) - // take a snapshot of the current object - patch := client.MergeFrom(discoveryRule.DeepCopy()) - // update status - discoveryRule.ManagedFields = nil - discoveryRule.SetConditions(condv1alpha1.Ready()) + + newCond := condv1alpha1.Ready() + oldCond := discoveryRule.GetCondition(condv1alpha1.ConditionTypeReady) + + if newCond.Equal(oldCond) && !changed { + log.Info("handleSuccess -> no change") + return nil + } + + statusApply := invv1alpha1apply.DiscoveryRuleStatus(). + WithConditions(newCond) + if changed { - discoveryRule.Status.StartTime = ptr.To(metav1.Now()) + statusApply = statusApply.WithStartTime(metav1.Now()) r.recorder.Eventf(discoveryRule, nil, corev1.EventTypeNormal, invv1alpha1.DiscoveryRuleKind, "ready", "") } - log.Debug("handleSuccess", "key", discoveryRule.GetNamespacedName(), "status new", discoveryRule.Status) + applyConfig := invv1alpha1apply.DiscoveryRule(discoveryRule.Name, discoveryRule.Namespace). + WithStatus(statusApply) - return r.client.Status().Patch(ctx, discoveryRule, patch, &client.SubResourcePatchOptions{ - PatchOptions: client.PatchOptions{ + return r.client.Status().Apply(ctx, applyConfig, &client.SubResourceApplyOptions{ + ApplyOptions: client.ApplyOptions{ FieldManager: reconcilerName, }, }) @@ -279,20 +287,28 @@ func (r *reconciler) handleSuccess(ctx context.Context, discoveryRule *invv1alph func (r *reconciler) handleError(ctx context.Context, discoveryRule *invv1alpha1.DiscoveryRule, msg string, err error) error { log := log.FromContext(ctx) - // take a snapshot of the current object - patch := client.MergeFrom(discoveryRule.DeepCopy()) - + if err != nil { msg = fmt.Sprintf("%s err %s", msg, err.Error()) } - discoveryRule.ManagedFields = nil - discoveryRule.Status.StartTime = ptr.To(metav1.Now()) - discoveryRule.SetConditions(condv1alpha1.Failed(msg)) + + newCond := condv1alpha1.Failed(msg) + oldCond := discoveryRule.GetCondition(condv1alpha1.ConditionTypeReady) + + // always update on error since StartTime changes + _ = oldCond + log.Error(msg) r.recorder.Eventf(discoveryRule, nil, corev1.EventTypeWarning, invv1alpha1.DiscoveryRuleKind, msg, "") - return r.client.Status().Patch(ctx, discoveryRule, patch, &client.SubResourcePatchOptions{ - PatchOptions: client.PatchOptions{ + applyConfig := invv1alpha1apply.DiscoveryRule(discoveryRule.Name, discoveryRule.Namespace). + WithStatus(invv1alpha1apply.DiscoveryRuleStatus(). + WithConditions(newCond). + WithStartTime(metav1.Now()), + ) + + return r.client.Status().Apply(ctx, applyConfig, &client.SubResourceApplyOptions{ + ApplyOptions: client.ApplyOptions{ FieldManager: reconcilerName, }, }) diff --git a/pkg/reconcilers/rollout/reconciler.go b/pkg/reconcilers/rollout/reconciler.go index 11586198..711c3a3d 100644 --- a/pkg/reconcilers/rollout/reconciler.go +++ b/pkg/reconcilers/rollout/reconciler.go @@ -32,6 +32,7 @@ import ( configapi "github.com/sdcio/config-server/apis/config" configv1alpha1 "github.com/sdcio/config-server/apis/config/v1alpha1" invv1alpha1 "github.com/sdcio/config-server/apis/inv/v1alpha1" + invv1alpha1apply "github.com/sdcio/config-server/pkg/generated/applyconfiguration/inv/v1alpha1" "github.com/sdcio/config-server/pkg/git/auth/secret" "github.com/sdcio/config-server/pkg/reconcilers" "github.com/sdcio/config-server/pkg/reconcilers/ctrlconfig" @@ -325,13 +326,18 @@ func (r *reconciler) handleStatus( err error, ) (ctrl.Result, error) { log := log.FromContext(ctx).With("ref", rollout.Spec.Ref) - patch := client.MergeFrom(rollout.DeepCopy()) + if err != nil { condition.Message = fmt.Sprintf("%s err %s", condition.Message, err.Error()) } - rollout.ManagedFields = nil - rollout.SetConditions(condition) - rollout.Status.Targets = getTargetStatus(ctx, targetStatus) + + newTargets := getTargetStatus(ctx, targetStatus) + oldCond := rollout.GetCondition(condv1alpha1.ConditionType(condition.Type)) + + if condition.Equal(oldCond) && reflect.DeepEqual(newTargets, rollout.Status.Targets) { + log.Info("handleStatus -> no change") + return ctrl.Result{Requeue: requeue}, nil + } if condition.Type == string(condv1alpha1.ConditionTypeReady) { r.recorder.Eventf(rollout, nil, corev1.EventTypeNormal, crName, fmt.Sprintf("ready ref %s", rollout.Spec.Ref), "") @@ -339,9 +345,17 @@ func (r *reconciler) handleStatus( log.Error(condition.Message) r.recorder.Eventf(rollout, nil, corev1.EventTypeWarning, crName, condition.Message, "") } + + statusApply := invv1alpha1apply.RolloutStatus(). + WithConditions(condition). + WithTargets(rolloutTargetStatusToApply(newTargets)...) + + applyConfig := invv1alpha1apply.Rollout(rollout.Name, rollout.Namespace). + WithStatus(statusApply) + result := ctrl.Result{Requeue: requeue} - return result, pkgerrors.Wrap(r.client.Status().Patch(ctx, rollout, patch, &client.SubResourcePatchOptions{ - PatchOptions: client.PatchOptions{ + return result, pkgerrors.Wrap(r.client.Status().Apply(ctx, applyConfig, &client.SubResourceApplyOptions{ + ApplyOptions: client.ApplyOptions{ FieldManager: reconcilerName, }, }), errUpdateStatus) @@ -367,3 +381,13 @@ func getTargetStatus(ctx context.Context, storeTargetStatus storebackend.Storer[ }) return targetStatus } + +func rolloutTargetStatusToApply(targets []invv1alpha1.RolloutTargetStatus) []*invv1alpha1apply.RolloutTargetStatusApplyConfiguration { + result := make([]*invv1alpha1apply.RolloutTargetStatusApplyConfiguration, 0, len(targets)) + for _, t := range targets { + result = append(result, invv1alpha1apply.RolloutTargetStatus(). + WithName(t.Name), + ) + } + return result +} diff --git a/pkg/reconcilers/schema/reconciler.go b/pkg/reconcilers/schema/reconciler.go index 27995ff7..f7de0f95 100644 --- a/pkg/reconcilers/schema/reconciler.go +++ b/pkg/reconcilers/schema/reconciler.go @@ -27,6 +27,7 @@ import ( pkgerrors "github.com/pkg/errors" condv1alpha1 "github.com/sdcio/config-server/apis/condition/v1alpha1" invv1alpha1 "github.com/sdcio/config-server/apis/inv/v1alpha1" + invv1alpha1apply "github.com/sdcio/config-server/pkg/generated/applyconfiguration/inv/v1alpha1" sdcerrors "github.com/sdcio/config-server/pkg/errors" "github.com/sdcio/config-server/pkg/git/auth/secret" "github.com/sdcio/config-server/pkg/reconcilers" @@ -249,18 +250,31 @@ func (r *reconciler) Reconcile(ctx context.Context, req ctrl.Request) (ctrl.Resu func (r *reconciler) handleSuccess(ctx context.Context, schema *invv1alpha1.Schema, updatedStatus *invv1alpha1.SchemaStatus) (ctrl.Result, error) { log := log.FromContext(ctx) log.Debug("handleSuccess", "key", schema.GetNamespacedName(), "status old", schema.DeepCopy().Status) - // take a snapshot of the current object - patch := client.MergeFrom(schema.DeepCopy()) - // update status - schema.Status = *updatedStatus - //schema.ManagedFields = nil - schema.SetConditions(condv1alpha1.Ready()) + + newCond := condv1alpha1.Ready() + oldCond := schema.GetCondition(condv1alpha1.ConditionTypeReady) + + // no-change guard includes both condition and repositories + if newCond.Equal(oldCond) && reflect.DeepEqual(updatedStatus.Repositories, schema.Status.Repositories) { + log.Info("handleSuccess -> no change") + return ctrl.Result{}, nil + } + r.recorder.Eventf(schema, nil, corev1.EventTypeNormal, invv1alpha1.SchemaKind, "ready", "") - log.Debug("handleSuccess", "key", schema.GetNamespacedName(), "status new", schema.Status) + statusApply := invv1alpha1apply.SchemaStatus(). + WithConditions(newCond) + + // only set repositories if populated + if len(updatedStatus.Repositories) > 0 { + statusApply = statusApply.WithRepositories(repoStatusToApply(updatedStatus.Repositories)...) + } + + applyConfig := invv1alpha1apply.Schema(schema.Name, schema.Namespace). + WithStatus(statusApply) - return ctrl.Result{}, pkgerrors.Wrap(r.client.Status().Patch(ctx, schema, patch, &client.SubResourcePatchOptions{ - PatchOptions: client.PatchOptions{ + return ctrl.Result{}, pkgerrors.Wrap(r.client.Status().Apply(ctx, applyConfig, &client.SubResourceApplyOptions{ + ApplyOptions: client.ApplyOptions{ FieldManager: reconcilerName, }, }), errUpdateStatus) @@ -269,26 +283,51 @@ func (r *reconciler) handleSuccess(ctx context.Context, schema *invv1alpha1.Sche func (r *reconciler) handleError(ctx context.Context, schema *invv1alpha1.Schema, msg string, err error) (ctrl.Result, error) { log := log.FromContext(ctx) - // take a snapshot of the current object - patch := client.MergeFrom(schema.DeepCopy()) - if err != nil { msg = fmt.Sprintf("%s err %s", msg, err.Error()) } - schema.ManagedFields = nil - schema.SetConditions(condv1alpha1.Failed(msg)) + + newCond := condv1alpha1.Failed(msg) + oldCond := schema.GetCondition(condv1alpha1.ConditionTypeReady) + + if newCond.Equal(oldCond) { + log.Info("handleError -> no change") + return ctrl.Result{}, nil + } + log.Error(msg) r.recorder.Eventf(schema, nil, corev1.EventTypeWarning, crName, msg, "") + applyConfig := invv1alpha1apply.Schema(schema.Name, schema.Namespace). + WithStatus(invv1alpha1apply.SchemaStatus(). + WithConditions(newCond), + ) + var unrecoverableError *sdcerrors.UnrecoverableError result := ctrl.Result{} if errors.As(err, &unrecoverableError) { - result = ctrl.Result{Requeue: false} // unrecoverable error - setting an error here would result in ignoring a request to not requeue + result = ctrl.Result{Requeue: false} } - return result, pkgerrors.Wrap(r.client.Status().Patch(ctx, schema, patch, &client.SubResourcePatchOptions{ - PatchOptions: client.PatchOptions{ + return result, pkgerrors.Wrap(r.client.Status().Apply(ctx, applyConfig, &client.SubResourceApplyOptions{ + ApplyOptions: client.ApplyOptions{ FieldManager: reconcilerName, }, }), errUpdateStatus) } + + +func repoStatusToApply(repos []invv1alpha1.SchemaRepositoryStatus) []*invv1alpha1apply.SchemaRepositoryStatusApplyConfiguration { + result := make([]*invv1alpha1apply.SchemaRepositoryStatusApplyConfiguration, 0, len(repos)) + for _, r := range repos { + a := invv1alpha1apply.SchemaRepositoryStatus() + if r.RepoURL != "" { + a.WithRepoURL(r.RepoURL) + } + if r.Reference != "" { + a.WithReference(r.Reference) + } + result = append(result, a) + } + return result +} \ No newline at end of file diff --git a/pkg/reconcilers/subscription/reconciler.go b/pkg/reconcilers/subscription/reconciler.go index 293266d0..3748b372 100644 --- a/pkg/reconcilers/subscription/reconciler.go +++ b/pkg/reconcilers/subscription/reconciler.go @@ -25,6 +25,7 @@ import ( pkgerrors "github.com/pkg/errors" condv1alpha1 "github.com/sdcio/config-server/apis/condition/v1alpha1" invv1alpha1 "github.com/sdcio/config-server/apis/inv/v1alpha1" + invv1alpha1apply "github.com/sdcio/config-server/pkg/generated/applyconfiguration/inv/v1alpha1" "github.com/sdcio/config-server/pkg/reconcilers" "github.com/sdcio/config-server/pkg/reconcilers/ctrlconfig" "github.com/sdcio/config-server/pkg/reconcilers/eventhandler" @@ -125,17 +126,26 @@ func (r *reconciler) Reconcile(ctx context.Context, req ctrl.Request) (ctrl.Resu func (r *reconciler) handleSuccess(ctx context.Context, state *invv1alpha1.Subscription, targets []string) (ctrl.Result, error) { log := log.FromContext(ctx) log.Debug("handleSuccess", "key", state.GetNamespacedName(), "status old", state.DeepCopy().Status) - // take a snapshot of the current object - patch := client.MergeFrom(state.DeepCopy()) - // update status - state.SetConditions(condv1alpha1.Ready()) - state.SetTargets(targets) + + newCond := condv1alpha1.Ready() + oldCond := state.GetCondition(condv1alpha1.ConditionTypeReady) + + // no-change guard + if newCond.Equal(oldCond) && reflect.DeepEqual(targets, state.Status.Targets) { + log.Info("handleSuccess -> no change") + return ctrl.Result{}, nil + } + r.recorder.Eventf(state, nil, corev1.EventTypeNormal, invv1alpha1.SubscriptionKind, "ready", "") - log.Debug("handleSuccess", "key", state.GetNamespacedName(), "status new", state.Status) - - return ctrl.Result{}, pkgerrors.Wrap(r.client.Status().Patch(ctx, state, patch, &client.SubResourcePatchOptions{ - PatchOptions: client.PatchOptions{ + applyConfig := invv1alpha1apply.Subscription(state.Name, state.Namespace). + WithStatus(invv1alpha1apply.SubscriptionStatus(). + WithConditions(newCond). + WithTargets(targets...), + ) + + return ctrl.Result{}, pkgerrors.Wrap(r.client.Status().Apply(ctx, applyConfig, &client.SubResourceApplyOptions{ + ApplyOptions: client.ApplyOptions{ FieldManager: reconcilerName, }, }), errUpdateStatus) @@ -144,19 +154,28 @@ func (r *reconciler) handleSuccess(ctx context.Context, state *invv1alpha1.Subsc func (r *reconciler) handleError(ctx context.Context, state *invv1alpha1.Subscription, msg string, err error) (ctrl.Result, error) { log := log.FromContext(ctx) - // take a snapshot of the current object - patch := client.MergeFrom(state.DeepCopy()) - if err != nil { msg = fmt.Sprintf("%s err %s", msg, err.Error()) } - state.ManagedFields = nil - state.SetConditions(condv1alpha1.Failed(msg)) + + newCond := condv1alpha1.Failed(msg) + oldCond := state.GetCondition(condv1alpha1.ConditionTypeReady) + + if newCond.Equal(oldCond) { + log.Info("handleError -> no change") + return ctrl.Result{}, nil + } + log.Error(msg) r.recorder.Eventf(state, nil, corev1.EventTypeWarning, crName, msg, "") - return ctrl.Result{}, pkgerrors.Wrap(r.client.Status().Patch(ctx, state, patch, &client.SubResourcePatchOptions{ - PatchOptions: client.PatchOptions{ + applyConfig := invv1alpha1apply.Subscription(state.Name, state.Namespace). + WithStatus(invv1alpha1apply.SubscriptionStatus(). + WithConditions(newCond), + ) + + return ctrl.Result{}, pkgerrors.Wrap(r.client.Status().Apply(ctx, applyConfig, &client.SubResourceApplyOptions{ + ApplyOptions: client.ApplyOptions{ FieldManager: reconcilerName, }, }), errUpdateStatus) diff --git a/pkg/reconcilers/target/reconciler.go b/pkg/reconcilers/target/reconciler.go index a3b340ad..4405dc99 100644 --- a/pkg/reconcilers/target/reconciler.go +++ b/pkg/reconcilers/target/reconciler.go @@ -28,12 +28,13 @@ import ( "github.com/sdcio/config-server/pkg/reconcilers/ctrlconfig" "github.com/sdcio/config-server/pkg/reconcilers/resource" corev1 "k8s.io/api/core/v1" - metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/apimachinery/pkg/runtime/schema" "k8s.io/client-go/tools/events" ctrl "sigs.k8s.io/controller-runtime" "sigs.k8s.io/controller-runtime/pkg/client" "sigs.k8s.io/controller-runtime/pkg/event" + + invv1alpha1apply "github.com/sdcio/config-server/pkg/generated/applyconfiguration/inv/v1alpha1" ) func init() { @@ -107,21 +108,8 @@ func (r *reconciler) updateCondition(ctx context.Context, target *invv1alpha1.Ta log := log.FromContext(ctx) log.Debug("handleSuccess", "key", target.GetNamespacedName(), "status old", target.DeepCopy().Status) - patch := client.MergeFrom(target.DeepCopy()) - // Build SSA patch object for /status - newTarget := invv1alpha1.BuildTarget( - metav1.ObjectMeta{ - Namespace: target.Namespace, - Name: target.Name, - }, - invv1alpha1.TargetSpec{}, - invv1alpha1.TargetStatus{}, - ) - // set new conditions - newTarget.SetOverallStatus(target) - oldCond := target.GetCondition(condv1alpha1.ConditionTypeReady) - newCond := newTarget.GetCondition(condv1alpha1.ConditionTypeReady) + newCond := invv1alpha1.GetOverallStatus(target) changed = !newCond.Equal(oldCond) newReady = newCond.IsTrue() @@ -135,13 +123,18 @@ func (r *reconciler) updateCondition(ctx context.Context, target *invv1alpha1.Ta // Optional: emit different event types if newReady { - r.recorder.Eventf(newTarget, nil, corev1.EventTypeNormal, invv1alpha1.TargetKind, "ready", "") + r.recorder.Eventf(target, nil, corev1.EventTypeNormal, invv1alpha1.TargetKind, "ready", "") } else { - r.recorder.Eventf(newTarget, nil, corev1.EventTypeWarning, invv1alpha1.TargetKind, "not ready", "") + r.recorder.Eventf(target, nil, corev1.EventTypeWarning, invv1alpha1.TargetKind, "not ready", "") } - if err := r.client.Status().Patch(ctx, newTarget, patch, &client.SubResourcePatchOptions{ - PatchOptions: client.PatchOptions{ + applyConfig := invv1alpha1apply.Target(target.Name, target.Namespace). + WithStatus(invv1alpha1apply.TargetStatus(). + WithConditions(newCond), + ) + + if err := r.client.Status().Apply(ctx, applyConfig, &client.SubResourceApplyOptions{ + ApplyOptions: client.ApplyOptions{ FieldManager: reconcilerName, }, }); err != nil { diff --git a/pkg/reconcilers/targetdatastore/reconciler.go b/pkg/reconcilers/targetdatastore/reconciler.go index b4974c5d..f4d1d9b4 100644 --- a/pkg/reconcilers/targetdatastore/reconciler.go +++ b/pkg/reconcilers/targetdatastore/reconciler.go @@ -27,6 +27,7 @@ import ( "github.com/pkg/errors" condv1alpha1 "github.com/sdcio/config-server/apis/condition/v1alpha1" invv1alpha1 "github.com/sdcio/config-server/apis/inv/v1alpha1" + invv1alpha1apply "github.com/sdcio/config-server/pkg/generated/applyconfiguration/inv/v1alpha1" "github.com/sdcio/config-server/pkg/reconcilers" "github.com/sdcio/config-server/pkg/reconcilers/ctrlconfig" "github.com/sdcio/config-server/pkg/reconcilers/eventhandler" @@ -212,42 +213,30 @@ func (r *reconciler) handleSuccess(ctx context.Context, target *invv1alpha1.Targ log := log.FromContext(ctx) //log.Info("handleSuccess", "key", target.GetNamespacedName(), "status old", target.DeepCopy().Status) // take a snapshot of the current object - patch := client.MergeFrom(target.DeepCopy()) - // update status - newTarget := invv1alpha1.BuildTarget( - metav1.ObjectMeta{ - Namespace: target.Namespace, - Name: target.Name, - }, - invv1alpha1.TargetSpec{}, - invv1alpha1.TargetStatus{}, - ) - // set new conditions - newTarget.SetConditions(invv1alpha1.DatastoreReady()) - newTarget.Status.UsedReferences = usedRefs - + newCond := invv1alpha1.DatastoreReady() oldCond := target.GetCondition(invv1alpha1.ConditionTypeDatastoreReady) - newCond := newTarget.GetCondition(invv1alpha1.ConditionTypeDatastoreReady) - - changed := !newCond.Equal(oldCond) // we don't update the resource if no condition changed - if !changed && - equality.Semantic.DeepEqual(newTarget.Status.UsedReferences, target.Status.UsedReferences) { + if newCond.Equal(oldCond) && + equality.Semantic.DeepEqual(usedRefs, target.Status.UsedReferences) { log.Info("handleSuccess -> no change") return nil } log.Info("handleSuccess", - "condition change", newTarget.GetCondition(invv1alpha1.ConditionTypeDatastoreReady).Equal(target.GetCondition(invv1alpha1.ConditionTypeDatastoreReady)), - "shared ref change", equality.Semantic.DeepEqual(newTarget.Status.UsedReferences, target.Status.UsedReferences), + "condition change", !newCond.Equal(oldCond), + "usedRefs change", !equality.Semantic.DeepEqual(usedRefs, target.Status.UsedReferences), ) - r.recorder.Eventf(newTarget, nil, corev1.EventTypeNormal, invv1alpha1.TargetKind, "datastore ready", "") + r.recorder.Eventf(target, nil, corev1.EventTypeNormal, invv1alpha1.TargetKind, "datastore ready", "") - log.Debug("handleSuccess", "key", newTarget.GetNamespacedName(), "status new", target.Status) + applyConfig := invv1alpha1apply.Target(target.Name, target.Namespace). + WithStatus(invv1alpha1apply.TargetStatus(). + WithConditions(newCond). + WithUsedReferences(usedRefsToApply(usedRefs)), + ) - return r.client.Status().Patch(ctx, newTarget, patch, &client.SubResourcePatchOptions{ - PatchOptions: client.PatchOptions{ + return r.client.Status().Apply(ctx, applyConfig, &client.SubResourceApplyOptions{ + ApplyOptions: client.ApplyOptions{ FieldManager: reconcilerName, }, }) @@ -255,49 +244,40 @@ func (r *reconciler) handleSuccess(ctx context.Context, target *invv1alpha1.Targ func (r *reconciler) handleError(ctx context.Context, target *invv1alpha1.Target, msg string, err error, resetUsedRefs bool) error { log := log.FromContext(ctx) - // take a snapshot of the current object - patch := client.MergeFrom(target.DeepCopy()) if err != nil { msg = fmt.Sprintf("%s err %s", msg, err.Error()) } - newTarget := invv1alpha1.BuildTarget( - metav1.ObjectMeta{ - Namespace: target.Namespace, - Name: target.Name, - }, - invv1alpha1.TargetSpec{}, - invv1alpha1.TargetStatus{}, - ) - - // set new conditions - newTarget.SetConditions(invv1alpha1.DatastoreFailed(msg)) - //target.SetOverallStatus() - if resetUsedRefs { - newTarget.Status.UsedReferences = nil - } + newCond := invv1alpha1.DatastoreFailed(msg) oldCond := target.GetCondition(invv1alpha1.ConditionTypeDatastoreReady) - newCond := newTarget.GetCondition(invv1alpha1.ConditionTypeDatastoreReady) - changed := !newCond.Equal(oldCond) + var newUsedRefs *invv1alpha1.TargetStatusUsedReferences + if !resetUsedRefs { + newUsedRefs = target.Status.UsedReferences + } - // we don't update the resource if no condition changed - if !changed && - equality.Semantic.DeepEqual(newTarget.Status.UsedReferences, target.Status.UsedReferences) { + if newCond.Equal(oldCond) && + equality.Semantic.DeepEqual(newUsedRefs, target.Status.UsedReferences) { log.Info("handleError -> no change") return nil } + log.Info("handleError", - "condition change", newTarget.GetCondition(invv1alpha1.ConditionTypeDatastoreReady).Equal(target.GetCondition(invv1alpha1.ConditionTypeDatastoreReady)), - "shared ref change", equality.Semantic.DeepEqual(newTarget.Status.UsedReferences, target.Status.UsedReferences), + "condition change", !newCond.Equal(oldCond), + "usedRefs change", !equality.Semantic.DeepEqual(newUsedRefs, target.Status.UsedReferences), ) - log.Error(msg, "error", err) - r.recorder.Eventf(newTarget, nil, corev1.EventTypeWarning, invv1alpha1.TargetKind, msg, "") + r.recorder.Eventf(target, nil, corev1.EventTypeWarning, invv1alpha1.TargetKind, msg, "") + + applyConfig := invv1alpha1apply.Target(target.Name, target.Namespace). + WithStatus(invv1alpha1apply.TargetStatus(). + WithConditions(newCond). + WithUsedReferences(usedRefsToApply(newUsedRefs)), + ) - return r.client.Status().Patch(ctx, newTarget, patch, &client.SubResourcePatchOptions{ - PatchOptions: client.PatchOptions{ + return r.client.Status().Apply(ctx, applyConfig, &client.SubResourceApplyOptions{ + ApplyOptions: client.ApplyOptions{ FieldManager: reconcilerName, }, }) @@ -455,3 +435,24 @@ func (r *reconciler) getCreateDataStoreRequest(ctx context.Context, target *invv return req, usedReferences, nil } + + +func usedRefsToApply(refs *invv1alpha1.TargetStatusUsedReferences) *invv1alpha1apply.TargetStatusUsedReferencesApplyConfiguration { + if refs == nil { + return nil + } + a := invv1alpha1apply.TargetStatusUsedReferences() + if refs.SecretResourceVersion != "" { + a.WithSecretResourceVersion(refs.SecretResourceVersion) + } + if refs.TLSSecretResourceVersion != "" { + a.WithTLSSecretResourceVersion(refs.TLSSecretResourceVersion) + } + if refs.ConnectionProfileResourceVersion != "" { + a.WithConnectionProfileResourceVersion(refs.ConnectionProfileResourceVersion) + } + if refs.SyncProfileResourceVersion != "" { + a.WithSyncProfileResourceVersion(refs.SyncProfileResourceVersion) + } + return a +} \ No newline at end of file diff --git a/pkg/reconcilers/targetrecovery/reconciler.go b/pkg/reconcilers/targetrecovery/reconciler.go index 38ffb444..468d8b1b 100644 --- a/pkg/reconcilers/targetrecovery/reconciler.go +++ b/pkg/reconcilers/targetrecovery/reconciler.go @@ -27,12 +27,12 @@ import ( "github.com/pkg/errors" configv1alpha1 "github.com/sdcio/config-server/apis/config/v1alpha1" invv1alpha1 "github.com/sdcio/config-server/apis/inv/v1alpha1" + invv1alpha1apply "github.com/sdcio/config-server/pkg/generated/applyconfiguration/inv/v1alpha1" "github.com/sdcio/config-server/pkg/reconcilers" "github.com/sdcio/config-server/pkg/reconcilers/ctrlconfig" "github.com/sdcio/config-server/pkg/reconcilers/resource" targetmanager "github.com/sdcio/config-server/pkg/sdc/target/manager" corev1 "k8s.io/api/core/v1" - metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/apimachinery/pkg/runtime/schema" "k8s.io/client-go/discovery" "k8s.io/client-go/tools/events" @@ -158,43 +158,28 @@ func (r *reconciler) Reconcile(ctx context.Context, req ctrl.Request) (ctrl.Resu func (r *reconciler) handleSuccess(ctx context.Context, target *invv1alpha1.Target, msg *string) error { log := log.FromContext(ctx) - log.Debug("handleSuccess", "key", target.GetNamespacedName(), "status old", target.DeepCopy().Status) - // take a snapshot of the current object - patch := client.MergeFrom(target.DeepCopy()) - // update status - newTarget := invv1alpha1.BuildTarget( - metav1.ObjectMeta{ - Namespace: target.Namespace, - Name: target.Name, - }, - invv1alpha1.TargetSpec{}, - invv1alpha1.TargetStatus{}, - ) - // set new conditions newMsg := "" if msg != nil { newMsg = *msg } - newTarget.SetConditions(invv1alpha1.ConfigReady(newMsg)) - + newCond := invv1alpha1.ConfigReady(newMsg) oldCond := target.GetCondition(invv1alpha1.ConditionTypeConfigRecoveryReady) - newCond := newTarget.GetCondition(invv1alpha1.ConditionTypeConfigRecoveryReady) - - changed := !newCond.Equal(oldCond) - // we don't update the resource if no condition changed - if !changed { - // we don't update the resource if no condition changed + if newCond.Equal(oldCond) { log.Info("handleSuccess -> no change") return nil } - log.Info("handleSuccess -> change", - "condition change", newTarget.GetCondition(invv1alpha1.ConditionTypeConfigRecoveryReady).Equal(target.GetCondition(invv1alpha1.ConditionTypeConfigRecoveryReady))) - r.recorder.Eventf(newTarget, nil, corev1.EventTypeNormal, invv1alpha1.TargetKind, "config recovery ready", "") + log.Info("handleSuccess -> change", "condition change", true) + r.recorder.Eventf(target, nil, corev1.EventTypeNormal, invv1alpha1.TargetKind, "config recovery ready", "") - return r.client.Status().Patch(ctx, newTarget, patch, &client.SubResourcePatchOptions{ - PatchOptions: client.PatchOptions{ + applyConfig := invv1alpha1apply.Target(target.Name, target.Namespace). + WithStatus(invv1alpha1apply.TargetStatus(). + WithConditions(newCond), + ) + + return r.client.Status().Apply(ctx, applyConfig, &client.SubResourceApplyOptions{ + ApplyOptions: client.ApplyOptions{ FieldManager: reconcilerName, }, }) @@ -202,41 +187,29 @@ func (r *reconciler) handleSuccess(ctx context.Context, target *invv1alpha1.Targ func (r *reconciler) handleError(ctx context.Context, target *invv1alpha1.Target, msg string, err error) error { log := log.FromContext(ctx) - // take a snapshot of the current object - patch := client.MergeFrom(target.DeepCopy()) if err != nil { msg = fmt.Sprintf("%s err %s", msg, err.Error()) } - newTarget := invv1alpha1.BuildTarget( - metav1.ObjectMeta{ - Namespace: target.Namespace, - Name: target.Name, - }, - invv1alpha1.TargetSpec{}, - invv1alpha1.TargetStatus{}, - ) - // set new conditions - newTarget.SetConditions(invv1alpha1.ConfigFailed(msg)) - - log.Warn(msg, "error", err) + newCond := invv1alpha1.ConfigFailed(msg) oldCond := target.GetCondition(invv1alpha1.ConditionTypeConfigRecoveryReady) - newCond := newTarget.GetCondition(invv1alpha1.ConditionTypeConfigRecoveryReady) - - changed := !newCond.Equal(oldCond) - if !changed { - // we don't update the resource if no condition changed + if newCond.Equal(oldCond) { log.Info("handleError -> no change") return nil } - r.recorder.Eventf(newTarget, nil, corev1.EventTypeWarning, invv1alpha1.TargetKind, msg, "") - log.Info("handleError -> change", - "condition change", newTarget.GetCondition(invv1alpha1.ConditionTypeConfigRecoveryReady).Equal(target.GetCondition(invv1alpha1.ConditionTypeConfigRecoveryReady))) + log.Warn(msg, "error", err) + log.Info("handleError -> change", "condition change", true) + r.recorder.Eventf(target, nil, corev1.EventTypeWarning, invv1alpha1.TargetKind, msg, "") + + applyConfig := invv1alpha1apply.Target(target.Name, target.Namespace). + WithStatus(invv1alpha1apply.TargetStatus(). + WithConditions(newCond), + ) - return r.client.Status().Patch(ctx, newTarget, patch, &client.SubResourcePatchOptions{ - PatchOptions: client.PatchOptions{ + return r.client.Status().Apply(ctx, applyConfig, &client.SubResourceApplyOptions{ + ApplyOptions: client.ApplyOptions{ FieldManager: reconcilerName, }, }) diff --git a/pkg/reconcilers/workspace/reconciler.go b/pkg/reconcilers/workspace/reconciler.go index 9f424375..0decb50c 100644 --- a/pkg/reconcilers/workspace/reconciler.go +++ b/pkg/reconcilers/workspace/reconciler.go @@ -25,6 +25,7 @@ import ( "github.com/pkg/errors" condv1alpha1 "github.com/sdcio/config-server/apis/condition/v1alpha1" invv1alpha1 "github.com/sdcio/config-server/apis/inv/v1alpha1" + invv1alpha1apply "github.com/sdcio/config-server/pkg/generated/applyconfiguration/inv/v1alpha1" "github.com/sdcio/config-server/pkg/git/auth/secret" "github.com/sdcio/config-server/pkg/reconcilers" "github.com/sdcio/config-server/pkg/reconcilers/ctrlconfig" @@ -177,16 +178,15 @@ func (r *reconciler) handleStatus( ) (ctrl.Result, error) { log := log.FromContext(ctx) - patch := client.MergeFrom(workspace.DeepCopy()) - if err != nil { condition.Message = fmt.Sprintf("%s err %s", condition.Message, err.Error()) } - workspace.ManagedFields = nil - workspace.SetConditions(condition) + oldCond := workspace.GetCondition(condv1alpha1.ConditionType(condition.Type)) + if condition.Equal(oldCond) { + return ctrl.Result{Requeue: requeue}, nil + } - // Determine event type based on condition type if condition.Type == string(condv1alpha1.ConditionTypeReady) { r.recorder.Eventf(workspace, nil, corev1.EventTypeNormal, crName, fmt.Sprintf("ready ref %s", workspace.Spec.Ref), "") } else { @@ -194,89 +194,15 @@ func (r *reconciler) handleStatus( r.recorder.Eventf(workspace, nil, corev1.EventTypeWarning, crName, condition.Message, "") } - result := ctrl.Result{Requeue: requeue} - return result, errors.Wrap(r.client.Status().Patch(ctx, workspace, patch, &client.SubResourcePatchOptions{ - PatchOptions: client.PatchOptions{ - FieldManager: reconcilerName, - }, - }), errUpdateStatus) -} - -/* - -func (r *reconciler) handleSuccess(ctx context.Context, workspace *invv1alpha1.Workspace) (ctrl.Result, error) { - log := log.FromContext(ctx) - log.Debug("handleSuccess", "key", workspace.GetNamespacedName(), "status old", workspace.DeepCopy().Status) - // take a snapshot of the current object - patch := client.MergeFrom(workspace.DeepCopy()) - // update status - workspace.SetConditions(condv1alpha1.Ready()) - r.recorder.Eventf(workspace, corev1.EventTypeNormal, crName, "ready") - - log.Debug("handleSuccess", "key", workspace.GetNamespacedName(), "status new", workspace.Status) - - return ctrl.Result{}, errors.Wrap(r.Client.Status().Patch(ctx, workspace, patch, &client.SubResourcePatchOptions{ - PatchOptions: client.PatchOptions{ - FieldManager: reconcilerName, - }, - }), errUpdateStatus) -} - -func (r *reconciler) handleFailed(ctx context.Context, workspace *invv1alpha1.Workspace, msg string) (ctrl.Result, error) { - log := log.FromContext(ctx) - log.Debug("handleFailure", "key", workspace.GetNamespacedName(), "status old", workspace.DeepCopy().Status) - // take a snapshot of the current object - patch := client.MergeFrom(workspace.DeepCopy()) - // update status - workspace.SetConditions(condv1alpha1.Failed(msg)) - r.recorder.Eventf(workspace, corev1.EventTypeNormal, crName, "failed") - - log.Debug("handleFailure", "key", workspace.GetNamespacedName(), "status new", workspace.Status) - - return ctrl.Result{}, errors.Wrap(r.Client.Status().Patch(ctx, workspace, patch, &client.SubResourcePatchOptions{ - PatchOptions: client.PatchOptions{ - FieldManager: reconcilerName, - }, - }), errUpdateStatus) -} - -func (r *reconciler) handleRollout(ctx context.Context, workspace *invv1alpha1.Workspace, msg string) (ctrl.Result, error) { - log := log.FromContext(ctx) - - // take a snapshot of the current object - patch := client.MergeFrom(workspace.DeepCopy()) - - workspace.SetConditions(condv1alpha1.Rollout(msg)) - log.Debug(msg) - r.recorder.Eventf(workspace, corev1.EventTypeNormal, crName, msg) - - result := ctrl.Result{} - return result, errors.Wrap(r.Client.Status().Patch(ctx, workspace, patch, &client.SubResourcePatchOptions{ - PatchOptions: client.PatchOptions{ - FieldManager: reconcilerName, - }, - }), errUpdateStatus) -} - -func (r *reconciler) handleError(ctx context.Context, workspace *invv1alpha1.Workspace, msg string, err error) (ctrl.Result, error) { - log := log.FromContext(ctx) - - // take a snapshot of the current object - patch := client.MergeFrom(workspace.DeepCopy()) - - if err != nil { - msg = fmt.Sprintf("%s err %s", msg, err.Error()) - } - - workspace.SetConditions(condv1alpha1.Failed(msg)) - log.Error(msg) - r.recorder.Eventf(workspace, corev1.EventTypeWarning, crName, msg) + applyConfig := invv1alpha1apply.Workspace(workspace.Name, workspace.Namespace). + WithStatus(invv1alpha1apply.WorkspaceStatus(). + WithConditions(condition), + ) - result := ctrl.Result{Requeue: true} - return result, errors.Wrap(r.Client.Status().Patch(ctx, workspace, patch, &client.SubResourcePatchOptions{ - PatchOptions: client.PatchOptions{ + result := ctrl.Result{Requeue: requeue} + return result, errors.Wrap(r.client.Status().Apply(ctx, applyConfig, &client.SubResourceApplyOptions{ + ApplyOptions: client.ApplyOptions{ FieldManager: reconcilerName, }, }), errUpdateStatus) -} -*/ +} \ No newline at end of file diff --git a/pkg/sdc/ctx/schemaserver_context.go b/pkg/sdc/ctx/schemaserver_context.go deleted file mode 100644 index 6bce8f9a..00000000 --- a/pkg/sdc/ctx/schemaserver_context.go +++ /dev/null @@ -1,152 +0,0 @@ -/* -Copyright 2024 Nokia. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ - -package sdcctx - -/* - -import ( - "context" - "os" - "time" - - "github.com/henderiw/apiserver-store/pkg/storebackend" - "github.com/henderiw/logger/log" - invv1alpha1 "github.com/sdcio/config-server/apis/inv/v1alpha1" - ssclient "github.com/sdcio/config-server/pkg/sdc/schemaserver/client" - "sigs.k8s.io/controller-runtime/pkg/client" -) - -type SSContext struct { - Config *ssclient.Config - SSClient ssclient.Client // schemaserver client - client client.Client - cancelWatch context.CancelFunc -} - -const ( - localDataServerAddress = "localhost:56000" - SchemaServerAddress = "data-server-0.schema-server.sdc-system.svc.cluster.local:56000" -) - -func CreateSchemaServerClient(ctx context.Context, schemaServerStore storebackend.Storer[SSContext], client client.Client) error { - log := log.FromContext(ctx) - - // For the schema server we first check if the SDC_SCHEMA_SERVER was et if not we could also use - // the SDC_DATA_SERVER as fallback. If none are set it is the default address (localhost) - schemaServerAddress := SchemaServerAddress - if address, found := os.LookupEnv("SDC_SCHEMA_SERVER"); found { - schemaServerAddress = address - } else { - if address, found := os.LookupEnv("SDC_DATA_SERVER"); found { - schemaServerAddress = address - } - } - - ssConfig := &ssclient.Config{ - Address: schemaServerAddress, - } - ssClient, err := ssclient.New(ssConfig) - if err != nil { - log.Error("cannot initialize schemaserver client", "err", err) - return err - } - if err := ssClient.Start(ctx); err != nil { - log.Error("cannot start schemaserver client", "err", err) - return err - } - - watchCtx, cancelWatch := context.WithCancel(ctx) - ssCtx := SSContext{ - Config: ssConfig, - SSClient: ssClient, - cancelWatch: cancelWatch, - client: client, - } - - go ssCtx.watchSchemaServerConnection(watchCtx) - - if err := schemaServerStore.Create(ctx, storebackend.ToKey(schemaServerAddress), ssCtx); err != nil { - log.Error("cannot store schema context in schemaserver", "err", err) - return err - } - log.Info("schemaserver client created") - return nil -} - -func (r *SSContext) watchSchemaServerConnection(ctx context.Context) { - log := log.FromContext(ctx) - prevState := r.SSClient.IsConnectionReady() - - ticker := time.NewTicker(10 * time.Second) - defer ticker.Stop() - - for { - select { - case <-ctx.Done(): - log.Info("Stopping schema server connection watcher") - return - case <-ticker.C: - currentState := r.SSClient.IsConnectionReady() - if currentState != prevState { - log.Info("Schema server connection state changed", "ready", currentState) - - schemaList := &invv1alpha1.SchemaList{} - if err := r.client.List(ctx, schemaList); err != nil { - log.Error("cannot get schemas", "error", err) - } - - for _, schema := range schemaList.Items { - patch := client.MergeFrom(schema.DeepCopy()) - if currentState { - schema.SetConditions(invv1alpha1.SchemaServerReady()) - } else { - schema.SetConditions(invv1alpha1.SchemaServerFailed()) - } - if err := r.client.Status().Patch(ctx, &schema, patch, &client.SubResourcePatchOptions{ - PatchOptions: client.PatchOptions{ - FieldManager: "schema server watcher", - }, - }); err != nil { - log.Error("cannot get schemas", "error", err) - } - } - prevState = currentState - } - } - } -} - -func DeleteSchemaServerClient(ctx context.Context, schemaServerStore storebackend.Storer[SSContext], schemaServerAddress string) error { - log := log.FromContext(ctx) - - ssCtx, err := schemaServerStore.Get(ctx, storebackend.ToKey(schemaServerAddress)) - if err != nil { - log.Error("cannot retrieve schema context", "err", err) - return err - } - - ssCtx.cancelWatch() // Stop the watcher - - if err := schemaServerStore.Delete(ctx, storebackend.ToKey(schemaServerAddress)); err != nil { - log.Error("cannot delete schema context", "err", err) - return err - } - - log.Info("schemaserver client deleted") - return nil -} -*/ \ No newline at end of file diff --git a/pkg/sdc/target/manager/deviation_watcher.go b/pkg/sdc/target/manager/deviation_watcher.go index 6ddf6d06..0d9eed26 100644 --- a/pkg/sdc/target/manager/deviation_watcher.go +++ b/pkg/sdc/target/manager/deviation_watcher.go @@ -27,6 +27,7 @@ import ( "github.com/henderiw/logger/log" "github.com/pkg/errors" configv1alpha1 "github.com/sdcio/config-server/apis/config/v1alpha1" + configv1alpha1apply "github.com/sdcio/config-server/pkg/generated/applyconfiguration/config/v1alpha1" dsclient "github.com/sdcio/config-server/pkg/sdc/dataserver/client" sdcpb "github.com/sdcio/sdc-protos/sdcpb" "google.golang.org/grpc/codes" @@ -242,22 +243,17 @@ func (r *DeviationWatcher) processConfigDeviations( return deviations[i].Path < deviations[j].Path }) - deviation := &configv1alpha1.Deviation{} - if err := r.client.Get(ctx, nsn, deviation); err != nil { - log.Error("cannot get intent for recieved deviation", "config", nsn, "err", err) - return - } + applyConfig := configv1alpha1apply.Deviation(nsn.Name, nsn.Namespace). + WithSpec(configv1alpha1apply.DeviationSpec(). + WithDeviations(configDeviationsToApply(deviations)...), + ) log.Info("patch deviations", "nsn", nsn, "devs", len(deviations)) - patch := client.MergeFrom(deviation.DeepObjectCopy()) - - deviation.Spec.Deviations = deviations - - if err := r.client.Patch(ctx, deviation, patch, &client.PatchOptions{ + if err := r.client.Apply(ctx, applyConfig, &client.ApplyOptions{ FieldManager: fieldManagerDeviation, }); err != nil { - log.Error("cannot update intent for recieved deviation", "config", nsn) + log.Error("cannot update intent for received deviation", "config", nsn, "err", err) } } @@ -280,13 +276,14 @@ func (r *DeviationWatcher) clearTargetDeviation( log.Info("clear deviations", "nsn", nsn) - patch := client.MergeFrom(deviation.DeepObjectCopy()) - deviation.Spec.Deviations = nil + applyConfig := configv1alpha1apply.Deviation(nsn.Name, nsn.Namespace). + WithSpec(configv1alpha1apply.DeviationSpec()) + // empty spec with no deviations — SSA with Force will clear the field - if err := r.client.Patch(ctx, deviation, patch, &client.PatchOptions{ + if err := r.client.Apply(ctx, applyConfig, &client.ApplyOptions{ FieldManager: fieldManagerDeviation, }); err != nil { - log.Error("cannot update intent for recieved deviation", "config", nsn) + log.Error("cannot clear deviation", "config", nsn, "err", err) } } @@ -327,3 +324,21 @@ func getDeviationString(val *sdcpb.TypedValue) (*string, error) { } return v, nil } + + +func configDeviationsToApply(devs []configv1alpha1.ConfigDeviation) []*configv1alpha1apply.ConfigDeviationApplyConfiguration { + result := make([]*configv1alpha1apply.ConfigDeviationApplyConfiguration, 0, len(devs)) + for _, d := range devs { + a := configv1alpha1apply.ConfigDeviation(). + WithPath(d.Path). + WithReason(d.Reason) + if d.DesiredValue != nil { + a = a.WithDesiredValue(*d.DesiredValue) + } + if d.CurrentValue != nil { + a = a.WithCurrentValue(*d.CurrentValue) + } + result = append(result, a) + } + return result +} \ No newline at end of file diff --git a/pkg/sdc/target/manager/runtime.go b/pkg/sdc/target/manager/runtime.go index 6637cb61..3f943972 100644 --- a/pkg/sdc/target/manager/runtime.go +++ b/pkg/sdc/target/manager/runtime.go @@ -26,14 +26,15 @@ import ( //"github.com/henderiw/logger/log" "github.com/henderiw/apiserver-store/pkg/storebackend" "github.com/henderiw/logger/log" + condv1alpha1 "github.com/sdcio/config-server/apis/condition/v1alpha1" configv1alpha1 "github.com/sdcio/config-server/apis/config/v1alpha1" invv1alpha1 "github.com/sdcio/config-server/apis/inv/v1alpha1" dsclient "github.com/sdcio/config-server/pkg/sdc/dataserver/client" dsmanager "github.com/sdcio/config-server/pkg/sdc/dataserver/manager" + invv1alpha1apply "github.com/sdcio/config-server/pkg/generated/applyconfiguration/inv/v1alpha1" sdcpb "github.com/sdcio/sdc-protos/sdcpb" "google.golang.org/grpc/codes" "google.golang.org/grpc/status" - metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "sigs.k8s.io/controller-runtime/pkg/client" ) @@ -583,7 +584,6 @@ func (r *TargetRuntime) pushConnIfChanged(ctx context.Context, connected bool, m log.Info("pushConnIfChanged entry") r.statusMu.Lock() - // throttle flaps if r.lastConnValid && r.lastConn == connected && time.Since(r.lastPushed) < 2*time.Second { r.statusMu.Unlock() return @@ -593,35 +593,21 @@ func (r *TargetRuntime) pushConnIfChanged(ctx context.Context, connected bool, m r.lastConn = connected r.statusMu.Unlock() - // get from informer cache target := &invv1alpha1.Target{} if err := r.client.Get(ctx, r.key.NamespacedName, target); err != nil { log.Error("target fetch failed", "error", err) return } - newTarget := invv1alpha1.BuildTarget( - metav1.ObjectMeta{ - Namespace: target.Namespace, - Name: target.Name, - }, - invv1alpha1.TargetSpec{}, - invv1alpha1.TargetStatus{}, - ) - - // mutate only what you own in status - // (use your existing helpers, but mutate `target`, not a separate object) + var newCond condv1alpha1.Condition if connected { - newTarget.SetConditions(invv1alpha1.TargetConnectionReady()) + newCond = invv1alpha1.TargetConnectionReady() } else { - newTarget.SetConditions(invv1alpha1.TargetConnectionFailed(msg)) + newCond = invv1alpha1.TargetConnectionFailed(msg) } - // if no effective status change, skip write oldCond := target.GetCondition(invv1alpha1.ConditionTypeTargetConnectionReady) - newCond := newTarget.GetCondition(invv1alpha1.ConditionTypeTargetConnectionReady) - changed := !newCond.Equal(oldCond) - if !changed { + if newCond.Equal(oldCond) { log.Info("pushConnIfChanged -> no change", "connected", connected, "phase", r.Status().Phase, @@ -630,11 +616,13 @@ func (r *TargetRuntime) pushConnIfChanged(ctx context.Context, connected bool, m return } - // PATCH /status using MergeFrom + applyConfig := invv1alpha1apply.Target(target.Name, target.Namespace). + WithStatus(invv1alpha1apply.TargetStatus(). + WithConditions(newCond), + ) - patch := client.MergeFrom(target.DeepCopy()) - if err := r.client.Status().Patch(ctx, newTarget, patch, &client.SubResourcePatchOptions{ - PatchOptions: client.PatchOptions{ + if err := r.client.Status().Apply(ctx, applyConfig, &client.SubResourceApplyOptions{ + ApplyOptions: client.ApplyOptions{ FieldManager: fieldManagerTargetRuntime, }, }); err != nil { diff --git a/pkg/sdc/target/manager/transactor.go b/pkg/sdc/target/manager/transactor.go index 9c032f5b..e06703e6 100644 --- a/pkg/sdc/target/manager/transactor.go +++ b/pkg/sdc/target/manager/transactor.go @@ -30,6 +30,7 @@ import ( condv1alpha1 "github.com/sdcio/config-server/apis/condition/v1alpha1" "github.com/sdcio/config-server/apis/config" configv1alpha1 "github.com/sdcio/config-server/apis/config/v1alpha1" + configv1alpha1apply "github.com/sdcio/config-server/pkg/generated/applyconfiguration/config/v1alpha1" invv1alpha1 "github.com/sdcio/config-server/apis/inv/v1alpha1" "github.com/sdcio/config-server/pkg/reconcilers/resource" sdcpb "github.com/sdcio/sdc-protos/sdcpb" @@ -333,17 +334,14 @@ func (r *Transactor) updateConfigWithError(ctx context.Context, config *configv1 log := log.FromContext(ctx) log.Warn("updateConfigWithError", "config", config.GetName(), "recoverable", recoverable, "msg", msg, "err", err) - configOrig := config.DeepCopy() - patch := client.MergeFrom(configOrig) - if err != nil { msg = fmt.Sprintf("%s err %s", msg, err.Error()) } config.SetFinalizers([]string{finalizer}) + var cond condv1alpha1.Condition if recoverable { - // IMPRTANT TO USE THIS TYPE - config.SetConditions(configv1alpha1.ConfigFailed(msg)) + cond = configv1alpha1.ConfigFailed(msg) } else { newMessage := condv1alpha1.UnrecoverableMessage{ ResourceVersion: config.GetResourceVersion(), @@ -353,12 +351,22 @@ func (r *Transactor) updateConfigWithError(ctx context.Context, config *configv1 if err != nil { return err } - config.Status.DeviationGeneration = nil - config.SetConditions(condv1alpha1.FailedUnRecoverable(string(newmsg))) + cond = condv1alpha1.FailedUnRecoverable(string(newmsg)) } - return r.client.Status().Patch(ctx, config, patch, &client.SubResourcePatchOptions{ - PatchOptions: client.PatchOptions{ + statusApply := configv1alpha1apply.ConfigStatus(). + WithConditions(cond) + + if !recoverable { + // clear DeviationGeneration + statusApply = statusApply.WithDeviationGeneration(0) + } + + applyConfig := configv1alpha1apply.Config(config.Name, config.Namespace). + WithStatus(statusApply) + + return r.client.Status().Apply(ctx, applyConfig, &client.SubResourceApplyOptions{ + ApplyOptions: client.ApplyOptions{ FieldManager: r.fieldManager, }, }) @@ -391,26 +399,27 @@ func (r *Transactor) updateConfigWithSuccess( log := log.FromContext(ctx) log.Debug("updateConfigWithSuccess", "config", cfg.GetName()) - // THE TYPE IS IMPORTANT here cond := configv1alpha1.ConfigReady(msg) + overallCond := configv1alpha1.GetOverallCondition(cfg) - return r.patchStatusIfChanged(ctx, cfg, func(c *configv1alpha1.Config) { - c.SetConditions(cond) - c.Status.LastKnownGoodSchema = schema - c.Status.AppliedConfig = &c.Spec - c.SetOverallStatus() - }, func(old, new *configv1alpha1.Config) bool { - // only write if the ready condition or these fields changed - if !new.GetCondition(condv1alpha1.ConditionTypeReady).Equal(old.GetCondition(condv1alpha1.ConditionTypeReady)) { - return true - } - if !reflect.DeepEqual(old.Status.LastKnownGoodSchema, new.Status.LastKnownGoodSchema) { - return true - } - if !reflect.DeepEqual(old.Status.AppliedConfig, new.Status.AppliedConfig) { - return true - } - return false + if cond.Equal(cfg.GetCondition(condv1alpha1.ConditionType(cond.Type))) && + reflect.DeepEqual(schema, cfg.Status.LastKnownGoodSchema) && + reflect.DeepEqual(&cfg.Spec, cfg.Status.AppliedConfig) { + return nil + } + + statusApply := configv1alpha1apply.ConfigStatus(). + WithConditions(cond, overallCond). + WithLastKnownGoodSchema(schemaToApply(schema)). + WithAppliedConfig(configSpecToApply(&cfg.Spec)) + + applyConfig := configv1alpha1apply.Config(cfg.Name, cfg.Namespace). + WithStatus(statusApply) + + return r.client.Status().Apply(ctx, applyConfig, &client.SubResourceApplyOptions{ + ApplyOptions: client.ApplyOptions{ + FieldManager: r.fieldManager, + }, }) } @@ -472,21 +481,6 @@ func toV1Alpha1Config(cfg *config.Config) (*configv1alpha1.Config, error) { return out, nil } -/* -func (r *Transactor) patchStatus( - ctx context.Context, - obj client.Object, - mutate func(), -) error { - orig := obj.DeepCopyObject().(client.Object) - mutate() - return r.client.Status().Patch(ctx, obj, client.MergeFrom(orig), - &client.SubResourcePatchOptions{ - PatchOptions: client.PatchOptions{FieldManager: r.fieldManager}, - }, - ) -} -*/ func (r *Transactor) patchMetadata( ctx context.Context, @@ -720,27 +714,6 @@ func analyzeIntentResponse(err error, rsp *sdcpb.TransactionSetResponse) Transac return result } -func (r *Transactor) patchStatusIfChanged( - ctx context.Context, - cfg *configv1alpha1.Config, - mutate func(c *configv1alpha1.Config), - changed func(old, new *configv1alpha1.Config) bool, -) error { - orig := cfg.DeepCopy() - - mutate(cfg) - - if changed != nil && !changed(orig, cfg) { - return nil - } - - return r.client.Status().Patch(ctx, cfg, client.MergeFrom(orig), - &client.SubResourcePatchOptions{ - PatchOptions: client.PatchOptions{FieldManager: r.fieldManager}, - }, - ) -} - func (r *Transactor) SetConfigsTargetConditionForTarget( ctx context.Context, target *invv1alpha1.Target, @@ -755,34 +728,98 @@ func (r *Transactor) SetConfigsTargetConditionForTarget( } for i := range cfgList.Items { - // convert to v1alpha1 for patching v1cfg, err := toV1Alpha1Config(&cfgList.Items[i]) if err != nil { return err } - err = r.patchStatusIfChanged(ctx, v1cfg, func(c *configv1alpha1.Config) { - // 1) set TargetReady condition - c.SetConditions(targetCond) - // 2) derive overall Ready from ConfigReady + TargetReady - c.SetOverallStatus() - }, func(old, new *configv1alpha1.Config) bool { - // compare the two condition types you may change - oldT := old.GetCondition(condv1alpha1.ConditionType(targetCond.Type)) - newT := new.GetCondition(condv1alpha1.ConditionType(targetCond.Type)) - if !newT.Equal(oldT) { - return true - } + oldTargetCond := v1cfg.GetCondition(condv1alpha1.ConditionType(targetCond.Type)) + oldReadyCond := v1cfg.GetCondition(condv1alpha1.ConditionTypeReady) - // 2) did overall Ready change? - oldR := old.GetCondition(condv1alpha1.ConditionTypeReady) - newR := new.GetCondition(condv1alpha1.ConditionTypeReady) - return !newR.Equal(oldR) - }) - if err != nil { + // compute new overall ready + v1cfg.SetConditions(targetCond) + v1cfg.SetOverallStatus() + newReadyCond := v1cfg.GetCondition(condv1alpha1.ConditionTypeReady) + + if targetCond.Equal(oldTargetCond) && newReadyCond.Equal(oldReadyCond) { + continue + } + + applyConfig := configv1alpha1apply.Config(v1cfg.Name, v1cfg.Namespace). + WithStatus(configv1alpha1apply.ConfigStatus(). + WithConditions(targetCond, newReadyCond), + ) + + if err := r.client.Status().Apply(ctx, applyConfig, &client.SubResourceApplyOptions{ + ApplyOptions: client.ApplyOptions{ + FieldManager: r.fieldManager, + }, + }); err != nil { return err } } - return nil } + + +func schemaToApply(s *configv1alpha1.ConfigStatusLastKnownGoodSchema) *configv1alpha1apply.ConfigStatusLastKnownGoodSchemaApplyConfiguration { + if s == nil { + return nil + } + a := configv1alpha1apply.ConfigStatusLastKnownGoodSchema() + if s.Type != "" { + a.WithType(s.Type) + } + if s.Vendor != "" { + a.WithVendor(s.Vendor) + } + if s.Version != "" { + a.WithVersion(s.Version) + } + return a +} + +func configSpecToApply(s *configv1alpha1.ConfigSpec) *configv1alpha1apply.ConfigSpecApplyConfiguration { + if s == nil { + return nil + } + revertive := false + if (s.Revertive != nil) { + revertive= *s.Revertive + } + + a := configv1alpha1apply.ConfigSpec(). + WithPriority(s.Priority). + WithRevertive(revertive) + + if s.Lifecycle != nil { + a.WithLifecycle(lifecycleToApply(s.Lifecycle)) + } + + for i := range s.Config { + a.WithConfig(configBlobToApply(&s.Config[i])) + } + return a +} + +func lifecycleToApply(l *configv1alpha1.Lifecycle) *configv1alpha1apply.LifecycleApplyConfiguration { + if l == nil { + return nil + } + a := configv1alpha1apply.Lifecycle() + a.WithDeletionPolicy(l.DeletionPolicy) + + return a +} + +func configBlobToApply(b *configv1alpha1.ConfigBlob) *configv1alpha1apply.ConfigBlobApplyConfiguration { + if b == nil { + return nil + } + a := configv1alpha1apply.ConfigBlob() + if b.Path != "" { + a.WithPath(b.Path) + } + a.WithValue(b.Value) + return a +} \ No newline at end of file diff --git a/tools/apiserver-runtime-gen/main.go b/tools/apiserver-runtime-gen/main.go index 37ba4df7..50beb8d6 100644 --- a/tools/apiserver-runtime-gen/main.go +++ b/tools/apiserver-runtime-gen/main.go @@ -244,6 +244,18 @@ func doGen() error { } } + if gen["applyconfiguration-gen"] { + applyArgs := []string{ + "--output-dir", "pkg/generated/applyconfiguration", + "--output-pkg", fmt.Sprintf("%s/pkg/generated/applyconfiguration", module), + } + applyArgs = append(applyArgs, clientgenVersions...) + err := run(getCmd("applyconfiguration-gen", applyArgs...)) + if err != nil { + return err + } + } + return nil } @@ -259,7 +271,7 @@ var ( func main() { cmd.Flags().BoolVar(&clean, "clean", true, "Delete temporary directory for code generation.") - options := []string{"client-gen", "deepcopy-gen", "informer-gen", "lister-gen", "openapi-gen", "go-to-protobuf"} + options := []string{"client-gen", "deepcopy-gen", "informer-gen", "lister-gen", "openapi-gen", "go-to-protobuf", "applyconfiguration-gen"} defaultGen := []string{"deepcopy-gen", "openapi-gen"} cmd.Flags().StringSliceVarP(&generators, "generator", "g", defaultGen, fmt.Sprintf("Code generator to install and run. Options: %v.", options)) From 40b758d44d21909714b42fdf59f2e3845e6f5e3b Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Wed, 18 Feb 2026 11:14:01 +0100 Subject: [PATCH 007/135] rework ssa --- pkg/reconcilers/schema/reconciler.go | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) diff --git a/pkg/reconcilers/schema/reconciler.go b/pkg/reconcilers/schema/reconciler.go index f7de0f95..f5fbb9fe 100644 --- a/pkg/reconcilers/schema/reconciler.go +++ b/pkg/reconcilers/schema/reconciler.go @@ -178,10 +178,16 @@ func (r *reconciler) Reconcile(ctx context.Context, req ctrl.Request) (ctrl.Resu } if !dirExists { - // we set the loading condition to know loading started - schema.SetConditions(invv1alpha1.Loading()) - if err := r.client.Status().Update(ctx, schema); err != nil { - // we always retry when status fails -> optimistic concurrency + // SSA apply for loading condition + loadingApply := invv1alpha1apply.Schema(schema.Name, schema.Namespace). + WithStatus(invv1alpha1apply.SchemaStatus(). + WithConditions(invv1alpha1.Loading()), + ) + if err := r.client.Status().Apply(ctx, loadingApply, &client.SubResourceApplyOptions{ + ApplyOptions: client.ApplyOptions{ + FieldManager: reconcilerName, + }, + }); err != nil { return r.handleError(ctx, schemaOrig, "cannot update status", err) } r.recorder.Eventf(schema, nil, corev1.EventTypeNormal, From 4aa4b35883811ef2676c8e20bddbd0f48ea09cd5 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Wed, 18 Feb 2026 11:15:52 +0100 Subject: [PATCH 008/135] update go version in docker files --- DockerfileAPIServer | 2 +- DockerfileController | 2 +- goreleaser.api-server.dockerfile | 2 +- goreleaser.controller.dockerfile | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/DockerfileAPIServer b/DockerfileAPIServer index 92f386ba..5789eaec 100644 --- a/DockerfileAPIServer +++ b/DockerfileAPIServer @@ -2,7 +2,7 @@ # Licensed under the Apache License 2.0 # SPDX-License-Identifier: Apache-2.0 # -FROM golang:1.24 AS builder +FROM golang:1.25 AS builder ARG TARGETOS ARG TARGETARCH diff --git a/DockerfileController b/DockerfileController index 1c04a712..9a725e84 100644 --- a/DockerfileController +++ b/DockerfileController @@ -3,7 +3,7 @@ # SPDX-License-Identifier: Apache-2.0 # Build the manager binary -FROM golang:1.24 AS builder +FROM golang:1.25 AS builder ARG TARGETOS ARG TARGETARCH diff --git a/goreleaser.api-server.dockerfile b/goreleaser.api-server.dockerfile index 0b3878d6..83808c3e 100644 --- a/goreleaser.api-server.dockerfile +++ b/goreleaser.api-server.dockerfile @@ -2,7 +2,7 @@ # Licensed under the Apache License 2.0 # SPDX-License-Identifier: Apache-2.0 # -FROM golang:1.21 AS builder +FROM golang:1.25 AS builder ARG USERID=10000 # no need to include cgo bindings ENV CGO_ENABLED=0 GOOS=linux GOARCH=amd64 diff --git a/goreleaser.controller.dockerfile b/goreleaser.controller.dockerfile index d224a4ee..9763200b 100644 --- a/goreleaser.controller.dockerfile +++ b/goreleaser.controller.dockerfile @@ -2,7 +2,7 @@ # Licensed under the Apache License 2.0 # SPDX-License-Identifier: Apache-2.0 # -FROM golang:1.21 AS builder +FROM golang:1.25 AS builder ARG USERID=10000 # no need to include cgo bindings ENV CGO_ENABLED=0 GOOS=linux GOARCH=amd64 From b681f767b819a9afc3216fa60609cbf35e581cc4 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Wed, 18 Feb 2026 12:30:59 +0100 Subject: [PATCH 009/135] added apibuilder with typeconvertor ssa --- go.mod | 2 +- go.sum | 4 ++-- pkg/registry/generic/store.go | 6 ++++-- 3 files changed, 7 insertions(+), 5 deletions(-) diff --git a/go.mod b/go.mod index 6ef0268c..daf541ab 100644 --- a/go.mod +++ b/go.mod @@ -8,7 +8,7 @@ require ( github.com/gogo/protobuf v1.3.2 github.com/google/go-cmp v0.7.0 github.com/google/uuid v1.6.0 - github.com/henderiw/apiserver-builder v0.0.6-0.20260218064045-beff0f08c914 + github.com/henderiw/apiserver-builder v0.0.6-0.20260218112901-d0790aaa1c36 github.com/henderiw/apiserver-store v0.0.3 github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c github.com/henderiw/logger v0.0.0-20230911123436-8655829b1abe diff --git a/go.sum b/go.sum index 922f4615..2129c241 100644 --- a/go.sum +++ b/go.sum @@ -169,8 +169,8 @@ github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0 h1:Ovs26xHkKqVztRpIrF/92Bcuy github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0/go.mod h1:8NvIoxWQoOIhqOTXgfV/d3M/q6VIi02HzZEHgUlZvzk= github.com/grpc-ecosystem/grpc-gateway/v2 v2.27.3 h1:NmZ1PKzSTQbuGHw9DGPFomqkkLWMC+vZCkfs+FHv1Vg= github.com/grpc-ecosystem/grpc-gateway/v2 v2.27.3/go.mod h1:zQrxl1YP88HQlA6i9c63DSVPFklWpGX4OWAc9bFuaH4= -github.com/henderiw/apiserver-builder v0.0.6-0.20260218064045-beff0f08c914 h1:Xm7i7hLL+E7C92adVmi10bPewdX4Fkhi2+xGAQdfxDY= -github.com/henderiw/apiserver-builder v0.0.6-0.20260218064045-beff0f08c914/go.mod h1:n5ApsFfaK3h5B1WVEnZ29erGuMV0ovPA0/ErcXeQet0= +github.com/henderiw/apiserver-builder v0.0.6-0.20260218112901-d0790aaa1c36 h1:dsS+BnJCatlrXKdp6ieWQYlbBRgIHdam71DaQxqFQ08= +github.com/henderiw/apiserver-builder v0.0.6-0.20260218112901-d0790aaa1c36/go.mod h1:n5ApsFfaK3h5B1WVEnZ29erGuMV0ovPA0/ErcXeQet0= github.com/henderiw/apiserver-store v0.0.3 h1:cUNzimOvxVKsw+/kj+7IkI/GnRuFlziwCc3AsfYo9zM= github.com/henderiw/apiserver-store v0.0.3/go.mod h1:RuXLMHJwszn6LXgL6fO9fxMC7AW5wAc4zOddnnZpkKI= github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c h1:nFnCNyRV1Ej/zqV/gn8UnFESkoPUXhwpUCZyhSYGSYA= diff --git a/pkg/registry/generic/store.go b/pkg/registry/generic/store.go index 6d912087..76013144 100644 --- a/pkg/registry/generic/store.go +++ b/pkg/registry/generic/store.go @@ -32,6 +32,7 @@ import ( "k8s.io/apimachinery/pkg/runtime" "k8s.io/apiserver/pkg/registry/generic" "k8s.io/apiserver/pkg/registry/rest" + builderoptions "github.com/henderiw/apiserver-builder/pkg/cmd/apiserverbuilder/options" ) func NewStorageProvider(ctx context.Context, obj resource.InternalObject, opts *options.Options) *builderrest.StorageProvider { @@ -109,11 +110,12 @@ func NewREST( ShortNameList: obj.GetShortNames(), Storage: storage, } - options := &generic.StoreOptions{ + storeOptions := &generic.StoreOptions{ RESTOptions: optsGetter, AttrFunc: utils.GetAttrs, } - if err := store.CompleteWithOptions(options); err != nil { + + if err := store.CompleteWithOptions(storeOptions); err != nil { return nil, err } return store, nil From c378869f6d13a59771f4cb11616978af2e6f041a Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Wed, 18 Feb 2026 12:42:20 +0100 Subject: [PATCH 010/135] added apibuilder with typeconvertor ssa --- pkg/registry/generic/store.go | 1 - 1 file changed, 1 deletion(-) diff --git a/pkg/registry/generic/store.go b/pkg/registry/generic/store.go index 76013144..8eba27e8 100644 --- a/pkg/registry/generic/store.go +++ b/pkg/registry/generic/store.go @@ -32,7 +32,6 @@ import ( "k8s.io/apimachinery/pkg/runtime" "k8s.io/apiserver/pkg/registry/generic" "k8s.io/apiserver/pkg/registry/rest" - builderoptions "github.com/henderiw/apiserver-builder/pkg/cmd/apiserverbuilder/options" ) func NewStorageProvider(ctx context.Context, obj resource.InternalObject, opts *options.Options) *builderrest.StorageProvider { From 54ed2399a546a25dae941e203737bd834a900c6b Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Wed, 18 Feb 2026 12:58:29 +0100 Subject: [PATCH 011/135] debug openapi --- go.mod | 2 +- go.sum | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/go.mod b/go.mod index daf541ab..2ed8b4aa 100644 --- a/go.mod +++ b/go.mod @@ -8,7 +8,7 @@ require ( github.com/gogo/protobuf v1.3.2 github.com/google/go-cmp v0.7.0 github.com/google/uuid v1.6.0 - github.com/henderiw/apiserver-builder v0.0.6-0.20260218112901-d0790aaa1c36 + github.com/henderiw/apiserver-builder v0.0.6-0.20260218115710-eb505705c3c1 github.com/henderiw/apiserver-store v0.0.3 github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c github.com/henderiw/logger v0.0.0-20230911123436-8655829b1abe diff --git a/go.sum b/go.sum index 2129c241..cbfa7fcf 100644 --- a/go.sum +++ b/go.sum @@ -169,8 +169,8 @@ github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0 h1:Ovs26xHkKqVztRpIrF/92Bcuy github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0/go.mod h1:8NvIoxWQoOIhqOTXgfV/d3M/q6VIi02HzZEHgUlZvzk= github.com/grpc-ecosystem/grpc-gateway/v2 v2.27.3 h1:NmZ1PKzSTQbuGHw9DGPFomqkkLWMC+vZCkfs+FHv1Vg= github.com/grpc-ecosystem/grpc-gateway/v2 v2.27.3/go.mod h1:zQrxl1YP88HQlA6i9c63DSVPFklWpGX4OWAc9bFuaH4= -github.com/henderiw/apiserver-builder v0.0.6-0.20260218112901-d0790aaa1c36 h1:dsS+BnJCatlrXKdp6ieWQYlbBRgIHdam71DaQxqFQ08= -github.com/henderiw/apiserver-builder v0.0.6-0.20260218112901-d0790aaa1c36/go.mod h1:n5ApsFfaK3h5B1WVEnZ29erGuMV0ovPA0/ErcXeQet0= +github.com/henderiw/apiserver-builder v0.0.6-0.20260218115710-eb505705c3c1 h1:NB5M7JCtXRjp+ADB5oyzaEDV6jomiItACSNH2d4SUKY= +github.com/henderiw/apiserver-builder v0.0.6-0.20260218115710-eb505705c3c1/go.mod h1:n5ApsFfaK3h5B1WVEnZ29erGuMV0ovPA0/ErcXeQet0= github.com/henderiw/apiserver-store v0.0.3 h1:cUNzimOvxVKsw+/kj+7IkI/GnRuFlziwCc3AsfYo9zM= github.com/henderiw/apiserver-store v0.0.3/go.mod h1:RuXLMHJwszn6LXgL6fO9fxMC7AW5wAc4zOddnnZpkKI= github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c h1:nFnCNyRV1Ej/zqV/gn8UnFESkoPUXhwpUCZyhSYGSYA= From 785d51d97a853d9e35ae9529b8c59b00a5e203e5 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Wed, 18 Feb 2026 13:09:50 +0100 Subject: [PATCH 012/135] debug openapi --- go.mod | 2 +- go.sum | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/go.mod b/go.mod index 2ed8b4aa..b374b30b 100644 --- a/go.mod +++ b/go.mod @@ -8,7 +8,7 @@ require ( github.com/gogo/protobuf v1.3.2 github.com/google/go-cmp v0.7.0 github.com/google/uuid v1.6.0 - github.com/henderiw/apiserver-builder v0.0.6-0.20260218115710-eb505705c3c1 + github.com/henderiw/apiserver-builder v0.0.6-0.20260218120559-4938d11d2f33 github.com/henderiw/apiserver-store v0.0.3 github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c github.com/henderiw/logger v0.0.0-20230911123436-8655829b1abe diff --git a/go.sum b/go.sum index cbfa7fcf..552c0f77 100644 --- a/go.sum +++ b/go.sum @@ -171,6 +171,8 @@ github.com/grpc-ecosystem/grpc-gateway/v2 v2.27.3 h1:NmZ1PKzSTQbuGHw9DGPFomqkkLW github.com/grpc-ecosystem/grpc-gateway/v2 v2.27.3/go.mod h1:zQrxl1YP88HQlA6i9c63DSVPFklWpGX4OWAc9bFuaH4= github.com/henderiw/apiserver-builder v0.0.6-0.20260218115710-eb505705c3c1 h1:NB5M7JCtXRjp+ADB5oyzaEDV6jomiItACSNH2d4SUKY= github.com/henderiw/apiserver-builder v0.0.6-0.20260218115710-eb505705c3c1/go.mod h1:n5ApsFfaK3h5B1WVEnZ29erGuMV0ovPA0/ErcXeQet0= +github.com/henderiw/apiserver-builder v0.0.6-0.20260218120559-4938d11d2f33 h1:qV0O69hNM6LNhJBXFmFZG1Uj4PbnSOsfqrurNQWxKYY= +github.com/henderiw/apiserver-builder v0.0.6-0.20260218120559-4938d11d2f33/go.mod h1:n5ApsFfaK3h5B1WVEnZ29erGuMV0ovPA0/ErcXeQet0= github.com/henderiw/apiserver-store v0.0.3 h1:cUNzimOvxVKsw+/kj+7IkI/GnRuFlziwCc3AsfYo9zM= github.com/henderiw/apiserver-store v0.0.3/go.mod h1:RuXLMHJwszn6LXgL6fO9fxMC7AW5wAc4zOddnnZpkKI= github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c h1:nFnCNyRV1Ej/zqV/gn8UnFESkoPUXhwpUCZyhSYGSYA= From 5906be977a7a3d49ee043338466edcf6c95010bc Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Wed, 18 Feb 2026 13:15:49 +0100 Subject: [PATCH 013/135] updated debug --- go.mod | 2 +- go.sum | 6 ++---- 2 files changed, 3 insertions(+), 5 deletions(-) diff --git a/go.mod b/go.mod index b374b30b..d5e345b6 100644 --- a/go.mod +++ b/go.mod @@ -8,7 +8,7 @@ require ( github.com/gogo/protobuf v1.3.2 github.com/google/go-cmp v0.7.0 github.com/google/uuid v1.6.0 - github.com/henderiw/apiserver-builder v0.0.6-0.20260218120559-4938d11d2f33 + github.com/henderiw/apiserver-builder v0.0.6-0.20260218121458-7efa1d993a8f github.com/henderiw/apiserver-store v0.0.3 github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c github.com/henderiw/logger v0.0.0-20230911123436-8655829b1abe diff --git a/go.sum b/go.sum index 552c0f77..c1ba0f63 100644 --- a/go.sum +++ b/go.sum @@ -169,10 +169,8 @@ github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0 h1:Ovs26xHkKqVztRpIrF/92Bcuy github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0/go.mod h1:8NvIoxWQoOIhqOTXgfV/d3M/q6VIi02HzZEHgUlZvzk= github.com/grpc-ecosystem/grpc-gateway/v2 v2.27.3 h1:NmZ1PKzSTQbuGHw9DGPFomqkkLWMC+vZCkfs+FHv1Vg= github.com/grpc-ecosystem/grpc-gateway/v2 v2.27.3/go.mod h1:zQrxl1YP88HQlA6i9c63DSVPFklWpGX4OWAc9bFuaH4= -github.com/henderiw/apiserver-builder v0.0.6-0.20260218115710-eb505705c3c1 h1:NB5M7JCtXRjp+ADB5oyzaEDV6jomiItACSNH2d4SUKY= -github.com/henderiw/apiserver-builder v0.0.6-0.20260218115710-eb505705c3c1/go.mod h1:n5ApsFfaK3h5B1WVEnZ29erGuMV0ovPA0/ErcXeQet0= -github.com/henderiw/apiserver-builder v0.0.6-0.20260218120559-4938d11d2f33 h1:qV0O69hNM6LNhJBXFmFZG1Uj4PbnSOsfqrurNQWxKYY= -github.com/henderiw/apiserver-builder v0.0.6-0.20260218120559-4938d11d2f33/go.mod h1:n5ApsFfaK3h5B1WVEnZ29erGuMV0ovPA0/ErcXeQet0= +github.com/henderiw/apiserver-builder v0.0.6-0.20260218121458-7efa1d993a8f h1:VJicfe6zN9RmRpuv5sBnXwmbus74qmeU7N/vUDQVocY= +github.com/henderiw/apiserver-builder v0.0.6-0.20260218121458-7efa1d993a8f/go.mod h1:n5ApsFfaK3h5B1WVEnZ29erGuMV0ovPA0/ErcXeQet0= github.com/henderiw/apiserver-store v0.0.3 h1:cUNzimOvxVKsw+/kj+7IkI/GnRuFlziwCc3AsfYo9zM= github.com/henderiw/apiserver-store v0.0.3/go.mod h1:RuXLMHJwszn6LXgL6fO9fxMC7AW5wAc4zOddnnZpkKI= github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c h1:nFnCNyRV1Ej/zqV/gn8UnFESkoPUXhwpUCZyhSYGSYA= From 408a466c4a3cd160b8bc2889b0c1481c24e8ef36 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Wed, 18 Feb 2026 13:18:22 +0100 Subject: [PATCH 014/135] updated debug --- go.mod | 2 +- go.sum | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/go.mod b/go.mod index d5e345b6..12e23f4c 100644 --- a/go.mod +++ b/go.mod @@ -8,7 +8,7 @@ require ( github.com/gogo/protobuf v1.3.2 github.com/google/go-cmp v0.7.0 github.com/google/uuid v1.6.0 - github.com/henderiw/apiserver-builder v0.0.6-0.20260218121458-7efa1d993a8f + github.com/henderiw/apiserver-builder v0.0.6-0.20260218121741-989d0dc47015 github.com/henderiw/apiserver-store v0.0.3 github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c github.com/henderiw/logger v0.0.0-20230911123436-8655829b1abe diff --git a/go.sum b/go.sum index c1ba0f63..a1e80861 100644 --- a/go.sum +++ b/go.sum @@ -171,6 +171,8 @@ github.com/grpc-ecosystem/grpc-gateway/v2 v2.27.3 h1:NmZ1PKzSTQbuGHw9DGPFomqkkLW github.com/grpc-ecosystem/grpc-gateway/v2 v2.27.3/go.mod h1:zQrxl1YP88HQlA6i9c63DSVPFklWpGX4OWAc9bFuaH4= github.com/henderiw/apiserver-builder v0.0.6-0.20260218121458-7efa1d993a8f h1:VJicfe6zN9RmRpuv5sBnXwmbus74qmeU7N/vUDQVocY= github.com/henderiw/apiserver-builder v0.0.6-0.20260218121458-7efa1d993a8f/go.mod h1:n5ApsFfaK3h5B1WVEnZ29erGuMV0ovPA0/ErcXeQet0= +github.com/henderiw/apiserver-builder v0.0.6-0.20260218121741-989d0dc47015 h1:4lIM4cl76M/e3pMuj9b75FDGm3KQW4bBWQsRujWjp64= +github.com/henderiw/apiserver-builder v0.0.6-0.20260218121741-989d0dc47015/go.mod h1:n5ApsFfaK3h5B1WVEnZ29erGuMV0ovPA0/ErcXeQet0= github.com/henderiw/apiserver-store v0.0.3 h1:cUNzimOvxVKsw+/kj+7IkI/GnRuFlziwCc3AsfYo9zM= github.com/henderiw/apiserver-store v0.0.3/go.mod h1:RuXLMHJwszn6LXgL6fO9fxMC7AW5wAc4zOddnnZpkKI= github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c h1:nFnCNyRV1Ej/zqV/gn8UnFESkoPUXhwpUCZyhSYGSYA= From 7ef99ec9b634a2aca992852030eed6375e0cfef8 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Wed, 18 Feb 2026 13:37:47 +0100 Subject: [PATCH 015/135] updated debug --- go.mod | 2 +- go.sum | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/go.mod b/go.mod index 12e23f4c..24a18d22 100644 --- a/go.mod +++ b/go.mod @@ -8,7 +8,7 @@ require ( github.com/gogo/protobuf v1.3.2 github.com/google/go-cmp v0.7.0 github.com/google/uuid v1.6.0 - github.com/henderiw/apiserver-builder v0.0.6-0.20260218121741-989d0dc47015 + github.com/henderiw/apiserver-builder v0.0.6-0.20260218123707-152787fa3aff github.com/henderiw/apiserver-store v0.0.3 github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c github.com/henderiw/logger v0.0.0-20230911123436-8655829b1abe diff --git a/go.sum b/go.sum index a1e80861..e9d6723b 100644 --- a/go.sum +++ b/go.sum @@ -173,6 +173,8 @@ github.com/henderiw/apiserver-builder v0.0.6-0.20260218121458-7efa1d993a8f h1:VJ github.com/henderiw/apiserver-builder v0.0.6-0.20260218121458-7efa1d993a8f/go.mod h1:n5ApsFfaK3h5B1WVEnZ29erGuMV0ovPA0/ErcXeQet0= github.com/henderiw/apiserver-builder v0.0.6-0.20260218121741-989d0dc47015 h1:4lIM4cl76M/e3pMuj9b75FDGm3KQW4bBWQsRujWjp64= github.com/henderiw/apiserver-builder v0.0.6-0.20260218121741-989d0dc47015/go.mod h1:n5ApsFfaK3h5B1WVEnZ29erGuMV0ovPA0/ErcXeQet0= +github.com/henderiw/apiserver-builder v0.0.6-0.20260218123707-152787fa3aff h1:nANJ/KC8XMY/o+bcgwGI29YVt6SJFZzJQO+atWZqlrg= +github.com/henderiw/apiserver-builder v0.0.6-0.20260218123707-152787fa3aff/go.mod h1:n5ApsFfaK3h5B1WVEnZ29erGuMV0ovPA0/ErcXeQet0= github.com/henderiw/apiserver-store v0.0.3 h1:cUNzimOvxVKsw+/kj+7IkI/GnRuFlziwCc3AsfYo9zM= github.com/henderiw/apiserver-store v0.0.3/go.mod h1:RuXLMHJwszn6LXgL6fO9fxMC7AW5wAc4zOddnnZpkKI= github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c h1:nFnCNyRV1Ej/zqV/gn8UnFESkoPUXhwpUCZyhSYGSYA= From 452e8ac9005e282196479a2437dcfd88ede785ef Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Wed, 18 Feb 2026 13:55:30 +0100 Subject: [PATCH 016/135] added test --- pkg/generated/openapi/zz_generated.openapi.go | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/pkg/generated/openapi/zz_generated.openapi.go b/pkg/generated/openapi/zz_generated.openapi.go index 75f6c38a..891b4cd8 100644 --- a/pkg/generated/openapi/zz_generated.openapi.go +++ b/pkg/generated/openapi/zz_generated.openapi.go @@ -576,6 +576,14 @@ func schema_config_server_apis_config_v1alpha1_Config(ref common.ReferenceCallba Ref: ref("github.com/sdcio/config-server/apis/config/v1alpha1.ConfigStatus"), }, }, + + }, + }, + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-group-version-kind": []interface{}{ + map[string]interface{}{"group": "config.sdcio.dev", "kind": "Config", "version": "v1alpha1"}, + }, }, }, }, @@ -1212,6 +1220,13 @@ func schema_config_server_apis_config_v1alpha1_Deviation(ref common.ReferenceCal }, }, }, + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-group-version-kind": []interface{}{ + map[string]interface{}{"group": "config.sdcio.dev", "kind": "Deviation", "version": "v1alpha1"}, + }, + }, + }, }, Dependencies: []string{ "github.com/sdcio/config-server/apis/config/v1alpha1.DeviationSpec", "github.com/sdcio/config-server/apis/config/v1alpha1.DeviationStatus", "k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"}, From c95ae695e1425cb49f6750e06f6048b43d4979de Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Wed, 18 Feb 2026 15:56:48 +0100 Subject: [PATCH 017/135] update the prio version --- go.mod | 2 +- go.sum | 8 ++------ 2 files changed, 3 insertions(+), 7 deletions(-) diff --git a/go.mod b/go.mod index 24a18d22..1cab44df 100644 --- a/go.mod +++ b/go.mod @@ -8,7 +8,7 @@ require ( github.com/gogo/protobuf v1.3.2 github.com/google/go-cmp v0.7.0 github.com/google/uuid v1.6.0 - github.com/henderiw/apiserver-builder v0.0.6-0.20260218123707-152787fa3aff + github.com/henderiw/apiserver-builder v0.0.6-0.20260218145442-77ce7b3713a9 github.com/henderiw/apiserver-store v0.0.3 github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c github.com/henderiw/logger v0.0.0-20230911123436-8655829b1abe diff --git a/go.sum b/go.sum index e9d6723b..6f5be312 100644 --- a/go.sum +++ b/go.sum @@ -169,12 +169,8 @@ github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0 h1:Ovs26xHkKqVztRpIrF/92Bcuy github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0/go.mod h1:8NvIoxWQoOIhqOTXgfV/d3M/q6VIi02HzZEHgUlZvzk= github.com/grpc-ecosystem/grpc-gateway/v2 v2.27.3 h1:NmZ1PKzSTQbuGHw9DGPFomqkkLWMC+vZCkfs+FHv1Vg= github.com/grpc-ecosystem/grpc-gateway/v2 v2.27.3/go.mod h1:zQrxl1YP88HQlA6i9c63DSVPFklWpGX4OWAc9bFuaH4= -github.com/henderiw/apiserver-builder v0.0.6-0.20260218121458-7efa1d993a8f h1:VJicfe6zN9RmRpuv5sBnXwmbus74qmeU7N/vUDQVocY= -github.com/henderiw/apiserver-builder v0.0.6-0.20260218121458-7efa1d993a8f/go.mod h1:n5ApsFfaK3h5B1WVEnZ29erGuMV0ovPA0/ErcXeQet0= -github.com/henderiw/apiserver-builder v0.0.6-0.20260218121741-989d0dc47015 h1:4lIM4cl76M/e3pMuj9b75FDGm3KQW4bBWQsRujWjp64= -github.com/henderiw/apiserver-builder v0.0.6-0.20260218121741-989d0dc47015/go.mod h1:n5ApsFfaK3h5B1WVEnZ29erGuMV0ovPA0/ErcXeQet0= -github.com/henderiw/apiserver-builder v0.0.6-0.20260218123707-152787fa3aff h1:nANJ/KC8XMY/o+bcgwGI29YVt6SJFZzJQO+atWZqlrg= -github.com/henderiw/apiserver-builder v0.0.6-0.20260218123707-152787fa3aff/go.mod h1:n5ApsFfaK3h5B1WVEnZ29erGuMV0ovPA0/ErcXeQet0= +github.com/henderiw/apiserver-builder v0.0.6-0.20260218145442-77ce7b3713a9 h1:sFdegJDnvir5IbpVm5cWEHIKq25JfKk3JqAeW3kMmKU= +github.com/henderiw/apiserver-builder v0.0.6-0.20260218145442-77ce7b3713a9/go.mod h1:n5ApsFfaK3h5B1WVEnZ29erGuMV0ovPA0/ErcXeQet0= github.com/henderiw/apiserver-store v0.0.3 h1:cUNzimOvxVKsw+/kj+7IkI/GnRuFlziwCc3AsfYo9zM= github.com/henderiw/apiserver-store v0.0.3/go.mod h1:RuXLMHJwszn6LXgL6fO9fxMC7AW5wAc4zOddnnZpkKI= github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c h1:nFnCNyRV1Ej/zqV/gn8UnFESkoPUXhwpUCZyhSYGSYA= From aea8bd4f40118dc21f3748a9692a7f85a38a67d8 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Wed, 18 Feb 2026 16:05:04 +0100 Subject: [PATCH 018/135] updated openapi-gen --- pkg/generated/openapi/zz_generated.openapi.go | 2063 ++++++++--------- 1 file changed, 1023 insertions(+), 1040 deletions(-) diff --git a/pkg/generated/openapi/zz_generated.openapi.go b/pkg/generated/openapi/zz_generated.openapi.go index 891b4cd8..5d3b215d 100644 --- a/pkg/generated/openapi/zz_generated.openapi.go +++ b/pkg/generated/openapi/zz_generated.openapi.go @@ -24,6 +24,8 @@ import ( v1 "k8s.io/api/core/v1" resource "k8s.io/apimachinery/pkg/api/resource" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + runtime "k8s.io/apimachinery/pkg/runtime" + version "k8s.io/apimachinery/pkg/version" common "k8s.io/kube-openapi/pkg/common" spec "k8s.io/kube-openapi/pkg/validation/spec" ) @@ -118,298 +120,297 @@ func GetOpenAPIDefinitions(ref common.ReferenceCallback) map[string]common.OpenA "github.com/sdcio/config-server/apis/inv/v1alpha1.WorkspaceList": schema_config_server_apis_inv_v1alpha1_WorkspaceList(ref), "github.com/sdcio/config-server/apis/inv/v1alpha1.WorkspaceSpec": schema_config_server_apis_inv_v1alpha1_WorkspaceSpec(ref), "github.com/sdcio/config-server/apis/inv/v1alpha1.WorkspaceStatus": schema_config_server_apis_inv_v1alpha1_WorkspaceStatus(ref), - "k8s.io/api/core/v1.AWSElasticBlockStoreVolumeSource": schema_k8sio_api_core_v1_AWSElasticBlockStoreVolumeSource(ref), - "k8s.io/api/core/v1.Affinity": schema_k8sio_api_core_v1_Affinity(ref), - "k8s.io/api/core/v1.AppArmorProfile": schema_k8sio_api_core_v1_AppArmorProfile(ref), - "k8s.io/api/core/v1.AttachedVolume": schema_k8sio_api_core_v1_AttachedVolume(ref), - "k8s.io/api/core/v1.AvoidPods": schema_k8sio_api_core_v1_AvoidPods(ref), - "k8s.io/api/core/v1.AzureDiskVolumeSource": schema_k8sio_api_core_v1_AzureDiskVolumeSource(ref), - "k8s.io/api/core/v1.AzureFilePersistentVolumeSource": schema_k8sio_api_core_v1_AzureFilePersistentVolumeSource(ref), - "k8s.io/api/core/v1.AzureFileVolumeSource": schema_k8sio_api_core_v1_AzureFileVolumeSource(ref), - "k8s.io/api/core/v1.Binding": schema_k8sio_api_core_v1_Binding(ref), - "k8s.io/api/core/v1.CSIPersistentVolumeSource": schema_k8sio_api_core_v1_CSIPersistentVolumeSource(ref), - "k8s.io/api/core/v1.CSIVolumeSource": schema_k8sio_api_core_v1_CSIVolumeSource(ref), - "k8s.io/api/core/v1.Capabilities": schema_k8sio_api_core_v1_Capabilities(ref), - "k8s.io/api/core/v1.CephFSPersistentVolumeSource": schema_k8sio_api_core_v1_CephFSPersistentVolumeSource(ref), - "k8s.io/api/core/v1.CephFSVolumeSource": schema_k8sio_api_core_v1_CephFSVolumeSource(ref), - "k8s.io/api/core/v1.CinderPersistentVolumeSource": schema_k8sio_api_core_v1_CinderPersistentVolumeSource(ref), - "k8s.io/api/core/v1.CinderVolumeSource": schema_k8sio_api_core_v1_CinderVolumeSource(ref), - "k8s.io/api/core/v1.ClientIPConfig": schema_k8sio_api_core_v1_ClientIPConfig(ref), - "k8s.io/api/core/v1.ClusterTrustBundleProjection": schema_k8sio_api_core_v1_ClusterTrustBundleProjection(ref), - "k8s.io/api/core/v1.ComponentCondition": schema_k8sio_api_core_v1_ComponentCondition(ref), - "k8s.io/api/core/v1.ComponentStatus": schema_k8sio_api_core_v1_ComponentStatus(ref), - "k8s.io/api/core/v1.ComponentStatusList": schema_k8sio_api_core_v1_ComponentStatusList(ref), - "k8s.io/api/core/v1.ConfigMap": schema_k8sio_api_core_v1_ConfigMap(ref), - "k8s.io/api/core/v1.ConfigMapEnvSource": schema_k8sio_api_core_v1_ConfigMapEnvSource(ref), - "k8s.io/api/core/v1.ConfigMapKeySelector": schema_k8sio_api_core_v1_ConfigMapKeySelector(ref), - "k8s.io/api/core/v1.ConfigMapList": schema_k8sio_api_core_v1_ConfigMapList(ref), - "k8s.io/api/core/v1.ConfigMapNodeConfigSource": schema_k8sio_api_core_v1_ConfigMapNodeConfigSource(ref), - "k8s.io/api/core/v1.ConfigMapProjection": schema_k8sio_api_core_v1_ConfigMapProjection(ref), - "k8s.io/api/core/v1.ConfigMapVolumeSource": schema_k8sio_api_core_v1_ConfigMapVolumeSource(ref), - "k8s.io/api/core/v1.Container": schema_k8sio_api_core_v1_Container(ref), - "k8s.io/api/core/v1.ContainerExtendedResourceRequest": schema_k8sio_api_core_v1_ContainerExtendedResourceRequest(ref), - "k8s.io/api/core/v1.ContainerImage": schema_k8sio_api_core_v1_ContainerImage(ref), - "k8s.io/api/core/v1.ContainerPort": schema_k8sio_api_core_v1_ContainerPort(ref), - "k8s.io/api/core/v1.ContainerResizePolicy": schema_k8sio_api_core_v1_ContainerResizePolicy(ref), - "k8s.io/api/core/v1.ContainerRestartRule": schema_k8sio_api_core_v1_ContainerRestartRule(ref), - "k8s.io/api/core/v1.ContainerRestartRuleOnExitCodes": schema_k8sio_api_core_v1_ContainerRestartRuleOnExitCodes(ref), - "k8s.io/api/core/v1.ContainerState": schema_k8sio_api_core_v1_ContainerState(ref), - "k8s.io/api/core/v1.ContainerStateRunning": schema_k8sio_api_core_v1_ContainerStateRunning(ref), - "k8s.io/api/core/v1.ContainerStateTerminated": schema_k8sio_api_core_v1_ContainerStateTerminated(ref), - "k8s.io/api/core/v1.ContainerStateWaiting": schema_k8sio_api_core_v1_ContainerStateWaiting(ref), - "k8s.io/api/core/v1.ContainerStatus": schema_k8sio_api_core_v1_ContainerStatus(ref), - "k8s.io/api/core/v1.ContainerUser": schema_k8sio_api_core_v1_ContainerUser(ref), - "k8s.io/api/core/v1.DaemonEndpoint": schema_k8sio_api_core_v1_DaemonEndpoint(ref), - "k8s.io/api/core/v1.DownwardAPIProjection": schema_k8sio_api_core_v1_DownwardAPIProjection(ref), - "k8s.io/api/core/v1.DownwardAPIVolumeFile": schema_k8sio_api_core_v1_DownwardAPIVolumeFile(ref), - "k8s.io/api/core/v1.DownwardAPIVolumeSource": schema_k8sio_api_core_v1_DownwardAPIVolumeSource(ref), - "k8s.io/api/core/v1.EmptyDirVolumeSource": schema_k8sio_api_core_v1_EmptyDirVolumeSource(ref), - "k8s.io/api/core/v1.EndpointAddress": schema_k8sio_api_core_v1_EndpointAddress(ref), - "k8s.io/api/core/v1.EndpointPort": schema_k8sio_api_core_v1_EndpointPort(ref), - "k8s.io/api/core/v1.EndpointSubset": schema_k8sio_api_core_v1_EndpointSubset(ref), - "k8s.io/api/core/v1.Endpoints": schema_k8sio_api_core_v1_Endpoints(ref), - "k8s.io/api/core/v1.EndpointsList": schema_k8sio_api_core_v1_EndpointsList(ref), - "k8s.io/api/core/v1.EnvFromSource": schema_k8sio_api_core_v1_EnvFromSource(ref), - "k8s.io/api/core/v1.EnvVar": schema_k8sio_api_core_v1_EnvVar(ref), - "k8s.io/api/core/v1.EnvVarSource": schema_k8sio_api_core_v1_EnvVarSource(ref), - "k8s.io/api/core/v1.EphemeralContainer": schema_k8sio_api_core_v1_EphemeralContainer(ref), - "k8s.io/api/core/v1.EphemeralContainerCommon": schema_k8sio_api_core_v1_EphemeralContainerCommon(ref), - "k8s.io/api/core/v1.EphemeralVolumeSource": schema_k8sio_api_core_v1_EphemeralVolumeSource(ref), - "k8s.io/api/core/v1.Event": schema_k8sio_api_core_v1_Event(ref), - "k8s.io/api/core/v1.EventList": schema_k8sio_api_core_v1_EventList(ref), - "k8s.io/api/core/v1.EventSeries": schema_k8sio_api_core_v1_EventSeries(ref), - "k8s.io/api/core/v1.EventSource": schema_k8sio_api_core_v1_EventSource(ref), - "k8s.io/api/core/v1.ExecAction": schema_k8sio_api_core_v1_ExecAction(ref), - "k8s.io/api/core/v1.FCVolumeSource": schema_k8sio_api_core_v1_FCVolumeSource(ref), - "k8s.io/api/core/v1.FileKeySelector": schema_k8sio_api_core_v1_FileKeySelector(ref), - "k8s.io/api/core/v1.FlexPersistentVolumeSource": schema_k8sio_api_core_v1_FlexPersistentVolumeSource(ref), - "k8s.io/api/core/v1.FlexVolumeSource": schema_k8sio_api_core_v1_FlexVolumeSource(ref), - "k8s.io/api/core/v1.FlockerVolumeSource": schema_k8sio_api_core_v1_FlockerVolumeSource(ref), - "k8s.io/api/core/v1.GCEPersistentDiskVolumeSource": schema_k8sio_api_core_v1_GCEPersistentDiskVolumeSource(ref), - "k8s.io/api/core/v1.GRPCAction": schema_k8sio_api_core_v1_GRPCAction(ref), - "k8s.io/api/core/v1.GitRepoVolumeSource": schema_k8sio_api_core_v1_GitRepoVolumeSource(ref), - "k8s.io/api/core/v1.GlusterfsPersistentVolumeSource": schema_k8sio_api_core_v1_GlusterfsPersistentVolumeSource(ref), - "k8s.io/api/core/v1.GlusterfsVolumeSource": schema_k8sio_api_core_v1_GlusterfsVolumeSource(ref), - "k8s.io/api/core/v1.HTTPGetAction": schema_k8sio_api_core_v1_HTTPGetAction(ref), - "k8s.io/api/core/v1.HTTPHeader": schema_k8sio_api_core_v1_HTTPHeader(ref), - "k8s.io/api/core/v1.HostAlias": schema_k8sio_api_core_v1_HostAlias(ref), - "k8s.io/api/core/v1.HostIP": schema_k8sio_api_core_v1_HostIP(ref), - "k8s.io/api/core/v1.HostPathVolumeSource": schema_k8sio_api_core_v1_HostPathVolumeSource(ref), - "k8s.io/api/core/v1.ISCSIPersistentVolumeSource": schema_k8sio_api_core_v1_ISCSIPersistentVolumeSource(ref), - "k8s.io/api/core/v1.ISCSIVolumeSource": schema_k8sio_api_core_v1_ISCSIVolumeSource(ref), - "k8s.io/api/core/v1.ImageVolumeSource": schema_k8sio_api_core_v1_ImageVolumeSource(ref), - "k8s.io/api/core/v1.KeyToPath": schema_k8sio_api_core_v1_KeyToPath(ref), - "k8s.io/api/core/v1.Lifecycle": schema_k8sio_api_core_v1_Lifecycle(ref), - "k8s.io/api/core/v1.LifecycleHandler": schema_k8sio_api_core_v1_LifecycleHandler(ref), - "k8s.io/api/core/v1.LimitRange": schema_k8sio_api_core_v1_LimitRange(ref), - "k8s.io/api/core/v1.LimitRangeItem": schema_k8sio_api_core_v1_LimitRangeItem(ref), - "k8s.io/api/core/v1.LimitRangeList": schema_k8sio_api_core_v1_LimitRangeList(ref), - "k8s.io/api/core/v1.LimitRangeSpec": schema_k8sio_api_core_v1_LimitRangeSpec(ref), - "k8s.io/api/core/v1.LinuxContainerUser": schema_k8sio_api_core_v1_LinuxContainerUser(ref), - "k8s.io/api/core/v1.List": schema_k8sio_api_core_v1_List(ref), - "k8s.io/api/core/v1.LoadBalancerIngress": schema_k8sio_api_core_v1_LoadBalancerIngress(ref), - "k8s.io/api/core/v1.LoadBalancerStatus": schema_k8sio_api_core_v1_LoadBalancerStatus(ref), - "k8s.io/api/core/v1.LocalObjectReference": schema_k8sio_api_core_v1_LocalObjectReference(ref), - "k8s.io/api/core/v1.LocalVolumeSource": schema_k8sio_api_core_v1_LocalVolumeSource(ref), - "k8s.io/api/core/v1.ModifyVolumeStatus": schema_k8sio_api_core_v1_ModifyVolumeStatus(ref), - "k8s.io/api/core/v1.NFSVolumeSource": schema_k8sio_api_core_v1_NFSVolumeSource(ref), - "k8s.io/api/core/v1.Namespace": schema_k8sio_api_core_v1_Namespace(ref), - "k8s.io/api/core/v1.NamespaceCondition": schema_k8sio_api_core_v1_NamespaceCondition(ref), - "k8s.io/api/core/v1.NamespaceList": schema_k8sio_api_core_v1_NamespaceList(ref), - "k8s.io/api/core/v1.NamespaceSpec": schema_k8sio_api_core_v1_NamespaceSpec(ref), - "k8s.io/api/core/v1.NamespaceStatus": schema_k8sio_api_core_v1_NamespaceStatus(ref), - "k8s.io/api/core/v1.Node": schema_k8sio_api_core_v1_Node(ref), - "k8s.io/api/core/v1.NodeAddress": schema_k8sio_api_core_v1_NodeAddress(ref), - "k8s.io/api/core/v1.NodeAffinity": schema_k8sio_api_core_v1_NodeAffinity(ref), - "k8s.io/api/core/v1.NodeCondition": schema_k8sio_api_core_v1_NodeCondition(ref), - "k8s.io/api/core/v1.NodeConfigSource": schema_k8sio_api_core_v1_NodeConfigSource(ref), - "k8s.io/api/core/v1.NodeConfigStatus": schema_k8sio_api_core_v1_NodeConfigStatus(ref), - "k8s.io/api/core/v1.NodeDaemonEndpoints": schema_k8sio_api_core_v1_NodeDaemonEndpoints(ref), - "k8s.io/api/core/v1.NodeFeatures": schema_k8sio_api_core_v1_NodeFeatures(ref), - "k8s.io/api/core/v1.NodeList": schema_k8sio_api_core_v1_NodeList(ref), - "k8s.io/api/core/v1.NodeProxyOptions": schema_k8sio_api_core_v1_NodeProxyOptions(ref), - "k8s.io/api/core/v1.NodeRuntimeHandler": schema_k8sio_api_core_v1_NodeRuntimeHandler(ref), - "k8s.io/api/core/v1.NodeRuntimeHandlerFeatures": schema_k8sio_api_core_v1_NodeRuntimeHandlerFeatures(ref), - "k8s.io/api/core/v1.NodeSelector": schema_k8sio_api_core_v1_NodeSelector(ref), - "k8s.io/api/core/v1.NodeSelectorRequirement": schema_k8sio_api_core_v1_NodeSelectorRequirement(ref), - "k8s.io/api/core/v1.NodeSelectorTerm": schema_k8sio_api_core_v1_NodeSelectorTerm(ref), - "k8s.io/api/core/v1.NodeSpec": schema_k8sio_api_core_v1_NodeSpec(ref), - "k8s.io/api/core/v1.NodeStatus": schema_k8sio_api_core_v1_NodeStatus(ref), - "k8s.io/api/core/v1.NodeSwapStatus": schema_k8sio_api_core_v1_NodeSwapStatus(ref), - "k8s.io/api/core/v1.NodeSystemInfo": schema_k8sio_api_core_v1_NodeSystemInfo(ref), - "k8s.io/api/core/v1.ObjectFieldSelector": schema_k8sio_api_core_v1_ObjectFieldSelector(ref), - "k8s.io/api/core/v1.ObjectReference": schema_k8sio_api_core_v1_ObjectReference(ref), - "k8s.io/api/core/v1.PersistentVolume": schema_k8sio_api_core_v1_PersistentVolume(ref), - "k8s.io/api/core/v1.PersistentVolumeClaim": schema_k8sio_api_core_v1_PersistentVolumeClaim(ref), - "k8s.io/api/core/v1.PersistentVolumeClaimCondition": schema_k8sio_api_core_v1_PersistentVolumeClaimCondition(ref), - "k8s.io/api/core/v1.PersistentVolumeClaimList": schema_k8sio_api_core_v1_PersistentVolumeClaimList(ref), - "k8s.io/api/core/v1.PersistentVolumeClaimSpec": schema_k8sio_api_core_v1_PersistentVolumeClaimSpec(ref), - "k8s.io/api/core/v1.PersistentVolumeClaimStatus": schema_k8sio_api_core_v1_PersistentVolumeClaimStatus(ref), - "k8s.io/api/core/v1.PersistentVolumeClaimTemplate": schema_k8sio_api_core_v1_PersistentVolumeClaimTemplate(ref), - "k8s.io/api/core/v1.PersistentVolumeClaimVolumeSource": schema_k8sio_api_core_v1_PersistentVolumeClaimVolumeSource(ref), - "k8s.io/api/core/v1.PersistentVolumeList": schema_k8sio_api_core_v1_PersistentVolumeList(ref), - "k8s.io/api/core/v1.PersistentVolumeSource": schema_k8sio_api_core_v1_PersistentVolumeSource(ref), - "k8s.io/api/core/v1.PersistentVolumeSpec": schema_k8sio_api_core_v1_PersistentVolumeSpec(ref), - "k8s.io/api/core/v1.PersistentVolumeStatus": schema_k8sio_api_core_v1_PersistentVolumeStatus(ref), - "k8s.io/api/core/v1.PhotonPersistentDiskVolumeSource": schema_k8sio_api_core_v1_PhotonPersistentDiskVolumeSource(ref), - "k8s.io/api/core/v1.Pod": schema_k8sio_api_core_v1_Pod(ref), - "k8s.io/api/core/v1.PodAffinity": schema_k8sio_api_core_v1_PodAffinity(ref), - "k8s.io/api/core/v1.PodAffinityTerm": schema_k8sio_api_core_v1_PodAffinityTerm(ref), - "k8s.io/api/core/v1.PodAntiAffinity": schema_k8sio_api_core_v1_PodAntiAffinity(ref), - "k8s.io/api/core/v1.PodAttachOptions": schema_k8sio_api_core_v1_PodAttachOptions(ref), - "k8s.io/api/core/v1.PodCertificateProjection": schema_k8sio_api_core_v1_PodCertificateProjection(ref), - "k8s.io/api/core/v1.PodCondition": schema_k8sio_api_core_v1_PodCondition(ref), - "k8s.io/api/core/v1.PodDNSConfig": schema_k8sio_api_core_v1_PodDNSConfig(ref), - "k8s.io/api/core/v1.PodDNSConfigOption": schema_k8sio_api_core_v1_PodDNSConfigOption(ref), - "k8s.io/api/core/v1.PodExecOptions": schema_k8sio_api_core_v1_PodExecOptions(ref), - "k8s.io/api/core/v1.PodExtendedResourceClaimStatus": schema_k8sio_api_core_v1_PodExtendedResourceClaimStatus(ref), - "k8s.io/api/core/v1.PodIP": schema_k8sio_api_core_v1_PodIP(ref), - "k8s.io/api/core/v1.PodList": schema_k8sio_api_core_v1_PodList(ref), - "k8s.io/api/core/v1.PodLogOptions": schema_k8sio_api_core_v1_PodLogOptions(ref), - "k8s.io/api/core/v1.PodOS": schema_k8sio_api_core_v1_PodOS(ref), - "k8s.io/api/core/v1.PodPortForwardOptions": schema_k8sio_api_core_v1_PodPortForwardOptions(ref), - "k8s.io/api/core/v1.PodProxyOptions": schema_k8sio_api_core_v1_PodProxyOptions(ref), - "k8s.io/api/core/v1.PodReadinessGate": schema_k8sio_api_core_v1_PodReadinessGate(ref), - "k8s.io/api/core/v1.PodResourceClaim": schema_k8sio_api_core_v1_PodResourceClaim(ref), - "k8s.io/api/core/v1.PodResourceClaimStatus": schema_k8sio_api_core_v1_PodResourceClaimStatus(ref), - "k8s.io/api/core/v1.PodSchedulingGate": schema_k8sio_api_core_v1_PodSchedulingGate(ref), - "k8s.io/api/core/v1.PodSecurityContext": schema_k8sio_api_core_v1_PodSecurityContext(ref), - "k8s.io/api/core/v1.PodSignature": schema_k8sio_api_core_v1_PodSignature(ref), - "k8s.io/api/core/v1.PodSpec": schema_k8sio_api_core_v1_PodSpec(ref), - "k8s.io/api/core/v1.PodStatus": schema_k8sio_api_core_v1_PodStatus(ref), - "k8s.io/api/core/v1.PodStatusResult": schema_k8sio_api_core_v1_PodStatusResult(ref), - "k8s.io/api/core/v1.PodTemplate": schema_k8sio_api_core_v1_PodTemplate(ref), - "k8s.io/api/core/v1.PodTemplateList": schema_k8sio_api_core_v1_PodTemplateList(ref), - "k8s.io/api/core/v1.PodTemplateSpec": schema_k8sio_api_core_v1_PodTemplateSpec(ref), - "k8s.io/api/core/v1.PortStatus": schema_k8sio_api_core_v1_PortStatus(ref), - "k8s.io/api/core/v1.PortworxVolumeSource": schema_k8sio_api_core_v1_PortworxVolumeSource(ref), - "k8s.io/api/core/v1.PreferAvoidPodsEntry": schema_k8sio_api_core_v1_PreferAvoidPodsEntry(ref), - "k8s.io/api/core/v1.PreferredSchedulingTerm": schema_k8sio_api_core_v1_PreferredSchedulingTerm(ref), - "k8s.io/api/core/v1.Probe": schema_k8sio_api_core_v1_Probe(ref), - "k8s.io/api/core/v1.ProbeHandler": schema_k8sio_api_core_v1_ProbeHandler(ref), - "k8s.io/api/core/v1.ProjectedVolumeSource": schema_k8sio_api_core_v1_ProjectedVolumeSource(ref), - "k8s.io/api/core/v1.QuobyteVolumeSource": schema_k8sio_api_core_v1_QuobyteVolumeSource(ref), - "k8s.io/api/core/v1.RBDPersistentVolumeSource": schema_k8sio_api_core_v1_RBDPersistentVolumeSource(ref), - "k8s.io/api/core/v1.RBDVolumeSource": schema_k8sio_api_core_v1_RBDVolumeSource(ref), - "k8s.io/api/core/v1.RangeAllocation": schema_k8sio_api_core_v1_RangeAllocation(ref), - "k8s.io/api/core/v1.ReplicationController": schema_k8sio_api_core_v1_ReplicationController(ref), - "k8s.io/api/core/v1.ReplicationControllerCondition": schema_k8sio_api_core_v1_ReplicationControllerCondition(ref), - "k8s.io/api/core/v1.ReplicationControllerList": schema_k8sio_api_core_v1_ReplicationControllerList(ref), - "k8s.io/api/core/v1.ReplicationControllerSpec": schema_k8sio_api_core_v1_ReplicationControllerSpec(ref), - "k8s.io/api/core/v1.ReplicationControllerStatus": schema_k8sio_api_core_v1_ReplicationControllerStatus(ref), - "k8s.io/api/core/v1.ResourceClaim": schema_k8sio_api_core_v1_ResourceClaim(ref), - "k8s.io/api/core/v1.ResourceFieldSelector": schema_k8sio_api_core_v1_ResourceFieldSelector(ref), - "k8s.io/api/core/v1.ResourceHealth": schema_k8sio_api_core_v1_ResourceHealth(ref), - "k8s.io/api/core/v1.ResourceQuota": schema_k8sio_api_core_v1_ResourceQuota(ref), - "k8s.io/api/core/v1.ResourceQuotaList": schema_k8sio_api_core_v1_ResourceQuotaList(ref), - "k8s.io/api/core/v1.ResourceQuotaSpec": schema_k8sio_api_core_v1_ResourceQuotaSpec(ref), - "k8s.io/api/core/v1.ResourceQuotaStatus": schema_k8sio_api_core_v1_ResourceQuotaStatus(ref), - "k8s.io/api/core/v1.ResourceRequirements": schema_k8sio_api_core_v1_ResourceRequirements(ref), - "k8s.io/api/core/v1.ResourceStatus": schema_k8sio_api_core_v1_ResourceStatus(ref), - "k8s.io/api/core/v1.SELinuxOptions": schema_k8sio_api_core_v1_SELinuxOptions(ref), - "k8s.io/api/core/v1.ScaleIOPersistentVolumeSource": schema_k8sio_api_core_v1_ScaleIOPersistentVolumeSource(ref), - "k8s.io/api/core/v1.ScaleIOVolumeSource": schema_k8sio_api_core_v1_ScaleIOVolumeSource(ref), - "k8s.io/api/core/v1.ScopeSelector": schema_k8sio_api_core_v1_ScopeSelector(ref), - "k8s.io/api/core/v1.ScopedResourceSelectorRequirement": schema_k8sio_api_core_v1_ScopedResourceSelectorRequirement(ref), - "k8s.io/api/core/v1.SeccompProfile": schema_k8sio_api_core_v1_SeccompProfile(ref), - "k8s.io/api/core/v1.Secret": schema_k8sio_api_core_v1_Secret(ref), - "k8s.io/api/core/v1.SecretEnvSource": schema_k8sio_api_core_v1_SecretEnvSource(ref), - "k8s.io/api/core/v1.SecretKeySelector": schema_k8sio_api_core_v1_SecretKeySelector(ref), - "k8s.io/api/core/v1.SecretList": schema_k8sio_api_core_v1_SecretList(ref), - "k8s.io/api/core/v1.SecretProjection": schema_k8sio_api_core_v1_SecretProjection(ref), - "k8s.io/api/core/v1.SecretReference": schema_k8sio_api_core_v1_SecretReference(ref), - "k8s.io/api/core/v1.SecretVolumeSource": schema_k8sio_api_core_v1_SecretVolumeSource(ref), - "k8s.io/api/core/v1.SecurityContext": schema_k8sio_api_core_v1_SecurityContext(ref), - "k8s.io/api/core/v1.SerializedReference": schema_k8sio_api_core_v1_SerializedReference(ref), - "k8s.io/api/core/v1.Service": schema_k8sio_api_core_v1_Service(ref), - "k8s.io/api/core/v1.ServiceAccount": schema_k8sio_api_core_v1_ServiceAccount(ref), - "k8s.io/api/core/v1.ServiceAccountList": schema_k8sio_api_core_v1_ServiceAccountList(ref), - "k8s.io/api/core/v1.ServiceAccountTokenProjection": schema_k8sio_api_core_v1_ServiceAccountTokenProjection(ref), - "k8s.io/api/core/v1.ServiceList": schema_k8sio_api_core_v1_ServiceList(ref), - "k8s.io/api/core/v1.ServicePort": schema_k8sio_api_core_v1_ServicePort(ref), - "k8s.io/api/core/v1.ServiceProxyOptions": schema_k8sio_api_core_v1_ServiceProxyOptions(ref), - "k8s.io/api/core/v1.ServiceSpec": schema_k8sio_api_core_v1_ServiceSpec(ref), - "k8s.io/api/core/v1.ServiceStatus": schema_k8sio_api_core_v1_ServiceStatus(ref), - "k8s.io/api/core/v1.SessionAffinityConfig": schema_k8sio_api_core_v1_SessionAffinityConfig(ref), - "k8s.io/api/core/v1.SleepAction": schema_k8sio_api_core_v1_SleepAction(ref), - "k8s.io/api/core/v1.StorageOSPersistentVolumeSource": schema_k8sio_api_core_v1_StorageOSPersistentVolumeSource(ref), - "k8s.io/api/core/v1.StorageOSVolumeSource": schema_k8sio_api_core_v1_StorageOSVolumeSource(ref), - "k8s.io/api/core/v1.Sysctl": schema_k8sio_api_core_v1_Sysctl(ref), - "k8s.io/api/core/v1.TCPSocketAction": schema_k8sio_api_core_v1_TCPSocketAction(ref), - "k8s.io/api/core/v1.Taint": schema_k8sio_api_core_v1_Taint(ref), - "k8s.io/api/core/v1.Toleration": schema_k8sio_api_core_v1_Toleration(ref), - "k8s.io/api/core/v1.TopologySelectorLabelRequirement": schema_k8sio_api_core_v1_TopologySelectorLabelRequirement(ref), - "k8s.io/api/core/v1.TopologySelectorTerm": schema_k8sio_api_core_v1_TopologySelectorTerm(ref), - "k8s.io/api/core/v1.TopologySpreadConstraint": schema_k8sio_api_core_v1_TopologySpreadConstraint(ref), - "k8s.io/api/core/v1.TypedLocalObjectReference": schema_k8sio_api_core_v1_TypedLocalObjectReference(ref), - "k8s.io/api/core/v1.TypedObjectReference": schema_k8sio_api_core_v1_TypedObjectReference(ref), - "k8s.io/api/core/v1.Volume": schema_k8sio_api_core_v1_Volume(ref), - "k8s.io/api/core/v1.VolumeDevice": schema_k8sio_api_core_v1_VolumeDevice(ref), - "k8s.io/api/core/v1.VolumeMount": schema_k8sio_api_core_v1_VolumeMount(ref), - "k8s.io/api/core/v1.VolumeMountStatus": schema_k8sio_api_core_v1_VolumeMountStatus(ref), - "k8s.io/api/core/v1.VolumeNodeAffinity": schema_k8sio_api_core_v1_VolumeNodeAffinity(ref), - "k8s.io/api/core/v1.VolumeProjection": schema_k8sio_api_core_v1_VolumeProjection(ref), - "k8s.io/api/core/v1.VolumeResourceRequirements": schema_k8sio_api_core_v1_VolumeResourceRequirements(ref), - "k8s.io/api/core/v1.VolumeSource": schema_k8sio_api_core_v1_VolumeSource(ref), - "k8s.io/api/core/v1.VsphereVirtualDiskVolumeSource": schema_k8sio_api_core_v1_VsphereVirtualDiskVolumeSource(ref), - "k8s.io/api/core/v1.WeightedPodAffinityTerm": schema_k8sio_api_core_v1_WeightedPodAffinityTerm(ref), - "k8s.io/api/core/v1.WindowsSecurityContextOptions": schema_k8sio_api_core_v1_WindowsSecurityContextOptions(ref), - "k8s.io/api/core/v1.WorkloadReference": schema_k8sio_api_core_v1_WorkloadReference(ref), - "k8s.io/apimachinery/pkg/api/resource.Quantity": schema_apimachinery_pkg_api_resource_Quantity(ref), - "k8s.io/apimachinery/pkg/api/resource.int64Amount": schema_apimachinery_pkg_api_resource_int64Amount(ref), - "k8s.io/apimachinery/pkg/apis/meta/v1.APIGroup": schema_pkg_apis_meta_v1_APIGroup(ref), - "k8s.io/apimachinery/pkg/apis/meta/v1.APIGroupList": schema_pkg_apis_meta_v1_APIGroupList(ref), - "k8s.io/apimachinery/pkg/apis/meta/v1.APIResource": schema_pkg_apis_meta_v1_APIResource(ref), - "k8s.io/apimachinery/pkg/apis/meta/v1.APIResourceList": schema_pkg_apis_meta_v1_APIResourceList(ref), - "k8s.io/apimachinery/pkg/apis/meta/v1.APIVersions": schema_pkg_apis_meta_v1_APIVersions(ref), - "k8s.io/apimachinery/pkg/apis/meta/v1.ApplyOptions": schema_pkg_apis_meta_v1_ApplyOptions(ref), - "k8s.io/apimachinery/pkg/apis/meta/v1.Condition": schema_pkg_apis_meta_v1_Condition(ref), - "k8s.io/apimachinery/pkg/apis/meta/v1.CreateOptions": schema_pkg_apis_meta_v1_CreateOptions(ref), - "k8s.io/apimachinery/pkg/apis/meta/v1.DeleteOptions": schema_pkg_apis_meta_v1_DeleteOptions(ref), - "k8s.io/apimachinery/pkg/apis/meta/v1.Duration": schema_pkg_apis_meta_v1_Duration(ref), - "k8s.io/apimachinery/pkg/apis/meta/v1.FieldSelectorRequirement": schema_pkg_apis_meta_v1_FieldSelectorRequirement(ref), - "k8s.io/apimachinery/pkg/apis/meta/v1.FieldsV1": schema_pkg_apis_meta_v1_FieldsV1(ref), - "k8s.io/apimachinery/pkg/apis/meta/v1.GetOptions": schema_pkg_apis_meta_v1_GetOptions(ref), - "k8s.io/apimachinery/pkg/apis/meta/v1.GroupKind": schema_pkg_apis_meta_v1_GroupKind(ref), - "k8s.io/apimachinery/pkg/apis/meta/v1.GroupResource": schema_pkg_apis_meta_v1_GroupResource(ref), - "k8s.io/apimachinery/pkg/apis/meta/v1.GroupVersion": schema_pkg_apis_meta_v1_GroupVersion(ref), - "k8s.io/apimachinery/pkg/apis/meta/v1.GroupVersionForDiscovery": schema_pkg_apis_meta_v1_GroupVersionForDiscovery(ref), - "k8s.io/apimachinery/pkg/apis/meta/v1.GroupVersionKind": schema_pkg_apis_meta_v1_GroupVersionKind(ref), - "k8s.io/apimachinery/pkg/apis/meta/v1.GroupVersionResource": schema_pkg_apis_meta_v1_GroupVersionResource(ref), - "k8s.io/apimachinery/pkg/apis/meta/v1.InternalEvent": schema_pkg_apis_meta_v1_InternalEvent(ref), - "k8s.io/apimachinery/pkg/apis/meta/v1.LabelSelector": schema_pkg_apis_meta_v1_LabelSelector(ref), - "k8s.io/apimachinery/pkg/apis/meta/v1.LabelSelectorRequirement": schema_pkg_apis_meta_v1_LabelSelectorRequirement(ref), - "k8s.io/apimachinery/pkg/apis/meta/v1.List": schema_pkg_apis_meta_v1_List(ref), - "k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta": schema_pkg_apis_meta_v1_ListMeta(ref), - "k8s.io/apimachinery/pkg/apis/meta/v1.ListOptions": schema_pkg_apis_meta_v1_ListOptions(ref), - "k8s.io/apimachinery/pkg/apis/meta/v1.ManagedFieldsEntry": schema_pkg_apis_meta_v1_ManagedFieldsEntry(ref), - "k8s.io/apimachinery/pkg/apis/meta/v1.MicroTime": schema_pkg_apis_meta_v1_MicroTime(ref), - "k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta": schema_pkg_apis_meta_v1_ObjectMeta(ref), - "k8s.io/apimachinery/pkg/apis/meta/v1.OwnerReference": schema_pkg_apis_meta_v1_OwnerReference(ref), - "k8s.io/apimachinery/pkg/apis/meta/v1.PartialObjectMetadata": schema_pkg_apis_meta_v1_PartialObjectMetadata(ref), - "k8s.io/apimachinery/pkg/apis/meta/v1.PartialObjectMetadataList": schema_pkg_apis_meta_v1_PartialObjectMetadataList(ref), - "k8s.io/apimachinery/pkg/apis/meta/v1.Patch": schema_pkg_apis_meta_v1_Patch(ref), - "k8s.io/apimachinery/pkg/apis/meta/v1.PatchOptions": schema_pkg_apis_meta_v1_PatchOptions(ref), - "k8s.io/apimachinery/pkg/apis/meta/v1.Preconditions": schema_pkg_apis_meta_v1_Preconditions(ref), - "k8s.io/apimachinery/pkg/apis/meta/v1.RootPaths": schema_pkg_apis_meta_v1_RootPaths(ref), - "k8s.io/apimachinery/pkg/apis/meta/v1.ServerAddressByClientCIDR": schema_pkg_apis_meta_v1_ServerAddressByClientCIDR(ref), - "k8s.io/apimachinery/pkg/apis/meta/v1.Status": schema_pkg_apis_meta_v1_Status(ref), - "k8s.io/apimachinery/pkg/apis/meta/v1.StatusCause": schema_pkg_apis_meta_v1_StatusCause(ref), - "k8s.io/apimachinery/pkg/apis/meta/v1.StatusDetails": schema_pkg_apis_meta_v1_StatusDetails(ref), - "k8s.io/apimachinery/pkg/apis/meta/v1.Table": schema_pkg_apis_meta_v1_Table(ref), - "k8s.io/apimachinery/pkg/apis/meta/v1.TableColumnDefinition": schema_pkg_apis_meta_v1_TableColumnDefinition(ref), - "k8s.io/apimachinery/pkg/apis/meta/v1.TableOptions": schema_pkg_apis_meta_v1_TableOptions(ref), - "k8s.io/apimachinery/pkg/apis/meta/v1.TableRow": schema_pkg_apis_meta_v1_TableRow(ref), - "k8s.io/apimachinery/pkg/apis/meta/v1.TableRowCondition": schema_pkg_apis_meta_v1_TableRowCondition(ref), - "k8s.io/apimachinery/pkg/apis/meta/v1.Time": schema_pkg_apis_meta_v1_Time(ref), - "k8s.io/apimachinery/pkg/apis/meta/v1.Timestamp": schema_pkg_apis_meta_v1_Timestamp(ref), - "k8s.io/apimachinery/pkg/apis/meta/v1.TypeMeta": schema_pkg_apis_meta_v1_TypeMeta(ref), - "k8s.io/apimachinery/pkg/apis/meta/v1.UpdateOptions": schema_pkg_apis_meta_v1_UpdateOptions(ref), - "k8s.io/apimachinery/pkg/apis/meta/v1.WatchEvent": schema_pkg_apis_meta_v1_WatchEvent(ref), - "k8s.io/apimachinery/pkg/runtime.RawExtension": schema_k8sio_apimachinery_pkg_runtime_RawExtension(ref), - "k8s.io/apimachinery/pkg/runtime.TypeMeta": schema_k8sio_apimachinery_pkg_runtime_TypeMeta(ref), - "k8s.io/apimachinery/pkg/runtime.Unknown": schema_k8sio_apimachinery_pkg_runtime_Unknown(ref), - "k8s.io/apimachinery/pkg/version.Info": schema_k8sio_apimachinery_pkg_version_Info(ref), + v1.AWSElasticBlockStoreVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_AWSElasticBlockStoreVolumeSource(ref), + v1.Affinity{}.OpenAPIModelName(): schema_k8sio_api_core_v1_Affinity(ref), + v1.AppArmorProfile{}.OpenAPIModelName(): schema_k8sio_api_core_v1_AppArmorProfile(ref), + v1.AttachedVolume{}.OpenAPIModelName(): schema_k8sio_api_core_v1_AttachedVolume(ref), + v1.AvoidPods{}.OpenAPIModelName(): schema_k8sio_api_core_v1_AvoidPods(ref), + v1.AzureDiskVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_AzureDiskVolumeSource(ref), + v1.AzureFilePersistentVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_AzureFilePersistentVolumeSource(ref), + v1.AzureFileVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_AzureFileVolumeSource(ref), + v1.Binding{}.OpenAPIModelName(): schema_k8sio_api_core_v1_Binding(ref), + v1.CSIPersistentVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_CSIPersistentVolumeSource(ref), + v1.CSIVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_CSIVolumeSource(ref), + v1.Capabilities{}.OpenAPIModelName(): schema_k8sio_api_core_v1_Capabilities(ref), + v1.CephFSPersistentVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_CephFSPersistentVolumeSource(ref), + v1.CephFSVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_CephFSVolumeSource(ref), + v1.CinderPersistentVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_CinderPersistentVolumeSource(ref), + v1.CinderVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_CinderVolumeSource(ref), + v1.ClientIPConfig{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ClientIPConfig(ref), + v1.ClusterTrustBundleProjection{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ClusterTrustBundleProjection(ref), + v1.ComponentCondition{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ComponentCondition(ref), + v1.ComponentStatus{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ComponentStatus(ref), + v1.ComponentStatusList{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ComponentStatusList(ref), + v1.ConfigMap{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ConfigMap(ref), + v1.ConfigMapEnvSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ConfigMapEnvSource(ref), + v1.ConfigMapKeySelector{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ConfigMapKeySelector(ref), + v1.ConfigMapList{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ConfigMapList(ref), + v1.ConfigMapNodeConfigSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ConfigMapNodeConfigSource(ref), + v1.ConfigMapProjection{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ConfigMapProjection(ref), + v1.ConfigMapVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ConfigMapVolumeSource(ref), + v1.Container{}.OpenAPIModelName(): schema_k8sio_api_core_v1_Container(ref), + v1.ContainerExtendedResourceRequest{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ContainerExtendedResourceRequest(ref), + v1.ContainerImage{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ContainerImage(ref), + v1.ContainerPort{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ContainerPort(ref), + v1.ContainerResizePolicy{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ContainerResizePolicy(ref), + v1.ContainerRestartRule{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ContainerRestartRule(ref), + v1.ContainerRestartRuleOnExitCodes{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ContainerRestartRuleOnExitCodes(ref), + v1.ContainerState{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ContainerState(ref), + v1.ContainerStateRunning{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ContainerStateRunning(ref), + v1.ContainerStateTerminated{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ContainerStateTerminated(ref), + v1.ContainerStateWaiting{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ContainerStateWaiting(ref), + v1.ContainerStatus{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ContainerStatus(ref), + v1.ContainerUser{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ContainerUser(ref), + v1.DaemonEndpoint{}.OpenAPIModelName(): schema_k8sio_api_core_v1_DaemonEndpoint(ref), + v1.DownwardAPIProjection{}.OpenAPIModelName(): schema_k8sio_api_core_v1_DownwardAPIProjection(ref), + v1.DownwardAPIVolumeFile{}.OpenAPIModelName(): schema_k8sio_api_core_v1_DownwardAPIVolumeFile(ref), + v1.DownwardAPIVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_DownwardAPIVolumeSource(ref), + v1.EmptyDirVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_EmptyDirVolumeSource(ref), + v1.EndpointAddress{}.OpenAPIModelName(): schema_k8sio_api_core_v1_EndpointAddress(ref), + v1.EndpointPort{}.OpenAPIModelName(): schema_k8sio_api_core_v1_EndpointPort(ref), + v1.EndpointSubset{}.OpenAPIModelName(): schema_k8sio_api_core_v1_EndpointSubset(ref), + v1.Endpoints{}.OpenAPIModelName(): schema_k8sio_api_core_v1_Endpoints(ref), + v1.EndpointsList{}.OpenAPIModelName(): schema_k8sio_api_core_v1_EndpointsList(ref), + v1.EnvFromSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_EnvFromSource(ref), + v1.EnvVar{}.OpenAPIModelName(): schema_k8sio_api_core_v1_EnvVar(ref), + v1.EnvVarSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_EnvVarSource(ref), + v1.EphemeralContainer{}.OpenAPIModelName(): schema_k8sio_api_core_v1_EphemeralContainer(ref), + v1.EphemeralContainerCommon{}.OpenAPIModelName(): schema_k8sio_api_core_v1_EphemeralContainerCommon(ref), + v1.EphemeralVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_EphemeralVolumeSource(ref), + v1.Event{}.OpenAPIModelName(): schema_k8sio_api_core_v1_Event(ref), + v1.EventList{}.OpenAPIModelName(): schema_k8sio_api_core_v1_EventList(ref), + v1.EventSeries{}.OpenAPIModelName(): schema_k8sio_api_core_v1_EventSeries(ref), + v1.EventSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_EventSource(ref), + v1.ExecAction{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ExecAction(ref), + v1.FCVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_FCVolumeSource(ref), + v1.FileKeySelector{}.OpenAPIModelName(): schema_k8sio_api_core_v1_FileKeySelector(ref), + v1.FlexPersistentVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_FlexPersistentVolumeSource(ref), + v1.FlexVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_FlexVolumeSource(ref), + v1.FlockerVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_FlockerVolumeSource(ref), + v1.GCEPersistentDiskVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_GCEPersistentDiskVolumeSource(ref), + v1.GRPCAction{}.OpenAPIModelName(): schema_k8sio_api_core_v1_GRPCAction(ref), + v1.GitRepoVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_GitRepoVolumeSource(ref), + v1.GlusterfsPersistentVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_GlusterfsPersistentVolumeSource(ref), + v1.GlusterfsVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_GlusterfsVolumeSource(ref), + v1.HTTPGetAction{}.OpenAPIModelName(): schema_k8sio_api_core_v1_HTTPGetAction(ref), + v1.HTTPHeader{}.OpenAPIModelName(): schema_k8sio_api_core_v1_HTTPHeader(ref), + v1.HostAlias{}.OpenAPIModelName(): schema_k8sio_api_core_v1_HostAlias(ref), + v1.HostIP{}.OpenAPIModelName(): schema_k8sio_api_core_v1_HostIP(ref), + v1.HostPathVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_HostPathVolumeSource(ref), + v1.ISCSIPersistentVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ISCSIPersistentVolumeSource(ref), + v1.ISCSIVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ISCSIVolumeSource(ref), + v1.ImageVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ImageVolumeSource(ref), + v1.KeyToPath{}.OpenAPIModelName(): schema_k8sio_api_core_v1_KeyToPath(ref), + v1.Lifecycle{}.OpenAPIModelName(): schema_k8sio_api_core_v1_Lifecycle(ref), + v1.LifecycleHandler{}.OpenAPIModelName(): schema_k8sio_api_core_v1_LifecycleHandler(ref), + v1.LimitRange{}.OpenAPIModelName(): schema_k8sio_api_core_v1_LimitRange(ref), + v1.LimitRangeItem{}.OpenAPIModelName(): schema_k8sio_api_core_v1_LimitRangeItem(ref), + v1.LimitRangeList{}.OpenAPIModelName(): schema_k8sio_api_core_v1_LimitRangeList(ref), + v1.LimitRangeSpec{}.OpenAPIModelName(): schema_k8sio_api_core_v1_LimitRangeSpec(ref), + v1.LinuxContainerUser{}.OpenAPIModelName(): schema_k8sio_api_core_v1_LinuxContainerUser(ref), + v1.List{}.OpenAPIModelName(): schema_k8sio_api_core_v1_List(ref), + v1.LoadBalancerIngress{}.OpenAPIModelName(): schema_k8sio_api_core_v1_LoadBalancerIngress(ref), + v1.LoadBalancerStatus{}.OpenAPIModelName(): schema_k8sio_api_core_v1_LoadBalancerStatus(ref), + v1.LocalObjectReference{}.OpenAPIModelName(): schema_k8sio_api_core_v1_LocalObjectReference(ref), + v1.LocalVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_LocalVolumeSource(ref), + v1.ModifyVolumeStatus{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ModifyVolumeStatus(ref), + v1.NFSVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_NFSVolumeSource(ref), + v1.Namespace{}.OpenAPIModelName(): schema_k8sio_api_core_v1_Namespace(ref), + v1.NamespaceCondition{}.OpenAPIModelName(): schema_k8sio_api_core_v1_NamespaceCondition(ref), + v1.NamespaceList{}.OpenAPIModelName(): schema_k8sio_api_core_v1_NamespaceList(ref), + v1.NamespaceSpec{}.OpenAPIModelName(): schema_k8sio_api_core_v1_NamespaceSpec(ref), + v1.NamespaceStatus{}.OpenAPIModelName(): schema_k8sio_api_core_v1_NamespaceStatus(ref), + v1.Node{}.OpenAPIModelName(): schema_k8sio_api_core_v1_Node(ref), + v1.NodeAddress{}.OpenAPIModelName(): schema_k8sio_api_core_v1_NodeAddress(ref), + v1.NodeAffinity{}.OpenAPIModelName(): schema_k8sio_api_core_v1_NodeAffinity(ref), + v1.NodeCondition{}.OpenAPIModelName(): schema_k8sio_api_core_v1_NodeCondition(ref), + v1.NodeConfigSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_NodeConfigSource(ref), + v1.NodeConfigStatus{}.OpenAPIModelName(): schema_k8sio_api_core_v1_NodeConfigStatus(ref), + v1.NodeDaemonEndpoints{}.OpenAPIModelName(): schema_k8sio_api_core_v1_NodeDaemonEndpoints(ref), + v1.NodeFeatures{}.OpenAPIModelName(): schema_k8sio_api_core_v1_NodeFeatures(ref), + v1.NodeList{}.OpenAPIModelName(): schema_k8sio_api_core_v1_NodeList(ref), + v1.NodeProxyOptions{}.OpenAPIModelName(): schema_k8sio_api_core_v1_NodeProxyOptions(ref), + v1.NodeRuntimeHandler{}.OpenAPIModelName(): schema_k8sio_api_core_v1_NodeRuntimeHandler(ref), + v1.NodeRuntimeHandlerFeatures{}.OpenAPIModelName(): schema_k8sio_api_core_v1_NodeRuntimeHandlerFeatures(ref), + v1.NodeSelector{}.OpenAPIModelName(): schema_k8sio_api_core_v1_NodeSelector(ref), + v1.NodeSelectorRequirement{}.OpenAPIModelName(): schema_k8sio_api_core_v1_NodeSelectorRequirement(ref), + v1.NodeSelectorTerm{}.OpenAPIModelName(): schema_k8sio_api_core_v1_NodeSelectorTerm(ref), + v1.NodeSpec{}.OpenAPIModelName(): schema_k8sio_api_core_v1_NodeSpec(ref), + v1.NodeStatus{}.OpenAPIModelName(): schema_k8sio_api_core_v1_NodeStatus(ref), + v1.NodeSwapStatus{}.OpenAPIModelName(): schema_k8sio_api_core_v1_NodeSwapStatus(ref), + v1.NodeSystemInfo{}.OpenAPIModelName(): schema_k8sio_api_core_v1_NodeSystemInfo(ref), + v1.ObjectFieldSelector{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ObjectFieldSelector(ref), + v1.ObjectReference{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ObjectReference(ref), + v1.PersistentVolume{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PersistentVolume(ref), + v1.PersistentVolumeClaim{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PersistentVolumeClaim(ref), + v1.PersistentVolumeClaimCondition{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PersistentVolumeClaimCondition(ref), + v1.PersistentVolumeClaimList{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PersistentVolumeClaimList(ref), + v1.PersistentVolumeClaimSpec{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PersistentVolumeClaimSpec(ref), + v1.PersistentVolumeClaimStatus{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PersistentVolumeClaimStatus(ref), + v1.PersistentVolumeClaimTemplate{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PersistentVolumeClaimTemplate(ref), + v1.PersistentVolumeClaimVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PersistentVolumeClaimVolumeSource(ref), + v1.PersistentVolumeList{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PersistentVolumeList(ref), + v1.PersistentVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PersistentVolumeSource(ref), + v1.PersistentVolumeSpec{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PersistentVolumeSpec(ref), + v1.PersistentVolumeStatus{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PersistentVolumeStatus(ref), + v1.PhotonPersistentDiskVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PhotonPersistentDiskVolumeSource(ref), + v1.Pod{}.OpenAPIModelName(): schema_k8sio_api_core_v1_Pod(ref), + v1.PodAffinity{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PodAffinity(ref), + v1.PodAffinityTerm{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PodAffinityTerm(ref), + v1.PodAntiAffinity{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PodAntiAffinity(ref), + v1.PodAttachOptions{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PodAttachOptions(ref), + v1.PodCertificateProjection{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PodCertificateProjection(ref), + v1.PodCondition{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PodCondition(ref), + v1.PodDNSConfig{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PodDNSConfig(ref), + v1.PodDNSConfigOption{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PodDNSConfigOption(ref), + v1.PodExecOptions{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PodExecOptions(ref), + v1.PodExtendedResourceClaimStatus{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PodExtendedResourceClaimStatus(ref), + v1.PodIP{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PodIP(ref), + v1.PodList{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PodList(ref), + v1.PodLogOptions{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PodLogOptions(ref), + v1.PodOS{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PodOS(ref), + v1.PodPortForwardOptions{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PodPortForwardOptions(ref), + v1.PodProxyOptions{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PodProxyOptions(ref), + v1.PodReadinessGate{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PodReadinessGate(ref), + v1.PodResourceClaim{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PodResourceClaim(ref), + v1.PodResourceClaimStatus{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PodResourceClaimStatus(ref), + v1.PodSchedulingGate{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PodSchedulingGate(ref), + v1.PodSecurityContext{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PodSecurityContext(ref), + v1.PodSignature{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PodSignature(ref), + v1.PodSpec{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PodSpec(ref), + v1.PodStatus{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PodStatus(ref), + v1.PodStatusResult{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PodStatusResult(ref), + v1.PodTemplate{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PodTemplate(ref), + v1.PodTemplateList{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PodTemplateList(ref), + v1.PodTemplateSpec{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PodTemplateSpec(ref), + v1.PortStatus{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PortStatus(ref), + v1.PortworxVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PortworxVolumeSource(ref), + v1.PreferAvoidPodsEntry{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PreferAvoidPodsEntry(ref), + v1.PreferredSchedulingTerm{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PreferredSchedulingTerm(ref), + v1.Probe{}.OpenAPIModelName(): schema_k8sio_api_core_v1_Probe(ref), + v1.ProbeHandler{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ProbeHandler(ref), + v1.ProjectedVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ProjectedVolumeSource(ref), + v1.QuobyteVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_QuobyteVolumeSource(ref), + v1.RBDPersistentVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_RBDPersistentVolumeSource(ref), + v1.RBDVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_RBDVolumeSource(ref), + v1.RangeAllocation{}.OpenAPIModelName(): schema_k8sio_api_core_v1_RangeAllocation(ref), + v1.ReplicationController{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ReplicationController(ref), + v1.ReplicationControllerCondition{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ReplicationControllerCondition(ref), + v1.ReplicationControllerList{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ReplicationControllerList(ref), + v1.ReplicationControllerSpec{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ReplicationControllerSpec(ref), + v1.ReplicationControllerStatus{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ReplicationControllerStatus(ref), + v1.ResourceClaim{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ResourceClaim(ref), + v1.ResourceFieldSelector{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ResourceFieldSelector(ref), + v1.ResourceHealth{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ResourceHealth(ref), + v1.ResourceQuota{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ResourceQuota(ref), + v1.ResourceQuotaList{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ResourceQuotaList(ref), + v1.ResourceQuotaSpec{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ResourceQuotaSpec(ref), + v1.ResourceQuotaStatus{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ResourceQuotaStatus(ref), + v1.ResourceRequirements{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ResourceRequirements(ref), + v1.ResourceStatus{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ResourceStatus(ref), + v1.SELinuxOptions{}.OpenAPIModelName(): schema_k8sio_api_core_v1_SELinuxOptions(ref), + v1.ScaleIOPersistentVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ScaleIOPersistentVolumeSource(ref), + v1.ScaleIOVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ScaleIOVolumeSource(ref), + v1.ScopeSelector{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ScopeSelector(ref), + v1.ScopedResourceSelectorRequirement{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ScopedResourceSelectorRequirement(ref), + v1.SeccompProfile{}.OpenAPIModelName(): schema_k8sio_api_core_v1_SeccompProfile(ref), + v1.Secret{}.OpenAPIModelName(): schema_k8sio_api_core_v1_Secret(ref), + v1.SecretEnvSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_SecretEnvSource(ref), + v1.SecretKeySelector{}.OpenAPIModelName(): schema_k8sio_api_core_v1_SecretKeySelector(ref), + v1.SecretList{}.OpenAPIModelName(): schema_k8sio_api_core_v1_SecretList(ref), + v1.SecretProjection{}.OpenAPIModelName(): schema_k8sio_api_core_v1_SecretProjection(ref), + v1.SecretReference{}.OpenAPIModelName(): schema_k8sio_api_core_v1_SecretReference(ref), + v1.SecretVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_SecretVolumeSource(ref), + v1.SecurityContext{}.OpenAPIModelName(): schema_k8sio_api_core_v1_SecurityContext(ref), + v1.SerializedReference{}.OpenAPIModelName(): schema_k8sio_api_core_v1_SerializedReference(ref), + v1.Service{}.OpenAPIModelName(): schema_k8sio_api_core_v1_Service(ref), + v1.ServiceAccount{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ServiceAccount(ref), + v1.ServiceAccountList{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ServiceAccountList(ref), + v1.ServiceAccountTokenProjection{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ServiceAccountTokenProjection(ref), + v1.ServiceList{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ServiceList(ref), + v1.ServicePort{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ServicePort(ref), + v1.ServiceProxyOptions{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ServiceProxyOptions(ref), + v1.ServiceSpec{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ServiceSpec(ref), + v1.ServiceStatus{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ServiceStatus(ref), + v1.SessionAffinityConfig{}.OpenAPIModelName(): schema_k8sio_api_core_v1_SessionAffinityConfig(ref), + v1.SleepAction{}.OpenAPIModelName(): schema_k8sio_api_core_v1_SleepAction(ref), + v1.StorageOSPersistentVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_StorageOSPersistentVolumeSource(ref), + v1.StorageOSVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_StorageOSVolumeSource(ref), + v1.Sysctl{}.OpenAPIModelName(): schema_k8sio_api_core_v1_Sysctl(ref), + v1.TCPSocketAction{}.OpenAPIModelName(): schema_k8sio_api_core_v1_TCPSocketAction(ref), + v1.Taint{}.OpenAPIModelName(): schema_k8sio_api_core_v1_Taint(ref), + v1.Toleration{}.OpenAPIModelName(): schema_k8sio_api_core_v1_Toleration(ref), + v1.TopologySelectorLabelRequirement{}.OpenAPIModelName(): schema_k8sio_api_core_v1_TopologySelectorLabelRequirement(ref), + v1.TopologySelectorTerm{}.OpenAPIModelName(): schema_k8sio_api_core_v1_TopologySelectorTerm(ref), + v1.TopologySpreadConstraint{}.OpenAPIModelName(): schema_k8sio_api_core_v1_TopologySpreadConstraint(ref), + v1.TypedLocalObjectReference{}.OpenAPIModelName(): schema_k8sio_api_core_v1_TypedLocalObjectReference(ref), + v1.TypedObjectReference{}.OpenAPIModelName(): schema_k8sio_api_core_v1_TypedObjectReference(ref), + v1.Volume{}.OpenAPIModelName(): schema_k8sio_api_core_v1_Volume(ref), + v1.VolumeDevice{}.OpenAPIModelName(): schema_k8sio_api_core_v1_VolumeDevice(ref), + v1.VolumeMount{}.OpenAPIModelName(): schema_k8sio_api_core_v1_VolumeMount(ref), + v1.VolumeMountStatus{}.OpenAPIModelName(): schema_k8sio_api_core_v1_VolumeMountStatus(ref), + v1.VolumeNodeAffinity{}.OpenAPIModelName(): schema_k8sio_api_core_v1_VolumeNodeAffinity(ref), + v1.VolumeProjection{}.OpenAPIModelName(): schema_k8sio_api_core_v1_VolumeProjection(ref), + v1.VolumeResourceRequirements{}.OpenAPIModelName(): schema_k8sio_api_core_v1_VolumeResourceRequirements(ref), + v1.VolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_VolumeSource(ref), + v1.VsphereVirtualDiskVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_VsphereVirtualDiskVolumeSource(ref), + v1.WeightedPodAffinityTerm{}.OpenAPIModelName(): schema_k8sio_api_core_v1_WeightedPodAffinityTerm(ref), + v1.WindowsSecurityContextOptions{}.OpenAPIModelName(): schema_k8sio_api_core_v1_WindowsSecurityContextOptions(ref), + v1.WorkloadReference{}.OpenAPIModelName(): schema_k8sio_api_core_v1_WorkloadReference(ref), + resource.Quantity{}.OpenAPIModelName(): schema_apimachinery_pkg_api_resource_Quantity(ref), + metav1.APIGroup{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_APIGroup(ref), + metav1.APIGroupList{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_APIGroupList(ref), + metav1.APIResource{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_APIResource(ref), + metav1.APIResourceList{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_APIResourceList(ref), + metav1.APIVersions{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_APIVersions(ref), + metav1.ApplyOptions{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_ApplyOptions(ref), + metav1.Condition{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_Condition(ref), + metav1.CreateOptions{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_CreateOptions(ref), + metav1.DeleteOptions{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_DeleteOptions(ref), + metav1.Duration{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_Duration(ref), + metav1.FieldSelectorRequirement{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_FieldSelectorRequirement(ref), + metav1.FieldsV1{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_FieldsV1(ref), + metav1.GetOptions{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_GetOptions(ref), + metav1.GroupKind{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_GroupKind(ref), + metav1.GroupResource{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_GroupResource(ref), + metav1.GroupVersion{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_GroupVersion(ref), + metav1.GroupVersionForDiscovery{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_GroupVersionForDiscovery(ref), + metav1.GroupVersionKind{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_GroupVersionKind(ref), + metav1.GroupVersionResource{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_GroupVersionResource(ref), + metav1.InternalEvent{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_InternalEvent(ref), + metav1.LabelSelector{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_LabelSelector(ref), + metav1.LabelSelectorRequirement{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_LabelSelectorRequirement(ref), + metav1.List{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_List(ref), + metav1.ListMeta{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_ListMeta(ref), + metav1.ListOptions{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_ListOptions(ref), + metav1.ManagedFieldsEntry{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_ManagedFieldsEntry(ref), + metav1.MicroTime{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_MicroTime(ref), + metav1.ObjectMeta{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_ObjectMeta(ref), + metav1.OwnerReference{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_OwnerReference(ref), + metav1.PartialObjectMetadata{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_PartialObjectMetadata(ref), + metav1.PartialObjectMetadataList{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_PartialObjectMetadataList(ref), + metav1.Patch{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_Patch(ref), + metav1.PatchOptions{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_PatchOptions(ref), + metav1.Preconditions{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_Preconditions(ref), + metav1.RootPaths{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_RootPaths(ref), + metav1.ServerAddressByClientCIDR{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_ServerAddressByClientCIDR(ref), + metav1.Status{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_Status(ref), + metav1.StatusCause{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_StatusCause(ref), + metav1.StatusDetails{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_StatusDetails(ref), + metav1.Table{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_Table(ref), + metav1.TableColumnDefinition{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_TableColumnDefinition(ref), + metav1.TableOptions{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_TableOptions(ref), + metav1.TableRow{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_TableRow(ref), + metav1.TableRowCondition{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_TableRowCondition(ref), + metav1.Time{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_Time(ref), + metav1.Timestamp{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_Timestamp(ref), + metav1.TypeMeta{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_TypeMeta(ref), + metav1.UpdateOptions{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_UpdateOptions(ref), + metav1.WatchEvent{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_WatchEvent(ref), + runtime.RawExtension{}.OpenAPIModelName(): schema_k8sio_apimachinery_pkg_runtime_RawExtension(ref), + runtime.TypeMeta{}.OpenAPIModelName(): schema_k8sio_apimachinery_pkg_runtime_TypeMeta(ref), + runtime.Unknown{}.OpenAPIModelName(): schema_k8sio_apimachinery_pkg_runtime_Unknown(ref), + version.Info{}.OpenAPIModelName(): schema_k8sio_apimachinery_pkg_version_Info(ref), } } @@ -445,7 +446,7 @@ func schema_config_server_apis_condition_v1alpha1_Condition(ref common.Reference "lastTransitionTime": { SchemaProps: spec.SchemaProps{ Description: "lastTransitionTime is the last time the condition transitioned from one status to another. This should be when the underlying condition changed. If that is not known, then using the time when the API field changed is acceptable.", - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.Time"), + Ref: ref(metav1.Time{}.OpenAPIModelName()), }, }, "reason": { @@ -469,7 +470,7 @@ func schema_config_server_apis_condition_v1alpha1_Condition(ref common.Reference }, }, Dependencies: []string{ - "k8s.io/apimachinery/pkg/apis/meta/v1.Time"}, + metav1.Time{}.OpenAPIModelName()}, } } @@ -561,7 +562,7 @@ func schema_config_server_apis_config_v1alpha1_Config(ref common.ReferenceCallba "metadata": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"), + Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), }, }, "spec": { @@ -576,19 +577,11 @@ func schema_config_server_apis_config_v1alpha1_Config(ref common.ReferenceCallba Ref: ref("github.com/sdcio/config-server/apis/config/v1alpha1.ConfigStatus"), }, }, - - }, - }, - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-group-version-kind": []interface{}{ - map[string]interface{}{"group": "config.sdcio.dev", "kind": "Config", "version": "v1alpha1"}, - }, }, }, }, Dependencies: []string{ - "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigSpec", "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigStatus", "k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"}, + "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigSpec", "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigStatus", metav1.ObjectMeta{}.OpenAPIModelName()}, } } @@ -616,7 +609,7 @@ func schema_config_server_apis_config_v1alpha1_ConfigBlame(ref common.ReferenceC "metadata": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"), + Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), }, }, "spec": { @@ -635,7 +628,7 @@ func schema_config_server_apis_config_v1alpha1_ConfigBlame(ref common.ReferenceC }, }, Dependencies: []string{ - "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigBlameSpec", "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigBlameStatus", "k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"}, + "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigBlameSpec", "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigBlameStatus", metav1.ObjectMeta{}.OpenAPIModelName()}, } } @@ -663,7 +656,7 @@ func schema_config_server_apis_config_v1alpha1_ConfigBlameList(ref common.Refere "metadata": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"), + Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), }, }, "items": { @@ -684,7 +677,7 @@ func schema_config_server_apis_config_v1alpha1_ConfigBlameList(ref common.Refere }, }, Dependencies: []string{ - "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigBlame", "k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"}, + "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigBlame", metav1.ListMeta{}.OpenAPIModelName()}, } } @@ -708,7 +701,7 @@ func schema_config_server_apis_config_v1alpha1_ConfigBlameStatus(ref common.Refe Properties: map[string]spec.Schema{ "value": { SchemaProps: spec.SchemaProps{ - Ref: ref("k8s.io/apimachinery/pkg/runtime.RawExtension"), + Ref: ref(runtime.RawExtension{}.OpenAPIModelName()), }, }, }, @@ -716,7 +709,7 @@ func schema_config_server_apis_config_v1alpha1_ConfigBlameStatus(ref common.Refe }, }, Dependencies: []string{ - "k8s.io/apimachinery/pkg/runtime.RawExtension"}, + runtime.RawExtension{}.OpenAPIModelName()}, } } @@ -735,7 +728,7 @@ func schema_config_server_apis_config_v1alpha1_ConfigBlob(ref common.ReferenceCa }, "value": { SchemaProps: spec.SchemaProps{ - Ref: ref("k8s.io/apimachinery/pkg/runtime.RawExtension"), + Ref: ref(runtime.RawExtension{}.OpenAPIModelName()), }, }, }, @@ -743,7 +736,7 @@ func schema_config_server_apis_config_v1alpha1_ConfigBlob(ref common.ReferenceCa }, }, Dependencies: []string{ - "k8s.io/apimachinery/pkg/runtime.RawExtension"}, + runtime.RawExtension{}.OpenAPIModelName()}, } } @@ -811,7 +804,7 @@ func schema_config_server_apis_config_v1alpha1_ConfigList(ref common.ReferenceCa "metadata": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"), + Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), }, }, "items": { @@ -832,7 +825,7 @@ func schema_config_server_apis_config_v1alpha1_ConfigList(ref common.ReferenceCa }, }, Dependencies: []string{ - "github.com/sdcio/config-server/apis/config/v1alpha1.Config", "k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"}, + "github.com/sdcio/config-server/apis/config/v1alpha1.Config", metav1.ListMeta{}.OpenAPIModelName()}, } } @@ -860,7 +853,7 @@ func schema_config_server_apis_config_v1alpha1_ConfigSet(ref common.ReferenceCal "metadata": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"), + Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), }, }, "spec": { @@ -879,7 +872,7 @@ func schema_config_server_apis_config_v1alpha1_ConfigSet(ref common.ReferenceCal }, }, Dependencies: []string{ - "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigSetSpec", "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigSetStatus", "k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"}, + "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigSetSpec", "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigSetStatus", metav1.ObjectMeta{}.OpenAPIModelName()}, } } @@ -907,7 +900,7 @@ func schema_config_server_apis_config_v1alpha1_ConfigSetList(ref common.Referenc "metadata": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"), + Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), }, }, "items": { @@ -928,7 +921,7 @@ func schema_config_server_apis_config_v1alpha1_ConfigSetList(ref common.Referenc }, }, Dependencies: []string{ - "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigSet", "k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"}, + "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigSet", metav1.ListMeta{}.OpenAPIModelName()}, } } @@ -1203,7 +1196,7 @@ func schema_config_server_apis_config_v1alpha1_Deviation(ref common.ReferenceCal "metadata": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"), + Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), }, }, "spec": { @@ -1220,16 +1213,9 @@ func schema_config_server_apis_config_v1alpha1_Deviation(ref common.ReferenceCal }, }, }, - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-group-version-kind": []interface{}{ - map[string]interface{}{"group": "config.sdcio.dev", "kind": "Deviation", "version": "v1alpha1"}, - }, - }, - }, }, Dependencies: []string{ - "github.com/sdcio/config-server/apis/config/v1alpha1.DeviationSpec", "github.com/sdcio/config-server/apis/config/v1alpha1.DeviationStatus", "k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"}, + "github.com/sdcio/config-server/apis/config/v1alpha1.DeviationSpec", "github.com/sdcio/config-server/apis/config/v1alpha1.DeviationStatus", metav1.ObjectMeta{}.OpenAPIModelName()}, } } @@ -1257,7 +1243,7 @@ func schema_config_server_apis_config_v1alpha1_DeviationList(ref common.Referenc "metadata": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"), + Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), }, }, "items": { @@ -1278,7 +1264,7 @@ func schema_config_server_apis_config_v1alpha1_DeviationList(ref common.Referenc }, }, Dependencies: []string{ - "github.com/sdcio/config-server/apis/config/v1alpha1.Deviation", "k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"}, + "github.com/sdcio/config-server/apis/config/v1alpha1.Deviation", metav1.ListMeta{}.OpenAPIModelName()}, } } @@ -1397,7 +1383,7 @@ func schema_config_server_apis_config_v1alpha1_RunningConfig(ref common.Referenc "metadata": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"), + Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), }, }, "spec": { @@ -1416,7 +1402,7 @@ func schema_config_server_apis_config_v1alpha1_RunningConfig(ref common.Referenc }, }, Dependencies: []string{ - "github.com/sdcio/config-server/apis/config/v1alpha1.RunningConfigSpec", "github.com/sdcio/config-server/apis/config/v1alpha1.RunningConfigStatus", "k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"}, + "github.com/sdcio/config-server/apis/config/v1alpha1.RunningConfigSpec", "github.com/sdcio/config-server/apis/config/v1alpha1.RunningConfigStatus", metav1.ObjectMeta{}.OpenAPIModelName()}, } } @@ -1444,7 +1430,7 @@ func schema_config_server_apis_config_v1alpha1_RunningConfigList(ref common.Refe "metadata": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"), + Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), }, }, "items": { @@ -1465,7 +1451,7 @@ func schema_config_server_apis_config_v1alpha1_RunningConfigList(ref common.Refe }, }, Dependencies: []string{ - "github.com/sdcio/config-server/apis/config/v1alpha1.RunningConfig", "k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"}, + "github.com/sdcio/config-server/apis/config/v1alpha1.RunningConfig", metav1.ListMeta{}.OpenAPIModelName()}, } } @@ -1489,7 +1475,7 @@ func schema_config_server_apis_config_v1alpha1_RunningConfigStatus(ref common.Re Properties: map[string]spec.Schema{ "value": { SchemaProps: spec.SchemaProps{ - Ref: ref("k8s.io/apimachinery/pkg/runtime.RawExtension"), + Ref: ref(runtime.RawExtension{}.OpenAPIModelName()), }, }, }, @@ -1497,7 +1483,7 @@ func schema_config_server_apis_config_v1alpha1_RunningConfigStatus(ref common.Re }, }, Dependencies: []string{ - "k8s.io/apimachinery/pkg/runtime.RawExtension"}, + runtime.RawExtension{}.OpenAPIModelName()}, } } @@ -1525,7 +1511,7 @@ func schema_config_server_apis_config_v1alpha1_SensitiveConfig(ref common.Refere "metadata": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"), + Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), }, }, "spec": { @@ -1544,7 +1530,7 @@ func schema_config_server_apis_config_v1alpha1_SensitiveConfig(ref common.Refere }, }, Dependencies: []string{ - "github.com/sdcio/config-server/apis/config/v1alpha1.SensitiveConfigSpec", "github.com/sdcio/config-server/apis/config/v1alpha1.SensitiveConfigStatus", "k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"}, + "github.com/sdcio/config-server/apis/config/v1alpha1.SensitiveConfigSpec", "github.com/sdcio/config-server/apis/config/v1alpha1.SensitiveConfigStatus", metav1.ObjectMeta{}.OpenAPIModelName()}, } } @@ -1566,7 +1552,7 @@ func schema_config_server_apis_config_v1alpha1_SensitiveConfigData(ref common.Re SchemaProps: spec.SchemaProps{ Description: "SecretKeyRef refers to a secret in the same namesapce as the config", Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.SecretKeySelector"), + Ref: ref(v1.SecretKeySelector{}.OpenAPIModelName()), }, }, }, @@ -1574,7 +1560,7 @@ func schema_config_server_apis_config_v1alpha1_SensitiveConfigData(ref common.Re }, }, Dependencies: []string{ - "k8s.io/api/core/v1.SecretKeySelector"}, + v1.SecretKeySelector{}.OpenAPIModelName()}, } } @@ -1602,7 +1588,7 @@ func schema_config_server_apis_config_v1alpha1_SensitiveConfigList(ref common.Re "metadata": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"), + Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), }, }, "items": { @@ -1623,7 +1609,7 @@ func schema_config_server_apis_config_v1alpha1_SensitiveConfigList(ref common.Re }, }, Dependencies: []string{ - "github.com/sdcio/config-server/apis/config/v1alpha1.SensitiveConfig", "k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"}, + "github.com/sdcio/config-server/apis/config/v1alpha1.SensitiveConfig", metav1.ListMeta{}.OpenAPIModelName()}, } } @@ -1742,14 +1728,14 @@ func schema_config_server_apis_config_v1alpha1_Target(ref common.ReferenceCallba "targetSelector": { SchemaProps: spec.SchemaProps{ Description: "TargetSelector defines the selector used to select the targets to which the config applies", - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.LabelSelector"), + Ref: ref(metav1.LabelSelector{}.OpenAPIModelName()), }, }, }, }, }, Dependencies: []string{ - "k8s.io/apimachinery/pkg/apis/meta/v1.LabelSelector"}, + metav1.LabelSelector{}.OpenAPIModelName()}, } } @@ -1792,7 +1778,7 @@ func schema_config_server_apis_config_v1alpha1_TargetStatus(ref common.Reference "lastTransitionTime": { SchemaProps: spec.SchemaProps{ Description: "lastTransitionTime is the last time the condition transitioned from one status to another. This should be when the underlying condition changed. If that is not known, then using the time when the API field changed is acceptable.", - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.Time"), + Ref: ref(metav1.Time{}.OpenAPIModelName()), }, }, "reason": { @@ -1816,7 +1802,7 @@ func schema_config_server_apis_config_v1alpha1_TargetStatus(ref common.Reference }, }, Dependencies: []string{ - "k8s.io/apimachinery/pkg/apis/meta/v1.Time"}, + metav1.Time{}.OpenAPIModelName()}, } } @@ -1937,7 +1923,7 @@ func schema_config_server_apis_inv_v1alpha1_DiscoveryParameters(ref common.Refer "period": { SchemaProps: spec.SchemaProps{ Description: "Period defines the wait period between discovery rule runs", - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.Duration"), + Ref: ref(metav1.Duration{}.OpenAPIModelName()), }, }, "concurrentScans": { @@ -1952,7 +1938,7 @@ func schema_config_server_apis_inv_v1alpha1_DiscoveryParameters(ref common.Refer }, }, Dependencies: []string{ - "github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryProfile", "github.com/sdcio/config-server/apis/inv/v1alpha1.SchemaKey", "github.com/sdcio/config-server/apis/inv/v1alpha1.TargetProfile", "github.com/sdcio/config-server/apis/inv/v1alpha1.TargetTemplate", "k8s.io/apimachinery/pkg/apis/meta/v1.Duration"}, + "github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryProfile", "github.com/sdcio/config-server/apis/inv/v1alpha1.SchemaKey", "github.com/sdcio/config-server/apis/inv/v1alpha1.TargetProfile", "github.com/sdcio/config-server/apis/inv/v1alpha1.TargetTemplate", metav1.Duration{}.OpenAPIModelName()}, } } @@ -2066,7 +2052,7 @@ func schema_config_server_apis_inv_v1alpha1_DiscoveryRule(ref common.ReferenceCa "metadata": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"), + Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), }, }, "spec": { @@ -2085,7 +2071,7 @@ func schema_config_server_apis_inv_v1alpha1_DiscoveryRule(ref common.ReferenceCa }, }, Dependencies: []string{ - "github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryRuleSpec", "github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryRuleStatus", "k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"}, + "github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryRuleSpec", "github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryRuleStatus", metav1.ObjectMeta{}.OpenAPIModelName()}, } } @@ -2141,7 +2127,7 @@ func schema_config_server_apis_inv_v1alpha1_DiscoveryRuleList(ref common.Referen "metadata": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"), + Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), }, }, "items": { @@ -2162,7 +2148,7 @@ func schema_config_server_apis_inv_v1alpha1_DiscoveryRuleList(ref common.Referen }, }, Dependencies: []string{ - "github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryRule", "k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"}, + "github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryRule", metav1.ListMeta{}.OpenAPIModelName()}, } } @@ -2240,13 +2226,13 @@ func schema_config_server_apis_inv_v1alpha1_DiscoveryRuleSpec(ref common.Referen "podSelector": { SchemaProps: spec.SchemaProps{ Description: "PodSelector defines the pod selector for which this discovery rule applies", - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.LabelSelector"), + Ref: ref(metav1.LabelSelector{}.OpenAPIModelName()), }, }, "serviceSelector": { SchemaProps: spec.SchemaProps{ Description: "ServiceSelector defines the service selector for which this discovery rule applies", - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.LabelSelector"), + Ref: ref(metav1.LabelSelector{}.OpenAPIModelName()), }, }, "serviceDomain": { @@ -2291,7 +2277,7 @@ func schema_config_server_apis_inv_v1alpha1_DiscoveryRuleSpec(ref common.Referen "period": { SchemaProps: spec.SchemaProps{ Description: "Period defines the wait period between discovery rule runs", - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.Duration"), + Ref: ref(metav1.Duration{}.OpenAPIModelName()), }, }, "concurrentScans": { @@ -2306,7 +2292,7 @@ func schema_config_server_apis_inv_v1alpha1_DiscoveryRuleSpec(ref common.Referen }, }, Dependencies: []string{ - "github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryProfile", "github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryRuleAddress", "github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryRulePrefix", "github.com/sdcio/config-server/apis/inv/v1alpha1.SchemaKey", "github.com/sdcio/config-server/apis/inv/v1alpha1.TargetProfile", "github.com/sdcio/config-server/apis/inv/v1alpha1.TargetTemplate", "k8s.io/apimachinery/pkg/apis/meta/v1.Duration", "k8s.io/apimachinery/pkg/apis/meta/v1.LabelSelector"}, + "github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryProfile", "github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryRuleAddress", "github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryRulePrefix", "github.com/sdcio/config-server/apis/inv/v1alpha1.SchemaKey", "github.com/sdcio/config-server/apis/inv/v1alpha1.TargetProfile", "github.com/sdcio/config-server/apis/inv/v1alpha1.TargetTemplate", metav1.Duration{}.OpenAPIModelName(), metav1.LabelSelector{}.OpenAPIModelName()}, } } @@ -2342,14 +2328,14 @@ func schema_config_server_apis_inv_v1alpha1_DiscoveryRuleStatus(ref common.Refer "startTime": { SchemaProps: spec.SchemaProps{ Description: "StartTime identifies when the dr got started", - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.Time"), + Ref: ref(metav1.Time{}.OpenAPIModelName()), }, }, }, }, }, Dependencies: []string{ - "github.com/sdcio/config-server/apis/condition/v1alpha1.Condition", "k8s.io/apimachinery/pkg/apis/meta/v1.Time"}, + "github.com/sdcio/config-server/apis/condition/v1alpha1.Condition", metav1.Time{}.OpenAPIModelName()}, } } @@ -2377,7 +2363,7 @@ func schema_config_server_apis_inv_v1alpha1_DiscoveryVendorProfile(ref common.Re "metadata": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"), + Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), }, }, "spec": { @@ -2390,7 +2376,7 @@ func schema_config_server_apis_inv_v1alpha1_DiscoveryVendorProfile(ref common.Re }, }, Dependencies: []string{ - "github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryVendorProfileSpec", "k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"}, + "github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryVendorProfileSpec", metav1.ObjectMeta{}.OpenAPIModelName()}, } } @@ -2418,7 +2404,7 @@ func schema_config_server_apis_inv_v1alpha1_DiscoveryVendorProfileList(ref commo "metadata": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"), + Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), }, }, "items": { @@ -2439,7 +2425,7 @@ func schema_config_server_apis_inv_v1alpha1_DiscoveryVendorProfileList(ref commo }, }, Dependencies: []string{ - "github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryVendorProfile", "k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"}, + "github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryVendorProfile", metav1.ListMeta{}.OpenAPIModelName()}, } } @@ -2624,7 +2610,7 @@ func schema_config_server_apis_inv_v1alpha1_Rollout(ref common.ReferenceCallback "metadata": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"), + Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), }, }, "spec": { @@ -2643,7 +2629,7 @@ func schema_config_server_apis_inv_v1alpha1_Rollout(ref common.ReferenceCallback }, }, Dependencies: []string{ - "github.com/sdcio/config-server/apis/inv/v1alpha1.RolloutSpec", "github.com/sdcio/config-server/apis/inv/v1alpha1.RolloutStatus", "k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"}, + "github.com/sdcio/config-server/apis/inv/v1alpha1.RolloutSpec", "github.com/sdcio/config-server/apis/inv/v1alpha1.RolloutStatus", metav1.ObjectMeta{}.OpenAPIModelName()}, } } @@ -2671,7 +2657,7 @@ func schema_config_server_apis_inv_v1alpha1_RolloutList(ref common.ReferenceCall "metadata": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"), + Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), }, }, "items": { @@ -2692,7 +2678,7 @@ func schema_config_server_apis_inv_v1alpha1_RolloutList(ref common.ReferenceCall }, }, Dependencies: []string{ - "github.com/sdcio/config-server/apis/inv/v1alpha1.Rollout", "k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"}, + "github.com/sdcio/config-server/apis/inv/v1alpha1.Rollout", metav1.ListMeta{}.OpenAPIModelName()}, } } @@ -2881,7 +2867,7 @@ func schema_config_server_apis_inv_v1alpha1_Schema(ref common.ReferenceCallback) "metadata": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"), + Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), }, }, "spec": { @@ -2900,7 +2886,7 @@ func schema_config_server_apis_inv_v1alpha1_Schema(ref common.ReferenceCallback) }, }, Dependencies: []string{ - "github.com/sdcio/config-server/apis/inv/v1alpha1.SchemaSpec", "github.com/sdcio/config-server/apis/inv/v1alpha1.SchemaStatus", "k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"}, + "github.com/sdcio/config-server/apis/inv/v1alpha1.SchemaSpec", "github.com/sdcio/config-server/apis/inv/v1alpha1.SchemaStatus", metav1.ObjectMeta{}.OpenAPIModelName()}, } } @@ -2957,7 +2943,7 @@ func schema_config_server_apis_inv_v1alpha1_SchemaList(ref common.ReferenceCallb "metadata": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"), + Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), }, }, "items": { @@ -2978,7 +2964,7 @@ func schema_config_server_apis_inv_v1alpha1_SchemaList(ref common.ReferenceCallb }, }, Dependencies: []string{ - "github.com/sdcio/config-server/apis/inv/v1alpha1.Schema", "k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"}, + "github.com/sdcio/config-server/apis/inv/v1alpha1.Schema", metav1.ListMeta{}.OpenAPIModelName()}, } } @@ -3289,7 +3275,7 @@ func schema_config_server_apis_inv_v1alpha1_Subscription(ref common.ReferenceCal "metadata": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"), + Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), }, }, "spec": { @@ -3308,7 +3294,7 @@ func schema_config_server_apis_inv_v1alpha1_Subscription(ref common.ReferenceCal }, }, Dependencies: []string{ - "github.com/sdcio/config-server/apis/inv/v1alpha1.SubscriptionSpec", "github.com/sdcio/config-server/apis/inv/v1alpha1.SubscriptionStatus", "k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"}, + "github.com/sdcio/config-server/apis/inv/v1alpha1.SubscriptionSpec", "github.com/sdcio/config-server/apis/inv/v1alpha1.SubscriptionStatus", metav1.ObjectMeta{}.OpenAPIModelName()}, } } @@ -3336,7 +3322,7 @@ func schema_config_server_apis_inv_v1alpha1_SubscriptionList(ref common.Referenc "metadata": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"), + Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), }, }, "items": { @@ -3357,7 +3343,7 @@ func schema_config_server_apis_inv_v1alpha1_SubscriptionList(ref common.Referenc }, }, Dependencies: []string{ - "github.com/sdcio/config-server/apis/inv/v1alpha1.Subscription", "k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"}, + "github.com/sdcio/config-server/apis/inv/v1alpha1.Subscription", metav1.ListMeta{}.OpenAPIModelName()}, } } @@ -3415,7 +3401,7 @@ func schema_config_server_apis_inv_v1alpha1_SubscriptionParameters(ref common.Re }, "interval": { SchemaProps: spec.SchemaProps{ - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.Duration"), + Ref: ref(metav1.Duration{}.OpenAPIModelName()), }, }, "paths": { @@ -3437,7 +3423,7 @@ func schema_config_server_apis_inv_v1alpha1_SubscriptionParameters(ref common.Re }, }, Dependencies: []string{ - "k8s.io/apimachinery/pkg/apis/meta/v1.Duration"}, + metav1.Duration{}.OpenAPIModelName()}, } } @@ -3558,14 +3544,14 @@ func schema_config_server_apis_inv_v1alpha1_SubscriptionTarget(ref common.Refere "targetSelector": { SchemaProps: spec.SchemaProps{ Description: "TargetSelector defines the selector used to select the targets to which the config applies", - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.LabelSelector"), + Ref: ref(metav1.LabelSelector{}.OpenAPIModelName()), }, }, }, }, }, Dependencies: []string{ - "k8s.io/apimachinery/pkg/apis/meta/v1.LabelSelector"}, + metav1.LabelSelector{}.OpenAPIModelName()}, } } @@ -3593,7 +3579,7 @@ func schema_config_server_apis_inv_v1alpha1_Target(ref common.ReferenceCallback) "metadata": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"), + Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), }, }, "spec": { @@ -3612,7 +3598,7 @@ func schema_config_server_apis_inv_v1alpha1_Target(ref common.ReferenceCallback) }, }, Dependencies: []string{ - "github.com/sdcio/config-server/apis/inv/v1alpha1.TargetSpec", "github.com/sdcio/config-server/apis/inv/v1alpha1.TargetStatus", "k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"}, + "github.com/sdcio/config-server/apis/inv/v1alpha1.TargetSpec", "github.com/sdcio/config-server/apis/inv/v1alpha1.TargetStatus", metav1.ObjectMeta{}.OpenAPIModelName()}, } } @@ -3640,7 +3626,7 @@ func schema_config_server_apis_inv_v1alpha1_TargetConnectionProfile(ref common.R "metadata": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"), + Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), }, }, "spec": { @@ -3653,7 +3639,7 @@ func schema_config_server_apis_inv_v1alpha1_TargetConnectionProfile(ref common.R }, }, Dependencies: []string{ - "github.com/sdcio/config-server/apis/inv/v1alpha1.TargetConnectionProfileSpec", "k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"}, + "github.com/sdcio/config-server/apis/inv/v1alpha1.TargetConnectionProfileSpec", metav1.ObjectMeta{}.OpenAPIModelName()}, } } @@ -3681,7 +3667,7 @@ func schema_config_server_apis_inv_v1alpha1_TargetConnectionProfileList(ref comm "metadata": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"), + Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), }, }, "items": { @@ -3702,7 +3688,7 @@ func schema_config_server_apis_inv_v1alpha1_TargetConnectionProfileList(ref comm }, }, Dependencies: []string{ - "github.com/sdcio/config-server/apis/inv/v1alpha1.TargetConnectionProfile", "k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"}, + "github.com/sdcio/config-server/apis/inv/v1alpha1.TargetConnectionProfile", metav1.ListMeta{}.OpenAPIModelName()}, } } @@ -3715,12 +3701,12 @@ func schema_config_server_apis_inv_v1alpha1_TargetConnectionProfileSpec(ref comm Properties: map[string]spec.Schema{ "connectRetry": { SchemaProps: spec.SchemaProps{ - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.Duration"), + Ref: ref(metav1.Duration{}.OpenAPIModelName()), }, }, "timeout": { SchemaProps: spec.SchemaProps{ - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.Duration"), + Ref: ref(metav1.Duration{}.OpenAPIModelName()), }, }, "protocol": { @@ -3798,7 +3784,7 @@ func schema_config_server_apis_inv_v1alpha1_TargetConnectionProfileSpec(ref comm }, }, Dependencies: []string{ - "k8s.io/apimachinery/pkg/apis/meta/v1.Duration"}, + metav1.Duration{}.OpenAPIModelName()}, } } @@ -3826,7 +3812,7 @@ func schema_config_server_apis_inv_v1alpha1_TargetList(ref common.ReferenceCallb "metadata": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"), + Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), }, }, "items": { @@ -3847,7 +3833,7 @@ func schema_config_server_apis_inv_v1alpha1_TargetList(ref common.ReferenceCallb }, }, Dependencies: []string{ - "github.com/sdcio/config-server/apis/inv/v1alpha1.Target", "k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"}, + "github.com/sdcio/config-server/apis/inv/v1alpha1.Target", metav1.ListMeta{}.OpenAPIModelName()}, } } @@ -4066,7 +4052,7 @@ func schema_config_server_apis_inv_v1alpha1_TargetSyncProfile(ref common.Referen "metadata": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"), + Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), }, }, "spec": { @@ -4079,7 +4065,7 @@ func schema_config_server_apis_inv_v1alpha1_TargetSyncProfile(ref common.Referen }, }, Dependencies: []string{ - "github.com/sdcio/config-server/apis/inv/v1alpha1.TargetSyncProfileSpec", "k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"}, + "github.com/sdcio/config-server/apis/inv/v1alpha1.TargetSyncProfileSpec", metav1.ObjectMeta{}.OpenAPIModelName()}, } } @@ -4107,7 +4093,7 @@ func schema_config_server_apis_inv_v1alpha1_TargetSyncProfileList(ref common.Ref "metadata": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"), + Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), }, }, "items": { @@ -4128,7 +4114,7 @@ func schema_config_server_apis_inv_v1alpha1_TargetSyncProfileList(ref common.Ref }, }, Dependencies: []string{ - "github.com/sdcio/config-server/apis/inv/v1alpha1.TargetSyncProfile", "k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"}, + "github.com/sdcio/config-server/apis/inv/v1alpha1.TargetSyncProfile", metav1.ListMeta{}.OpenAPIModelName()}, } } @@ -4237,7 +4223,7 @@ func schema_config_server_apis_inv_v1alpha1_TargetSyncProfileSync(ref common.Ref }, "interval": { SchemaProps: spec.SchemaProps{ - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.Duration"), + Ref: ref(metav1.Duration{}.OpenAPIModelName()), }, }, }, @@ -4245,7 +4231,7 @@ func schema_config_server_apis_inv_v1alpha1_TargetSyncProfileSync(ref common.Ref }, }, Dependencies: []string{ - "k8s.io/apimachinery/pkg/apis/meta/v1.Duration"}, + metav1.Duration{}.OpenAPIModelName()}, } } @@ -4325,7 +4311,7 @@ func schema_config_server_apis_inv_v1alpha1_Workspace(ref common.ReferenceCallba "metadata": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"), + Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), }, }, "spec": { @@ -4344,7 +4330,7 @@ func schema_config_server_apis_inv_v1alpha1_Workspace(ref common.ReferenceCallba }, }, Dependencies: []string{ - "github.com/sdcio/config-server/apis/inv/v1alpha1.WorkspaceSpec", "github.com/sdcio/config-server/apis/inv/v1alpha1.WorkspaceStatus", "k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"}, + "github.com/sdcio/config-server/apis/inv/v1alpha1.WorkspaceSpec", "github.com/sdcio/config-server/apis/inv/v1alpha1.WorkspaceStatus", metav1.ObjectMeta{}.OpenAPIModelName()}, } } @@ -4372,7 +4358,7 @@ func schema_config_server_apis_inv_v1alpha1_WorkspaceList(ref common.ReferenceCa "metadata": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"), + Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), }, }, "items": { @@ -4393,7 +4379,7 @@ func schema_config_server_apis_inv_v1alpha1_WorkspaceList(ref common.ReferenceCa }, }, Dependencies: []string{ - "github.com/sdcio/config-server/apis/inv/v1alpha1.Workspace", "k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"}, + "github.com/sdcio/config-server/apis/inv/v1alpha1.Workspace", metav1.ListMeta{}.OpenAPIModelName()}, } } @@ -4554,26 +4540,26 @@ func schema_k8sio_api_core_v1_Affinity(ref common.ReferenceCallback) common.Open "nodeAffinity": { SchemaProps: spec.SchemaProps{ Description: "Describes node affinity scheduling rules for the pod.", - Ref: ref("k8s.io/api/core/v1.NodeAffinity"), + Ref: ref(v1.NodeAffinity{}.OpenAPIModelName()), }, }, "podAffinity": { SchemaProps: spec.SchemaProps{ Description: "Describes pod affinity scheduling rules (e.g. co-locate this pod in the same node, zone, etc. as some other pod(s)).", - Ref: ref("k8s.io/api/core/v1.PodAffinity"), + Ref: ref(v1.PodAffinity{}.OpenAPIModelName()), }, }, "podAntiAffinity": { SchemaProps: spec.SchemaProps{ Description: "Describes pod anti-affinity scheduling rules (e.g. avoid putting this pod in the same node, zone, etc. as some other pod(s)).", - Ref: ref("k8s.io/api/core/v1.PodAntiAffinity"), + Ref: ref(v1.PodAntiAffinity{}.OpenAPIModelName()), }, }, }, }, }, Dependencies: []string{ - "k8s.io/api/core/v1.NodeAffinity", "k8s.io/api/core/v1.PodAffinity", "k8s.io/api/core/v1.PodAntiAffinity"}, + v1.NodeAffinity{}.OpenAPIModelName(), v1.PodAffinity{}.OpenAPIModelName(), v1.PodAntiAffinity{}.OpenAPIModelName()}, } } @@ -4669,7 +4655,7 @@ func schema_k8sio_api_core_v1_AvoidPods(ref common.ReferenceCallback) common.Ope Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.PreferAvoidPodsEntry"), + Ref: ref(v1.PreferAvoidPodsEntry{}.OpenAPIModelName()), }, }, }, @@ -4679,7 +4665,7 @@ func schema_k8sio_api_core_v1_AvoidPods(ref common.ReferenceCallback) common.Ope }, }, Dependencies: []string{ - "k8s.io/api/core/v1.PreferAvoidPodsEntry"}, + v1.PreferAvoidPodsEntry{}.OpenAPIModelName()}, } } @@ -4853,14 +4839,14 @@ func schema_k8sio_api_core_v1_Binding(ref common.ReferenceCallback) common.OpenA SchemaProps: spec.SchemaProps{ Description: "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata", Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"), + Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), }, }, "target": { SchemaProps: spec.SchemaProps{ Description: "The target object that you want to bind to the standard object.", Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.ObjectReference"), + Ref: ref(v1.ObjectReference{}.OpenAPIModelName()), }, }, }, @@ -4868,7 +4854,7 @@ func schema_k8sio_api_core_v1_Binding(ref common.ReferenceCallback) common.OpenA }, }, Dependencies: []string{ - "k8s.io/api/core/v1.ObjectReference", "k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"}, + v1.ObjectReference{}.OpenAPIModelName(), metav1.ObjectMeta{}.OpenAPIModelName()}, } } @@ -4928,31 +4914,31 @@ func schema_k8sio_api_core_v1_CSIPersistentVolumeSource(ref common.ReferenceCall "controllerPublishSecretRef": { SchemaProps: spec.SchemaProps{ Description: "controllerPublishSecretRef is a reference to the secret object containing sensitive information to pass to the CSI driver to complete the CSI ControllerPublishVolume and ControllerUnpublishVolume calls. This field is optional, and may be empty if no secret is required. If the secret object contains more than one secret, all secrets are passed.", - Ref: ref("k8s.io/api/core/v1.SecretReference"), + Ref: ref(v1.SecretReference{}.OpenAPIModelName()), }, }, "nodeStageSecretRef": { SchemaProps: spec.SchemaProps{ Description: "nodeStageSecretRef is a reference to the secret object containing sensitive information to pass to the CSI driver to complete the CSI NodeStageVolume and NodeStageVolume and NodeUnstageVolume calls. This field is optional, and may be empty if no secret is required. If the secret object contains more than one secret, all secrets are passed.", - Ref: ref("k8s.io/api/core/v1.SecretReference"), + Ref: ref(v1.SecretReference{}.OpenAPIModelName()), }, }, "nodePublishSecretRef": { SchemaProps: spec.SchemaProps{ Description: "nodePublishSecretRef is a reference to the secret object containing sensitive information to pass to the CSI driver to complete the CSI NodePublishVolume and NodeUnpublishVolume calls. This field is optional, and may be empty if no secret is required. If the secret object contains more than one secret, all secrets are passed.", - Ref: ref("k8s.io/api/core/v1.SecretReference"), + Ref: ref(v1.SecretReference{}.OpenAPIModelName()), }, }, "controllerExpandSecretRef": { SchemaProps: spec.SchemaProps{ Description: "controllerExpandSecretRef is a reference to the secret object containing sensitive information to pass to the CSI driver to complete the CSI ControllerExpandVolume call. This field is optional, and may be empty if no secret is required. If the secret object contains more than one secret, all secrets are passed.", - Ref: ref("k8s.io/api/core/v1.SecretReference"), + Ref: ref(v1.SecretReference{}.OpenAPIModelName()), }, }, "nodeExpandSecretRef": { SchemaProps: spec.SchemaProps{ Description: "nodeExpandSecretRef is a reference to the secret object containing sensitive information to pass to the CSI driver to complete the CSI NodeExpandVolume call. This field is optional, may be omitted if no secret is required. If the secret object contains more than one secret, all secrets are passed.", - Ref: ref("k8s.io/api/core/v1.SecretReference"), + Ref: ref(v1.SecretReference{}.OpenAPIModelName()), }, }, }, @@ -4960,7 +4946,7 @@ func schema_k8sio_api_core_v1_CSIPersistentVolumeSource(ref common.ReferenceCall }, }, Dependencies: []string{ - "k8s.io/api/core/v1.SecretReference"}, + v1.SecretReference{}.OpenAPIModelName()}, } } @@ -5012,7 +4998,7 @@ func schema_k8sio_api_core_v1_CSIVolumeSource(ref common.ReferenceCallback) comm "nodePublishSecretRef": { SchemaProps: spec.SchemaProps{ Description: "nodePublishSecretRef is a reference to the secret object containing sensitive information to pass to the CSI driver to complete the CSI NodePublishVolume and NodeUnpublishVolume calls. This field is optional, and may be empty if no secret is required. If the secret object contains more than one secret, all secret references are passed.", - Ref: ref("k8s.io/api/core/v1.LocalObjectReference"), + Ref: ref(v1.LocalObjectReference{}.OpenAPIModelName()), }, }, }, @@ -5020,7 +5006,7 @@ func schema_k8sio_api_core_v1_CSIVolumeSource(ref common.ReferenceCallback) comm }, }, Dependencies: []string{ - "k8s.io/api/core/v1.LocalObjectReference"}, + v1.LocalObjectReference{}.OpenAPIModelName()}, } } @@ -5128,7 +5114,7 @@ func schema_k8sio_api_core_v1_CephFSPersistentVolumeSource(ref common.ReferenceC "secretRef": { SchemaProps: spec.SchemaProps{ Description: "secretRef is Optional: SecretRef is reference to the authentication secret for User, default is empty. More info: https://examples.k8s.io/volumes/cephfs/README.md#how-to-use-it", - Ref: ref("k8s.io/api/core/v1.SecretReference"), + Ref: ref(v1.SecretReference{}.OpenAPIModelName()), }, }, "readOnly": { @@ -5143,7 +5129,7 @@ func schema_k8sio_api_core_v1_CephFSPersistentVolumeSource(ref common.ReferenceC }, }, Dependencies: []string{ - "k8s.io/api/core/v1.SecretReference"}, + v1.SecretReference{}.OpenAPIModelName()}, } } @@ -5198,7 +5184,7 @@ func schema_k8sio_api_core_v1_CephFSVolumeSource(ref common.ReferenceCallback) c "secretRef": { SchemaProps: spec.SchemaProps{ Description: "secretRef is Optional: SecretRef is reference to the authentication secret for User, default is empty. More info: https://examples.k8s.io/volumes/cephfs/README.md#how-to-use-it", - Ref: ref("k8s.io/api/core/v1.LocalObjectReference"), + Ref: ref(v1.LocalObjectReference{}.OpenAPIModelName()), }, }, "readOnly": { @@ -5213,7 +5199,7 @@ func schema_k8sio_api_core_v1_CephFSVolumeSource(ref common.ReferenceCallback) c }, }, Dependencies: []string{ - "k8s.io/api/core/v1.LocalObjectReference"}, + v1.LocalObjectReference{}.OpenAPIModelName()}, } } @@ -5249,7 +5235,7 @@ func schema_k8sio_api_core_v1_CinderPersistentVolumeSource(ref common.ReferenceC "secretRef": { SchemaProps: spec.SchemaProps{ Description: "secretRef is Optional: points to a secret object containing parameters used to connect to OpenStack.", - Ref: ref("k8s.io/api/core/v1.SecretReference"), + Ref: ref(v1.SecretReference{}.OpenAPIModelName()), }, }, }, @@ -5257,7 +5243,7 @@ func schema_k8sio_api_core_v1_CinderPersistentVolumeSource(ref common.ReferenceC }, }, Dependencies: []string{ - "k8s.io/api/core/v1.SecretReference"}, + v1.SecretReference{}.OpenAPIModelName()}, } } @@ -5293,7 +5279,7 @@ func schema_k8sio_api_core_v1_CinderVolumeSource(ref common.ReferenceCallback) c "secretRef": { SchemaProps: spec.SchemaProps{ Description: "secretRef is optional: points to a secret object containing parameters used to connect to OpenStack.", - Ref: ref("k8s.io/api/core/v1.LocalObjectReference"), + Ref: ref(v1.LocalObjectReference{}.OpenAPIModelName()), }, }, }, @@ -5301,7 +5287,7 @@ func schema_k8sio_api_core_v1_CinderVolumeSource(ref common.ReferenceCallback) c }, }, Dependencies: []string{ - "k8s.io/api/core/v1.LocalObjectReference"}, + v1.LocalObjectReference{}.OpenAPIModelName()}, } } @@ -5349,7 +5335,7 @@ func schema_k8sio_api_core_v1_ClusterTrustBundleProjection(ref common.ReferenceC "labelSelector": { SchemaProps: spec.SchemaProps{ Description: "Select all ClusterTrustBundles that match this label selector. Only has effect if signerName is set. Mutually-exclusive with name. If unset, interpreted as \"match nothing\". If set but empty, interpreted as \"match everything\".", - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.LabelSelector"), + Ref: ref(metav1.LabelSelector{}.OpenAPIModelName()), }, }, "optional": { @@ -5372,7 +5358,7 @@ func schema_k8sio_api_core_v1_ClusterTrustBundleProjection(ref common.ReferenceC }, }, Dependencies: []string{ - "k8s.io/apimachinery/pkg/apis/meta/v1.LabelSelector"}, + metav1.LabelSelector{}.OpenAPIModelName()}, } } @@ -5445,7 +5431,7 @@ func schema_k8sio_api_core_v1_ComponentStatus(ref common.ReferenceCallback) comm SchemaProps: spec.SchemaProps{ Description: "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata", Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"), + Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), }, }, "conditions": { @@ -5466,7 +5452,7 @@ func schema_k8sio_api_core_v1_ComponentStatus(ref common.ReferenceCallback) comm Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.ComponentCondition"), + Ref: ref(v1.ComponentCondition{}.OpenAPIModelName()), }, }, }, @@ -5476,7 +5462,7 @@ func schema_k8sio_api_core_v1_ComponentStatus(ref common.ReferenceCallback) comm }, }, Dependencies: []string{ - "k8s.io/api/core/v1.ComponentCondition", "k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"}, + v1.ComponentCondition{}.OpenAPIModelName(), metav1.ObjectMeta{}.OpenAPIModelName()}, } } @@ -5505,7 +5491,7 @@ func schema_k8sio_api_core_v1_ComponentStatusList(ref common.ReferenceCallback) SchemaProps: spec.SchemaProps{ Description: "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"), + Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), }, }, "items": { @@ -5516,7 +5502,7 @@ func schema_k8sio_api_core_v1_ComponentStatusList(ref common.ReferenceCallback) Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.ComponentStatus"), + Ref: ref(v1.ComponentStatus{}.OpenAPIModelName()), }, }, }, @@ -5527,7 +5513,7 @@ func schema_k8sio_api_core_v1_ComponentStatusList(ref common.ReferenceCallback) }, }, Dependencies: []string{ - "k8s.io/api/core/v1.ComponentStatus", "k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"}, + v1.ComponentStatus{}.OpenAPIModelName(), metav1.ListMeta{}.OpenAPIModelName()}, } } @@ -5556,7 +5542,7 @@ func schema_k8sio_api_core_v1_ConfigMap(ref common.ReferenceCallback) common.Ope SchemaProps: spec.SchemaProps{ Description: "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata", Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"), + Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), }, }, "immutable": { @@ -5601,7 +5587,7 @@ func schema_k8sio_api_core_v1_ConfigMap(ref common.ReferenceCallback) common.Ope }, }, Dependencies: []string{ - "k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"}, + metav1.ObjectMeta{}.OpenAPIModelName()}, } } @@ -5700,7 +5686,7 @@ func schema_k8sio_api_core_v1_ConfigMapList(ref common.ReferenceCallback) common SchemaProps: spec.SchemaProps{ Description: "More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata", Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"), + Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), }, }, "items": { @@ -5711,7 +5697,7 @@ func schema_k8sio_api_core_v1_ConfigMapList(ref common.ReferenceCallback) common Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.ConfigMap"), + Ref: ref(v1.ConfigMap{}.OpenAPIModelName()), }, }, }, @@ -5722,7 +5708,7 @@ func schema_k8sio_api_core_v1_ConfigMapList(ref common.ReferenceCallback) common }, }, Dependencies: []string{ - "k8s.io/api/core/v1.ConfigMap", "k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"}, + v1.ConfigMap{}.OpenAPIModelName(), metav1.ListMeta{}.OpenAPIModelName()}, } } @@ -5806,7 +5792,7 @@ func schema_k8sio_api_core_v1_ConfigMapProjection(ref common.ReferenceCallback) Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.KeyToPath"), + Ref: ref(v1.KeyToPath{}.OpenAPIModelName()), }, }, }, @@ -5823,7 +5809,7 @@ func schema_k8sio_api_core_v1_ConfigMapProjection(ref common.ReferenceCallback) }, }, Dependencies: []string{ - "k8s.io/api/core/v1.KeyToPath"}, + v1.KeyToPath{}.OpenAPIModelName()}, } } @@ -5855,7 +5841,7 @@ func schema_k8sio_api_core_v1_ConfigMapVolumeSource(ref common.ReferenceCallback Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.KeyToPath"), + Ref: ref(v1.KeyToPath{}.OpenAPIModelName()), }, }, }, @@ -5879,7 +5865,7 @@ func schema_k8sio_api_core_v1_ConfigMapVolumeSource(ref common.ReferenceCallback }, }, Dependencies: []string{ - "k8s.io/api/core/v1.KeyToPath"}, + v1.KeyToPath{}.OpenAPIModelName()}, } } @@ -5971,7 +5957,7 @@ func schema_k8sio_api_core_v1_Container(ref common.ReferenceCallback) common.Ope Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.ContainerPort"), + Ref: ref(v1.ContainerPort{}.OpenAPIModelName()), }, }, }, @@ -5990,7 +5976,7 @@ func schema_k8sio_api_core_v1_Container(ref common.ReferenceCallback) common.Ope Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.EnvFromSource"), + Ref: ref(v1.EnvFromSource{}.OpenAPIModelName()), }, }, }, @@ -6014,7 +6000,7 @@ func schema_k8sio_api_core_v1_Container(ref common.ReferenceCallback) common.Ope Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.EnvVar"), + Ref: ref(v1.EnvVar{}.OpenAPIModelName()), }, }, }, @@ -6024,7 +6010,7 @@ func schema_k8sio_api_core_v1_Container(ref common.ReferenceCallback) common.Ope SchemaProps: spec.SchemaProps{ Description: "Compute Resources required by this container. Cannot be updated. More info: https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/", Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.ResourceRequirements"), + Ref: ref(v1.ResourceRequirements{}.OpenAPIModelName()), }, }, "resizePolicy": { @@ -6040,7 +6026,7 @@ func schema_k8sio_api_core_v1_Container(ref common.ReferenceCallback) common.Ope Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.ContainerResizePolicy"), + Ref: ref(v1.ContainerResizePolicy{}.OpenAPIModelName()), }, }, }, @@ -6066,7 +6052,7 @@ func schema_k8sio_api_core_v1_Container(ref common.ReferenceCallback) common.Ope Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.ContainerRestartRule"), + Ref: ref(v1.ContainerRestartRule{}.OpenAPIModelName()), }, }, }, @@ -6090,7 +6076,7 @@ func schema_k8sio_api_core_v1_Container(ref common.ReferenceCallback) common.Ope Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.VolumeMount"), + Ref: ref(v1.VolumeMount{}.OpenAPIModelName()), }, }, }, @@ -6114,7 +6100,7 @@ func schema_k8sio_api_core_v1_Container(ref common.ReferenceCallback) common.Ope Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.VolumeDevice"), + Ref: ref(v1.VolumeDevice{}.OpenAPIModelName()), }, }, }, @@ -6123,25 +6109,25 @@ func schema_k8sio_api_core_v1_Container(ref common.ReferenceCallback) common.Ope "livenessProbe": { SchemaProps: spec.SchemaProps{ Description: "Periodic probe of container liveness. Container will be restarted if the probe fails. Cannot be updated. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#container-probes", - Ref: ref("k8s.io/api/core/v1.Probe"), + Ref: ref(v1.Probe{}.OpenAPIModelName()), }, }, "readinessProbe": { SchemaProps: spec.SchemaProps{ Description: "Periodic probe of container service readiness. Container will be removed from service endpoints if the probe fails. Cannot be updated. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#container-probes", - Ref: ref("k8s.io/api/core/v1.Probe"), + Ref: ref(v1.Probe{}.OpenAPIModelName()), }, }, "startupProbe": { SchemaProps: spec.SchemaProps{ Description: "StartupProbe indicates that the Pod has successfully initialized. If specified, no other probes are executed until this completes successfully. If this probe fails, the Pod will be restarted, just as if the livenessProbe failed. This can be used to provide different probe parameters at the beginning of a Pod's lifecycle, when it might take a long time to load data or warm a cache, than during steady-state operation. This cannot be updated. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#container-probes", - Ref: ref("k8s.io/api/core/v1.Probe"), + Ref: ref(v1.Probe{}.OpenAPIModelName()), }, }, "lifecycle": { SchemaProps: spec.SchemaProps{ Description: "Actions that the management system should take in response to container lifecycle events. Cannot be updated.", - Ref: ref("k8s.io/api/core/v1.Lifecycle"), + Ref: ref(v1.Lifecycle{}.OpenAPIModelName()), }, }, "terminationMessagePath": { @@ -6170,7 +6156,7 @@ func schema_k8sio_api_core_v1_Container(ref common.ReferenceCallback) common.Ope "securityContext": { SchemaProps: spec.SchemaProps{ Description: "SecurityContext defines the security options the container should be run with. If set, the fields of SecurityContext override the equivalent fields of PodSecurityContext. More info: https://kubernetes.io/docs/tasks/configure-pod-container/security-context/", - Ref: ref("k8s.io/api/core/v1.SecurityContext"), + Ref: ref(v1.SecurityContext{}.OpenAPIModelName()), }, }, "stdin": { @@ -6199,7 +6185,7 @@ func schema_k8sio_api_core_v1_Container(ref common.ReferenceCallback) common.Ope }, }, Dependencies: []string{ - "k8s.io/api/core/v1.ContainerPort", "k8s.io/api/core/v1.ContainerResizePolicy", "k8s.io/api/core/v1.ContainerRestartRule", "k8s.io/api/core/v1.EnvFromSource", "k8s.io/api/core/v1.EnvVar", "k8s.io/api/core/v1.Lifecycle", "k8s.io/api/core/v1.Probe", "k8s.io/api/core/v1.ResourceRequirements", "k8s.io/api/core/v1.SecurityContext", "k8s.io/api/core/v1.VolumeDevice", "k8s.io/api/core/v1.VolumeMount"}, + v1.ContainerPort{}.OpenAPIModelName(), v1.ContainerResizePolicy{}.OpenAPIModelName(), v1.ContainerRestartRule{}.OpenAPIModelName(), v1.EnvFromSource{}.OpenAPIModelName(), v1.EnvVar{}.OpenAPIModelName(), v1.Lifecycle{}.OpenAPIModelName(), v1.Probe{}.OpenAPIModelName(), v1.ResourceRequirements{}.OpenAPIModelName(), v1.SecurityContext{}.OpenAPIModelName(), v1.VolumeDevice{}.OpenAPIModelName(), v1.VolumeMount{}.OpenAPIModelName()}, } } @@ -6380,7 +6366,7 @@ func schema_k8sio_api_core_v1_ContainerRestartRule(ref common.ReferenceCallback) "exitCodes": { SchemaProps: spec.SchemaProps{ Description: "Represents the exit codes to check on container exits.", - Ref: ref("k8s.io/api/core/v1.ContainerRestartRuleOnExitCodes"), + Ref: ref(v1.ContainerRestartRuleOnExitCodes{}.OpenAPIModelName()), }, }, }, @@ -6388,7 +6374,7 @@ func schema_k8sio_api_core_v1_ContainerRestartRule(ref common.ReferenceCallback) }, }, Dependencies: []string{ - "k8s.io/api/core/v1.ContainerRestartRuleOnExitCodes"}, + v1.ContainerRestartRuleOnExitCodes{}.OpenAPIModelName()}, } } @@ -6443,26 +6429,26 @@ func schema_k8sio_api_core_v1_ContainerState(ref common.ReferenceCallback) commo "waiting": { SchemaProps: spec.SchemaProps{ Description: "Details about a waiting container", - Ref: ref("k8s.io/api/core/v1.ContainerStateWaiting"), + Ref: ref(v1.ContainerStateWaiting{}.OpenAPIModelName()), }, }, "running": { SchemaProps: spec.SchemaProps{ Description: "Details about a running container", - Ref: ref("k8s.io/api/core/v1.ContainerStateRunning"), + Ref: ref(v1.ContainerStateRunning{}.OpenAPIModelName()), }, }, "terminated": { SchemaProps: spec.SchemaProps{ Description: "Details about a terminated container", - Ref: ref("k8s.io/api/core/v1.ContainerStateTerminated"), + Ref: ref(v1.ContainerStateTerminated{}.OpenAPIModelName()), }, }, }, }, }, Dependencies: []string{ - "k8s.io/api/core/v1.ContainerStateRunning", "k8s.io/api/core/v1.ContainerStateTerminated", "k8s.io/api/core/v1.ContainerStateWaiting"}, + v1.ContainerStateRunning{}.OpenAPIModelName(), v1.ContainerStateTerminated{}.OpenAPIModelName(), v1.ContainerStateWaiting{}.OpenAPIModelName()}, } } @@ -6476,14 +6462,14 @@ func schema_k8sio_api_core_v1_ContainerStateRunning(ref common.ReferenceCallback "startedAt": { SchemaProps: spec.SchemaProps{ Description: "Time at which the container was last (re-)started", - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.Time"), + Ref: ref(metav1.Time{}.OpenAPIModelName()), }, }, }, }, }, Dependencies: []string{ - "k8s.io/apimachinery/pkg/apis/meta/v1.Time"}, + metav1.Time{}.OpenAPIModelName()}, } } @@ -6526,13 +6512,13 @@ func schema_k8sio_api_core_v1_ContainerStateTerminated(ref common.ReferenceCallb "startedAt": { SchemaProps: spec.SchemaProps{ Description: "Time at which previous execution of the container started", - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.Time"), + Ref: ref(metav1.Time{}.OpenAPIModelName()), }, }, "finishedAt": { SchemaProps: spec.SchemaProps{ Description: "Time at which the container last terminated", - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.Time"), + Ref: ref(metav1.Time{}.OpenAPIModelName()), }, }, "containerID": { @@ -6547,7 +6533,7 @@ func schema_k8sio_api_core_v1_ContainerStateTerminated(ref common.ReferenceCallb }, }, Dependencies: []string{ - "k8s.io/apimachinery/pkg/apis/meta/v1.Time"}, + metav1.Time{}.OpenAPIModelName()}, } } @@ -6597,14 +6583,14 @@ func schema_k8sio_api_core_v1_ContainerStatus(ref common.ReferenceCallback) comm SchemaProps: spec.SchemaProps{ Description: "State holds details about the container's current condition.", Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.ContainerState"), + Ref: ref(v1.ContainerState{}.OpenAPIModelName()), }, }, "lastState": { SchemaProps: spec.SchemaProps{ Description: "LastTerminationState holds the last termination state of the container to help debug container crashes and restarts. This field is not populated if the container is still running and RestartCount is 0.", Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.ContainerState"), + Ref: ref(v1.ContainerState{}.OpenAPIModelName()), }, }, "ready": { @@ -6661,7 +6647,7 @@ func schema_k8sio_api_core_v1_ContainerStatus(ref common.ReferenceCallback) comm Allows: true, Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ - Ref: ref("k8s.io/apimachinery/pkg/api/resource.Quantity"), + Ref: ref(resource.Quantity{}.OpenAPIModelName()), }, }, }, @@ -6670,7 +6656,7 @@ func schema_k8sio_api_core_v1_ContainerStatus(ref common.ReferenceCallback) comm "resources": { SchemaProps: spec.SchemaProps{ Description: "Resources represents the compute resource requests and limits that have been successfully enacted on the running container after it has been started or has been successfully resized.", - Ref: ref("k8s.io/api/core/v1.ResourceRequirements"), + Ref: ref(v1.ResourceRequirements{}.OpenAPIModelName()), }, }, "volumeMounts": { @@ -6691,7 +6677,7 @@ func schema_k8sio_api_core_v1_ContainerStatus(ref common.ReferenceCallback) comm Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.VolumeMountStatus"), + Ref: ref(v1.VolumeMountStatus{}.OpenAPIModelName()), }, }, }, @@ -6700,7 +6686,7 @@ func schema_k8sio_api_core_v1_ContainerStatus(ref common.ReferenceCallback) comm "user": { SchemaProps: spec.SchemaProps{ Description: "User represents user identity information initially attached to the first process of the container", - Ref: ref("k8s.io/api/core/v1.ContainerUser"), + Ref: ref(v1.ContainerUser{}.OpenAPIModelName()), }, }, "allocatedResourcesStatus": { @@ -6721,7 +6707,7 @@ func schema_k8sio_api_core_v1_ContainerStatus(ref common.ReferenceCallback) comm Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.ResourceStatus"), + Ref: ref(v1.ResourceStatus{}.OpenAPIModelName()), }, }, }, @@ -6740,7 +6726,7 @@ func schema_k8sio_api_core_v1_ContainerStatus(ref common.ReferenceCallback) comm }, }, Dependencies: []string{ - "k8s.io/api/core/v1.ContainerState", "k8s.io/api/core/v1.ContainerUser", "k8s.io/api/core/v1.ResourceRequirements", "k8s.io/api/core/v1.ResourceStatus", "k8s.io/api/core/v1.VolumeMountStatus", "k8s.io/apimachinery/pkg/api/resource.Quantity"}, + v1.ContainerState{}.OpenAPIModelName(), v1.ContainerUser{}.OpenAPIModelName(), v1.ResourceRequirements{}.OpenAPIModelName(), v1.ResourceStatus{}.OpenAPIModelName(), v1.VolumeMountStatus{}.OpenAPIModelName(), resource.Quantity{}.OpenAPIModelName()}, } } @@ -6754,14 +6740,14 @@ func schema_k8sio_api_core_v1_ContainerUser(ref common.ReferenceCallback) common "linux": { SchemaProps: spec.SchemaProps{ Description: "Linux holds user identity information initially attached to the first process of the containers in Linux. Note that the actual running identity can be changed if the process has enough privilege to do so.", - Ref: ref("k8s.io/api/core/v1.LinuxContainerUser"), + Ref: ref(v1.LinuxContainerUser{}.OpenAPIModelName()), }, }, }, }, }, Dependencies: []string{ - "k8s.io/api/core/v1.LinuxContainerUser"}, + v1.LinuxContainerUser{}.OpenAPIModelName()}, } } @@ -6807,7 +6793,7 @@ func schema_k8sio_api_core_v1_DownwardAPIProjection(ref common.ReferenceCallback Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.DownwardAPIVolumeFile"), + Ref: ref(v1.DownwardAPIVolumeFile{}.OpenAPIModelName()), }, }, }, @@ -6817,7 +6803,7 @@ func schema_k8sio_api_core_v1_DownwardAPIProjection(ref common.ReferenceCallback }, }, Dependencies: []string{ - "k8s.io/api/core/v1.DownwardAPIVolumeFile"}, + v1.DownwardAPIVolumeFile{}.OpenAPIModelName()}, } } @@ -6839,13 +6825,13 @@ func schema_k8sio_api_core_v1_DownwardAPIVolumeFile(ref common.ReferenceCallback "fieldRef": { SchemaProps: spec.SchemaProps{ Description: "Required: Selects a field of the pod: only annotations, labels, name, namespace and uid are supported.", - Ref: ref("k8s.io/api/core/v1.ObjectFieldSelector"), + Ref: ref(v1.ObjectFieldSelector{}.OpenAPIModelName()), }, }, "resourceFieldRef": { SchemaProps: spec.SchemaProps{ Description: "Selects a resource of the container: only resources limits and requests (limits.cpu, limits.memory, requests.cpu and requests.memory) are currently supported.", - Ref: ref("k8s.io/api/core/v1.ResourceFieldSelector"), + Ref: ref(v1.ResourceFieldSelector{}.OpenAPIModelName()), }, }, "mode": { @@ -6860,7 +6846,7 @@ func schema_k8sio_api_core_v1_DownwardAPIVolumeFile(ref common.ReferenceCallback }, }, Dependencies: []string{ - "k8s.io/api/core/v1.ObjectFieldSelector", "k8s.io/api/core/v1.ResourceFieldSelector"}, + v1.ObjectFieldSelector{}.OpenAPIModelName(), v1.ResourceFieldSelector{}.OpenAPIModelName()}, } } @@ -6884,7 +6870,7 @@ func schema_k8sio_api_core_v1_DownwardAPIVolumeSource(ref common.ReferenceCallba Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.DownwardAPIVolumeFile"), + Ref: ref(v1.DownwardAPIVolumeFile{}.OpenAPIModelName()), }, }, }, @@ -6901,7 +6887,7 @@ func schema_k8sio_api_core_v1_DownwardAPIVolumeSource(ref common.ReferenceCallba }, }, Dependencies: []string{ - "k8s.io/api/core/v1.DownwardAPIVolumeFile"}, + v1.DownwardAPIVolumeFile{}.OpenAPIModelName()}, } } @@ -6922,14 +6908,14 @@ func schema_k8sio_api_core_v1_EmptyDirVolumeSource(ref common.ReferenceCallback) "sizeLimit": { SchemaProps: spec.SchemaProps{ Description: "sizeLimit is the total amount of local storage required for this EmptyDir volume. The size limit is also applicable for memory medium. The maximum usage on memory medium EmptyDir would be the minimum value between the SizeLimit specified here and the sum of memory limits of all containers in a pod. The default is nil which means that the limit is undefined. More info: https://kubernetes.io/docs/concepts/storage/volumes#emptydir", - Ref: ref("k8s.io/apimachinery/pkg/api/resource.Quantity"), + Ref: ref(resource.Quantity{}.OpenAPIModelName()), }, }, }, }, }, Dependencies: []string{ - "k8s.io/apimachinery/pkg/api/resource.Quantity"}, + resource.Quantity{}.OpenAPIModelName()}, } } @@ -6965,7 +6951,7 @@ func schema_k8sio_api_core_v1_EndpointAddress(ref common.ReferenceCallback) comm "targetRef": { SchemaProps: spec.SchemaProps{ Description: "Reference to object providing the endpoint.", - Ref: ref("k8s.io/api/core/v1.ObjectReference"), + Ref: ref(v1.ObjectReference{}.OpenAPIModelName()), }, }, }, @@ -6978,7 +6964,7 @@ func schema_k8sio_api_core_v1_EndpointAddress(ref common.ReferenceCallback) comm }, }, Dependencies: []string{ - "k8s.io/api/core/v1.ObjectReference"}, + v1.ObjectReference{}.OpenAPIModelName()}, } } @@ -7051,7 +7037,7 @@ func schema_k8sio_api_core_v1_EndpointSubset(ref common.ReferenceCallback) commo Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.EndpointAddress"), + Ref: ref(v1.EndpointAddress{}.OpenAPIModelName()), }, }, }, @@ -7070,7 +7056,7 @@ func schema_k8sio_api_core_v1_EndpointSubset(ref common.ReferenceCallback) commo Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.EndpointAddress"), + Ref: ref(v1.EndpointAddress{}.OpenAPIModelName()), }, }, }, @@ -7089,7 +7075,7 @@ func schema_k8sio_api_core_v1_EndpointSubset(ref common.ReferenceCallback) commo Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.EndpointPort"), + Ref: ref(v1.EndpointPort{}.OpenAPIModelName()), }, }, }, @@ -7099,7 +7085,7 @@ func schema_k8sio_api_core_v1_EndpointSubset(ref common.ReferenceCallback) commo }, }, Dependencies: []string{ - "k8s.io/api/core/v1.EndpointAddress", "k8s.io/api/core/v1.EndpointPort"}, + v1.EndpointAddress{}.OpenAPIModelName(), v1.EndpointPort{}.OpenAPIModelName()}, } } @@ -7128,7 +7114,7 @@ func schema_k8sio_api_core_v1_Endpoints(ref common.ReferenceCallback) common.Ope SchemaProps: spec.SchemaProps{ Description: "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata", Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"), + Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), }, }, "subsets": { @@ -7144,7 +7130,7 @@ func schema_k8sio_api_core_v1_Endpoints(ref common.ReferenceCallback) common.Ope Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.EndpointSubset"), + Ref: ref(v1.EndpointSubset{}.OpenAPIModelName()), }, }, }, @@ -7154,7 +7140,7 @@ func schema_k8sio_api_core_v1_Endpoints(ref common.ReferenceCallback) common.Ope }, }, Dependencies: []string{ - "k8s.io/api/core/v1.EndpointSubset", "k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"}, + v1.EndpointSubset{}.OpenAPIModelName(), metav1.ObjectMeta{}.OpenAPIModelName()}, } } @@ -7183,7 +7169,7 @@ func schema_k8sio_api_core_v1_EndpointsList(ref common.ReferenceCallback) common SchemaProps: spec.SchemaProps{ Description: "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"), + Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), }, }, "items": { @@ -7194,7 +7180,7 @@ func schema_k8sio_api_core_v1_EndpointsList(ref common.ReferenceCallback) common Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.Endpoints"), + Ref: ref(v1.Endpoints{}.OpenAPIModelName()), }, }, }, @@ -7205,7 +7191,7 @@ func schema_k8sio_api_core_v1_EndpointsList(ref common.ReferenceCallback) common }, }, Dependencies: []string{ - "k8s.io/api/core/v1.Endpoints", "k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"}, + v1.Endpoints{}.OpenAPIModelName(), metav1.ListMeta{}.OpenAPIModelName()}, } } @@ -7226,20 +7212,20 @@ func schema_k8sio_api_core_v1_EnvFromSource(ref common.ReferenceCallback) common "configMapRef": { SchemaProps: spec.SchemaProps{ Description: "The ConfigMap to select from", - Ref: ref("k8s.io/api/core/v1.ConfigMapEnvSource"), + Ref: ref(v1.ConfigMapEnvSource{}.OpenAPIModelName()), }, }, "secretRef": { SchemaProps: spec.SchemaProps{ Description: "The Secret to select from", - Ref: ref("k8s.io/api/core/v1.SecretEnvSource"), + Ref: ref(v1.SecretEnvSource{}.OpenAPIModelName()), }, }, }, }, }, Dependencies: []string{ - "k8s.io/api/core/v1.ConfigMapEnvSource", "k8s.io/api/core/v1.SecretEnvSource"}, + v1.ConfigMapEnvSource{}.OpenAPIModelName(), v1.SecretEnvSource{}.OpenAPIModelName()}, } } @@ -7268,7 +7254,7 @@ func schema_k8sio_api_core_v1_EnvVar(ref common.ReferenceCallback) common.OpenAP "valueFrom": { SchemaProps: spec.SchemaProps{ Description: "Source for the environment variable's value. Cannot be used if value is not empty.", - Ref: ref("k8s.io/api/core/v1.EnvVarSource"), + Ref: ref(v1.EnvVarSource{}.OpenAPIModelName()), }, }, }, @@ -7276,7 +7262,7 @@ func schema_k8sio_api_core_v1_EnvVar(ref common.ReferenceCallback) common.OpenAP }, }, Dependencies: []string{ - "k8s.io/api/core/v1.EnvVarSource"}, + v1.EnvVarSource{}.OpenAPIModelName()}, } } @@ -7290,38 +7276,38 @@ func schema_k8sio_api_core_v1_EnvVarSource(ref common.ReferenceCallback) common. "fieldRef": { SchemaProps: spec.SchemaProps{ Description: "Selects a field of the pod: supports metadata.name, metadata.namespace, `metadata.labels['']`, `metadata.annotations['']`, spec.nodeName, spec.serviceAccountName, status.hostIP, status.podIP, status.podIPs.", - Ref: ref("k8s.io/api/core/v1.ObjectFieldSelector"), + Ref: ref(v1.ObjectFieldSelector{}.OpenAPIModelName()), }, }, "resourceFieldRef": { SchemaProps: spec.SchemaProps{ Description: "Selects a resource of the container: only resources limits and requests (limits.cpu, limits.memory, limits.ephemeral-storage, requests.cpu, requests.memory and requests.ephemeral-storage) are currently supported.", - Ref: ref("k8s.io/api/core/v1.ResourceFieldSelector"), + Ref: ref(v1.ResourceFieldSelector{}.OpenAPIModelName()), }, }, "configMapKeyRef": { SchemaProps: spec.SchemaProps{ Description: "Selects a key of a ConfigMap.", - Ref: ref("k8s.io/api/core/v1.ConfigMapKeySelector"), + Ref: ref(v1.ConfigMapKeySelector{}.OpenAPIModelName()), }, }, "secretKeyRef": { SchemaProps: spec.SchemaProps{ Description: "Selects a key of a secret in the pod's namespace", - Ref: ref("k8s.io/api/core/v1.SecretKeySelector"), + Ref: ref(v1.SecretKeySelector{}.OpenAPIModelName()), }, }, "fileKeyRef": { SchemaProps: spec.SchemaProps{ Description: "FileKeyRef selects a key of the env file. Requires the EnvFiles feature gate to be enabled.", - Ref: ref("k8s.io/api/core/v1.FileKeySelector"), + Ref: ref(v1.FileKeySelector{}.OpenAPIModelName()), }, }, }, }, }, Dependencies: []string{ - "k8s.io/api/core/v1.ConfigMapKeySelector", "k8s.io/api/core/v1.FileKeySelector", "k8s.io/api/core/v1.ObjectFieldSelector", "k8s.io/api/core/v1.ResourceFieldSelector", "k8s.io/api/core/v1.SecretKeySelector"}, + v1.ConfigMapKeySelector{}.OpenAPIModelName(), v1.FileKeySelector{}.OpenAPIModelName(), v1.ObjectFieldSelector{}.OpenAPIModelName(), v1.ResourceFieldSelector{}.OpenAPIModelName(), v1.SecretKeySelector{}.OpenAPIModelName()}, } } @@ -7413,7 +7399,7 @@ func schema_k8sio_api_core_v1_EphemeralContainer(ref common.ReferenceCallback) c Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.ContainerPort"), + Ref: ref(v1.ContainerPort{}.OpenAPIModelName()), }, }, }, @@ -7432,7 +7418,7 @@ func schema_k8sio_api_core_v1_EphemeralContainer(ref common.ReferenceCallback) c Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.EnvFromSource"), + Ref: ref(v1.EnvFromSource{}.OpenAPIModelName()), }, }, }, @@ -7456,7 +7442,7 @@ func schema_k8sio_api_core_v1_EphemeralContainer(ref common.ReferenceCallback) c Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.EnvVar"), + Ref: ref(v1.EnvVar{}.OpenAPIModelName()), }, }, }, @@ -7466,7 +7452,7 @@ func schema_k8sio_api_core_v1_EphemeralContainer(ref common.ReferenceCallback) c SchemaProps: spec.SchemaProps{ Description: "Resources are not allowed for ephemeral containers. Ephemeral containers use spare resources already allocated to the pod.", Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.ResourceRequirements"), + Ref: ref(v1.ResourceRequirements{}.OpenAPIModelName()), }, }, "resizePolicy": { @@ -7482,7 +7468,7 @@ func schema_k8sio_api_core_v1_EphemeralContainer(ref common.ReferenceCallback) c Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.ContainerResizePolicy"), + Ref: ref(v1.ContainerResizePolicy{}.OpenAPIModelName()), }, }, }, @@ -7508,7 +7494,7 @@ func schema_k8sio_api_core_v1_EphemeralContainer(ref common.ReferenceCallback) c Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.ContainerRestartRule"), + Ref: ref(v1.ContainerRestartRule{}.OpenAPIModelName()), }, }, }, @@ -7532,7 +7518,7 @@ func schema_k8sio_api_core_v1_EphemeralContainer(ref common.ReferenceCallback) c Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.VolumeMount"), + Ref: ref(v1.VolumeMount{}.OpenAPIModelName()), }, }, }, @@ -7556,7 +7542,7 @@ func schema_k8sio_api_core_v1_EphemeralContainer(ref common.ReferenceCallback) c Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.VolumeDevice"), + Ref: ref(v1.VolumeDevice{}.OpenAPIModelName()), }, }, }, @@ -7565,25 +7551,25 @@ func schema_k8sio_api_core_v1_EphemeralContainer(ref common.ReferenceCallback) c "livenessProbe": { SchemaProps: spec.SchemaProps{ Description: "Probes are not allowed for ephemeral containers.", - Ref: ref("k8s.io/api/core/v1.Probe"), + Ref: ref(v1.Probe{}.OpenAPIModelName()), }, }, "readinessProbe": { SchemaProps: spec.SchemaProps{ Description: "Probes are not allowed for ephemeral containers.", - Ref: ref("k8s.io/api/core/v1.Probe"), + Ref: ref(v1.Probe{}.OpenAPIModelName()), }, }, "startupProbe": { SchemaProps: spec.SchemaProps{ Description: "Probes are not allowed for ephemeral containers.", - Ref: ref("k8s.io/api/core/v1.Probe"), + Ref: ref(v1.Probe{}.OpenAPIModelName()), }, }, "lifecycle": { SchemaProps: spec.SchemaProps{ Description: "Lifecycle is not allowed for ephemeral containers.", - Ref: ref("k8s.io/api/core/v1.Lifecycle"), + Ref: ref(v1.Lifecycle{}.OpenAPIModelName()), }, }, "terminationMessagePath": { @@ -7612,7 +7598,7 @@ func schema_k8sio_api_core_v1_EphemeralContainer(ref common.ReferenceCallback) c "securityContext": { SchemaProps: spec.SchemaProps{ Description: "Optional: SecurityContext defines the security options the ephemeral container should be run with. If set, the fields of SecurityContext override the equivalent fields of PodSecurityContext.", - Ref: ref("k8s.io/api/core/v1.SecurityContext"), + Ref: ref(v1.SecurityContext{}.OpenAPIModelName()), }, }, "stdin": { @@ -7648,7 +7634,7 @@ func schema_k8sio_api_core_v1_EphemeralContainer(ref common.ReferenceCallback) c }, }, Dependencies: []string{ - "k8s.io/api/core/v1.ContainerPort", "k8s.io/api/core/v1.ContainerResizePolicy", "k8s.io/api/core/v1.ContainerRestartRule", "k8s.io/api/core/v1.EnvFromSource", "k8s.io/api/core/v1.EnvVar", "k8s.io/api/core/v1.Lifecycle", "k8s.io/api/core/v1.Probe", "k8s.io/api/core/v1.ResourceRequirements", "k8s.io/api/core/v1.SecurityContext", "k8s.io/api/core/v1.VolumeDevice", "k8s.io/api/core/v1.VolumeMount"}, + v1.ContainerPort{}.OpenAPIModelName(), v1.ContainerResizePolicy{}.OpenAPIModelName(), v1.ContainerRestartRule{}.OpenAPIModelName(), v1.EnvFromSource{}.OpenAPIModelName(), v1.EnvVar{}.OpenAPIModelName(), v1.Lifecycle{}.OpenAPIModelName(), v1.Probe{}.OpenAPIModelName(), v1.ResourceRequirements{}.OpenAPIModelName(), v1.SecurityContext{}.OpenAPIModelName(), v1.VolumeDevice{}.OpenAPIModelName(), v1.VolumeMount{}.OpenAPIModelName()}, } } @@ -7740,7 +7726,7 @@ func schema_k8sio_api_core_v1_EphemeralContainerCommon(ref common.ReferenceCallb Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.ContainerPort"), + Ref: ref(v1.ContainerPort{}.OpenAPIModelName()), }, }, }, @@ -7759,7 +7745,7 @@ func schema_k8sio_api_core_v1_EphemeralContainerCommon(ref common.ReferenceCallb Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.EnvFromSource"), + Ref: ref(v1.EnvFromSource{}.OpenAPIModelName()), }, }, }, @@ -7783,7 +7769,7 @@ func schema_k8sio_api_core_v1_EphemeralContainerCommon(ref common.ReferenceCallb Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.EnvVar"), + Ref: ref(v1.EnvVar{}.OpenAPIModelName()), }, }, }, @@ -7793,7 +7779,7 @@ func schema_k8sio_api_core_v1_EphemeralContainerCommon(ref common.ReferenceCallb SchemaProps: spec.SchemaProps{ Description: "Resources are not allowed for ephemeral containers. Ephemeral containers use spare resources already allocated to the pod.", Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.ResourceRequirements"), + Ref: ref(v1.ResourceRequirements{}.OpenAPIModelName()), }, }, "resizePolicy": { @@ -7809,7 +7795,7 @@ func schema_k8sio_api_core_v1_EphemeralContainerCommon(ref common.ReferenceCallb Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.ContainerResizePolicy"), + Ref: ref(v1.ContainerResizePolicy{}.OpenAPIModelName()), }, }, }, @@ -7835,7 +7821,7 @@ func schema_k8sio_api_core_v1_EphemeralContainerCommon(ref common.ReferenceCallb Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.ContainerRestartRule"), + Ref: ref(v1.ContainerRestartRule{}.OpenAPIModelName()), }, }, }, @@ -7859,7 +7845,7 @@ func schema_k8sio_api_core_v1_EphemeralContainerCommon(ref common.ReferenceCallb Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.VolumeMount"), + Ref: ref(v1.VolumeMount{}.OpenAPIModelName()), }, }, }, @@ -7883,7 +7869,7 @@ func schema_k8sio_api_core_v1_EphemeralContainerCommon(ref common.ReferenceCallb Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.VolumeDevice"), + Ref: ref(v1.VolumeDevice{}.OpenAPIModelName()), }, }, }, @@ -7892,25 +7878,25 @@ func schema_k8sio_api_core_v1_EphemeralContainerCommon(ref common.ReferenceCallb "livenessProbe": { SchemaProps: spec.SchemaProps{ Description: "Probes are not allowed for ephemeral containers.", - Ref: ref("k8s.io/api/core/v1.Probe"), + Ref: ref(v1.Probe{}.OpenAPIModelName()), }, }, "readinessProbe": { SchemaProps: spec.SchemaProps{ Description: "Probes are not allowed for ephemeral containers.", - Ref: ref("k8s.io/api/core/v1.Probe"), + Ref: ref(v1.Probe{}.OpenAPIModelName()), }, }, "startupProbe": { SchemaProps: spec.SchemaProps{ Description: "Probes are not allowed for ephemeral containers.", - Ref: ref("k8s.io/api/core/v1.Probe"), + Ref: ref(v1.Probe{}.OpenAPIModelName()), }, }, "lifecycle": { SchemaProps: spec.SchemaProps{ Description: "Lifecycle is not allowed for ephemeral containers.", - Ref: ref("k8s.io/api/core/v1.Lifecycle"), + Ref: ref(v1.Lifecycle{}.OpenAPIModelName()), }, }, "terminationMessagePath": { @@ -7939,7 +7925,7 @@ func schema_k8sio_api_core_v1_EphemeralContainerCommon(ref common.ReferenceCallb "securityContext": { SchemaProps: spec.SchemaProps{ Description: "Optional: SecurityContext defines the security options the ephemeral container should be run with. If set, the fields of SecurityContext override the equivalent fields of PodSecurityContext.", - Ref: ref("k8s.io/api/core/v1.SecurityContext"), + Ref: ref(v1.SecurityContext{}.OpenAPIModelName()), }, }, "stdin": { @@ -7968,7 +7954,7 @@ func schema_k8sio_api_core_v1_EphemeralContainerCommon(ref common.ReferenceCallb }, }, Dependencies: []string{ - "k8s.io/api/core/v1.ContainerPort", "k8s.io/api/core/v1.ContainerResizePolicy", "k8s.io/api/core/v1.ContainerRestartRule", "k8s.io/api/core/v1.EnvFromSource", "k8s.io/api/core/v1.EnvVar", "k8s.io/api/core/v1.Lifecycle", "k8s.io/api/core/v1.Probe", "k8s.io/api/core/v1.ResourceRequirements", "k8s.io/api/core/v1.SecurityContext", "k8s.io/api/core/v1.VolumeDevice", "k8s.io/api/core/v1.VolumeMount"}, + v1.ContainerPort{}.OpenAPIModelName(), v1.ContainerResizePolicy{}.OpenAPIModelName(), v1.ContainerRestartRule{}.OpenAPIModelName(), v1.EnvFromSource{}.OpenAPIModelName(), v1.EnvVar{}.OpenAPIModelName(), v1.Lifecycle{}.OpenAPIModelName(), v1.Probe{}.OpenAPIModelName(), v1.ResourceRequirements{}.OpenAPIModelName(), v1.SecurityContext{}.OpenAPIModelName(), v1.VolumeDevice{}.OpenAPIModelName(), v1.VolumeMount{}.OpenAPIModelName()}, } } @@ -7982,14 +7968,14 @@ func schema_k8sio_api_core_v1_EphemeralVolumeSource(ref common.ReferenceCallback "volumeClaimTemplate": { SchemaProps: spec.SchemaProps{ Description: "Will be used to create a stand-alone PVC to provision the volume. The pod in which this EphemeralVolumeSource is embedded will be the owner of the PVC, i.e. the PVC will be deleted together with the pod. The name of the PVC will be `-` where `` is the name from the `PodSpec.Volumes` array entry. Pod validation will reject the pod if the concatenated name is not valid for a PVC (for example, too long).\n\nAn existing PVC with that name that is not owned by the pod will *not* be used for the pod to avoid using an unrelated volume by mistake. Starting the pod is then blocked until the unrelated PVC is removed. If such a pre-created PVC is meant to be used by the pod, the PVC has to updated with an owner reference to the pod once the pod exists. Normally this should not be necessary, but it may be useful when manually reconstructing a broken cluster.\n\nThis field is read-only and no changes will be made by Kubernetes to the PVC after it has been created.\n\nRequired, must not be nil.", - Ref: ref("k8s.io/api/core/v1.PersistentVolumeClaimTemplate"), + Ref: ref(v1.PersistentVolumeClaimTemplate{}.OpenAPIModelName()), }, }, }, }, }, Dependencies: []string{ - "k8s.io/api/core/v1.PersistentVolumeClaimTemplate"}, + v1.PersistentVolumeClaimTemplate{}.OpenAPIModelName()}, } } @@ -8018,14 +8004,14 @@ func schema_k8sio_api_core_v1_Event(ref common.ReferenceCallback) common.OpenAPI SchemaProps: spec.SchemaProps{ Description: "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata", Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"), + Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), }, }, "involvedObject": { SchemaProps: spec.SchemaProps{ Description: "The object that this event is about.", Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.ObjectReference"), + Ref: ref(v1.ObjectReference{}.OpenAPIModelName()), }, }, "reason": { @@ -8046,19 +8032,19 @@ func schema_k8sio_api_core_v1_Event(ref common.ReferenceCallback) common.OpenAPI SchemaProps: spec.SchemaProps{ Description: "The component reporting this event. Should be a short machine understandable string.", Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.EventSource"), + Ref: ref(v1.EventSource{}.OpenAPIModelName()), }, }, "firstTimestamp": { SchemaProps: spec.SchemaProps{ Description: "The time at which the event was first recorded. (Time of server receipt is in TypeMeta.)", - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.Time"), + Ref: ref(metav1.Time{}.OpenAPIModelName()), }, }, "lastTimestamp": { SchemaProps: spec.SchemaProps{ Description: "The time at which the most recent occurrence of this event was recorded.", - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.Time"), + Ref: ref(metav1.Time{}.OpenAPIModelName()), }, }, "count": { @@ -8078,13 +8064,13 @@ func schema_k8sio_api_core_v1_Event(ref common.ReferenceCallback) common.OpenAPI "eventTime": { SchemaProps: spec.SchemaProps{ Description: "Time when this Event was first observed.", - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.MicroTime"), + Ref: ref(metav1.MicroTime{}.OpenAPIModelName()), }, }, "series": { SchemaProps: spec.SchemaProps{ Description: "Data about the Event series this event represents or nil if it's a singleton Event.", - Ref: ref("k8s.io/api/core/v1.EventSeries"), + Ref: ref(v1.EventSeries{}.OpenAPIModelName()), }, }, "action": { @@ -8097,7 +8083,7 @@ func schema_k8sio_api_core_v1_Event(ref common.ReferenceCallback) common.OpenAPI "related": { SchemaProps: spec.SchemaProps{ Description: "Optional secondary object for more complex actions.", - Ref: ref("k8s.io/api/core/v1.ObjectReference"), + Ref: ref(v1.ObjectReference{}.OpenAPIModelName()), }, }, "reportingComponent": { @@ -8121,7 +8107,7 @@ func schema_k8sio_api_core_v1_Event(ref common.ReferenceCallback) common.OpenAPI }, }, Dependencies: []string{ - "k8s.io/api/core/v1.EventSeries", "k8s.io/api/core/v1.EventSource", "k8s.io/api/core/v1.ObjectReference", "k8s.io/apimachinery/pkg/apis/meta/v1.MicroTime", "k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta", "k8s.io/apimachinery/pkg/apis/meta/v1.Time"}, + v1.EventSeries{}.OpenAPIModelName(), v1.EventSource{}.OpenAPIModelName(), v1.ObjectReference{}.OpenAPIModelName(), metav1.MicroTime{}.OpenAPIModelName(), metav1.ObjectMeta{}.OpenAPIModelName(), metav1.Time{}.OpenAPIModelName()}, } } @@ -8150,7 +8136,7 @@ func schema_k8sio_api_core_v1_EventList(ref common.ReferenceCallback) common.Ope SchemaProps: spec.SchemaProps{ Description: "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"), + Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), }, }, "items": { @@ -8161,7 +8147,7 @@ func schema_k8sio_api_core_v1_EventList(ref common.ReferenceCallback) common.Ope Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.Event"), + Ref: ref(v1.Event{}.OpenAPIModelName()), }, }, }, @@ -8172,7 +8158,7 @@ func schema_k8sio_api_core_v1_EventList(ref common.ReferenceCallback) common.Ope }, }, Dependencies: []string{ - "k8s.io/api/core/v1.Event", "k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"}, + v1.Event{}.OpenAPIModelName(), metav1.ListMeta{}.OpenAPIModelName()}, } } @@ -8193,14 +8179,14 @@ func schema_k8sio_api_core_v1_EventSeries(ref common.ReferenceCallback) common.O "lastObservedTime": { SchemaProps: spec.SchemaProps{ Description: "Time of the last occurrence observed", - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.MicroTime"), + Ref: ref(metav1.MicroTime{}.OpenAPIModelName()), }, }, }, }, }, Dependencies: []string{ - "k8s.io/apimachinery/pkg/apis/meta/v1.MicroTime"}, + metav1.MicroTime{}.OpenAPIModelName()}, } } @@ -8414,7 +8400,7 @@ func schema_k8sio_api_core_v1_FlexPersistentVolumeSource(ref common.ReferenceCal "secretRef": { SchemaProps: spec.SchemaProps{ Description: "secretRef is Optional: SecretRef is reference to the secret object containing sensitive information to pass to the plugin scripts. This may be empty if no secret object is specified. If the secret object contains more than one secret, all secrets are passed to the plugin scripts.", - Ref: ref("k8s.io/api/core/v1.SecretReference"), + Ref: ref(v1.SecretReference{}.OpenAPIModelName()), }, }, "readOnly": { @@ -8445,7 +8431,7 @@ func schema_k8sio_api_core_v1_FlexPersistentVolumeSource(ref common.ReferenceCal }, }, Dependencies: []string{ - "k8s.io/api/core/v1.SecretReference"}, + v1.SecretReference{}.OpenAPIModelName()}, } } @@ -8474,7 +8460,7 @@ func schema_k8sio_api_core_v1_FlexVolumeSource(ref common.ReferenceCallback) com "secretRef": { SchemaProps: spec.SchemaProps{ Description: "secretRef is Optional: secretRef is reference to the secret object containing sensitive information to pass to the plugin scripts. This may be empty if no secret object is specified. If the secret object contains more than one secret, all secrets are passed to the plugin scripts.", - Ref: ref("k8s.io/api/core/v1.LocalObjectReference"), + Ref: ref(v1.LocalObjectReference{}.OpenAPIModelName()), }, }, "readOnly": { @@ -8505,7 +8491,7 @@ func schema_k8sio_api_core_v1_FlexVolumeSource(ref common.ReferenceCallback) com }, }, Dependencies: []string{ - "k8s.io/api/core/v1.LocalObjectReference"}, + v1.LocalObjectReference{}.OpenAPIModelName()}, } } @@ -8774,7 +8760,7 @@ func schema_k8sio_api_core_v1_HTTPGetAction(ref common.ReferenceCallback) common Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.HTTPHeader"), + Ref: ref(v1.HTTPHeader{}.OpenAPIModelName()), }, }, }, @@ -8785,7 +8771,7 @@ func schema_k8sio_api_core_v1_HTTPGetAction(ref common.ReferenceCallback) common }, }, Dependencies: []string{ - "k8s.io/api/core/v1.HTTPHeader", "k8s.io/apimachinery/pkg/util/intstr.IntOrString"}, + v1.HTTPHeader{}.OpenAPIModelName(), "k8s.io/apimachinery/pkg/util/intstr.IntOrString"}, } } @@ -9003,7 +8989,7 @@ func schema_k8sio_api_core_v1_ISCSIPersistentVolumeSource(ref common.ReferenceCa "secretRef": { SchemaProps: spec.SchemaProps{ Description: "secretRef is the CHAP Secret for iSCSI target and initiator authentication", - Ref: ref("k8s.io/api/core/v1.SecretReference"), + Ref: ref(v1.SecretReference{}.OpenAPIModelName()), }, }, "initiatorName": { @@ -9018,7 +9004,7 @@ func schema_k8sio_api_core_v1_ISCSIPersistentVolumeSource(ref common.ReferenceCa }, }, Dependencies: []string{ - "k8s.io/api/core/v1.SecretReference"}, + v1.SecretReference{}.OpenAPIModelName()}, } } @@ -9112,7 +9098,7 @@ func schema_k8sio_api_core_v1_ISCSIVolumeSource(ref common.ReferenceCallback) co "secretRef": { SchemaProps: spec.SchemaProps{ Description: "secretRef is the CHAP Secret for iSCSI target and initiator authentication", - Ref: ref("k8s.io/api/core/v1.LocalObjectReference"), + Ref: ref(v1.LocalObjectReference{}.OpenAPIModelName()), }, }, "initiatorName": { @@ -9127,7 +9113,7 @@ func schema_k8sio_api_core_v1_ISCSIVolumeSource(ref common.ReferenceCallback) co }, }, Dependencies: []string{ - "k8s.io/api/core/v1.LocalObjectReference"}, + v1.LocalObjectReference{}.OpenAPIModelName()}, } } @@ -9206,13 +9192,13 @@ func schema_k8sio_api_core_v1_Lifecycle(ref common.ReferenceCallback) common.Ope "postStart": { SchemaProps: spec.SchemaProps{ Description: "PostStart is called immediately after a container is created. If the handler fails, the container is terminated and restarted according to its restart policy. Other management of the container blocks until the hook completes. More info: https://kubernetes.io/docs/concepts/containers/container-lifecycle-hooks/#container-hooks", - Ref: ref("k8s.io/api/core/v1.LifecycleHandler"), + Ref: ref(v1.LifecycleHandler{}.OpenAPIModelName()), }, }, "preStop": { SchemaProps: spec.SchemaProps{ Description: "PreStop is called immediately before a container is terminated due to an API request or management event such as liveness/startup probe failure, preemption, resource contention, etc. The handler is not called if the container crashes or exits. The Pod's termination grace period countdown begins before the PreStop hook is executed. Regardless of the outcome of the handler, the container will eventually terminate within the Pod's termination grace period (unless delayed by finalizers). Other management of the container blocks until the hook completes or until the termination grace period is reached. More info: https://kubernetes.io/docs/concepts/containers/container-lifecycle-hooks/#container-hooks", - Ref: ref("k8s.io/api/core/v1.LifecycleHandler"), + Ref: ref(v1.LifecycleHandler{}.OpenAPIModelName()), }, }, "stopSignal": { @@ -9227,7 +9213,7 @@ func schema_k8sio_api_core_v1_Lifecycle(ref common.ReferenceCallback) common.Ope }, }, Dependencies: []string{ - "k8s.io/api/core/v1.LifecycleHandler"}, + v1.LifecycleHandler{}.OpenAPIModelName()}, } } @@ -9241,32 +9227,32 @@ func schema_k8sio_api_core_v1_LifecycleHandler(ref common.ReferenceCallback) com "exec": { SchemaProps: spec.SchemaProps{ Description: "Exec specifies a command to execute in the container.", - Ref: ref("k8s.io/api/core/v1.ExecAction"), + Ref: ref(v1.ExecAction{}.OpenAPIModelName()), }, }, "httpGet": { SchemaProps: spec.SchemaProps{ Description: "HTTPGet specifies an HTTP GET request to perform.", - Ref: ref("k8s.io/api/core/v1.HTTPGetAction"), + Ref: ref(v1.HTTPGetAction{}.OpenAPIModelName()), }, }, "tcpSocket": { SchemaProps: spec.SchemaProps{ Description: "Deprecated. TCPSocket is NOT supported as a LifecycleHandler and kept for backward compatibility. There is no validation of this field and lifecycle hooks will fail at runtime when it is specified.", - Ref: ref("k8s.io/api/core/v1.TCPSocketAction"), + Ref: ref(v1.TCPSocketAction{}.OpenAPIModelName()), }, }, "sleep": { SchemaProps: spec.SchemaProps{ Description: "Sleep represents a duration that the container should sleep.", - Ref: ref("k8s.io/api/core/v1.SleepAction"), + Ref: ref(v1.SleepAction{}.OpenAPIModelName()), }, }, }, }, }, Dependencies: []string{ - "k8s.io/api/core/v1.ExecAction", "k8s.io/api/core/v1.HTTPGetAction", "k8s.io/api/core/v1.SleepAction", "k8s.io/api/core/v1.TCPSocketAction"}, + v1.ExecAction{}.OpenAPIModelName(), v1.HTTPGetAction{}.OpenAPIModelName(), v1.SleepAction{}.OpenAPIModelName(), v1.TCPSocketAction{}.OpenAPIModelName()}, } } @@ -9295,21 +9281,21 @@ func schema_k8sio_api_core_v1_LimitRange(ref common.ReferenceCallback) common.Op SchemaProps: spec.SchemaProps{ Description: "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata", Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"), + Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), }, }, "spec": { SchemaProps: spec.SchemaProps{ Description: "Spec defines the limits enforced. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status", Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.LimitRangeSpec"), + Ref: ref(v1.LimitRangeSpec{}.OpenAPIModelName()), }, }, }, }, }, Dependencies: []string{ - "k8s.io/api/core/v1.LimitRangeSpec", "k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"}, + v1.LimitRangeSpec{}.OpenAPIModelName(), metav1.ObjectMeta{}.OpenAPIModelName()}, } } @@ -9336,7 +9322,7 @@ func schema_k8sio_api_core_v1_LimitRangeItem(ref common.ReferenceCallback) commo Allows: true, Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ - Ref: ref("k8s.io/apimachinery/pkg/api/resource.Quantity"), + Ref: ref(resource.Quantity{}.OpenAPIModelName()), }, }, }, @@ -9350,7 +9336,7 @@ func schema_k8sio_api_core_v1_LimitRangeItem(ref common.ReferenceCallback) commo Allows: true, Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ - Ref: ref("k8s.io/apimachinery/pkg/api/resource.Quantity"), + Ref: ref(resource.Quantity{}.OpenAPIModelName()), }, }, }, @@ -9364,7 +9350,7 @@ func schema_k8sio_api_core_v1_LimitRangeItem(ref common.ReferenceCallback) commo Allows: true, Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ - Ref: ref("k8s.io/apimachinery/pkg/api/resource.Quantity"), + Ref: ref(resource.Quantity{}.OpenAPIModelName()), }, }, }, @@ -9378,7 +9364,7 @@ func schema_k8sio_api_core_v1_LimitRangeItem(ref common.ReferenceCallback) commo Allows: true, Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ - Ref: ref("k8s.io/apimachinery/pkg/api/resource.Quantity"), + Ref: ref(resource.Quantity{}.OpenAPIModelName()), }, }, }, @@ -9392,7 +9378,7 @@ func schema_k8sio_api_core_v1_LimitRangeItem(ref common.ReferenceCallback) commo Allows: true, Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ - Ref: ref("k8s.io/apimachinery/pkg/api/resource.Quantity"), + Ref: ref(resource.Quantity{}.OpenAPIModelName()), }, }, }, @@ -9403,7 +9389,7 @@ func schema_k8sio_api_core_v1_LimitRangeItem(ref common.ReferenceCallback) commo }, }, Dependencies: []string{ - "k8s.io/apimachinery/pkg/api/resource.Quantity"}, + resource.Quantity{}.OpenAPIModelName()}, } } @@ -9432,7 +9418,7 @@ func schema_k8sio_api_core_v1_LimitRangeList(ref common.ReferenceCallback) commo SchemaProps: spec.SchemaProps{ Description: "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"), + Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), }, }, "items": { @@ -9443,7 +9429,7 @@ func schema_k8sio_api_core_v1_LimitRangeList(ref common.ReferenceCallback) commo Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.LimitRange"), + Ref: ref(v1.LimitRange{}.OpenAPIModelName()), }, }, }, @@ -9454,7 +9440,7 @@ func schema_k8sio_api_core_v1_LimitRangeList(ref common.ReferenceCallback) commo }, }, Dependencies: []string{ - "k8s.io/api/core/v1.LimitRange", "k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"}, + v1.LimitRange{}.OpenAPIModelName(), metav1.ListMeta{}.OpenAPIModelName()}, } } @@ -9478,7 +9464,7 @@ func schema_k8sio_api_core_v1_LimitRangeSpec(ref common.ReferenceCallback) commo Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.LimitRangeItem"), + Ref: ref(v1.LimitRangeItem{}.OpenAPIModelName()), }, }, }, @@ -9489,7 +9475,7 @@ func schema_k8sio_api_core_v1_LimitRangeSpec(ref common.ReferenceCallback) commo }, }, Dependencies: []string{ - "k8s.io/api/core/v1.LimitRangeItem"}, + v1.LimitRangeItem{}.OpenAPIModelName()}, } } @@ -9568,7 +9554,7 @@ func schema_k8sio_api_core_v1_List(ref common.ReferenceCallback) common.OpenAPID SchemaProps: spec.SchemaProps{ Description: "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"), + Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), }, }, "items": { @@ -9578,7 +9564,7 @@ func schema_k8sio_api_core_v1_List(ref common.ReferenceCallback) common.OpenAPID Items: &spec.SchemaOrArray{ Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ - Ref: ref("k8s.io/apimachinery/pkg/runtime.RawExtension"), + Ref: ref(runtime.RawExtension{}.OpenAPIModelName()), }, }, }, @@ -9589,7 +9575,7 @@ func schema_k8sio_api_core_v1_List(ref common.ReferenceCallback) common.OpenAPID }, }, Dependencies: []string{ - "k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta", "k8s.io/apimachinery/pkg/runtime.RawExtension"}, + metav1.ListMeta{}.OpenAPIModelName(), runtime.RawExtension{}.OpenAPIModelName()}, } } @@ -9634,7 +9620,7 @@ func schema_k8sio_api_core_v1_LoadBalancerIngress(ref common.ReferenceCallback) Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.PortStatus"), + Ref: ref(v1.PortStatus{}.OpenAPIModelName()), }, }, }, @@ -9644,7 +9630,7 @@ func schema_k8sio_api_core_v1_LoadBalancerIngress(ref common.ReferenceCallback) }, }, Dependencies: []string{ - "k8s.io/api/core/v1.PortStatus"}, + v1.PortStatus{}.OpenAPIModelName()}, } } @@ -9668,7 +9654,7 @@ func schema_k8sio_api_core_v1_LoadBalancerStatus(ref common.ReferenceCallback) c Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.LoadBalancerIngress"), + Ref: ref(v1.LoadBalancerIngress{}.OpenAPIModelName()), }, }, }, @@ -9678,7 +9664,7 @@ func schema_k8sio_api_core_v1_LoadBalancerStatus(ref common.ReferenceCallback) c }, }, Dependencies: []string{ - "k8s.io/api/core/v1.LoadBalancerIngress"}, + v1.LoadBalancerIngress{}.OpenAPIModelName()}, } } @@ -9829,28 +9815,28 @@ func schema_k8sio_api_core_v1_Namespace(ref common.ReferenceCallback) common.Ope SchemaProps: spec.SchemaProps{ Description: "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata", Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"), + Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), }, }, "spec": { SchemaProps: spec.SchemaProps{ Description: "Spec defines the behavior of the Namespace. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status", Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.NamespaceSpec"), + Ref: ref(v1.NamespaceSpec{}.OpenAPIModelName()), }, }, "status": { SchemaProps: spec.SchemaProps{ Description: "Status describes the current status of a Namespace. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status", Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.NamespaceStatus"), + Ref: ref(v1.NamespaceStatus{}.OpenAPIModelName()), }, }, }, }, }, Dependencies: []string{ - "k8s.io/api/core/v1.NamespaceSpec", "k8s.io/api/core/v1.NamespaceStatus", "k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"}, + v1.NamespaceSpec{}.OpenAPIModelName(), v1.NamespaceStatus{}.OpenAPIModelName(), metav1.ObjectMeta{}.OpenAPIModelName()}, } } @@ -9880,7 +9866,7 @@ func schema_k8sio_api_core_v1_NamespaceCondition(ref common.ReferenceCallback) c "lastTransitionTime": { SchemaProps: spec.SchemaProps{ Description: "Last time the condition transitioned from one status to another.", - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.Time"), + Ref: ref(metav1.Time{}.OpenAPIModelName()), }, }, "reason": { @@ -9902,7 +9888,7 @@ func schema_k8sio_api_core_v1_NamespaceCondition(ref common.ReferenceCallback) c }, }, Dependencies: []string{ - "k8s.io/apimachinery/pkg/apis/meta/v1.Time"}, + metav1.Time{}.OpenAPIModelName()}, } } @@ -9931,7 +9917,7 @@ func schema_k8sio_api_core_v1_NamespaceList(ref common.ReferenceCallback) common SchemaProps: spec.SchemaProps{ Description: "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"), + Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), }, }, "items": { @@ -9942,7 +9928,7 @@ func schema_k8sio_api_core_v1_NamespaceList(ref common.ReferenceCallback) common Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.Namespace"), + Ref: ref(v1.Namespace{}.OpenAPIModelName()), }, }, }, @@ -9953,7 +9939,7 @@ func schema_k8sio_api_core_v1_NamespaceList(ref common.ReferenceCallback) common }, }, Dependencies: []string{ - "k8s.io/api/core/v1.Namespace", "k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"}, + v1.Namespace{}.OpenAPIModelName(), metav1.ListMeta{}.OpenAPIModelName()}, } } @@ -10023,7 +10009,7 @@ func schema_k8sio_api_core_v1_NamespaceStatus(ref common.ReferenceCallback) comm Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.NamespaceCondition"), + Ref: ref(v1.NamespaceCondition{}.OpenAPIModelName()), }, }, }, @@ -10033,7 +10019,7 @@ func schema_k8sio_api_core_v1_NamespaceStatus(ref common.ReferenceCallback) comm }, }, Dependencies: []string{ - "k8s.io/api/core/v1.NamespaceCondition"}, + v1.NamespaceCondition{}.OpenAPIModelName()}, } } @@ -10062,28 +10048,28 @@ func schema_k8sio_api_core_v1_Node(ref common.ReferenceCallback) common.OpenAPID SchemaProps: spec.SchemaProps{ Description: "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata", Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"), + Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), }, }, "spec": { SchemaProps: spec.SchemaProps{ Description: "Spec defines the behavior of a node. https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status", Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.NodeSpec"), + Ref: ref(v1.NodeSpec{}.OpenAPIModelName()), }, }, "status": { SchemaProps: spec.SchemaProps{ Description: "Most recently observed status of the node. Populated by the system. Read-only. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status", Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.NodeStatus"), + Ref: ref(v1.NodeStatus{}.OpenAPIModelName()), }, }, }, }, }, Dependencies: []string{ - "k8s.io/api/core/v1.NodeSpec", "k8s.io/api/core/v1.NodeStatus", "k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"}, + v1.NodeSpec{}.OpenAPIModelName(), v1.NodeStatus{}.OpenAPIModelName(), metav1.ObjectMeta{}.OpenAPIModelName()}, } } @@ -10127,7 +10113,7 @@ func schema_k8sio_api_core_v1_NodeAffinity(ref common.ReferenceCallback) common. "requiredDuringSchedulingIgnoredDuringExecution": { SchemaProps: spec.SchemaProps{ Description: "If the affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to an update), the system may or may not try to eventually evict the pod from its node.", - Ref: ref("k8s.io/api/core/v1.NodeSelector"), + Ref: ref(v1.NodeSelector{}.OpenAPIModelName()), }, }, "preferredDuringSchedulingIgnoredDuringExecution": { @@ -10143,7 +10129,7 @@ func schema_k8sio_api_core_v1_NodeAffinity(ref common.ReferenceCallback) common. Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.PreferredSchedulingTerm"), + Ref: ref(v1.PreferredSchedulingTerm{}.OpenAPIModelName()), }, }, }, @@ -10153,7 +10139,7 @@ func schema_k8sio_api_core_v1_NodeAffinity(ref common.ReferenceCallback) common. }, }, Dependencies: []string{ - "k8s.io/api/core/v1.NodeSelector", "k8s.io/api/core/v1.PreferredSchedulingTerm"}, + v1.NodeSelector{}.OpenAPIModelName(), v1.PreferredSchedulingTerm{}.OpenAPIModelName()}, } } @@ -10183,13 +10169,13 @@ func schema_k8sio_api_core_v1_NodeCondition(ref common.ReferenceCallback) common "lastHeartbeatTime": { SchemaProps: spec.SchemaProps{ Description: "Last time we got an update on a given condition.", - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.Time"), + Ref: ref(metav1.Time{}.OpenAPIModelName()), }, }, "lastTransitionTime": { SchemaProps: spec.SchemaProps{ Description: "Last time the condition transit from one status to another.", - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.Time"), + Ref: ref(metav1.Time{}.OpenAPIModelName()), }, }, "reason": { @@ -10211,7 +10197,7 @@ func schema_k8sio_api_core_v1_NodeCondition(ref common.ReferenceCallback) common }, }, Dependencies: []string{ - "k8s.io/apimachinery/pkg/apis/meta/v1.Time"}, + metav1.Time{}.OpenAPIModelName()}, } } @@ -10225,14 +10211,14 @@ func schema_k8sio_api_core_v1_NodeConfigSource(ref common.ReferenceCallback) com "configMap": { SchemaProps: spec.SchemaProps{ Description: "ConfigMap is a reference to a Node's ConfigMap", - Ref: ref("k8s.io/api/core/v1.ConfigMapNodeConfigSource"), + Ref: ref(v1.ConfigMapNodeConfigSource{}.OpenAPIModelName()), }, }, }, }, }, Dependencies: []string{ - "k8s.io/api/core/v1.ConfigMapNodeConfigSource"}, + v1.ConfigMapNodeConfigSource{}.OpenAPIModelName()}, } } @@ -10246,19 +10232,19 @@ func schema_k8sio_api_core_v1_NodeConfigStatus(ref common.ReferenceCallback) com "assigned": { SchemaProps: spec.SchemaProps{ Description: "Assigned reports the checkpointed config the node will try to use. When Node.Spec.ConfigSource is updated, the node checkpoints the associated config payload to local disk, along with a record indicating intended config. The node refers to this record to choose its config checkpoint, and reports this record in Assigned. Assigned only updates in the status after the record has been checkpointed to disk. When the Kubelet is restarted, it tries to make the Assigned config the Active config by loading and validating the checkpointed payload identified by Assigned.", - Ref: ref("k8s.io/api/core/v1.NodeConfigSource"), + Ref: ref(v1.NodeConfigSource{}.OpenAPIModelName()), }, }, "active": { SchemaProps: spec.SchemaProps{ Description: "Active reports the checkpointed config the node is actively using. Active will represent either the current version of the Assigned config, or the current LastKnownGood config, depending on whether attempting to use the Assigned config results in an error.", - Ref: ref("k8s.io/api/core/v1.NodeConfigSource"), + Ref: ref(v1.NodeConfigSource{}.OpenAPIModelName()), }, }, "lastKnownGood": { SchemaProps: spec.SchemaProps{ Description: "LastKnownGood reports the checkpointed config the node will fall back to when it encounters an error attempting to use the Assigned config. The Assigned config becomes the LastKnownGood config when the node determines that the Assigned config is stable and correct. This is currently implemented as a 10-minute soak period starting when the local record of Assigned config is updated. If the Assigned config is Active at the end of this period, it becomes the LastKnownGood. Note that if Spec.ConfigSource is reset to nil (use local defaults), the LastKnownGood is also immediately reset to nil, because the local default config is always assumed good. You should not make assumptions about the node's method of determining config stability and correctness, as this may change or become configurable in the future.", - Ref: ref("k8s.io/api/core/v1.NodeConfigSource"), + Ref: ref(v1.NodeConfigSource{}.OpenAPIModelName()), }, }, "error": { @@ -10272,7 +10258,7 @@ func schema_k8sio_api_core_v1_NodeConfigStatus(ref common.ReferenceCallback) com }, }, Dependencies: []string{ - "k8s.io/api/core/v1.NodeConfigSource"}, + v1.NodeConfigSource{}.OpenAPIModelName()}, } } @@ -10287,14 +10273,14 @@ func schema_k8sio_api_core_v1_NodeDaemonEndpoints(ref common.ReferenceCallback) SchemaProps: spec.SchemaProps{ Description: "Endpoint on which Kubelet is listening.", Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.DaemonEndpoint"), + Ref: ref(v1.DaemonEndpoint{}.OpenAPIModelName()), }, }, }, }, }, Dependencies: []string{ - "k8s.io/api/core/v1.DaemonEndpoint"}, + v1.DaemonEndpoint{}.OpenAPIModelName()}, } } @@ -10343,7 +10329,7 @@ func schema_k8sio_api_core_v1_NodeList(ref common.ReferenceCallback) common.Open SchemaProps: spec.SchemaProps{ Description: "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"), + Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), }, }, "items": { @@ -10354,7 +10340,7 @@ func schema_k8sio_api_core_v1_NodeList(ref common.ReferenceCallback) common.Open Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.Node"), + Ref: ref(v1.Node{}.OpenAPIModelName()), }, }, }, @@ -10365,7 +10351,7 @@ func schema_k8sio_api_core_v1_NodeList(ref common.ReferenceCallback) common.Open }, }, Dependencies: []string{ - "k8s.io/api/core/v1.Node", "k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"}, + v1.Node{}.OpenAPIModelName(), metav1.ListMeta{}.OpenAPIModelName()}, } } @@ -10421,14 +10407,14 @@ func schema_k8sio_api_core_v1_NodeRuntimeHandler(ref common.ReferenceCallback) c "features": { SchemaProps: spec.SchemaProps{ Description: "Supported features.", - Ref: ref("k8s.io/api/core/v1.NodeRuntimeHandlerFeatures"), + Ref: ref(v1.NodeRuntimeHandlerFeatures{}.OpenAPIModelName()), }, }, }, }, }, Dependencies: []string{ - "k8s.io/api/core/v1.NodeRuntimeHandlerFeatures"}, + v1.NodeRuntimeHandlerFeatures{}.OpenAPIModelName()}, } } @@ -10479,7 +10465,7 @@ func schema_k8sio_api_core_v1_NodeSelector(ref common.ReferenceCallback) common. Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.NodeSelectorTerm"), + Ref: ref(v1.NodeSelectorTerm{}.OpenAPIModelName()), }, }, }, @@ -10495,7 +10481,7 @@ func schema_k8sio_api_core_v1_NodeSelector(ref common.ReferenceCallback) common. }, }, Dependencies: []string{ - "k8s.io/api/core/v1.NodeSelectorTerm"}, + v1.NodeSelectorTerm{}.OpenAPIModelName()}, } } @@ -10570,7 +10556,7 @@ func schema_k8sio_api_core_v1_NodeSelectorTerm(ref common.ReferenceCallback) com Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.NodeSelectorRequirement"), + Ref: ref(v1.NodeSelectorRequirement{}.OpenAPIModelName()), }, }, }, @@ -10589,7 +10575,7 @@ func schema_k8sio_api_core_v1_NodeSelectorTerm(ref common.ReferenceCallback) com Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.NodeSelectorRequirement"), + Ref: ref(v1.NodeSelectorRequirement{}.OpenAPIModelName()), }, }, }, @@ -10604,7 +10590,7 @@ func schema_k8sio_api_core_v1_NodeSelectorTerm(ref common.ReferenceCallback) com }, }, Dependencies: []string{ - "k8s.io/api/core/v1.NodeSelectorRequirement"}, + v1.NodeSelectorRequirement{}.OpenAPIModelName()}, } } @@ -10670,7 +10656,7 @@ func schema_k8sio_api_core_v1_NodeSpec(ref common.ReferenceCallback) common.Open Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.Taint"), + Ref: ref(v1.Taint{}.OpenAPIModelName()), }, }, }, @@ -10679,7 +10665,7 @@ func schema_k8sio_api_core_v1_NodeSpec(ref common.ReferenceCallback) common.Open "configSource": { SchemaProps: spec.SchemaProps{ Description: "Deprecated: Previously used to specify the source of the node's configuration for the DynamicKubeletConfig feature. This feature is removed.", - Ref: ref("k8s.io/api/core/v1.NodeConfigSource"), + Ref: ref(v1.NodeConfigSource{}.OpenAPIModelName()), }, }, "externalID": { @@ -10693,7 +10679,7 @@ func schema_k8sio_api_core_v1_NodeSpec(ref common.ReferenceCallback) common.Open }, }, Dependencies: []string{ - "k8s.io/api/core/v1.NodeConfigSource", "k8s.io/api/core/v1.Taint"}, + v1.NodeConfigSource{}.OpenAPIModelName(), v1.Taint{}.OpenAPIModelName()}, } } @@ -10712,7 +10698,7 @@ func schema_k8sio_api_core_v1_NodeStatus(ref common.ReferenceCallback) common.Op Allows: true, Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ - Ref: ref("k8s.io/apimachinery/pkg/api/resource.Quantity"), + Ref: ref(resource.Quantity{}.OpenAPIModelName()), }, }, }, @@ -10726,7 +10712,7 @@ func schema_k8sio_api_core_v1_NodeStatus(ref common.ReferenceCallback) common.Op Allows: true, Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ - Ref: ref("k8s.io/apimachinery/pkg/api/resource.Quantity"), + Ref: ref(resource.Quantity{}.OpenAPIModelName()), }, }, }, @@ -10758,7 +10744,7 @@ func schema_k8sio_api_core_v1_NodeStatus(ref common.ReferenceCallback) common.Op Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.NodeCondition"), + Ref: ref(v1.NodeCondition{}.OpenAPIModelName()), }, }, }, @@ -10782,7 +10768,7 @@ func schema_k8sio_api_core_v1_NodeStatus(ref common.ReferenceCallback) common.Op Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.NodeAddress"), + Ref: ref(v1.NodeAddress{}.OpenAPIModelName()), }, }, }, @@ -10792,14 +10778,14 @@ func schema_k8sio_api_core_v1_NodeStatus(ref common.ReferenceCallback) common.Op SchemaProps: spec.SchemaProps{ Description: "Endpoints of daemons running on the Node.", Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.NodeDaemonEndpoints"), + Ref: ref(v1.NodeDaemonEndpoints{}.OpenAPIModelName()), }, }, "nodeInfo": { SchemaProps: spec.SchemaProps{ Description: "Set of ids/uuids to uniquely identify the node. More info: https://kubernetes.io/docs/reference/node/node-status/#info", Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.NodeSystemInfo"), + Ref: ref(v1.NodeSystemInfo{}.OpenAPIModelName()), }, }, "images": { @@ -10815,7 +10801,7 @@ func schema_k8sio_api_core_v1_NodeStatus(ref common.ReferenceCallback) common.Op Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.ContainerImage"), + Ref: ref(v1.ContainerImage{}.OpenAPIModelName()), }, }, }, @@ -10854,7 +10840,7 @@ func schema_k8sio_api_core_v1_NodeStatus(ref common.ReferenceCallback) common.Op Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.AttachedVolume"), + Ref: ref(v1.AttachedVolume{}.OpenAPIModelName()), }, }, }, @@ -10863,7 +10849,7 @@ func schema_k8sio_api_core_v1_NodeStatus(ref common.ReferenceCallback) common.Op "config": { SchemaProps: spec.SchemaProps{ Description: "Status of the config assigned to the node via the dynamic Kubelet config feature.", - Ref: ref("k8s.io/api/core/v1.NodeConfigStatus"), + Ref: ref(v1.NodeConfigStatus{}.OpenAPIModelName()), }, }, "runtimeHandlers": { @@ -10879,7 +10865,7 @@ func schema_k8sio_api_core_v1_NodeStatus(ref common.ReferenceCallback) common.Op Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.NodeRuntimeHandler"), + Ref: ref(v1.NodeRuntimeHandler{}.OpenAPIModelName()), }, }, }, @@ -10888,7 +10874,7 @@ func schema_k8sio_api_core_v1_NodeStatus(ref common.ReferenceCallback) common.Op "features": { SchemaProps: spec.SchemaProps{ Description: "Features describes the set of features implemented by the CRI implementation.", - Ref: ref("k8s.io/api/core/v1.NodeFeatures"), + Ref: ref(v1.NodeFeatures{}.OpenAPIModelName()), }, }, "declaredFeatures": { @@ -10915,7 +10901,7 @@ func schema_k8sio_api_core_v1_NodeStatus(ref common.ReferenceCallback) common.Op }, }, Dependencies: []string{ - "k8s.io/api/core/v1.AttachedVolume", "k8s.io/api/core/v1.ContainerImage", "k8s.io/api/core/v1.NodeAddress", "k8s.io/api/core/v1.NodeCondition", "k8s.io/api/core/v1.NodeConfigStatus", "k8s.io/api/core/v1.NodeDaemonEndpoints", "k8s.io/api/core/v1.NodeFeatures", "k8s.io/api/core/v1.NodeRuntimeHandler", "k8s.io/api/core/v1.NodeSystemInfo", "k8s.io/apimachinery/pkg/api/resource.Quantity"}, + v1.AttachedVolume{}.OpenAPIModelName(), v1.ContainerImage{}.OpenAPIModelName(), v1.NodeAddress{}.OpenAPIModelName(), v1.NodeCondition{}.OpenAPIModelName(), v1.NodeConfigStatus{}.OpenAPIModelName(), v1.NodeDaemonEndpoints{}.OpenAPIModelName(), v1.NodeFeatures{}.OpenAPIModelName(), v1.NodeRuntimeHandler{}.OpenAPIModelName(), v1.NodeSystemInfo{}.OpenAPIModelName(), resource.Quantity{}.OpenAPIModelName()}, } } @@ -11029,7 +11015,7 @@ func schema_k8sio_api_core_v1_NodeSystemInfo(ref common.ReferenceCallback) commo "swap": { SchemaProps: spec.SchemaProps{ Description: "Swap Info reported by the node.", - Ref: ref("k8s.io/api/core/v1.NodeSwapStatus"), + Ref: ref(v1.NodeSwapStatus{}.OpenAPIModelName()), }, }, }, @@ -11037,7 +11023,7 @@ func schema_k8sio_api_core_v1_NodeSystemInfo(ref common.ReferenceCallback) commo }, }, Dependencies: []string{ - "k8s.io/api/core/v1.NodeSwapStatus"}, + v1.NodeSwapStatus{}.OpenAPIModelName()}, } } @@ -11167,28 +11153,28 @@ func schema_k8sio_api_core_v1_PersistentVolume(ref common.ReferenceCallback) com SchemaProps: spec.SchemaProps{ Description: "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata", Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"), + Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), }, }, "spec": { SchemaProps: spec.SchemaProps{ Description: "spec defines a specification of a persistent volume owned by the cluster. Provisioned by an administrator. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#persistent-volumes", Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.PersistentVolumeSpec"), + Ref: ref(v1.PersistentVolumeSpec{}.OpenAPIModelName()), }, }, "status": { SchemaProps: spec.SchemaProps{ Description: "status represents the current information/status for the persistent volume. Populated by the system. Read-only. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#persistent-volumes", Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.PersistentVolumeStatus"), + Ref: ref(v1.PersistentVolumeStatus{}.OpenAPIModelName()), }, }, }, }, }, Dependencies: []string{ - "k8s.io/api/core/v1.PersistentVolumeSpec", "k8s.io/api/core/v1.PersistentVolumeStatus", "k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"}, + v1.PersistentVolumeSpec{}.OpenAPIModelName(), v1.PersistentVolumeStatus{}.OpenAPIModelName(), metav1.ObjectMeta{}.OpenAPIModelName()}, } } @@ -11217,28 +11203,28 @@ func schema_k8sio_api_core_v1_PersistentVolumeClaim(ref common.ReferenceCallback SchemaProps: spec.SchemaProps{ Description: "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata", Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"), + Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), }, }, "spec": { SchemaProps: spec.SchemaProps{ Description: "spec defines the desired characteristics of a volume requested by a pod author. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#persistentvolumeclaims", Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.PersistentVolumeClaimSpec"), + Ref: ref(v1.PersistentVolumeClaimSpec{}.OpenAPIModelName()), }, }, "status": { SchemaProps: spec.SchemaProps{ Description: "status represents the current information/status of a persistent volume claim. Read-only. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#persistentvolumeclaims", Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.PersistentVolumeClaimStatus"), + Ref: ref(v1.PersistentVolumeClaimStatus{}.OpenAPIModelName()), }, }, }, }, }, Dependencies: []string{ - "k8s.io/api/core/v1.PersistentVolumeClaimSpec", "k8s.io/api/core/v1.PersistentVolumeClaimStatus", "k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"}, + v1.PersistentVolumeClaimSpec{}.OpenAPIModelName(), v1.PersistentVolumeClaimStatus{}.OpenAPIModelName(), metav1.ObjectMeta{}.OpenAPIModelName()}, } } @@ -11268,13 +11254,13 @@ func schema_k8sio_api_core_v1_PersistentVolumeClaimCondition(ref common.Referenc "lastProbeTime": { SchemaProps: spec.SchemaProps{ Description: "lastProbeTime is the time we probed the condition.", - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.Time"), + Ref: ref(metav1.Time{}.OpenAPIModelName()), }, }, "lastTransitionTime": { SchemaProps: spec.SchemaProps{ Description: "lastTransitionTime is the time the condition transitioned from one status to another.", - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.Time"), + Ref: ref(metav1.Time{}.OpenAPIModelName()), }, }, "reason": { @@ -11296,7 +11282,7 @@ func schema_k8sio_api_core_v1_PersistentVolumeClaimCondition(ref common.Referenc }, }, Dependencies: []string{ - "k8s.io/apimachinery/pkg/apis/meta/v1.Time"}, + metav1.Time{}.OpenAPIModelName()}, } } @@ -11325,7 +11311,7 @@ func schema_k8sio_api_core_v1_PersistentVolumeClaimList(ref common.ReferenceCall SchemaProps: spec.SchemaProps{ Description: "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"), + Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), }, }, "items": { @@ -11336,7 +11322,7 @@ func schema_k8sio_api_core_v1_PersistentVolumeClaimList(ref common.ReferenceCall Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.PersistentVolumeClaim"), + Ref: ref(v1.PersistentVolumeClaim{}.OpenAPIModelName()), }, }, }, @@ -11347,7 +11333,7 @@ func schema_k8sio_api_core_v1_PersistentVolumeClaimList(ref common.ReferenceCall }, }, Dependencies: []string{ - "k8s.io/api/core/v1.PersistentVolumeClaim", "k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"}, + v1.PersistentVolumeClaim{}.OpenAPIModelName(), metav1.ListMeta{}.OpenAPIModelName()}, } } @@ -11382,14 +11368,14 @@ func schema_k8sio_api_core_v1_PersistentVolumeClaimSpec(ref common.ReferenceCall "selector": { SchemaProps: spec.SchemaProps{ Description: "selector is a label query over volumes to consider for binding.", - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.LabelSelector"), + Ref: ref(metav1.LabelSelector{}.OpenAPIModelName()), }, }, "resources": { SchemaProps: spec.SchemaProps{ Description: "resources represents the minimum resources the volume should have. Users are allowed to specify resource requirements that are lower than previous value but must still be higher than capacity recorded in the status field of the claim. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#resources", Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.VolumeResourceRequirements"), + Ref: ref(v1.VolumeResourceRequirements{}.OpenAPIModelName()), }, }, "volumeName": { @@ -11417,13 +11403,13 @@ func schema_k8sio_api_core_v1_PersistentVolumeClaimSpec(ref common.ReferenceCall "dataSource": { SchemaProps: spec.SchemaProps{ Description: "dataSource field can be used to specify either: * An existing VolumeSnapshot object (snapshot.storage.k8s.io/VolumeSnapshot) * An existing PVC (PersistentVolumeClaim) If the provisioner or an external controller can support the specified data source, it will create a new volume based on the contents of the specified data source. When the AnyVolumeDataSource feature gate is enabled, dataSource contents will be copied to dataSourceRef, and dataSourceRef contents will be copied to dataSource when dataSourceRef.namespace is not specified. If the namespace is specified, then dataSourceRef will not be copied to dataSource.", - Ref: ref("k8s.io/api/core/v1.TypedLocalObjectReference"), + Ref: ref(v1.TypedLocalObjectReference{}.OpenAPIModelName()), }, }, "dataSourceRef": { SchemaProps: spec.SchemaProps{ Description: "dataSourceRef specifies the object from which to populate the volume with data, if a non-empty volume is desired. This may be any object from a non-empty API group (non core object) or a PersistentVolumeClaim object. When this field is specified, volume binding will only succeed if the type of the specified object matches some installed volume populator or dynamic provisioner. This field will replace the functionality of the dataSource field and as such if both fields are non-empty, they must have the same value. For backwards compatibility, when namespace isn't specified in dataSourceRef, both fields (dataSource and dataSourceRef) will be set to the same value automatically if one of them is empty and the other is non-empty. When namespace is specified in dataSourceRef, dataSource isn't set to the same value and must be empty. There are three important differences between dataSource and dataSourceRef: * While dataSource only allows two specific types of objects, dataSourceRef\n allows any non-core object, as well as PersistentVolumeClaim objects.\n* While dataSource ignores disallowed values (dropping them), dataSourceRef\n preserves all values, and generates an error if a disallowed value is\n specified.\n* While dataSource only allows local objects, dataSourceRef allows objects\n in any namespaces.\n(Beta) Using this field requires the AnyVolumeDataSource feature gate to be enabled. (Alpha) Using the namespace field of dataSourceRef requires the CrossNamespaceVolumeDataSource feature gate to be enabled.", - Ref: ref("k8s.io/api/core/v1.TypedObjectReference"), + Ref: ref(v1.TypedObjectReference{}.OpenAPIModelName()), }, }, "volumeAttributesClassName": { @@ -11437,7 +11423,7 @@ func schema_k8sio_api_core_v1_PersistentVolumeClaimSpec(ref common.ReferenceCall }, }, Dependencies: []string{ - "k8s.io/api/core/v1.TypedLocalObjectReference", "k8s.io/api/core/v1.TypedObjectReference", "k8s.io/api/core/v1.VolumeResourceRequirements", "k8s.io/apimachinery/pkg/apis/meta/v1.LabelSelector"}, + v1.TypedLocalObjectReference{}.OpenAPIModelName(), v1.TypedObjectReference{}.OpenAPIModelName(), v1.VolumeResourceRequirements{}.OpenAPIModelName(), metav1.LabelSelector{}.OpenAPIModelName()}, } } @@ -11485,7 +11471,7 @@ func schema_k8sio_api_core_v1_PersistentVolumeClaimStatus(ref common.ReferenceCa Allows: true, Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ - Ref: ref("k8s.io/apimachinery/pkg/api/resource.Quantity"), + Ref: ref(resource.Quantity{}.OpenAPIModelName()), }, }, }, @@ -11509,7 +11495,7 @@ func schema_k8sio_api_core_v1_PersistentVolumeClaimStatus(ref common.ReferenceCa Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.PersistentVolumeClaimCondition"), + Ref: ref(v1.PersistentVolumeClaimCondition{}.OpenAPIModelName()), }, }, }, @@ -11523,7 +11509,7 @@ func schema_k8sio_api_core_v1_PersistentVolumeClaimStatus(ref common.ReferenceCa Allows: true, Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ - Ref: ref("k8s.io/apimachinery/pkg/api/resource.Quantity"), + Ref: ref(resource.Quantity{}.OpenAPIModelName()), }, }, }, @@ -11561,14 +11547,14 @@ func schema_k8sio_api_core_v1_PersistentVolumeClaimStatus(ref common.ReferenceCa "modifyVolumeStatus": { SchemaProps: spec.SchemaProps{ Description: "ModifyVolumeStatus represents the status object of ControllerModifyVolume operation. When this is unset, there is no ModifyVolume operation being attempted.", - Ref: ref("k8s.io/api/core/v1.ModifyVolumeStatus"), + Ref: ref(v1.ModifyVolumeStatus{}.OpenAPIModelName()), }, }, }, }, }, Dependencies: []string{ - "k8s.io/api/core/v1.ModifyVolumeStatus", "k8s.io/api/core/v1.PersistentVolumeClaimCondition", "k8s.io/apimachinery/pkg/api/resource.Quantity"}, + v1.ModifyVolumeStatus{}.OpenAPIModelName(), v1.PersistentVolumeClaimCondition{}.OpenAPIModelName(), resource.Quantity{}.OpenAPIModelName()}, } } @@ -11583,14 +11569,14 @@ func schema_k8sio_api_core_v1_PersistentVolumeClaimTemplate(ref common.Reference SchemaProps: spec.SchemaProps{ Description: "May contain labels and annotations that will be copied into the PVC when creating it. No other fields are allowed and will be rejected during validation.", Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"), + Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), }, }, "spec": { SchemaProps: spec.SchemaProps{ Description: "The specification for the PersistentVolumeClaim. The entire content is copied unchanged into the PVC that gets created from this template. The same fields as in a PersistentVolumeClaim are also valid here.", Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.PersistentVolumeClaimSpec"), + Ref: ref(v1.PersistentVolumeClaimSpec{}.OpenAPIModelName()), }, }, }, @@ -11598,7 +11584,7 @@ func schema_k8sio_api_core_v1_PersistentVolumeClaimTemplate(ref common.Reference }, }, Dependencies: []string{ - "k8s.io/api/core/v1.PersistentVolumeClaimSpec", "k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"}, + v1.PersistentVolumeClaimSpec{}.OpenAPIModelName(), metav1.ObjectMeta{}.OpenAPIModelName()}, } } @@ -11656,7 +11642,7 @@ func schema_k8sio_api_core_v1_PersistentVolumeList(ref common.ReferenceCallback) SchemaProps: spec.SchemaProps{ Description: "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"), + Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), }, }, "items": { @@ -11667,7 +11653,7 @@ func schema_k8sio_api_core_v1_PersistentVolumeList(ref common.ReferenceCallback) Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.PersistentVolume"), + Ref: ref(v1.PersistentVolume{}.OpenAPIModelName()), }, }, }, @@ -11678,7 +11664,7 @@ func schema_k8sio_api_core_v1_PersistentVolumeList(ref common.ReferenceCallback) }, }, Dependencies: []string{ - "k8s.io/api/core/v1.PersistentVolume", "k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"}, + v1.PersistentVolume{}.OpenAPIModelName(), metav1.ListMeta{}.OpenAPIModelName()}, } } @@ -11692,140 +11678,140 @@ func schema_k8sio_api_core_v1_PersistentVolumeSource(ref common.ReferenceCallbac "gcePersistentDisk": { SchemaProps: spec.SchemaProps{ Description: "gcePersistentDisk represents a GCE Disk resource that is attached to a kubelet's host machine and then exposed to the pod. Provisioned by an admin. Deprecated: GCEPersistentDisk is deprecated. All operations for the in-tree gcePersistentDisk type are redirected to the pd.csi.storage.gke.io CSI driver. More info: https://kubernetes.io/docs/concepts/storage/volumes#gcepersistentdisk", - Ref: ref("k8s.io/api/core/v1.GCEPersistentDiskVolumeSource"), + Ref: ref(v1.GCEPersistentDiskVolumeSource{}.OpenAPIModelName()), }, }, "awsElasticBlockStore": { SchemaProps: spec.SchemaProps{ Description: "awsElasticBlockStore represents an AWS Disk resource that is attached to a kubelet's host machine and then exposed to the pod. Deprecated: AWSElasticBlockStore is deprecated. All operations for the in-tree awsElasticBlockStore type are redirected to the ebs.csi.aws.com CSI driver. More info: https://kubernetes.io/docs/concepts/storage/volumes#awselasticblockstore", - Ref: ref("k8s.io/api/core/v1.AWSElasticBlockStoreVolumeSource"), + Ref: ref(v1.AWSElasticBlockStoreVolumeSource{}.OpenAPIModelName()), }, }, "hostPath": { SchemaProps: spec.SchemaProps{ Description: "hostPath represents a directory on the host. Provisioned by a developer or tester. This is useful for single-node development and testing only! On-host storage is not supported in any way and WILL NOT WORK in a multi-node cluster. More info: https://kubernetes.io/docs/concepts/storage/volumes#hostpath", - Ref: ref("k8s.io/api/core/v1.HostPathVolumeSource"), + Ref: ref(v1.HostPathVolumeSource{}.OpenAPIModelName()), }, }, "glusterfs": { SchemaProps: spec.SchemaProps{ Description: "glusterfs represents a Glusterfs volume that is attached to a host and exposed to the pod. Provisioned by an admin. Deprecated: Glusterfs is deprecated and the in-tree glusterfs type is no longer supported. More info: https://examples.k8s.io/volumes/glusterfs/README.md", - Ref: ref("k8s.io/api/core/v1.GlusterfsPersistentVolumeSource"), + Ref: ref(v1.GlusterfsPersistentVolumeSource{}.OpenAPIModelName()), }, }, "nfs": { SchemaProps: spec.SchemaProps{ Description: "nfs represents an NFS mount on the host. Provisioned by an admin. More info: https://kubernetes.io/docs/concepts/storage/volumes#nfs", - Ref: ref("k8s.io/api/core/v1.NFSVolumeSource"), + Ref: ref(v1.NFSVolumeSource{}.OpenAPIModelName()), }, }, "rbd": { SchemaProps: spec.SchemaProps{ Description: "rbd represents a Rados Block Device mount on the host that shares a pod's lifetime. Deprecated: RBD is deprecated and the in-tree rbd type is no longer supported. More info: https://examples.k8s.io/volumes/rbd/README.md", - Ref: ref("k8s.io/api/core/v1.RBDPersistentVolumeSource"), + Ref: ref(v1.RBDPersistentVolumeSource{}.OpenAPIModelName()), }, }, "iscsi": { SchemaProps: spec.SchemaProps{ Description: "iscsi represents an ISCSI Disk resource that is attached to a kubelet's host machine and then exposed to the pod. Provisioned by an admin.", - Ref: ref("k8s.io/api/core/v1.ISCSIPersistentVolumeSource"), + Ref: ref(v1.ISCSIPersistentVolumeSource{}.OpenAPIModelName()), }, }, "cinder": { SchemaProps: spec.SchemaProps{ Description: "cinder represents a cinder volume attached and mounted on kubelets host machine. Deprecated: Cinder is deprecated. All operations for the in-tree cinder type are redirected to the cinder.csi.openstack.org CSI driver. More info: https://examples.k8s.io/mysql-cinder-pd/README.md", - Ref: ref("k8s.io/api/core/v1.CinderPersistentVolumeSource"), + Ref: ref(v1.CinderPersistentVolumeSource{}.OpenAPIModelName()), }, }, "cephfs": { SchemaProps: spec.SchemaProps{ Description: "cephFS represents a Ceph FS mount on the host that shares a pod's lifetime. Deprecated: CephFS is deprecated and the in-tree cephfs type is no longer supported.", - Ref: ref("k8s.io/api/core/v1.CephFSPersistentVolumeSource"), + Ref: ref(v1.CephFSPersistentVolumeSource{}.OpenAPIModelName()), }, }, "fc": { SchemaProps: spec.SchemaProps{ Description: "fc represents a Fibre Channel resource that is attached to a kubelet's host machine and then exposed to the pod.", - Ref: ref("k8s.io/api/core/v1.FCVolumeSource"), + Ref: ref(v1.FCVolumeSource{}.OpenAPIModelName()), }, }, "flocker": { SchemaProps: spec.SchemaProps{ Description: "flocker represents a Flocker volume attached to a kubelet's host machine and exposed to the pod for its usage. This depends on the Flocker control service being running. Deprecated: Flocker is deprecated and the in-tree flocker type is no longer supported.", - Ref: ref("k8s.io/api/core/v1.FlockerVolumeSource"), + Ref: ref(v1.FlockerVolumeSource{}.OpenAPIModelName()), }, }, "flexVolume": { SchemaProps: spec.SchemaProps{ Description: "flexVolume represents a generic volume resource that is provisioned/attached using an exec based plugin. Deprecated: FlexVolume is deprecated. Consider using a CSIDriver instead.", - Ref: ref("k8s.io/api/core/v1.FlexPersistentVolumeSource"), + Ref: ref(v1.FlexPersistentVolumeSource{}.OpenAPIModelName()), }, }, "azureFile": { SchemaProps: spec.SchemaProps{ Description: "azureFile represents an Azure File Service mount on the host and bind mount to the pod. Deprecated: AzureFile is deprecated. All operations for the in-tree azureFile type are redirected to the file.csi.azure.com CSI driver.", - Ref: ref("k8s.io/api/core/v1.AzureFilePersistentVolumeSource"), + Ref: ref(v1.AzureFilePersistentVolumeSource{}.OpenAPIModelName()), }, }, "vsphereVolume": { SchemaProps: spec.SchemaProps{ Description: "vsphereVolume represents a vSphere volume attached and mounted on kubelets host machine. Deprecated: VsphereVolume is deprecated. All operations for the in-tree vsphereVolume type are redirected to the csi.vsphere.vmware.com CSI driver.", - Ref: ref("k8s.io/api/core/v1.VsphereVirtualDiskVolumeSource"), + Ref: ref(v1.VsphereVirtualDiskVolumeSource{}.OpenAPIModelName()), }, }, "quobyte": { SchemaProps: spec.SchemaProps{ Description: "quobyte represents a Quobyte mount on the host that shares a pod's lifetime. Deprecated: Quobyte is deprecated and the in-tree quobyte type is no longer supported.", - Ref: ref("k8s.io/api/core/v1.QuobyteVolumeSource"), + Ref: ref(v1.QuobyteVolumeSource{}.OpenAPIModelName()), }, }, "azureDisk": { SchemaProps: spec.SchemaProps{ Description: "azureDisk represents an Azure Data Disk mount on the host and bind mount to the pod. Deprecated: AzureDisk is deprecated. All operations for the in-tree azureDisk type are redirected to the disk.csi.azure.com CSI driver.", - Ref: ref("k8s.io/api/core/v1.AzureDiskVolumeSource"), + Ref: ref(v1.AzureDiskVolumeSource{}.OpenAPIModelName()), }, }, "photonPersistentDisk": { SchemaProps: spec.SchemaProps{ Description: "photonPersistentDisk represents a PhotonController persistent disk attached and mounted on kubelets host machine. Deprecated: PhotonPersistentDisk is deprecated and the in-tree photonPersistentDisk type is no longer supported.", - Ref: ref("k8s.io/api/core/v1.PhotonPersistentDiskVolumeSource"), + Ref: ref(v1.PhotonPersistentDiskVolumeSource{}.OpenAPIModelName()), }, }, "portworxVolume": { SchemaProps: spec.SchemaProps{ Description: "portworxVolume represents a portworx volume attached and mounted on kubelets host machine. Deprecated: PortworxVolume is deprecated. All operations for the in-tree portworxVolume type are redirected to the pxd.portworx.com CSI driver when the CSIMigrationPortworx feature-gate is on.", - Ref: ref("k8s.io/api/core/v1.PortworxVolumeSource"), + Ref: ref(v1.PortworxVolumeSource{}.OpenAPIModelName()), }, }, "scaleIO": { SchemaProps: spec.SchemaProps{ Description: "scaleIO represents a ScaleIO persistent volume attached and mounted on Kubernetes nodes. Deprecated: ScaleIO is deprecated and the in-tree scaleIO type is no longer supported.", - Ref: ref("k8s.io/api/core/v1.ScaleIOPersistentVolumeSource"), + Ref: ref(v1.ScaleIOPersistentVolumeSource{}.OpenAPIModelName()), }, }, "local": { SchemaProps: spec.SchemaProps{ Description: "local represents directly-attached storage with node affinity", - Ref: ref("k8s.io/api/core/v1.LocalVolumeSource"), + Ref: ref(v1.LocalVolumeSource{}.OpenAPIModelName()), }, }, "storageos": { SchemaProps: spec.SchemaProps{ Description: "storageOS represents a StorageOS volume that is attached to the kubelet's host machine and mounted into the pod. Deprecated: StorageOS is deprecated and the in-tree storageos type is no longer supported. More info: https://examples.k8s.io/volumes/storageos/README.md", - Ref: ref("k8s.io/api/core/v1.StorageOSPersistentVolumeSource"), + Ref: ref(v1.StorageOSPersistentVolumeSource{}.OpenAPIModelName()), }, }, "csi": { SchemaProps: spec.SchemaProps{ Description: "csi represents storage that is handled by an external CSI driver.", - Ref: ref("k8s.io/api/core/v1.CSIPersistentVolumeSource"), + Ref: ref(v1.CSIPersistentVolumeSource{}.OpenAPIModelName()), }, }, }, }, }, Dependencies: []string{ - "k8s.io/api/core/v1.AWSElasticBlockStoreVolumeSource", "k8s.io/api/core/v1.AzureDiskVolumeSource", "k8s.io/api/core/v1.AzureFilePersistentVolumeSource", "k8s.io/api/core/v1.CSIPersistentVolumeSource", "k8s.io/api/core/v1.CephFSPersistentVolumeSource", "k8s.io/api/core/v1.CinderPersistentVolumeSource", "k8s.io/api/core/v1.FCVolumeSource", "k8s.io/api/core/v1.FlexPersistentVolumeSource", "k8s.io/api/core/v1.FlockerVolumeSource", "k8s.io/api/core/v1.GCEPersistentDiskVolumeSource", "k8s.io/api/core/v1.GlusterfsPersistentVolumeSource", "k8s.io/api/core/v1.HostPathVolumeSource", "k8s.io/api/core/v1.ISCSIPersistentVolumeSource", "k8s.io/api/core/v1.LocalVolumeSource", "k8s.io/api/core/v1.NFSVolumeSource", "k8s.io/api/core/v1.PhotonPersistentDiskVolumeSource", "k8s.io/api/core/v1.PortworxVolumeSource", "k8s.io/api/core/v1.QuobyteVolumeSource", "k8s.io/api/core/v1.RBDPersistentVolumeSource", "k8s.io/api/core/v1.ScaleIOPersistentVolumeSource", "k8s.io/api/core/v1.StorageOSPersistentVolumeSource", "k8s.io/api/core/v1.VsphereVirtualDiskVolumeSource"}, + v1.AWSElasticBlockStoreVolumeSource{}.OpenAPIModelName(), v1.AzureDiskVolumeSource{}.OpenAPIModelName(), v1.AzureFilePersistentVolumeSource{}.OpenAPIModelName(), v1.CSIPersistentVolumeSource{}.OpenAPIModelName(), v1.CephFSPersistentVolumeSource{}.OpenAPIModelName(), v1.CinderPersistentVolumeSource{}.OpenAPIModelName(), v1.FCVolumeSource{}.OpenAPIModelName(), v1.FlexPersistentVolumeSource{}.OpenAPIModelName(), v1.FlockerVolumeSource{}.OpenAPIModelName(), v1.GCEPersistentDiskVolumeSource{}.OpenAPIModelName(), v1.GlusterfsPersistentVolumeSource{}.OpenAPIModelName(), v1.HostPathVolumeSource{}.OpenAPIModelName(), v1.ISCSIPersistentVolumeSource{}.OpenAPIModelName(), v1.LocalVolumeSource{}.OpenAPIModelName(), v1.NFSVolumeSource{}.OpenAPIModelName(), v1.PhotonPersistentDiskVolumeSource{}.OpenAPIModelName(), v1.PortworxVolumeSource{}.OpenAPIModelName(), v1.QuobyteVolumeSource{}.OpenAPIModelName(), v1.RBDPersistentVolumeSource{}.OpenAPIModelName(), v1.ScaleIOPersistentVolumeSource{}.OpenAPIModelName(), v1.StorageOSPersistentVolumeSource{}.OpenAPIModelName(), v1.VsphereVirtualDiskVolumeSource{}.OpenAPIModelName()}, } } @@ -11844,7 +11830,7 @@ func schema_k8sio_api_core_v1_PersistentVolumeSpec(ref common.ReferenceCallback) Allows: true, Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ - Ref: ref("k8s.io/apimachinery/pkg/api/resource.Quantity"), + Ref: ref(resource.Quantity{}.OpenAPIModelName()), }, }, }, @@ -11853,133 +11839,133 @@ func schema_k8sio_api_core_v1_PersistentVolumeSpec(ref common.ReferenceCallback) "gcePersistentDisk": { SchemaProps: spec.SchemaProps{ Description: "gcePersistentDisk represents a GCE Disk resource that is attached to a kubelet's host machine and then exposed to the pod. Provisioned by an admin. Deprecated: GCEPersistentDisk is deprecated. All operations for the in-tree gcePersistentDisk type are redirected to the pd.csi.storage.gke.io CSI driver. More info: https://kubernetes.io/docs/concepts/storage/volumes#gcepersistentdisk", - Ref: ref("k8s.io/api/core/v1.GCEPersistentDiskVolumeSource"), + Ref: ref(v1.GCEPersistentDiskVolumeSource{}.OpenAPIModelName()), }, }, "awsElasticBlockStore": { SchemaProps: spec.SchemaProps{ Description: "awsElasticBlockStore represents an AWS Disk resource that is attached to a kubelet's host machine and then exposed to the pod. Deprecated: AWSElasticBlockStore is deprecated. All operations for the in-tree awsElasticBlockStore type are redirected to the ebs.csi.aws.com CSI driver. More info: https://kubernetes.io/docs/concepts/storage/volumes#awselasticblockstore", - Ref: ref("k8s.io/api/core/v1.AWSElasticBlockStoreVolumeSource"), + Ref: ref(v1.AWSElasticBlockStoreVolumeSource{}.OpenAPIModelName()), }, }, "hostPath": { SchemaProps: spec.SchemaProps{ Description: "hostPath represents a directory on the host. Provisioned by a developer or tester. This is useful for single-node development and testing only! On-host storage is not supported in any way and WILL NOT WORK in a multi-node cluster. More info: https://kubernetes.io/docs/concepts/storage/volumes#hostpath", - Ref: ref("k8s.io/api/core/v1.HostPathVolumeSource"), + Ref: ref(v1.HostPathVolumeSource{}.OpenAPIModelName()), }, }, "glusterfs": { SchemaProps: spec.SchemaProps{ Description: "glusterfs represents a Glusterfs volume that is attached to a host and exposed to the pod. Provisioned by an admin. Deprecated: Glusterfs is deprecated and the in-tree glusterfs type is no longer supported. More info: https://examples.k8s.io/volumes/glusterfs/README.md", - Ref: ref("k8s.io/api/core/v1.GlusterfsPersistentVolumeSource"), + Ref: ref(v1.GlusterfsPersistentVolumeSource{}.OpenAPIModelName()), }, }, "nfs": { SchemaProps: spec.SchemaProps{ Description: "nfs represents an NFS mount on the host. Provisioned by an admin. More info: https://kubernetes.io/docs/concepts/storage/volumes#nfs", - Ref: ref("k8s.io/api/core/v1.NFSVolumeSource"), + Ref: ref(v1.NFSVolumeSource{}.OpenAPIModelName()), }, }, "rbd": { SchemaProps: spec.SchemaProps{ Description: "rbd represents a Rados Block Device mount on the host that shares a pod's lifetime. Deprecated: RBD is deprecated and the in-tree rbd type is no longer supported. More info: https://examples.k8s.io/volumes/rbd/README.md", - Ref: ref("k8s.io/api/core/v1.RBDPersistentVolumeSource"), + Ref: ref(v1.RBDPersistentVolumeSource{}.OpenAPIModelName()), }, }, "iscsi": { SchemaProps: spec.SchemaProps{ Description: "iscsi represents an ISCSI Disk resource that is attached to a kubelet's host machine and then exposed to the pod. Provisioned by an admin.", - Ref: ref("k8s.io/api/core/v1.ISCSIPersistentVolumeSource"), + Ref: ref(v1.ISCSIPersistentVolumeSource{}.OpenAPIModelName()), }, }, "cinder": { SchemaProps: spec.SchemaProps{ Description: "cinder represents a cinder volume attached and mounted on kubelets host machine. Deprecated: Cinder is deprecated. All operations for the in-tree cinder type are redirected to the cinder.csi.openstack.org CSI driver. More info: https://examples.k8s.io/mysql-cinder-pd/README.md", - Ref: ref("k8s.io/api/core/v1.CinderPersistentVolumeSource"), + Ref: ref(v1.CinderPersistentVolumeSource{}.OpenAPIModelName()), }, }, "cephfs": { SchemaProps: spec.SchemaProps{ Description: "cephFS represents a Ceph FS mount on the host that shares a pod's lifetime. Deprecated: CephFS is deprecated and the in-tree cephfs type is no longer supported.", - Ref: ref("k8s.io/api/core/v1.CephFSPersistentVolumeSource"), + Ref: ref(v1.CephFSPersistentVolumeSource{}.OpenAPIModelName()), }, }, "fc": { SchemaProps: spec.SchemaProps{ Description: "fc represents a Fibre Channel resource that is attached to a kubelet's host machine and then exposed to the pod.", - Ref: ref("k8s.io/api/core/v1.FCVolumeSource"), + Ref: ref(v1.FCVolumeSource{}.OpenAPIModelName()), }, }, "flocker": { SchemaProps: spec.SchemaProps{ Description: "flocker represents a Flocker volume attached to a kubelet's host machine and exposed to the pod for its usage. This depends on the Flocker control service being running. Deprecated: Flocker is deprecated and the in-tree flocker type is no longer supported.", - Ref: ref("k8s.io/api/core/v1.FlockerVolumeSource"), + Ref: ref(v1.FlockerVolumeSource{}.OpenAPIModelName()), }, }, "flexVolume": { SchemaProps: spec.SchemaProps{ Description: "flexVolume represents a generic volume resource that is provisioned/attached using an exec based plugin. Deprecated: FlexVolume is deprecated. Consider using a CSIDriver instead.", - Ref: ref("k8s.io/api/core/v1.FlexPersistentVolumeSource"), + Ref: ref(v1.FlexPersistentVolumeSource{}.OpenAPIModelName()), }, }, "azureFile": { SchemaProps: spec.SchemaProps{ Description: "azureFile represents an Azure File Service mount on the host and bind mount to the pod. Deprecated: AzureFile is deprecated. All operations for the in-tree azureFile type are redirected to the file.csi.azure.com CSI driver.", - Ref: ref("k8s.io/api/core/v1.AzureFilePersistentVolumeSource"), + Ref: ref(v1.AzureFilePersistentVolumeSource{}.OpenAPIModelName()), }, }, "vsphereVolume": { SchemaProps: spec.SchemaProps{ Description: "vsphereVolume represents a vSphere volume attached and mounted on kubelets host machine. Deprecated: VsphereVolume is deprecated. All operations for the in-tree vsphereVolume type are redirected to the csi.vsphere.vmware.com CSI driver.", - Ref: ref("k8s.io/api/core/v1.VsphereVirtualDiskVolumeSource"), + Ref: ref(v1.VsphereVirtualDiskVolumeSource{}.OpenAPIModelName()), }, }, "quobyte": { SchemaProps: spec.SchemaProps{ Description: "quobyte represents a Quobyte mount on the host that shares a pod's lifetime. Deprecated: Quobyte is deprecated and the in-tree quobyte type is no longer supported.", - Ref: ref("k8s.io/api/core/v1.QuobyteVolumeSource"), + Ref: ref(v1.QuobyteVolumeSource{}.OpenAPIModelName()), }, }, "azureDisk": { SchemaProps: spec.SchemaProps{ Description: "azureDisk represents an Azure Data Disk mount on the host and bind mount to the pod. Deprecated: AzureDisk is deprecated. All operations for the in-tree azureDisk type are redirected to the disk.csi.azure.com CSI driver.", - Ref: ref("k8s.io/api/core/v1.AzureDiskVolumeSource"), + Ref: ref(v1.AzureDiskVolumeSource{}.OpenAPIModelName()), }, }, "photonPersistentDisk": { SchemaProps: spec.SchemaProps{ Description: "photonPersistentDisk represents a PhotonController persistent disk attached and mounted on kubelets host machine. Deprecated: PhotonPersistentDisk is deprecated and the in-tree photonPersistentDisk type is no longer supported.", - Ref: ref("k8s.io/api/core/v1.PhotonPersistentDiskVolumeSource"), + Ref: ref(v1.PhotonPersistentDiskVolumeSource{}.OpenAPIModelName()), }, }, "portworxVolume": { SchemaProps: spec.SchemaProps{ Description: "portworxVolume represents a portworx volume attached and mounted on kubelets host machine. Deprecated: PortworxVolume is deprecated. All operations for the in-tree portworxVolume type are redirected to the pxd.portworx.com CSI driver when the CSIMigrationPortworx feature-gate is on.", - Ref: ref("k8s.io/api/core/v1.PortworxVolumeSource"), + Ref: ref(v1.PortworxVolumeSource{}.OpenAPIModelName()), }, }, "scaleIO": { SchemaProps: spec.SchemaProps{ Description: "scaleIO represents a ScaleIO persistent volume attached and mounted on Kubernetes nodes. Deprecated: ScaleIO is deprecated and the in-tree scaleIO type is no longer supported.", - Ref: ref("k8s.io/api/core/v1.ScaleIOPersistentVolumeSource"), + Ref: ref(v1.ScaleIOPersistentVolumeSource{}.OpenAPIModelName()), }, }, "local": { SchemaProps: spec.SchemaProps{ Description: "local represents directly-attached storage with node affinity", - Ref: ref("k8s.io/api/core/v1.LocalVolumeSource"), + Ref: ref(v1.LocalVolumeSource{}.OpenAPIModelName()), }, }, "storageos": { SchemaProps: spec.SchemaProps{ Description: "storageOS represents a StorageOS volume that is attached to the kubelet's host machine and mounted into the pod. Deprecated: StorageOS is deprecated and the in-tree storageos type is no longer supported. More info: https://examples.k8s.io/volumes/storageos/README.md", - Ref: ref("k8s.io/api/core/v1.StorageOSPersistentVolumeSource"), + Ref: ref(v1.StorageOSPersistentVolumeSource{}.OpenAPIModelName()), }, }, "csi": { SchemaProps: spec.SchemaProps{ Description: "csi represents storage that is handled by an external CSI driver.", - Ref: ref("k8s.io/api/core/v1.CSIPersistentVolumeSource"), + Ref: ref(v1.CSIPersistentVolumeSource{}.OpenAPIModelName()), }, }, "accessModes": { @@ -12011,7 +11997,7 @@ func schema_k8sio_api_core_v1_PersistentVolumeSpec(ref common.ReferenceCallback) }, SchemaProps: spec.SchemaProps{ Description: "claimRef is part of a bi-directional binding between PersistentVolume and PersistentVolumeClaim. Expected to be non-nil when bound. claim.VolumeName is the authoritative bind between PV and PVC. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#binding", - Ref: ref("k8s.io/api/core/v1.ObjectReference"), + Ref: ref(v1.ObjectReference{}.OpenAPIModelName()), }, }, "persistentVolumeReclaimPolicy": { @@ -12060,7 +12046,7 @@ func schema_k8sio_api_core_v1_PersistentVolumeSpec(ref common.ReferenceCallback) "nodeAffinity": { SchemaProps: spec.SchemaProps{ Description: "nodeAffinity defines constraints that limit what nodes this volume can be accessed from. This field influences the scheduling of pods that use this volume. This field is mutable if MutablePVNodeAffinity feature gate is enabled.", - Ref: ref("k8s.io/api/core/v1.VolumeNodeAffinity"), + Ref: ref(v1.VolumeNodeAffinity{}.OpenAPIModelName()), }, }, "volumeAttributesClassName": { @@ -12074,7 +12060,7 @@ func schema_k8sio_api_core_v1_PersistentVolumeSpec(ref common.ReferenceCallback) }, }, Dependencies: []string{ - "k8s.io/api/core/v1.AWSElasticBlockStoreVolumeSource", "k8s.io/api/core/v1.AzureDiskVolumeSource", "k8s.io/api/core/v1.AzureFilePersistentVolumeSource", "k8s.io/api/core/v1.CSIPersistentVolumeSource", "k8s.io/api/core/v1.CephFSPersistentVolumeSource", "k8s.io/api/core/v1.CinderPersistentVolumeSource", "k8s.io/api/core/v1.FCVolumeSource", "k8s.io/api/core/v1.FlexPersistentVolumeSource", "k8s.io/api/core/v1.FlockerVolumeSource", "k8s.io/api/core/v1.GCEPersistentDiskVolumeSource", "k8s.io/api/core/v1.GlusterfsPersistentVolumeSource", "k8s.io/api/core/v1.HostPathVolumeSource", "k8s.io/api/core/v1.ISCSIPersistentVolumeSource", "k8s.io/api/core/v1.LocalVolumeSource", "k8s.io/api/core/v1.NFSVolumeSource", "k8s.io/api/core/v1.ObjectReference", "k8s.io/api/core/v1.PhotonPersistentDiskVolumeSource", "k8s.io/api/core/v1.PortworxVolumeSource", "k8s.io/api/core/v1.QuobyteVolumeSource", "k8s.io/api/core/v1.RBDPersistentVolumeSource", "k8s.io/api/core/v1.ScaleIOPersistentVolumeSource", "k8s.io/api/core/v1.StorageOSPersistentVolumeSource", "k8s.io/api/core/v1.VolumeNodeAffinity", "k8s.io/api/core/v1.VsphereVirtualDiskVolumeSource", "k8s.io/apimachinery/pkg/api/resource.Quantity"}, + v1.AWSElasticBlockStoreVolumeSource{}.OpenAPIModelName(), v1.AzureDiskVolumeSource{}.OpenAPIModelName(), v1.AzureFilePersistentVolumeSource{}.OpenAPIModelName(), v1.CSIPersistentVolumeSource{}.OpenAPIModelName(), v1.CephFSPersistentVolumeSource{}.OpenAPIModelName(), v1.CinderPersistentVolumeSource{}.OpenAPIModelName(), v1.FCVolumeSource{}.OpenAPIModelName(), v1.FlexPersistentVolumeSource{}.OpenAPIModelName(), v1.FlockerVolumeSource{}.OpenAPIModelName(), v1.GCEPersistentDiskVolumeSource{}.OpenAPIModelName(), v1.GlusterfsPersistentVolumeSource{}.OpenAPIModelName(), v1.HostPathVolumeSource{}.OpenAPIModelName(), v1.ISCSIPersistentVolumeSource{}.OpenAPIModelName(), v1.LocalVolumeSource{}.OpenAPIModelName(), v1.NFSVolumeSource{}.OpenAPIModelName(), v1.ObjectReference{}.OpenAPIModelName(), v1.PhotonPersistentDiskVolumeSource{}.OpenAPIModelName(), v1.PortworxVolumeSource{}.OpenAPIModelName(), v1.QuobyteVolumeSource{}.OpenAPIModelName(), v1.RBDPersistentVolumeSource{}.OpenAPIModelName(), v1.ScaleIOPersistentVolumeSource{}.OpenAPIModelName(), v1.StorageOSPersistentVolumeSource{}.OpenAPIModelName(), v1.VolumeNodeAffinity{}.OpenAPIModelName(), v1.VsphereVirtualDiskVolumeSource{}.OpenAPIModelName(), resource.Quantity{}.OpenAPIModelName()}, } } @@ -12110,14 +12096,14 @@ func schema_k8sio_api_core_v1_PersistentVolumeStatus(ref common.ReferenceCallbac "lastPhaseTransitionTime": { SchemaProps: spec.SchemaProps{ Description: "lastPhaseTransitionTime is the time the phase transitioned from one to another and automatically resets to current time everytime a volume phase transitions.", - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.Time"), + Ref: ref(metav1.Time{}.OpenAPIModelName()), }, }, }, }, }, Dependencies: []string{ - "k8s.io/apimachinery/pkg/apis/meta/v1.Time"}, + metav1.Time{}.OpenAPIModelName()}, } } @@ -12175,28 +12161,28 @@ func schema_k8sio_api_core_v1_Pod(ref common.ReferenceCallback) common.OpenAPIDe SchemaProps: spec.SchemaProps{ Description: "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata", Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"), + Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), }, }, "spec": { SchemaProps: spec.SchemaProps{ Description: "Specification of the desired behavior of the pod. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status", Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.PodSpec"), + Ref: ref(v1.PodSpec{}.OpenAPIModelName()), }, }, "status": { SchemaProps: spec.SchemaProps{ Description: "Most recently observed status of the pod. This data may not be up to date. Populated by the system. Read-only. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status", Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.PodStatus"), + Ref: ref(v1.PodStatus{}.OpenAPIModelName()), }, }, }, }, }, Dependencies: []string{ - "k8s.io/api/core/v1.PodSpec", "k8s.io/api/core/v1.PodStatus", "k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"}, + v1.PodSpec{}.OpenAPIModelName(), v1.PodStatus{}.OpenAPIModelName(), metav1.ObjectMeta{}.OpenAPIModelName()}, } } @@ -12220,7 +12206,7 @@ func schema_k8sio_api_core_v1_PodAffinity(ref common.ReferenceCallback) common.O Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.PodAffinityTerm"), + Ref: ref(v1.PodAffinityTerm{}.OpenAPIModelName()), }, }, }, @@ -12239,7 +12225,7 @@ func schema_k8sio_api_core_v1_PodAffinity(ref common.ReferenceCallback) common.O Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.WeightedPodAffinityTerm"), + Ref: ref(v1.WeightedPodAffinityTerm{}.OpenAPIModelName()), }, }, }, @@ -12249,7 +12235,7 @@ func schema_k8sio_api_core_v1_PodAffinity(ref common.ReferenceCallback) common.O }, }, Dependencies: []string{ - "k8s.io/api/core/v1.PodAffinityTerm", "k8s.io/api/core/v1.WeightedPodAffinityTerm"}, + v1.PodAffinityTerm{}.OpenAPIModelName(), v1.WeightedPodAffinityTerm{}.OpenAPIModelName()}, } } @@ -12263,7 +12249,7 @@ func schema_k8sio_api_core_v1_PodAffinityTerm(ref common.ReferenceCallback) comm "labelSelector": { SchemaProps: spec.SchemaProps{ Description: "A label query over a set of resources, in this case pods. If it's null, this PodAffinityTerm matches with no Pods.", - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.LabelSelector"), + Ref: ref(metav1.LabelSelector{}.OpenAPIModelName()), }, }, "namespaces": { @@ -12297,7 +12283,7 @@ func schema_k8sio_api_core_v1_PodAffinityTerm(ref common.ReferenceCallback) comm "namespaceSelector": { SchemaProps: spec.SchemaProps{ Description: "A label query over the set of namespaces that the term applies to. The term is applied to the union of the namespaces selected by this field and the ones listed in the namespaces field. null selector and null or empty namespaces list means \"this pod's namespace\". An empty selector ({}) matches all namespaces.", - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.LabelSelector"), + Ref: ref(metav1.LabelSelector{}.OpenAPIModelName()), }, }, "matchLabelKeys": { @@ -12345,7 +12331,7 @@ func schema_k8sio_api_core_v1_PodAffinityTerm(ref common.ReferenceCallback) comm }, }, Dependencies: []string{ - "k8s.io/apimachinery/pkg/apis/meta/v1.LabelSelector"}, + metav1.LabelSelector{}.OpenAPIModelName()}, } } @@ -12369,7 +12355,7 @@ func schema_k8sio_api_core_v1_PodAntiAffinity(ref common.ReferenceCallback) comm Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.PodAffinityTerm"), + Ref: ref(v1.PodAffinityTerm{}.OpenAPIModelName()), }, }, }, @@ -12388,7 +12374,7 @@ func schema_k8sio_api_core_v1_PodAntiAffinity(ref common.ReferenceCallback) comm Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.WeightedPodAffinityTerm"), + Ref: ref(v1.WeightedPodAffinityTerm{}.OpenAPIModelName()), }, }, }, @@ -12398,7 +12384,7 @@ func schema_k8sio_api_core_v1_PodAntiAffinity(ref common.ReferenceCallback) comm }, }, Dependencies: []string{ - "k8s.io/api/core/v1.PodAffinityTerm", "k8s.io/api/core/v1.WeightedPodAffinityTerm"}, + v1.PodAffinityTerm{}.OpenAPIModelName(), v1.WeightedPodAffinityTerm{}.OpenAPIModelName()}, } } @@ -12569,13 +12555,13 @@ func schema_k8sio_api_core_v1_PodCondition(ref common.ReferenceCallback) common. "lastProbeTime": { SchemaProps: spec.SchemaProps{ Description: "Last time we probed the condition.", - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.Time"), + Ref: ref(metav1.Time{}.OpenAPIModelName()), }, }, "lastTransitionTime": { SchemaProps: spec.SchemaProps{ Description: "Last time the condition transitioned from one status to another.", - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.Time"), + Ref: ref(metav1.Time{}.OpenAPIModelName()), }, }, "reason": { @@ -12597,7 +12583,7 @@ func schema_k8sio_api_core_v1_PodCondition(ref common.ReferenceCallback) common. }, }, Dependencies: []string{ - "k8s.io/apimachinery/pkg/apis/meta/v1.Time"}, + metav1.Time{}.OpenAPIModelName()}, } } @@ -12661,7 +12647,7 @@ func schema_k8sio_api_core_v1_PodDNSConfig(ref common.ReferenceCallback) common. Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.PodDNSConfigOption"), + Ref: ref(v1.PodDNSConfigOption{}.OpenAPIModelName()), }, }, }, @@ -12671,7 +12657,7 @@ func schema_k8sio_api_core_v1_PodDNSConfig(ref common.ReferenceCallback) common. }, }, Dependencies: []string{ - "k8s.io/api/core/v1.PodDNSConfigOption"}, + v1.PodDNSConfigOption{}.OpenAPIModelName()}, } } @@ -12805,7 +12791,7 @@ func schema_k8sio_api_core_v1_PodExtendedResourceClaimStatus(ref common.Referenc Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.ContainerExtendedResourceRequest"), + Ref: ref(v1.ContainerExtendedResourceRequest{}.OpenAPIModelName()), }, }, }, @@ -12824,7 +12810,7 @@ func schema_k8sio_api_core_v1_PodExtendedResourceClaimStatus(ref common.Referenc }, }, Dependencies: []string{ - "k8s.io/api/core/v1.ContainerExtendedResourceRequest"}, + v1.ContainerExtendedResourceRequest{}.OpenAPIModelName()}, } } @@ -12875,7 +12861,7 @@ func schema_k8sio_api_core_v1_PodList(ref common.ReferenceCallback) common.OpenA SchemaProps: spec.SchemaProps{ Description: "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"), + Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), }, }, "items": { @@ -12886,7 +12872,7 @@ func schema_k8sio_api_core_v1_PodList(ref common.ReferenceCallback) common.OpenA Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.Pod"), + Ref: ref(v1.Pod{}.OpenAPIModelName()), }, }, }, @@ -12897,7 +12883,7 @@ func schema_k8sio_api_core_v1_PodList(ref common.ReferenceCallback) common.OpenA }, }, Dependencies: []string{ - "k8s.io/api/core/v1.Pod", "k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"}, + v1.Pod{}.OpenAPIModelName(), metav1.ListMeta{}.OpenAPIModelName()}, } } @@ -12953,7 +12939,7 @@ func schema_k8sio_api_core_v1_PodLogOptions(ref common.ReferenceCallback) common "sinceTime": { SchemaProps: spec.SchemaProps{ Description: "An RFC3339 timestamp from which to show logs. If this value precedes the time a pod was started, only logs since the pod start will be returned. If this value is in the future, no logs will be returned. Only one of sinceSeconds or sinceTime may be specified.", - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.Time"), + Ref: ref(metav1.Time{}.OpenAPIModelName()), }, }, "timestamps": { @@ -12995,7 +12981,7 @@ func schema_k8sio_api_core_v1_PodLogOptions(ref common.ReferenceCallback) common }, }, Dependencies: []string{ - "k8s.io/apimachinery/pkg/apis/meta/v1.Time"}, + metav1.Time{}.OpenAPIModelName()}, } } @@ -13221,13 +13207,13 @@ func schema_k8sio_api_core_v1_PodSecurityContext(ref common.ReferenceCallback) c "seLinuxOptions": { SchemaProps: spec.SchemaProps{ Description: "The SELinux context to be applied to all containers. If unspecified, the container runtime will allocate a random SELinux context for each container. May also be set in SecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence for that container. Note that this field cannot be set when spec.os.name is windows.", - Ref: ref("k8s.io/api/core/v1.SELinuxOptions"), + Ref: ref(v1.SELinuxOptions{}.OpenAPIModelName()), }, }, "windowsOptions": { SchemaProps: spec.SchemaProps{ Description: "The Windows specific settings applied to all containers. If unspecified, the options within a container's SecurityContext will be used. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence. Note that this field cannot be set when spec.os.name is linux.", - Ref: ref("k8s.io/api/core/v1.WindowsSecurityContextOptions"), + Ref: ref(v1.WindowsSecurityContextOptions{}.OpenAPIModelName()), }, }, "runAsUser": { @@ -13299,7 +13285,7 @@ func schema_k8sio_api_core_v1_PodSecurityContext(ref common.ReferenceCallback) c Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.Sysctl"), + Ref: ref(v1.Sysctl{}.OpenAPIModelName()), }, }, }, @@ -13316,13 +13302,13 @@ func schema_k8sio_api_core_v1_PodSecurityContext(ref common.ReferenceCallback) c "seccompProfile": { SchemaProps: spec.SchemaProps{ Description: "The seccomp options to use by the containers in this pod. Note that this field cannot be set when spec.os.name is windows.", - Ref: ref("k8s.io/api/core/v1.SeccompProfile"), + Ref: ref(v1.SeccompProfile{}.OpenAPIModelName()), }, }, "appArmorProfile": { SchemaProps: spec.SchemaProps{ Description: "appArmorProfile is the AppArmor options to use by the containers in this pod. Note that this field cannot be set when spec.os.name is windows.", - Ref: ref("k8s.io/api/core/v1.AppArmorProfile"), + Ref: ref(v1.AppArmorProfile{}.OpenAPIModelName()), }, }, "seLinuxChangePolicy": { @@ -13336,7 +13322,7 @@ func schema_k8sio_api_core_v1_PodSecurityContext(ref common.ReferenceCallback) c }, }, Dependencies: []string{ - "k8s.io/api/core/v1.AppArmorProfile", "k8s.io/api/core/v1.SELinuxOptions", "k8s.io/api/core/v1.SeccompProfile", "k8s.io/api/core/v1.Sysctl", "k8s.io/api/core/v1.WindowsSecurityContextOptions"}, + v1.AppArmorProfile{}.OpenAPIModelName(), v1.SELinuxOptions{}.OpenAPIModelName(), v1.SeccompProfile{}.OpenAPIModelName(), v1.Sysctl{}.OpenAPIModelName(), v1.WindowsSecurityContextOptions{}.OpenAPIModelName()}, } } @@ -13350,14 +13336,14 @@ func schema_k8sio_api_core_v1_PodSignature(ref common.ReferenceCallback) common. "podController": { SchemaProps: spec.SchemaProps{ Description: "Reference to controller whose pods should avoid this node.", - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.OwnerReference"), + Ref: ref(metav1.OwnerReference{}.OpenAPIModelName()), }, }, }, }, }, Dependencies: []string{ - "k8s.io/apimachinery/pkg/apis/meta/v1.OwnerReference"}, + metav1.OwnerReference{}.OpenAPIModelName()}, } } @@ -13386,7 +13372,7 @@ func schema_k8sio_api_core_v1_PodSpec(ref common.ReferenceCallback) common.OpenA Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.Volume"), + Ref: ref(v1.Volume{}.OpenAPIModelName()), }, }, }, @@ -13410,7 +13396,7 @@ func schema_k8sio_api_core_v1_PodSpec(ref common.ReferenceCallback) common.OpenA Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.Container"), + Ref: ref(v1.Container{}.OpenAPIModelName()), }, }, }, @@ -13434,7 +13420,7 @@ func schema_k8sio_api_core_v1_PodSpec(ref common.ReferenceCallback) common.OpenA Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.Container"), + Ref: ref(v1.Container{}.OpenAPIModelName()), }, }, }, @@ -13458,7 +13444,7 @@ func schema_k8sio_api_core_v1_PodSpec(ref common.ReferenceCallback) common.OpenA Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.EphemeralContainer"), + Ref: ref(v1.EphemeralContainer{}.OpenAPIModelName()), }, }, }, @@ -13574,7 +13560,7 @@ func schema_k8sio_api_core_v1_PodSpec(ref common.ReferenceCallback) common.OpenA "securityContext": { SchemaProps: spec.SchemaProps{ Description: "SecurityContext holds pod-level security attributes and common container settings. Optional: Defaults to empty. See type description for default values of each field.", - Ref: ref("k8s.io/api/core/v1.PodSecurityContext"), + Ref: ref(v1.PodSecurityContext{}.OpenAPIModelName()), }, }, "imagePullSecrets": { @@ -13595,7 +13581,7 @@ func schema_k8sio_api_core_v1_PodSpec(ref common.ReferenceCallback) common.OpenA Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.LocalObjectReference"), + Ref: ref(v1.LocalObjectReference{}.OpenAPIModelName()), }, }, }, @@ -13618,7 +13604,7 @@ func schema_k8sio_api_core_v1_PodSpec(ref common.ReferenceCallback) common.OpenA "affinity": { SchemaProps: spec.SchemaProps{ Description: "If specified, the pod's scheduling constraints", - Ref: ref("k8s.io/api/core/v1.Affinity"), + Ref: ref(v1.Affinity{}.OpenAPIModelName()), }, }, "schedulerName": { @@ -13641,7 +13627,7 @@ func schema_k8sio_api_core_v1_PodSpec(ref common.ReferenceCallback) common.OpenA Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.Toleration"), + Ref: ref(v1.Toleration{}.OpenAPIModelName()), }, }, }, @@ -13665,7 +13651,7 @@ func schema_k8sio_api_core_v1_PodSpec(ref common.ReferenceCallback) common.OpenA Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.HostAlias"), + Ref: ref(v1.HostAlias{}.OpenAPIModelName()), }, }, }, @@ -13688,7 +13674,7 @@ func schema_k8sio_api_core_v1_PodSpec(ref common.ReferenceCallback) common.OpenA "dnsConfig": { SchemaProps: spec.SchemaProps{ Description: "Specifies the DNS parameters of a pod. Parameters specified here will be merged to the generated DNS configuration based on DNSPolicy.", - Ref: ref("k8s.io/api/core/v1.PodDNSConfig"), + Ref: ref(v1.PodDNSConfig{}.OpenAPIModelName()), }, }, "readinessGates": { @@ -13704,7 +13690,7 @@ func schema_k8sio_api_core_v1_PodSpec(ref common.ReferenceCallback) common.OpenA Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.PodReadinessGate"), + Ref: ref(v1.PodReadinessGate{}.OpenAPIModelName()), }, }, }, @@ -13740,7 +13726,7 @@ func schema_k8sio_api_core_v1_PodSpec(ref common.ReferenceCallback) common.OpenA Allows: true, Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ - Ref: ref("k8s.io/apimachinery/pkg/api/resource.Quantity"), + Ref: ref(resource.Quantity{}.OpenAPIModelName()), }, }, }, @@ -13765,7 +13751,7 @@ func schema_k8sio_api_core_v1_PodSpec(ref common.ReferenceCallback) common.OpenA Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.TopologySpreadConstraint"), + Ref: ref(v1.TopologySpreadConstraint{}.OpenAPIModelName()), }, }, }, @@ -13781,7 +13767,7 @@ func schema_k8sio_api_core_v1_PodSpec(ref common.ReferenceCallback) common.OpenA "os": { SchemaProps: spec.SchemaProps{ Description: "Specifies the OS of the containers in the pod. Some pod and container fields are restricted if this is set.\n\nIf the OS field is set to linux, the following fields must be unset: -securityContext.windowsOptions\n\nIf the OS field is set to windows, following fields must be unset: - spec.hostPID - spec.hostIPC - spec.hostUsers - spec.resources - spec.securityContext.appArmorProfile - spec.securityContext.seLinuxOptions - spec.securityContext.seccompProfile - spec.securityContext.fsGroup - spec.securityContext.fsGroupChangePolicy - spec.securityContext.sysctls - spec.shareProcessNamespace - spec.securityContext.runAsUser - spec.securityContext.runAsGroup - spec.securityContext.supplementalGroups - spec.securityContext.supplementalGroupsPolicy - spec.containers[*].securityContext.appArmorProfile - spec.containers[*].securityContext.seLinuxOptions - spec.containers[*].securityContext.seccompProfile - spec.containers[*].securityContext.capabilities - spec.containers[*].securityContext.readOnlyRootFilesystem - spec.containers[*].securityContext.privileged - spec.containers[*].securityContext.allowPrivilegeEscalation - spec.containers[*].securityContext.procMount - spec.containers[*].securityContext.runAsUser - spec.containers[*].securityContext.runAsGroup", - Ref: ref("k8s.io/api/core/v1.PodOS"), + Ref: ref(v1.PodOS{}.OpenAPIModelName()), }, }, "hostUsers": { @@ -13809,7 +13795,7 @@ func schema_k8sio_api_core_v1_PodSpec(ref common.ReferenceCallback) common.OpenA Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.PodSchedulingGate"), + Ref: ref(v1.PodSchedulingGate{}.OpenAPIModelName()), }, }, }, @@ -13833,7 +13819,7 @@ func schema_k8sio_api_core_v1_PodSpec(ref common.ReferenceCallback) common.OpenA Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.PodResourceClaim"), + Ref: ref(v1.PodResourceClaim{}.OpenAPIModelName()), }, }, }, @@ -13842,7 +13828,7 @@ func schema_k8sio_api_core_v1_PodSpec(ref common.ReferenceCallback) common.OpenA "resources": { SchemaProps: spec.SchemaProps{ Description: "Resources is the total amount of CPU and Memory resources required by all containers in the pod. It supports specifying Requests and Limits for \"cpu\", \"memory\" and \"hugepages-\" resource names only. ResourceClaims are not supported.\n\nThis field enables fine-grained control over resource allocation for the entire pod, allowing resource sharing among containers in a pod.\n\nThis is an alpha field and requires enabling the PodLevelResources feature gate.", - Ref: ref("k8s.io/api/core/v1.ResourceRequirements"), + Ref: ref(v1.ResourceRequirements{}.OpenAPIModelName()), }, }, "hostnameOverride": { @@ -13855,7 +13841,7 @@ func schema_k8sio_api_core_v1_PodSpec(ref common.ReferenceCallback) common.OpenA "workloadRef": { SchemaProps: spec.SchemaProps{ Description: "WorkloadRef provides a reference to the Workload object that this Pod belongs to. This field is used by the scheduler to identify the PodGroup and apply the correct group scheduling policies. The Workload object referenced by this field may not exist at the time the Pod is created. This field is immutable, but a Workload object with the same name may be recreated with different policies. Doing this during pod scheduling may result in the placement not conforming to the expected policies.", - Ref: ref("k8s.io/api/core/v1.WorkloadReference"), + Ref: ref(v1.WorkloadReference{}.OpenAPIModelName()), }, }, }, @@ -13863,7 +13849,7 @@ func schema_k8sio_api_core_v1_PodSpec(ref common.ReferenceCallback) common.OpenA }, }, Dependencies: []string{ - "k8s.io/api/core/v1.Affinity", "k8s.io/api/core/v1.Container", "k8s.io/api/core/v1.EphemeralContainer", "k8s.io/api/core/v1.HostAlias", "k8s.io/api/core/v1.LocalObjectReference", "k8s.io/api/core/v1.PodDNSConfig", "k8s.io/api/core/v1.PodOS", "k8s.io/api/core/v1.PodReadinessGate", "k8s.io/api/core/v1.PodResourceClaim", "k8s.io/api/core/v1.PodSchedulingGate", "k8s.io/api/core/v1.PodSecurityContext", "k8s.io/api/core/v1.ResourceRequirements", "k8s.io/api/core/v1.Toleration", "k8s.io/api/core/v1.TopologySpreadConstraint", "k8s.io/api/core/v1.Volume", "k8s.io/api/core/v1.WorkloadReference", "k8s.io/apimachinery/pkg/api/resource.Quantity"}, + v1.Affinity{}.OpenAPIModelName(), v1.Container{}.OpenAPIModelName(), v1.EphemeralContainer{}.OpenAPIModelName(), v1.HostAlias{}.OpenAPIModelName(), v1.LocalObjectReference{}.OpenAPIModelName(), v1.PodDNSConfig{}.OpenAPIModelName(), v1.PodOS{}.OpenAPIModelName(), v1.PodReadinessGate{}.OpenAPIModelName(), v1.PodResourceClaim{}.OpenAPIModelName(), v1.PodSchedulingGate{}.OpenAPIModelName(), v1.PodSecurityContext{}.OpenAPIModelName(), v1.ResourceRequirements{}.OpenAPIModelName(), v1.Toleration{}.OpenAPIModelName(), v1.TopologySpreadConstraint{}.OpenAPIModelName(), v1.Volume{}.OpenAPIModelName(), v1.WorkloadReference{}.OpenAPIModelName(), resource.Quantity{}.OpenAPIModelName()}, } } @@ -13907,7 +13893,7 @@ func schema_k8sio_api_core_v1_PodStatus(ref common.ReferenceCallback) common.Ope Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.PodCondition"), + Ref: ref(v1.PodCondition{}.OpenAPIModelName()), }, }, }, @@ -13956,7 +13942,7 @@ func schema_k8sio_api_core_v1_PodStatus(ref common.ReferenceCallback) common.Ope Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.HostIP"), + Ref: ref(v1.HostIP{}.OpenAPIModelName()), }, }, }, @@ -13987,7 +13973,7 @@ func schema_k8sio_api_core_v1_PodStatus(ref common.ReferenceCallback) common.Ope Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.PodIP"), + Ref: ref(v1.PodIP{}.OpenAPIModelName()), }, }, }, @@ -13996,7 +13982,7 @@ func schema_k8sio_api_core_v1_PodStatus(ref common.ReferenceCallback) common.Ope "startTime": { SchemaProps: spec.SchemaProps{ Description: "RFC 3339 date and time at which the object was acknowledged by the Kubelet. This is before the Kubelet pulled the container image(s) for the pod.", - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.Time"), + Ref: ref(metav1.Time{}.OpenAPIModelName()), }, }, "initContainerStatuses": { @@ -14012,7 +13998,7 @@ func schema_k8sio_api_core_v1_PodStatus(ref common.ReferenceCallback) common.Ope Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.ContainerStatus"), + Ref: ref(v1.ContainerStatus{}.OpenAPIModelName()), }, }, }, @@ -14031,7 +14017,7 @@ func schema_k8sio_api_core_v1_PodStatus(ref common.ReferenceCallback) common.Ope Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.ContainerStatus"), + Ref: ref(v1.ContainerStatus{}.OpenAPIModelName()), }, }, }, @@ -14058,7 +14044,7 @@ func schema_k8sio_api_core_v1_PodStatus(ref common.ReferenceCallback) common.Ope Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.ContainerStatus"), + Ref: ref(v1.ContainerStatus{}.OpenAPIModelName()), }, }, }, @@ -14089,7 +14075,7 @@ func schema_k8sio_api_core_v1_PodStatus(ref common.ReferenceCallback) common.Ope Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.PodResourceClaimStatus"), + Ref: ref(v1.PodResourceClaimStatus{}.OpenAPIModelName()), }, }, }, @@ -14098,7 +14084,7 @@ func schema_k8sio_api_core_v1_PodStatus(ref common.ReferenceCallback) common.Ope "extendedResourceClaimStatus": { SchemaProps: spec.SchemaProps{ Description: "Status of extended resource claim backed by DRA.", - Ref: ref("k8s.io/api/core/v1.PodExtendedResourceClaimStatus"), + Ref: ref(v1.PodExtendedResourceClaimStatus{}.OpenAPIModelName()), }, }, "allocatedResources": { @@ -14109,7 +14095,7 @@ func schema_k8sio_api_core_v1_PodStatus(ref common.ReferenceCallback) common.Ope Allows: true, Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ - Ref: ref("k8s.io/apimachinery/pkg/api/resource.Quantity"), + Ref: ref(resource.Quantity{}.OpenAPIModelName()), }, }, }, @@ -14118,14 +14104,14 @@ func schema_k8sio_api_core_v1_PodStatus(ref common.ReferenceCallback) common.Ope "resources": { SchemaProps: spec.SchemaProps{ Description: "Resources represents the compute resource requests and limits that have been applied at the pod level if pod-level requests or limits are set in PodSpec.Resources", - Ref: ref("k8s.io/api/core/v1.ResourceRequirements"), + Ref: ref(v1.ResourceRequirements{}.OpenAPIModelName()), }, }, }, }, }, Dependencies: []string{ - "k8s.io/api/core/v1.ContainerStatus", "k8s.io/api/core/v1.HostIP", "k8s.io/api/core/v1.PodCondition", "k8s.io/api/core/v1.PodExtendedResourceClaimStatus", "k8s.io/api/core/v1.PodIP", "k8s.io/api/core/v1.PodResourceClaimStatus", "k8s.io/api/core/v1.ResourceRequirements", "k8s.io/apimachinery/pkg/api/resource.Quantity", "k8s.io/apimachinery/pkg/apis/meta/v1.Time"}, + v1.ContainerStatus{}.OpenAPIModelName(), v1.HostIP{}.OpenAPIModelName(), v1.PodCondition{}.OpenAPIModelName(), v1.PodExtendedResourceClaimStatus{}.OpenAPIModelName(), v1.PodIP{}.OpenAPIModelName(), v1.PodResourceClaimStatus{}.OpenAPIModelName(), v1.ResourceRequirements{}.OpenAPIModelName(), resource.Quantity{}.OpenAPIModelName(), metav1.Time{}.OpenAPIModelName()}, } } @@ -14154,21 +14140,21 @@ func schema_k8sio_api_core_v1_PodStatusResult(ref common.ReferenceCallback) comm SchemaProps: spec.SchemaProps{ Description: "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata", Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"), + Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), }, }, "status": { SchemaProps: spec.SchemaProps{ Description: "Most recently observed status of the pod. This data may not be up to date. Populated by the system. Read-only. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status", Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.PodStatus"), + Ref: ref(v1.PodStatus{}.OpenAPIModelName()), }, }, }, }, }, Dependencies: []string{ - "k8s.io/api/core/v1.PodStatus", "k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"}, + v1.PodStatus{}.OpenAPIModelName(), metav1.ObjectMeta{}.OpenAPIModelName()}, } } @@ -14197,21 +14183,21 @@ func schema_k8sio_api_core_v1_PodTemplate(ref common.ReferenceCallback) common.O SchemaProps: spec.SchemaProps{ Description: "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata", Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"), + Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), }, }, "template": { SchemaProps: spec.SchemaProps{ Description: "Template defines the pods that will be created from this pod template. https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status", Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.PodTemplateSpec"), + Ref: ref(v1.PodTemplateSpec{}.OpenAPIModelName()), }, }, }, }, }, Dependencies: []string{ - "k8s.io/api/core/v1.PodTemplateSpec", "k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"}, + v1.PodTemplateSpec{}.OpenAPIModelName(), metav1.ObjectMeta{}.OpenAPIModelName()}, } } @@ -14240,7 +14226,7 @@ func schema_k8sio_api_core_v1_PodTemplateList(ref common.ReferenceCallback) comm SchemaProps: spec.SchemaProps{ Description: "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"), + Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), }, }, "items": { @@ -14251,7 +14237,7 @@ func schema_k8sio_api_core_v1_PodTemplateList(ref common.ReferenceCallback) comm Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.PodTemplate"), + Ref: ref(v1.PodTemplate{}.OpenAPIModelName()), }, }, }, @@ -14262,7 +14248,7 @@ func schema_k8sio_api_core_v1_PodTemplateList(ref common.ReferenceCallback) comm }, }, Dependencies: []string{ - "k8s.io/api/core/v1.PodTemplate", "k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"}, + v1.PodTemplate{}.OpenAPIModelName(), metav1.ListMeta{}.OpenAPIModelName()}, } } @@ -14277,21 +14263,21 @@ func schema_k8sio_api_core_v1_PodTemplateSpec(ref common.ReferenceCallback) comm SchemaProps: spec.SchemaProps{ Description: "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata", Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"), + Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), }, }, "spec": { SchemaProps: spec.SchemaProps{ Description: "Specification of the desired behavior of the pod. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status", Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.PodSpec"), + Ref: ref(v1.PodSpec{}.OpenAPIModelName()), }, }, }, }, }, Dependencies: []string{ - "k8s.io/api/core/v1.PodSpec", "k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"}, + v1.PodSpec{}.OpenAPIModelName(), metav1.ObjectMeta{}.OpenAPIModelName()}, } } @@ -14380,13 +14366,13 @@ func schema_k8sio_api_core_v1_PreferAvoidPodsEntry(ref common.ReferenceCallback) SchemaProps: spec.SchemaProps{ Description: "The class of pods.", Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.PodSignature"), + Ref: ref(v1.PodSignature{}.OpenAPIModelName()), }, }, "evictionTime": { SchemaProps: spec.SchemaProps{ Description: "Time at which this entry was added to the list.", - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.Time"), + Ref: ref(metav1.Time{}.OpenAPIModelName()), }, }, "reason": { @@ -14408,7 +14394,7 @@ func schema_k8sio_api_core_v1_PreferAvoidPodsEntry(ref common.ReferenceCallback) }, }, Dependencies: []string{ - "k8s.io/api/core/v1.PodSignature", "k8s.io/apimachinery/pkg/apis/meta/v1.Time"}, + v1.PodSignature{}.OpenAPIModelName(), metav1.Time{}.OpenAPIModelName()}, } } @@ -14431,7 +14417,7 @@ func schema_k8sio_api_core_v1_PreferredSchedulingTerm(ref common.ReferenceCallba SchemaProps: spec.SchemaProps{ Description: "A node selector term, associated with the corresponding weight.", Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.NodeSelectorTerm"), + Ref: ref(v1.NodeSelectorTerm{}.OpenAPIModelName()), }, }, }, @@ -14439,7 +14425,7 @@ func schema_k8sio_api_core_v1_PreferredSchedulingTerm(ref common.ReferenceCallba }, }, Dependencies: []string{ - "k8s.io/api/core/v1.NodeSelectorTerm"}, + v1.NodeSelectorTerm{}.OpenAPIModelName()}, } } @@ -14453,25 +14439,25 @@ func schema_k8sio_api_core_v1_Probe(ref common.ReferenceCallback) common.OpenAPI "exec": { SchemaProps: spec.SchemaProps{ Description: "Exec specifies a command to execute in the container.", - Ref: ref("k8s.io/api/core/v1.ExecAction"), + Ref: ref(v1.ExecAction{}.OpenAPIModelName()), }, }, "httpGet": { SchemaProps: spec.SchemaProps{ Description: "HTTPGet specifies an HTTP GET request to perform.", - Ref: ref("k8s.io/api/core/v1.HTTPGetAction"), + Ref: ref(v1.HTTPGetAction{}.OpenAPIModelName()), }, }, "tcpSocket": { SchemaProps: spec.SchemaProps{ Description: "TCPSocket specifies a connection to a TCP port.", - Ref: ref("k8s.io/api/core/v1.TCPSocketAction"), + Ref: ref(v1.TCPSocketAction{}.OpenAPIModelName()), }, }, "grpc": { SchemaProps: spec.SchemaProps{ Description: "GRPC specifies a GRPC HealthCheckRequest.", - Ref: ref("k8s.io/api/core/v1.GRPCAction"), + Ref: ref(v1.GRPCAction{}.OpenAPIModelName()), }, }, "initialDelaySeconds": { @@ -14520,7 +14506,7 @@ func schema_k8sio_api_core_v1_Probe(ref common.ReferenceCallback) common.OpenAPI }, }, Dependencies: []string{ - "k8s.io/api/core/v1.ExecAction", "k8s.io/api/core/v1.GRPCAction", "k8s.io/api/core/v1.HTTPGetAction", "k8s.io/api/core/v1.TCPSocketAction"}, + v1.ExecAction{}.OpenAPIModelName(), v1.GRPCAction{}.OpenAPIModelName(), v1.HTTPGetAction{}.OpenAPIModelName(), v1.TCPSocketAction{}.OpenAPIModelName()}, } } @@ -14534,32 +14520,32 @@ func schema_k8sio_api_core_v1_ProbeHandler(ref common.ReferenceCallback) common. "exec": { SchemaProps: spec.SchemaProps{ Description: "Exec specifies a command to execute in the container.", - Ref: ref("k8s.io/api/core/v1.ExecAction"), + Ref: ref(v1.ExecAction{}.OpenAPIModelName()), }, }, "httpGet": { SchemaProps: spec.SchemaProps{ Description: "HTTPGet specifies an HTTP GET request to perform.", - Ref: ref("k8s.io/api/core/v1.HTTPGetAction"), + Ref: ref(v1.HTTPGetAction{}.OpenAPIModelName()), }, }, "tcpSocket": { SchemaProps: spec.SchemaProps{ Description: "TCPSocket specifies a connection to a TCP port.", - Ref: ref("k8s.io/api/core/v1.TCPSocketAction"), + Ref: ref(v1.TCPSocketAction{}.OpenAPIModelName()), }, }, "grpc": { SchemaProps: spec.SchemaProps{ Description: "GRPC specifies a GRPC HealthCheckRequest.", - Ref: ref("k8s.io/api/core/v1.GRPCAction"), + Ref: ref(v1.GRPCAction{}.OpenAPIModelName()), }, }, }, }, }, Dependencies: []string{ - "k8s.io/api/core/v1.ExecAction", "k8s.io/api/core/v1.GRPCAction", "k8s.io/api/core/v1.HTTPGetAction", "k8s.io/api/core/v1.TCPSocketAction"}, + v1.ExecAction{}.OpenAPIModelName(), v1.GRPCAction{}.OpenAPIModelName(), v1.HTTPGetAction{}.OpenAPIModelName(), v1.TCPSocketAction{}.OpenAPIModelName()}, } } @@ -14583,7 +14569,7 @@ func schema_k8sio_api_core_v1_ProjectedVolumeSource(ref common.ReferenceCallback Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.VolumeProjection"), + Ref: ref(v1.VolumeProjection{}.OpenAPIModelName()), }, }, }, @@ -14600,7 +14586,7 @@ func schema_k8sio_api_core_v1_ProjectedVolumeSource(ref common.ReferenceCallback }, }, Dependencies: []string{ - "k8s.io/api/core/v1.VolumeProjection"}, + v1.VolumeProjection{}.OpenAPIModelName()}, } } @@ -14731,7 +14717,7 @@ func schema_k8sio_api_core_v1_RBDPersistentVolumeSource(ref common.ReferenceCall "secretRef": { SchemaProps: spec.SchemaProps{ Description: "secretRef is name of the authentication secret for RBDUser. If provided overrides keyring. Default is nil. More info: https://examples.k8s.io/volumes/rbd/README.md#how-to-use-it", - Ref: ref("k8s.io/api/core/v1.SecretReference"), + Ref: ref(v1.SecretReference{}.OpenAPIModelName()), }, }, "readOnly": { @@ -14746,7 +14732,7 @@ func schema_k8sio_api_core_v1_RBDPersistentVolumeSource(ref common.ReferenceCall }, }, Dependencies: []string{ - "k8s.io/api/core/v1.SecretReference"}, + v1.SecretReference{}.OpenAPIModelName()}, } } @@ -14819,7 +14805,7 @@ func schema_k8sio_api_core_v1_RBDVolumeSource(ref common.ReferenceCallback) comm "secretRef": { SchemaProps: spec.SchemaProps{ Description: "secretRef is name of the authentication secret for RBDUser. If provided overrides keyring. Default is nil. More info: https://examples.k8s.io/volumes/rbd/README.md#how-to-use-it", - Ref: ref("k8s.io/api/core/v1.LocalObjectReference"), + Ref: ref(v1.LocalObjectReference{}.OpenAPIModelName()), }, }, "readOnly": { @@ -14834,7 +14820,7 @@ func schema_k8sio_api_core_v1_RBDVolumeSource(ref common.ReferenceCallback) comm }, }, Dependencies: []string{ - "k8s.io/api/core/v1.LocalObjectReference"}, + v1.LocalObjectReference{}.OpenAPIModelName()}, } } @@ -14863,7 +14849,7 @@ func schema_k8sio_api_core_v1_RangeAllocation(ref common.ReferenceCallback) comm SchemaProps: spec.SchemaProps{ Description: "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata", Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"), + Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), }, }, "range": { @@ -14886,7 +14872,7 @@ func schema_k8sio_api_core_v1_RangeAllocation(ref common.ReferenceCallback) comm }, }, Dependencies: []string{ - "k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"}, + metav1.ObjectMeta{}.OpenAPIModelName()}, } } @@ -14915,28 +14901,28 @@ func schema_k8sio_api_core_v1_ReplicationController(ref common.ReferenceCallback SchemaProps: spec.SchemaProps{ Description: "If the Labels of a ReplicationController are empty, they are defaulted to be the same as the Pod(s) that the replication controller manages. Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata", Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"), + Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), }, }, "spec": { SchemaProps: spec.SchemaProps{ Description: "Spec defines the specification of the desired behavior of the replication controller. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status", Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.ReplicationControllerSpec"), + Ref: ref(v1.ReplicationControllerSpec{}.OpenAPIModelName()), }, }, "status": { SchemaProps: spec.SchemaProps{ Description: "Status is the most recently observed status of the replication controller. This data may be out of date by some window of time. Populated by the system. Read-only. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status", Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.ReplicationControllerStatus"), + Ref: ref(v1.ReplicationControllerStatus{}.OpenAPIModelName()), }, }, }, }, }, Dependencies: []string{ - "k8s.io/api/core/v1.ReplicationControllerSpec", "k8s.io/api/core/v1.ReplicationControllerStatus", "k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"}, + v1.ReplicationControllerSpec{}.OpenAPIModelName(), v1.ReplicationControllerStatus{}.OpenAPIModelName(), metav1.ObjectMeta{}.OpenAPIModelName()}, } } @@ -14966,7 +14952,7 @@ func schema_k8sio_api_core_v1_ReplicationControllerCondition(ref common.Referenc "lastTransitionTime": { SchemaProps: spec.SchemaProps{ Description: "The last time the condition transitioned from one status to another.", - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.Time"), + Ref: ref(metav1.Time{}.OpenAPIModelName()), }, }, "reason": { @@ -14988,7 +14974,7 @@ func schema_k8sio_api_core_v1_ReplicationControllerCondition(ref common.Referenc }, }, Dependencies: []string{ - "k8s.io/apimachinery/pkg/apis/meta/v1.Time"}, + metav1.Time{}.OpenAPIModelName()}, } } @@ -15017,7 +15003,7 @@ func schema_k8sio_api_core_v1_ReplicationControllerList(ref common.ReferenceCall SchemaProps: spec.SchemaProps{ Description: "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"), + Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), }, }, "items": { @@ -15028,7 +15014,7 @@ func schema_k8sio_api_core_v1_ReplicationControllerList(ref common.ReferenceCall Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.ReplicationController"), + Ref: ref(v1.ReplicationController{}.OpenAPIModelName()), }, }, }, @@ -15039,7 +15025,7 @@ func schema_k8sio_api_core_v1_ReplicationControllerList(ref common.ReferenceCall }, }, Dependencies: []string{ - "k8s.io/api/core/v1.ReplicationController", "k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"}, + v1.ReplicationController{}.OpenAPIModelName(), metav1.ListMeta{}.OpenAPIModelName()}, } } @@ -15090,14 +15076,14 @@ func schema_k8sio_api_core_v1_ReplicationControllerSpec(ref common.ReferenceCall "template": { SchemaProps: spec.SchemaProps{ Description: "Template is the object that describes the pod that will be created if insufficient replicas are detected. This takes precedence over a TemplateRef. The only allowed template.spec.restartPolicy value is \"Always\". More info: https://kubernetes.io/docs/concepts/workloads/controllers/replicationcontroller#pod-template", - Ref: ref("k8s.io/api/core/v1.PodTemplateSpec"), + Ref: ref(v1.PodTemplateSpec{}.OpenAPIModelName()), }, }, }, }, }, Dependencies: []string{ - "k8s.io/api/core/v1.PodTemplateSpec"}, + v1.PodTemplateSpec{}.OpenAPIModelName()}, } } @@ -15162,7 +15148,7 @@ func schema_k8sio_api_core_v1_ReplicationControllerStatus(ref common.ReferenceCa Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.ReplicationControllerCondition"), + Ref: ref(v1.ReplicationControllerCondition{}.OpenAPIModelName()), }, }, }, @@ -15173,7 +15159,7 @@ func schema_k8sio_api_core_v1_ReplicationControllerStatus(ref common.ReferenceCa }, }, Dependencies: []string{ - "k8s.io/api/core/v1.ReplicationControllerCondition"}, + v1.ReplicationControllerCondition{}.OpenAPIModelName()}, } } @@ -15231,7 +15217,7 @@ func schema_k8sio_api_core_v1_ResourceFieldSelector(ref common.ReferenceCallback "divisor": { SchemaProps: spec.SchemaProps{ Description: "Specifies the output format of the exposed resources, defaults to \"1\"", - Ref: ref("k8s.io/apimachinery/pkg/api/resource.Quantity"), + Ref: ref(resource.Quantity{}.OpenAPIModelName()), }, }, }, @@ -15244,7 +15230,7 @@ func schema_k8sio_api_core_v1_ResourceFieldSelector(ref common.ReferenceCallback }, }, Dependencies: []string{ - "k8s.io/apimachinery/pkg/api/resource.Quantity"}, + resource.Quantity{}.OpenAPIModelName()}, } } @@ -15302,28 +15288,28 @@ func schema_k8sio_api_core_v1_ResourceQuota(ref common.ReferenceCallback) common SchemaProps: spec.SchemaProps{ Description: "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata", Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"), + Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), }, }, "spec": { SchemaProps: spec.SchemaProps{ Description: "Spec defines the desired quota. https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status", Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.ResourceQuotaSpec"), + Ref: ref(v1.ResourceQuotaSpec{}.OpenAPIModelName()), }, }, "status": { SchemaProps: spec.SchemaProps{ Description: "Status defines the actual enforced quota and its current usage. https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status", Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.ResourceQuotaStatus"), + Ref: ref(v1.ResourceQuotaStatus{}.OpenAPIModelName()), }, }, }, }, }, Dependencies: []string{ - "k8s.io/api/core/v1.ResourceQuotaSpec", "k8s.io/api/core/v1.ResourceQuotaStatus", "k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"}, + v1.ResourceQuotaSpec{}.OpenAPIModelName(), v1.ResourceQuotaStatus{}.OpenAPIModelName(), metav1.ObjectMeta{}.OpenAPIModelName()}, } } @@ -15352,7 +15338,7 @@ func schema_k8sio_api_core_v1_ResourceQuotaList(ref common.ReferenceCallback) co SchemaProps: spec.SchemaProps{ Description: "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"), + Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), }, }, "items": { @@ -15363,7 +15349,7 @@ func schema_k8sio_api_core_v1_ResourceQuotaList(ref common.ReferenceCallback) co Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.ResourceQuota"), + Ref: ref(v1.ResourceQuota{}.OpenAPIModelName()), }, }, }, @@ -15374,7 +15360,7 @@ func schema_k8sio_api_core_v1_ResourceQuotaList(ref common.ReferenceCallback) co }, }, Dependencies: []string{ - "k8s.io/api/core/v1.ResourceQuota", "k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"}, + v1.ResourceQuota{}.OpenAPIModelName(), metav1.ListMeta{}.OpenAPIModelName()}, } } @@ -15393,7 +15379,7 @@ func schema_k8sio_api_core_v1_ResourceQuotaSpec(ref common.ReferenceCallback) co Allows: true, Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ - Ref: ref("k8s.io/apimachinery/pkg/api/resource.Quantity"), + Ref: ref(resource.Quantity{}.OpenAPIModelName()), }, }, }, @@ -15423,14 +15409,14 @@ func schema_k8sio_api_core_v1_ResourceQuotaSpec(ref common.ReferenceCallback) co "scopeSelector": { SchemaProps: spec.SchemaProps{ Description: "scopeSelector is also a collection of filters like scopes that must match each object tracked by a quota but expressed using ScopeSelectorOperator in combination with possible values. For a resource to match, both scopes AND scopeSelector (if specified in spec), must be matched.", - Ref: ref("k8s.io/api/core/v1.ScopeSelector"), + Ref: ref(v1.ScopeSelector{}.OpenAPIModelName()), }, }, }, }, }, Dependencies: []string{ - "k8s.io/api/core/v1.ScopeSelector", "k8s.io/apimachinery/pkg/api/resource.Quantity"}, + v1.ScopeSelector{}.OpenAPIModelName(), resource.Quantity{}.OpenAPIModelName()}, } } @@ -15449,7 +15435,7 @@ func schema_k8sio_api_core_v1_ResourceQuotaStatus(ref common.ReferenceCallback) Allows: true, Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ - Ref: ref("k8s.io/apimachinery/pkg/api/resource.Quantity"), + Ref: ref(resource.Quantity{}.OpenAPIModelName()), }, }, }, @@ -15463,7 +15449,7 @@ func schema_k8sio_api_core_v1_ResourceQuotaStatus(ref common.ReferenceCallback) Allows: true, Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ - Ref: ref("k8s.io/apimachinery/pkg/api/resource.Quantity"), + Ref: ref(resource.Quantity{}.OpenAPIModelName()), }, }, }, @@ -15473,7 +15459,7 @@ func schema_k8sio_api_core_v1_ResourceQuotaStatus(ref common.ReferenceCallback) }, }, Dependencies: []string{ - "k8s.io/apimachinery/pkg/api/resource.Quantity"}, + resource.Quantity{}.OpenAPIModelName()}, } } @@ -15492,7 +15478,7 @@ func schema_k8sio_api_core_v1_ResourceRequirements(ref common.ReferenceCallback) Allows: true, Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ - Ref: ref("k8s.io/apimachinery/pkg/api/resource.Quantity"), + Ref: ref(resource.Quantity{}.OpenAPIModelName()), }, }, }, @@ -15506,7 +15492,7 @@ func schema_k8sio_api_core_v1_ResourceRequirements(ref common.ReferenceCallback) Allows: true, Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ - Ref: ref("k8s.io/apimachinery/pkg/api/resource.Quantity"), + Ref: ref(resource.Quantity{}.OpenAPIModelName()), }, }, }, @@ -15528,7 +15514,7 @@ func schema_k8sio_api_core_v1_ResourceRequirements(ref common.ReferenceCallback) Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.ResourceClaim"), + Ref: ref(v1.ResourceClaim{}.OpenAPIModelName()), }, }, }, @@ -15538,7 +15524,7 @@ func schema_k8sio_api_core_v1_ResourceRequirements(ref common.ReferenceCallback) }, }, Dependencies: []string{ - "k8s.io/api/core/v1.ResourceClaim", "k8s.io/apimachinery/pkg/api/resource.Quantity"}, + v1.ResourceClaim{}.OpenAPIModelName(), resource.Quantity{}.OpenAPIModelName()}, } } @@ -15573,7 +15559,7 @@ func schema_k8sio_api_core_v1_ResourceStatus(ref common.ReferenceCallback) commo Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.ResourceHealth"), + Ref: ref(v1.ResourceHealth{}.OpenAPIModelName()), }, }, }, @@ -15584,7 +15570,7 @@ func schema_k8sio_api_core_v1_ResourceStatus(ref common.ReferenceCallback) commo }, }, Dependencies: []string{ - "k8s.io/api/core/v1.ResourceHealth"}, + v1.ResourceHealth{}.OpenAPIModelName()}, } } @@ -15655,7 +15641,7 @@ func schema_k8sio_api_core_v1_ScaleIOPersistentVolumeSource(ref common.Reference "secretRef": { SchemaProps: spec.SchemaProps{ Description: "secretRef references to the secret for ScaleIO user and other sensitive information. If this is not provided, Login operation will fail.", - Ref: ref("k8s.io/api/core/v1.SecretReference"), + Ref: ref(v1.SecretReference{}.OpenAPIModelName()), }, }, "sslEnabled": { @@ -15714,7 +15700,7 @@ func schema_k8sio_api_core_v1_ScaleIOPersistentVolumeSource(ref common.Reference }, }, Dependencies: []string{ - "k8s.io/api/core/v1.SecretReference"}, + v1.SecretReference{}.OpenAPIModelName()}, } } @@ -15744,7 +15730,7 @@ func schema_k8sio_api_core_v1_ScaleIOVolumeSource(ref common.ReferenceCallback) "secretRef": { SchemaProps: spec.SchemaProps{ Description: "secretRef references to the secret for ScaleIO user and other sensitive information. If this is not provided, Login operation will fail.", - Ref: ref("k8s.io/api/core/v1.LocalObjectReference"), + Ref: ref(v1.LocalObjectReference{}.OpenAPIModelName()), }, }, "sslEnabled": { @@ -15803,7 +15789,7 @@ func schema_k8sio_api_core_v1_ScaleIOVolumeSource(ref common.ReferenceCallback) }, }, Dependencies: []string{ - "k8s.io/api/core/v1.LocalObjectReference"}, + v1.LocalObjectReference{}.OpenAPIModelName()}, } } @@ -15827,7 +15813,7 @@ func schema_k8sio_api_core_v1_ScopeSelector(ref common.ReferenceCallback) common Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.ScopedResourceSelectorRequirement"), + Ref: ref(v1.ScopedResourceSelectorRequirement{}.OpenAPIModelName()), }, }, }, @@ -15842,7 +15828,7 @@ func schema_k8sio_api_core_v1_ScopeSelector(ref common.ReferenceCallback) common }, }, Dependencies: []string{ - "k8s.io/api/core/v1.ScopedResourceSelectorRequirement"}, + v1.ScopedResourceSelectorRequirement{}.OpenAPIModelName()}, } } @@ -15965,7 +15951,7 @@ func schema_k8sio_api_core_v1_Secret(ref common.ReferenceCallback) common.OpenAP SchemaProps: spec.SchemaProps{ Description: "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata", Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"), + Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), }, }, "immutable": { @@ -16017,7 +16003,7 @@ func schema_k8sio_api_core_v1_Secret(ref common.ReferenceCallback) common.OpenAP }, }, Dependencies: []string{ - "k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"}, + metav1.ObjectMeta{}.OpenAPIModelName()}, } } @@ -16116,7 +16102,7 @@ func schema_k8sio_api_core_v1_SecretList(ref common.ReferenceCallback) common.Op SchemaProps: spec.SchemaProps{ Description: "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"), + Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), }, }, "items": { @@ -16127,7 +16113,7 @@ func schema_k8sio_api_core_v1_SecretList(ref common.ReferenceCallback) common.Op Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.Secret"), + Ref: ref(v1.Secret{}.OpenAPIModelName()), }, }, }, @@ -16138,7 +16124,7 @@ func schema_k8sio_api_core_v1_SecretList(ref common.ReferenceCallback) common.Op }, }, Dependencies: []string{ - "k8s.io/api/core/v1.Secret", "k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"}, + v1.Secret{}.OpenAPIModelName(), metav1.ListMeta{}.OpenAPIModelName()}, } } @@ -16170,7 +16156,7 @@ func schema_k8sio_api_core_v1_SecretProjection(ref common.ReferenceCallback) com Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.KeyToPath"), + Ref: ref(v1.KeyToPath{}.OpenAPIModelName()), }, }, }, @@ -16187,7 +16173,7 @@ func schema_k8sio_api_core_v1_SecretProjection(ref common.ReferenceCallback) com }, }, Dependencies: []string{ - "k8s.io/api/core/v1.KeyToPath"}, + v1.KeyToPath{}.OpenAPIModelName()}, } } @@ -16250,7 +16236,7 @@ func schema_k8sio_api_core_v1_SecretVolumeSource(ref common.ReferenceCallback) c Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.KeyToPath"), + Ref: ref(v1.KeyToPath{}.OpenAPIModelName()), }, }, }, @@ -16274,7 +16260,7 @@ func schema_k8sio_api_core_v1_SecretVolumeSource(ref common.ReferenceCallback) c }, }, Dependencies: []string{ - "k8s.io/api/core/v1.KeyToPath"}, + v1.KeyToPath{}.OpenAPIModelName()}, } } @@ -16288,7 +16274,7 @@ func schema_k8sio_api_core_v1_SecurityContext(ref common.ReferenceCallback) comm "capabilities": { SchemaProps: spec.SchemaProps{ Description: "The capabilities to add/drop when running containers. Defaults to the default set of capabilities granted by the container runtime. Note that this field cannot be set when spec.os.name is windows.", - Ref: ref("k8s.io/api/core/v1.Capabilities"), + Ref: ref(v1.Capabilities{}.OpenAPIModelName()), }, }, "privileged": { @@ -16301,13 +16287,13 @@ func schema_k8sio_api_core_v1_SecurityContext(ref common.ReferenceCallback) comm "seLinuxOptions": { SchemaProps: spec.SchemaProps{ Description: "The SELinux context to be applied to the container. If unspecified, the container runtime will allocate a random SELinux context for each container. May also be set in PodSecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence. Note that this field cannot be set when spec.os.name is windows.", - Ref: ref("k8s.io/api/core/v1.SELinuxOptions"), + Ref: ref(v1.SELinuxOptions{}.OpenAPIModelName()), }, }, "windowsOptions": { SchemaProps: spec.SchemaProps{ Description: "The Windows specific settings applied to all containers. If unspecified, the options from the PodSecurityContext will be used. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence. Note that this field cannot be set when spec.os.name is linux.", - Ref: ref("k8s.io/api/core/v1.WindowsSecurityContextOptions"), + Ref: ref(v1.WindowsSecurityContextOptions{}.OpenAPIModelName()), }, }, "runAsUser": { @@ -16356,20 +16342,20 @@ func schema_k8sio_api_core_v1_SecurityContext(ref common.ReferenceCallback) comm "seccompProfile": { SchemaProps: spec.SchemaProps{ Description: "The seccomp options to use by this container. If seccomp options are provided at both the pod & container level, the container options override the pod options. Note that this field cannot be set when spec.os.name is windows.", - Ref: ref("k8s.io/api/core/v1.SeccompProfile"), + Ref: ref(v1.SeccompProfile{}.OpenAPIModelName()), }, }, "appArmorProfile": { SchemaProps: spec.SchemaProps{ Description: "appArmorProfile is the AppArmor options to use by this container. If set, this profile overrides the pod's appArmorProfile. Note that this field cannot be set when spec.os.name is windows.", - Ref: ref("k8s.io/api/core/v1.AppArmorProfile"), + Ref: ref(v1.AppArmorProfile{}.OpenAPIModelName()), }, }, }, }, }, Dependencies: []string{ - "k8s.io/api/core/v1.AppArmorProfile", "k8s.io/api/core/v1.Capabilities", "k8s.io/api/core/v1.SELinuxOptions", "k8s.io/api/core/v1.SeccompProfile", "k8s.io/api/core/v1.WindowsSecurityContextOptions"}, + v1.AppArmorProfile{}.OpenAPIModelName(), v1.Capabilities{}.OpenAPIModelName(), v1.SELinuxOptions{}.OpenAPIModelName(), v1.SeccompProfile{}.OpenAPIModelName(), v1.WindowsSecurityContextOptions{}.OpenAPIModelName()}, } } @@ -16398,14 +16384,14 @@ func schema_k8sio_api_core_v1_SerializedReference(ref common.ReferenceCallback) SchemaProps: spec.SchemaProps{ Description: "The reference to an object in the system.", Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.ObjectReference"), + Ref: ref(v1.ObjectReference{}.OpenAPIModelName()), }, }, }, }, }, Dependencies: []string{ - "k8s.io/api/core/v1.ObjectReference"}, + v1.ObjectReference{}.OpenAPIModelName()}, } } @@ -16434,28 +16420,28 @@ func schema_k8sio_api_core_v1_Service(ref common.ReferenceCallback) common.OpenA SchemaProps: spec.SchemaProps{ Description: "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata", Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"), + Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), }, }, "spec": { SchemaProps: spec.SchemaProps{ Description: "Spec defines the behavior of a service. https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status", Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.ServiceSpec"), + Ref: ref(v1.ServiceSpec{}.OpenAPIModelName()), }, }, "status": { SchemaProps: spec.SchemaProps{ Description: "Most recently observed status of the service. Populated by the system. Read-only. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status", Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.ServiceStatus"), + Ref: ref(v1.ServiceStatus{}.OpenAPIModelName()), }, }, }, }, }, Dependencies: []string{ - "k8s.io/api/core/v1.ServiceSpec", "k8s.io/api/core/v1.ServiceStatus", "k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"}, + v1.ServiceSpec{}.OpenAPIModelName(), v1.ServiceStatus{}.OpenAPIModelName(), metav1.ObjectMeta{}.OpenAPIModelName()}, } } @@ -16484,7 +16470,7 @@ func schema_k8sio_api_core_v1_ServiceAccount(ref common.ReferenceCallback) commo SchemaProps: spec.SchemaProps{ Description: "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata", Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"), + Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), }, }, "secrets": { @@ -16505,7 +16491,7 @@ func schema_k8sio_api_core_v1_ServiceAccount(ref common.ReferenceCallback) commo Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.ObjectReference"), + Ref: ref(v1.ObjectReference{}.OpenAPIModelName()), }, }, }, @@ -16524,7 +16510,7 @@ func schema_k8sio_api_core_v1_ServiceAccount(ref common.ReferenceCallback) commo Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.LocalObjectReference"), + Ref: ref(v1.LocalObjectReference{}.OpenAPIModelName()), }, }, }, @@ -16541,7 +16527,7 @@ func schema_k8sio_api_core_v1_ServiceAccount(ref common.ReferenceCallback) commo }, }, Dependencies: []string{ - "k8s.io/api/core/v1.LocalObjectReference", "k8s.io/api/core/v1.ObjectReference", "k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"}, + v1.LocalObjectReference{}.OpenAPIModelName(), v1.ObjectReference{}.OpenAPIModelName(), metav1.ObjectMeta{}.OpenAPIModelName()}, } } @@ -16570,7 +16556,7 @@ func schema_k8sio_api_core_v1_ServiceAccountList(ref common.ReferenceCallback) c SchemaProps: spec.SchemaProps{ Description: "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"), + Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), }, }, "items": { @@ -16581,7 +16567,7 @@ func schema_k8sio_api_core_v1_ServiceAccountList(ref common.ReferenceCallback) c Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.ServiceAccount"), + Ref: ref(v1.ServiceAccount{}.OpenAPIModelName()), }, }, }, @@ -16592,7 +16578,7 @@ func schema_k8sio_api_core_v1_ServiceAccountList(ref common.ReferenceCallback) c }, }, Dependencies: []string{ - "k8s.io/api/core/v1.ServiceAccount", "k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"}, + v1.ServiceAccount{}.OpenAPIModelName(), metav1.ListMeta{}.OpenAPIModelName()}, } } @@ -16657,7 +16643,7 @@ func schema_k8sio_api_core_v1_ServiceList(ref common.ReferenceCallback) common.O SchemaProps: spec.SchemaProps{ Description: "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"), + Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), }, }, "items": { @@ -16668,7 +16654,7 @@ func schema_k8sio_api_core_v1_ServiceList(ref common.ReferenceCallback) common.O Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.Service"), + Ref: ref(v1.Service{}.OpenAPIModelName()), }, }, }, @@ -16679,7 +16665,7 @@ func schema_k8sio_api_core_v1_ServiceList(ref common.ReferenceCallback) common.O }, }, Dependencies: []string{ - "k8s.io/api/core/v1.Service", "k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"}, + v1.Service{}.OpenAPIModelName(), metav1.ListMeta{}.OpenAPIModelName()}, } } @@ -16803,7 +16789,7 @@ func schema_k8sio_api_core_v1_ServiceSpec(ref common.ReferenceCallback) common.O Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.ServicePort"), + Ref: ref(v1.ServicePort{}.OpenAPIModelName()), }, }, }, @@ -16952,7 +16938,7 @@ func schema_k8sio_api_core_v1_ServiceSpec(ref common.ReferenceCallback) common.O "sessionAffinityConfig": { SchemaProps: spec.SchemaProps{ Description: "sessionAffinityConfig contains the configurations of session affinity.", - Ref: ref("k8s.io/api/core/v1.SessionAffinityConfig"), + Ref: ref(v1.SessionAffinityConfig{}.OpenAPIModelName()), }, }, "ipFamilies": { @@ -17017,7 +17003,7 @@ func schema_k8sio_api_core_v1_ServiceSpec(ref common.ReferenceCallback) common.O }, }, Dependencies: []string{ - "k8s.io/api/core/v1.ServicePort", "k8s.io/api/core/v1.SessionAffinityConfig"}, + v1.ServicePort{}.OpenAPIModelName(), v1.SessionAffinityConfig{}.OpenAPIModelName()}, } } @@ -17032,7 +17018,7 @@ func schema_k8sio_api_core_v1_ServiceStatus(ref common.ReferenceCallback) common SchemaProps: spec.SchemaProps{ Description: "LoadBalancer contains the current status of the load-balancer, if one is present.", Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.LoadBalancerStatus"), + Ref: ref(v1.LoadBalancerStatus{}.OpenAPIModelName()), }, }, "conditions": { @@ -17053,7 +17039,7 @@ func schema_k8sio_api_core_v1_ServiceStatus(ref common.ReferenceCallback) common Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.Condition"), + Ref: ref(metav1.Condition{}.OpenAPIModelName()), }, }, }, @@ -17063,7 +17049,7 @@ func schema_k8sio_api_core_v1_ServiceStatus(ref common.ReferenceCallback) common }, }, Dependencies: []string{ - "k8s.io/api/core/v1.LoadBalancerStatus", "k8s.io/apimachinery/pkg/apis/meta/v1.Condition"}, + v1.LoadBalancerStatus{}.OpenAPIModelName(), metav1.Condition{}.OpenAPIModelName()}, } } @@ -17077,14 +17063,14 @@ func schema_k8sio_api_core_v1_SessionAffinityConfig(ref common.ReferenceCallback "clientIP": { SchemaProps: spec.SchemaProps{ Description: "clientIP contains the configurations of Client IP based session affinity.", - Ref: ref("k8s.io/api/core/v1.ClientIPConfig"), + Ref: ref(v1.ClientIPConfig{}.OpenAPIModelName()), }, }, }, }, }, Dependencies: []string{ - "k8s.io/api/core/v1.ClientIPConfig"}, + v1.ClientIPConfig{}.OpenAPIModelName()}, } } @@ -17148,14 +17134,14 @@ func schema_k8sio_api_core_v1_StorageOSPersistentVolumeSource(ref common.Referen "secretRef": { SchemaProps: spec.SchemaProps{ Description: "secretRef specifies the secret to use for obtaining the StorageOS API credentials. If not specified, default values will be attempted.", - Ref: ref("k8s.io/api/core/v1.ObjectReference"), + Ref: ref(v1.ObjectReference{}.OpenAPIModelName()), }, }, }, }, }, Dependencies: []string{ - "k8s.io/api/core/v1.ObjectReference"}, + v1.ObjectReference{}.OpenAPIModelName()}, } } @@ -17197,14 +17183,14 @@ func schema_k8sio_api_core_v1_StorageOSVolumeSource(ref common.ReferenceCallback "secretRef": { SchemaProps: spec.SchemaProps{ Description: "secretRef specifies the secret to use for obtaining the StorageOS API credentials. If not specified, default values will be attempted.", - Ref: ref("k8s.io/api/core/v1.LocalObjectReference"), + Ref: ref(v1.LocalObjectReference{}.OpenAPIModelName()), }, }, }, }, }, Dependencies: []string{ - "k8s.io/api/core/v1.LocalObjectReference"}, + v1.LocalObjectReference{}.OpenAPIModelName()}, } } @@ -17301,7 +17287,7 @@ func schema_k8sio_api_core_v1_Taint(ref common.ReferenceCallback) common.OpenAPI "timeAdded": { SchemaProps: spec.SchemaProps{ Description: "TimeAdded represents the time at which the taint was added.", - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.Time"), + Ref: ref(metav1.Time{}.OpenAPIModelName()), }, }, }, @@ -17309,7 +17295,7 @@ func schema_k8sio_api_core_v1_Taint(ref common.ReferenceCallback) common.OpenAPI }, }, Dependencies: []string{ - "k8s.io/apimachinery/pkg/apis/meta/v1.Time"}, + metav1.Time{}.OpenAPIModelName()}, } } @@ -17425,7 +17411,7 @@ func schema_k8sio_api_core_v1_TopologySelectorTerm(ref common.ReferenceCallback) Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.TopologySelectorLabelRequirement"), + Ref: ref(v1.TopologySelectorLabelRequirement{}.OpenAPIModelName()), }, }, }, @@ -17440,7 +17426,7 @@ func schema_k8sio_api_core_v1_TopologySelectorTerm(ref common.ReferenceCallback) }, }, Dependencies: []string{ - "k8s.io/api/core/v1.TopologySelectorLabelRequirement"}, + v1.TopologySelectorLabelRequirement{}.OpenAPIModelName()}, } } @@ -17479,7 +17465,7 @@ func schema_k8sio_api_core_v1_TopologySpreadConstraint(ref common.ReferenceCallb "labelSelector": { SchemaProps: spec.SchemaProps{ Description: "LabelSelector is used to find matching pods. Pods that match this label selector are counted to determine the number of pods in their corresponding topology domain.", - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.LabelSelector"), + Ref: ref(metav1.LabelSelector{}.OpenAPIModelName()), }, }, "minDomains": { @@ -17530,7 +17516,7 @@ func schema_k8sio_api_core_v1_TopologySpreadConstraint(ref common.ReferenceCallb }, }, Dependencies: []string{ - "k8s.io/apimachinery/pkg/apis/meta/v1.LabelSelector"}, + metav1.LabelSelector{}.OpenAPIModelName()}, } } @@ -17638,181 +17624,181 @@ func schema_k8sio_api_core_v1_Volume(ref common.ReferenceCallback) common.OpenAP "hostPath": { SchemaProps: spec.SchemaProps{ Description: "hostPath represents a pre-existing file or directory on the host machine that is directly exposed to the container. This is generally used for system agents or other privileged things that are allowed to see the host machine. Most containers will NOT need this. More info: https://kubernetes.io/docs/concepts/storage/volumes#hostpath", - Ref: ref("k8s.io/api/core/v1.HostPathVolumeSource"), + Ref: ref(v1.HostPathVolumeSource{}.OpenAPIModelName()), }, }, "emptyDir": { SchemaProps: spec.SchemaProps{ Description: "emptyDir represents a temporary directory that shares a pod's lifetime. More info: https://kubernetes.io/docs/concepts/storage/volumes#emptydir", - Ref: ref("k8s.io/api/core/v1.EmptyDirVolumeSource"), + Ref: ref(v1.EmptyDirVolumeSource{}.OpenAPIModelName()), }, }, "gcePersistentDisk": { SchemaProps: spec.SchemaProps{ Description: "gcePersistentDisk represents a GCE Disk resource that is attached to a kubelet's host machine and then exposed to the pod. Deprecated: GCEPersistentDisk is deprecated. All operations for the in-tree gcePersistentDisk type are redirected to the pd.csi.storage.gke.io CSI driver. More info: https://kubernetes.io/docs/concepts/storage/volumes#gcepersistentdisk", - Ref: ref("k8s.io/api/core/v1.GCEPersistentDiskVolumeSource"), + Ref: ref(v1.GCEPersistentDiskVolumeSource{}.OpenAPIModelName()), }, }, "awsElasticBlockStore": { SchemaProps: spec.SchemaProps{ Description: "awsElasticBlockStore represents an AWS Disk resource that is attached to a kubelet's host machine and then exposed to the pod. Deprecated: AWSElasticBlockStore is deprecated. All operations for the in-tree awsElasticBlockStore type are redirected to the ebs.csi.aws.com CSI driver. More info: https://kubernetes.io/docs/concepts/storage/volumes#awselasticblockstore", - Ref: ref("k8s.io/api/core/v1.AWSElasticBlockStoreVolumeSource"), + Ref: ref(v1.AWSElasticBlockStoreVolumeSource{}.OpenAPIModelName()), }, }, "gitRepo": { SchemaProps: spec.SchemaProps{ Description: "gitRepo represents a git repository at a particular revision. Deprecated: GitRepo is deprecated. To provision a container with a git repo, mount an EmptyDir into an InitContainer that clones the repo using git, then mount the EmptyDir into the Pod's container.", - Ref: ref("k8s.io/api/core/v1.GitRepoVolumeSource"), + Ref: ref(v1.GitRepoVolumeSource{}.OpenAPIModelName()), }, }, "secret": { SchemaProps: spec.SchemaProps{ Description: "secret represents a secret that should populate this volume. More info: https://kubernetes.io/docs/concepts/storage/volumes#secret", - Ref: ref("k8s.io/api/core/v1.SecretVolumeSource"), + Ref: ref(v1.SecretVolumeSource{}.OpenAPIModelName()), }, }, "nfs": { SchemaProps: spec.SchemaProps{ Description: "nfs represents an NFS mount on the host that shares a pod's lifetime More info: https://kubernetes.io/docs/concepts/storage/volumes#nfs", - Ref: ref("k8s.io/api/core/v1.NFSVolumeSource"), + Ref: ref(v1.NFSVolumeSource{}.OpenAPIModelName()), }, }, "iscsi": { SchemaProps: spec.SchemaProps{ Description: "iscsi represents an ISCSI Disk resource that is attached to a kubelet's host machine and then exposed to the pod. More info: https://kubernetes.io/docs/concepts/storage/volumes/#iscsi", - Ref: ref("k8s.io/api/core/v1.ISCSIVolumeSource"), + Ref: ref(v1.ISCSIVolumeSource{}.OpenAPIModelName()), }, }, "glusterfs": { SchemaProps: spec.SchemaProps{ Description: "glusterfs represents a Glusterfs mount on the host that shares a pod's lifetime. Deprecated: Glusterfs is deprecated and the in-tree glusterfs type is no longer supported.", - Ref: ref("k8s.io/api/core/v1.GlusterfsVolumeSource"), + Ref: ref(v1.GlusterfsVolumeSource{}.OpenAPIModelName()), }, }, "persistentVolumeClaim": { SchemaProps: spec.SchemaProps{ Description: "persistentVolumeClaimVolumeSource represents a reference to a PersistentVolumeClaim in the same namespace. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#persistentvolumeclaims", - Ref: ref("k8s.io/api/core/v1.PersistentVolumeClaimVolumeSource"), + Ref: ref(v1.PersistentVolumeClaimVolumeSource{}.OpenAPIModelName()), }, }, "rbd": { SchemaProps: spec.SchemaProps{ Description: "rbd represents a Rados Block Device mount on the host that shares a pod's lifetime. Deprecated: RBD is deprecated and the in-tree rbd type is no longer supported.", - Ref: ref("k8s.io/api/core/v1.RBDVolumeSource"), + Ref: ref(v1.RBDVolumeSource{}.OpenAPIModelName()), }, }, "flexVolume": { SchemaProps: spec.SchemaProps{ Description: "flexVolume represents a generic volume resource that is provisioned/attached using an exec based plugin. Deprecated: FlexVolume is deprecated. Consider using a CSIDriver instead.", - Ref: ref("k8s.io/api/core/v1.FlexVolumeSource"), + Ref: ref(v1.FlexVolumeSource{}.OpenAPIModelName()), }, }, "cinder": { SchemaProps: spec.SchemaProps{ Description: "cinder represents a cinder volume attached and mounted on kubelets host machine. Deprecated: Cinder is deprecated. All operations for the in-tree cinder type are redirected to the cinder.csi.openstack.org CSI driver. More info: https://examples.k8s.io/mysql-cinder-pd/README.md", - Ref: ref("k8s.io/api/core/v1.CinderVolumeSource"), + Ref: ref(v1.CinderVolumeSource{}.OpenAPIModelName()), }, }, "cephfs": { SchemaProps: spec.SchemaProps{ Description: "cephFS represents a Ceph FS mount on the host that shares a pod's lifetime. Deprecated: CephFS is deprecated and the in-tree cephfs type is no longer supported.", - Ref: ref("k8s.io/api/core/v1.CephFSVolumeSource"), + Ref: ref(v1.CephFSVolumeSource{}.OpenAPIModelName()), }, }, "flocker": { SchemaProps: spec.SchemaProps{ Description: "flocker represents a Flocker volume attached to a kubelet's host machine. This depends on the Flocker control service being running. Deprecated: Flocker is deprecated and the in-tree flocker type is no longer supported.", - Ref: ref("k8s.io/api/core/v1.FlockerVolumeSource"), + Ref: ref(v1.FlockerVolumeSource{}.OpenAPIModelName()), }, }, "downwardAPI": { SchemaProps: spec.SchemaProps{ Description: "downwardAPI represents downward API about the pod that should populate this volume", - Ref: ref("k8s.io/api/core/v1.DownwardAPIVolumeSource"), + Ref: ref(v1.DownwardAPIVolumeSource{}.OpenAPIModelName()), }, }, "fc": { SchemaProps: spec.SchemaProps{ Description: "fc represents a Fibre Channel resource that is attached to a kubelet's host machine and then exposed to the pod.", - Ref: ref("k8s.io/api/core/v1.FCVolumeSource"), + Ref: ref(v1.FCVolumeSource{}.OpenAPIModelName()), }, }, "azureFile": { SchemaProps: spec.SchemaProps{ Description: "azureFile represents an Azure File Service mount on the host and bind mount to the pod. Deprecated: AzureFile is deprecated. All operations for the in-tree azureFile type are redirected to the file.csi.azure.com CSI driver.", - Ref: ref("k8s.io/api/core/v1.AzureFileVolumeSource"), + Ref: ref(v1.AzureFileVolumeSource{}.OpenAPIModelName()), }, }, "configMap": { SchemaProps: spec.SchemaProps{ Description: "configMap represents a configMap that should populate this volume", - Ref: ref("k8s.io/api/core/v1.ConfigMapVolumeSource"), + Ref: ref(v1.ConfigMapVolumeSource{}.OpenAPIModelName()), }, }, "vsphereVolume": { SchemaProps: spec.SchemaProps{ Description: "vsphereVolume represents a vSphere volume attached and mounted on kubelets host machine. Deprecated: VsphereVolume is deprecated. All operations for the in-tree vsphereVolume type are redirected to the csi.vsphere.vmware.com CSI driver.", - Ref: ref("k8s.io/api/core/v1.VsphereVirtualDiskVolumeSource"), + Ref: ref(v1.VsphereVirtualDiskVolumeSource{}.OpenAPIModelName()), }, }, "quobyte": { SchemaProps: spec.SchemaProps{ Description: "quobyte represents a Quobyte mount on the host that shares a pod's lifetime. Deprecated: Quobyte is deprecated and the in-tree quobyte type is no longer supported.", - Ref: ref("k8s.io/api/core/v1.QuobyteVolumeSource"), + Ref: ref(v1.QuobyteVolumeSource{}.OpenAPIModelName()), }, }, "azureDisk": { SchemaProps: spec.SchemaProps{ Description: "azureDisk represents an Azure Data Disk mount on the host and bind mount to the pod. Deprecated: AzureDisk is deprecated. All operations for the in-tree azureDisk type are redirected to the disk.csi.azure.com CSI driver.", - Ref: ref("k8s.io/api/core/v1.AzureDiskVolumeSource"), + Ref: ref(v1.AzureDiskVolumeSource{}.OpenAPIModelName()), }, }, "photonPersistentDisk": { SchemaProps: spec.SchemaProps{ Description: "photonPersistentDisk represents a PhotonController persistent disk attached and mounted on kubelets host machine. Deprecated: PhotonPersistentDisk is deprecated and the in-tree photonPersistentDisk type is no longer supported.", - Ref: ref("k8s.io/api/core/v1.PhotonPersistentDiskVolumeSource"), + Ref: ref(v1.PhotonPersistentDiskVolumeSource{}.OpenAPIModelName()), }, }, "projected": { SchemaProps: spec.SchemaProps{ Description: "projected items for all in one resources secrets, configmaps, and downward API", - Ref: ref("k8s.io/api/core/v1.ProjectedVolumeSource"), + Ref: ref(v1.ProjectedVolumeSource{}.OpenAPIModelName()), }, }, "portworxVolume": { SchemaProps: spec.SchemaProps{ Description: "portworxVolume represents a portworx volume attached and mounted on kubelets host machine. Deprecated: PortworxVolume is deprecated. All operations for the in-tree portworxVolume type are redirected to the pxd.portworx.com CSI driver when the CSIMigrationPortworx feature-gate is on.", - Ref: ref("k8s.io/api/core/v1.PortworxVolumeSource"), + Ref: ref(v1.PortworxVolumeSource{}.OpenAPIModelName()), }, }, "scaleIO": { SchemaProps: spec.SchemaProps{ Description: "scaleIO represents a ScaleIO persistent volume attached and mounted on Kubernetes nodes. Deprecated: ScaleIO is deprecated and the in-tree scaleIO type is no longer supported.", - Ref: ref("k8s.io/api/core/v1.ScaleIOVolumeSource"), + Ref: ref(v1.ScaleIOVolumeSource{}.OpenAPIModelName()), }, }, "storageos": { SchemaProps: spec.SchemaProps{ Description: "storageOS represents a StorageOS volume attached and mounted on Kubernetes nodes. Deprecated: StorageOS is deprecated and the in-tree storageos type is no longer supported.", - Ref: ref("k8s.io/api/core/v1.StorageOSVolumeSource"), + Ref: ref(v1.StorageOSVolumeSource{}.OpenAPIModelName()), }, }, "csi": { SchemaProps: spec.SchemaProps{ Description: "csi (Container Storage Interface) represents ephemeral storage that is handled by certain external CSI drivers.", - Ref: ref("k8s.io/api/core/v1.CSIVolumeSource"), + Ref: ref(v1.CSIVolumeSource{}.OpenAPIModelName()), }, }, "ephemeral": { SchemaProps: spec.SchemaProps{ Description: "ephemeral represents a volume that is handled by a cluster storage driver. The volume's lifecycle is tied to the pod that defines it - it will be created before the pod starts, and deleted when the pod is removed.\n\nUse this if: a) the volume is only needed while the pod runs, b) features of normal volumes like restoring from snapshot or capacity\n tracking are needed,\nc) the storage driver is specified through a storage class, and d) the storage driver supports dynamic volume provisioning through\n a PersistentVolumeClaim (see EphemeralVolumeSource for more\n information on the connection between this volume type\n and PersistentVolumeClaim).\n\nUse PersistentVolumeClaim or one of the vendor-specific APIs for volumes that persist for longer than the lifecycle of an individual pod.\n\nUse CSI for light-weight local ephemeral volumes if the CSI driver is meant to be used that way - see the documentation of the driver for more information.\n\nA pod can use both types of ephemeral volumes and persistent volumes at the same time.", - Ref: ref("k8s.io/api/core/v1.EphemeralVolumeSource"), + Ref: ref(v1.EphemeralVolumeSource{}.OpenAPIModelName()), }, }, "image": { SchemaProps: spec.SchemaProps{ Description: "image represents an OCI object (a container image or artifact) pulled and mounted on the kubelet's host machine. The volume is resolved at pod startup depending on which PullPolicy value is provided:\n\n- Always: the kubelet always attempts to pull the reference. Container creation will fail If the pull fails. - Never: the kubelet never pulls the reference and only uses a local image or artifact. Container creation will fail if the reference isn't present. - IfNotPresent: the kubelet pulls if the reference isn't already present on disk. Container creation will fail if the reference isn't present and the pull fails.\n\nThe volume gets re-resolved if the pod gets deleted and recreated, which means that new remote content will become available on pod recreation. A failure to resolve or pull the image during pod startup will block containers from starting and may add significant latency. Failures will be retried using normal volume backoff and will be reported on the pod reason and message. The types of objects that may be mounted by this volume are defined by the container runtime implementation on a host machine and at minimum must include all valid types supported by the container image field. The OCI object gets mounted in a single directory (spec.containers[*].volumeMounts.mountPath) by merging the manifest layers in the same way as for container images. The volume will be mounted read-only (ro) and non-executable files (noexec). Sub path mounts for containers are not supported (spec.containers[*].volumeMounts.subpath) before 1.33. The field spec.securityContext.fsGroupChangePolicy has no effect on this volume type.", - Ref: ref("k8s.io/api/core/v1.ImageVolumeSource"), + Ref: ref(v1.ImageVolumeSource{}.OpenAPIModelName()), }, }, }, @@ -17820,7 +17806,7 @@ func schema_k8sio_api_core_v1_Volume(ref common.ReferenceCallback) common.OpenAP }, }, Dependencies: []string{ - "k8s.io/api/core/v1.AWSElasticBlockStoreVolumeSource", "k8s.io/api/core/v1.AzureDiskVolumeSource", "k8s.io/api/core/v1.AzureFileVolumeSource", "k8s.io/api/core/v1.CSIVolumeSource", "k8s.io/api/core/v1.CephFSVolumeSource", "k8s.io/api/core/v1.CinderVolumeSource", "k8s.io/api/core/v1.ConfigMapVolumeSource", "k8s.io/api/core/v1.DownwardAPIVolumeSource", "k8s.io/api/core/v1.EmptyDirVolumeSource", "k8s.io/api/core/v1.EphemeralVolumeSource", "k8s.io/api/core/v1.FCVolumeSource", "k8s.io/api/core/v1.FlexVolumeSource", "k8s.io/api/core/v1.FlockerVolumeSource", "k8s.io/api/core/v1.GCEPersistentDiskVolumeSource", "k8s.io/api/core/v1.GitRepoVolumeSource", "k8s.io/api/core/v1.GlusterfsVolumeSource", "k8s.io/api/core/v1.HostPathVolumeSource", "k8s.io/api/core/v1.ISCSIVolumeSource", "k8s.io/api/core/v1.ImageVolumeSource", "k8s.io/api/core/v1.NFSVolumeSource", "k8s.io/api/core/v1.PersistentVolumeClaimVolumeSource", "k8s.io/api/core/v1.PhotonPersistentDiskVolumeSource", "k8s.io/api/core/v1.PortworxVolumeSource", "k8s.io/api/core/v1.ProjectedVolumeSource", "k8s.io/api/core/v1.QuobyteVolumeSource", "k8s.io/api/core/v1.RBDVolumeSource", "k8s.io/api/core/v1.ScaleIOVolumeSource", "k8s.io/api/core/v1.SecretVolumeSource", "k8s.io/api/core/v1.StorageOSVolumeSource", "k8s.io/api/core/v1.VsphereVirtualDiskVolumeSource"}, + v1.AWSElasticBlockStoreVolumeSource{}.OpenAPIModelName(), v1.AzureDiskVolumeSource{}.OpenAPIModelName(), v1.AzureFileVolumeSource{}.OpenAPIModelName(), v1.CSIVolumeSource{}.OpenAPIModelName(), v1.CephFSVolumeSource{}.OpenAPIModelName(), v1.CinderVolumeSource{}.OpenAPIModelName(), v1.ConfigMapVolumeSource{}.OpenAPIModelName(), v1.DownwardAPIVolumeSource{}.OpenAPIModelName(), v1.EmptyDirVolumeSource{}.OpenAPIModelName(), v1.EphemeralVolumeSource{}.OpenAPIModelName(), v1.FCVolumeSource{}.OpenAPIModelName(), v1.FlexVolumeSource{}.OpenAPIModelName(), v1.FlockerVolumeSource{}.OpenAPIModelName(), v1.GCEPersistentDiskVolumeSource{}.OpenAPIModelName(), v1.GitRepoVolumeSource{}.OpenAPIModelName(), v1.GlusterfsVolumeSource{}.OpenAPIModelName(), v1.HostPathVolumeSource{}.OpenAPIModelName(), v1.ISCSIVolumeSource{}.OpenAPIModelName(), v1.ImageVolumeSource{}.OpenAPIModelName(), v1.NFSVolumeSource{}.OpenAPIModelName(), v1.PersistentVolumeClaimVolumeSource{}.OpenAPIModelName(), v1.PhotonPersistentDiskVolumeSource{}.OpenAPIModelName(), v1.PortworxVolumeSource{}.OpenAPIModelName(), v1.ProjectedVolumeSource{}.OpenAPIModelName(), v1.QuobyteVolumeSource{}.OpenAPIModelName(), v1.RBDVolumeSource{}.OpenAPIModelName(), v1.ScaleIOVolumeSource{}.OpenAPIModelName(), v1.SecretVolumeSource{}.OpenAPIModelName(), v1.StorageOSVolumeSource{}.OpenAPIModelName(), v1.VsphereVirtualDiskVolumeSource{}.OpenAPIModelName()}, } } @@ -17974,14 +17960,14 @@ func schema_k8sio_api_core_v1_VolumeNodeAffinity(ref common.ReferenceCallback) c "required": { SchemaProps: spec.SchemaProps{ Description: "required specifies hard node constraints that must be met.", - Ref: ref("k8s.io/api/core/v1.NodeSelector"), + Ref: ref(v1.NodeSelector{}.OpenAPIModelName()), }, }, }, }, }, Dependencies: []string{ - "k8s.io/api/core/v1.NodeSelector"}, + v1.NodeSelector{}.OpenAPIModelName()}, } } @@ -17995,44 +17981,44 @@ func schema_k8sio_api_core_v1_VolumeProjection(ref common.ReferenceCallback) com "secret": { SchemaProps: spec.SchemaProps{ Description: "secret information about the secret data to project", - Ref: ref("k8s.io/api/core/v1.SecretProjection"), + Ref: ref(v1.SecretProjection{}.OpenAPIModelName()), }, }, "downwardAPI": { SchemaProps: spec.SchemaProps{ Description: "downwardAPI information about the downwardAPI data to project", - Ref: ref("k8s.io/api/core/v1.DownwardAPIProjection"), + Ref: ref(v1.DownwardAPIProjection{}.OpenAPIModelName()), }, }, "configMap": { SchemaProps: spec.SchemaProps{ Description: "configMap information about the configMap data to project", - Ref: ref("k8s.io/api/core/v1.ConfigMapProjection"), + Ref: ref(v1.ConfigMapProjection{}.OpenAPIModelName()), }, }, "serviceAccountToken": { SchemaProps: spec.SchemaProps{ Description: "serviceAccountToken is information about the serviceAccountToken data to project", - Ref: ref("k8s.io/api/core/v1.ServiceAccountTokenProjection"), + Ref: ref(v1.ServiceAccountTokenProjection{}.OpenAPIModelName()), }, }, "clusterTrustBundle": { SchemaProps: spec.SchemaProps{ Description: "ClusterTrustBundle allows a pod to access the `.spec.trustBundle` field of ClusterTrustBundle objects in an auto-updating file.\n\nAlpha, gated by the ClusterTrustBundleProjection feature gate.\n\nClusterTrustBundle objects can either be selected by name, or by the combination of signer name and a label selector.\n\nKubelet performs aggressive normalization of the PEM contents written into the pod filesystem. Esoteric PEM features such as inter-block comments and block headers are stripped. Certificates are deduplicated. The ordering of certificates within the file is arbitrary, and Kubelet may change the order over time.", - Ref: ref("k8s.io/api/core/v1.ClusterTrustBundleProjection"), + Ref: ref(v1.ClusterTrustBundleProjection{}.OpenAPIModelName()), }, }, "podCertificate": { SchemaProps: spec.SchemaProps{ Description: "Projects an auto-rotating credential bundle (private key and certificate chain) that the pod can use either as a TLS client or server.\n\nKubelet generates a private key and uses it to send a PodCertificateRequest to the named signer. Once the signer approves the request and issues a certificate chain, Kubelet writes the key and certificate chain to the pod filesystem. The pod does not start until certificates have been issued for each podCertificate projected volume source in its spec.\n\nKubelet will begin trying to rotate the certificate at the time indicated by the signer using the PodCertificateRequest.Status.BeginRefreshAt timestamp.\n\nKubelet can write a single file, indicated by the credentialBundlePath field, or separate files, indicated by the keyPath and certificateChainPath fields.\n\nThe credential bundle is a single file in PEM format. The first PEM entry is the private key (in PKCS#8 format), and the remaining PEM entries are the certificate chain issued by the signer (typically, signers will return their certificate chain in leaf-to-root order).\n\nPrefer using the credential bundle format, since your application code can read it atomically. If you use keyPath and certificateChainPath, your application must make two separate file reads. If these coincide with a certificate rotation, it is possible that the private key and leaf certificate you read may not correspond to each other. Your application will need to check for this condition, and re-read until they are consistent.\n\nThe named signer controls chooses the format of the certificate it issues; consult the signer implementation's documentation to learn how to use the certificates it issues.", - Ref: ref("k8s.io/api/core/v1.PodCertificateProjection"), + Ref: ref(v1.PodCertificateProjection{}.OpenAPIModelName()), }, }, }, }, }, Dependencies: []string{ - "k8s.io/api/core/v1.ClusterTrustBundleProjection", "k8s.io/api/core/v1.ConfigMapProjection", "k8s.io/api/core/v1.DownwardAPIProjection", "k8s.io/api/core/v1.PodCertificateProjection", "k8s.io/api/core/v1.SecretProjection", "k8s.io/api/core/v1.ServiceAccountTokenProjection"}, + v1.ClusterTrustBundleProjection{}.OpenAPIModelName(), v1.ConfigMapProjection{}.OpenAPIModelName(), v1.DownwardAPIProjection{}.OpenAPIModelName(), v1.PodCertificateProjection{}.OpenAPIModelName(), v1.SecretProjection{}.OpenAPIModelName(), v1.ServiceAccountTokenProjection{}.OpenAPIModelName()}, } } @@ -18051,7 +18037,7 @@ func schema_k8sio_api_core_v1_VolumeResourceRequirements(ref common.ReferenceCal Allows: true, Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ - Ref: ref("k8s.io/apimachinery/pkg/api/resource.Quantity"), + Ref: ref(resource.Quantity{}.OpenAPIModelName()), }, }, }, @@ -18065,7 +18051,7 @@ func schema_k8sio_api_core_v1_VolumeResourceRequirements(ref common.ReferenceCal Allows: true, Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ - Ref: ref("k8s.io/apimachinery/pkg/api/resource.Quantity"), + Ref: ref(resource.Quantity{}.OpenAPIModelName()), }, }, }, @@ -18075,7 +18061,7 @@ func schema_k8sio_api_core_v1_VolumeResourceRequirements(ref common.ReferenceCal }, }, Dependencies: []string{ - "k8s.io/apimachinery/pkg/api/resource.Quantity"}, + resource.Quantity{}.OpenAPIModelName()}, } } @@ -18089,188 +18075,188 @@ func schema_k8sio_api_core_v1_VolumeSource(ref common.ReferenceCallback) common. "hostPath": { SchemaProps: spec.SchemaProps{ Description: "hostPath represents a pre-existing file or directory on the host machine that is directly exposed to the container. This is generally used for system agents or other privileged things that are allowed to see the host machine. Most containers will NOT need this. More info: https://kubernetes.io/docs/concepts/storage/volumes#hostpath", - Ref: ref("k8s.io/api/core/v1.HostPathVolumeSource"), + Ref: ref(v1.HostPathVolumeSource{}.OpenAPIModelName()), }, }, "emptyDir": { SchemaProps: spec.SchemaProps{ Description: "emptyDir represents a temporary directory that shares a pod's lifetime. More info: https://kubernetes.io/docs/concepts/storage/volumes#emptydir", - Ref: ref("k8s.io/api/core/v1.EmptyDirVolumeSource"), + Ref: ref(v1.EmptyDirVolumeSource{}.OpenAPIModelName()), }, }, "gcePersistentDisk": { SchemaProps: spec.SchemaProps{ Description: "gcePersistentDisk represents a GCE Disk resource that is attached to a kubelet's host machine and then exposed to the pod. Deprecated: GCEPersistentDisk is deprecated. All operations for the in-tree gcePersistentDisk type are redirected to the pd.csi.storage.gke.io CSI driver. More info: https://kubernetes.io/docs/concepts/storage/volumes#gcepersistentdisk", - Ref: ref("k8s.io/api/core/v1.GCEPersistentDiskVolumeSource"), + Ref: ref(v1.GCEPersistentDiskVolumeSource{}.OpenAPIModelName()), }, }, "awsElasticBlockStore": { SchemaProps: spec.SchemaProps{ Description: "awsElasticBlockStore represents an AWS Disk resource that is attached to a kubelet's host machine and then exposed to the pod. Deprecated: AWSElasticBlockStore is deprecated. All operations for the in-tree awsElasticBlockStore type are redirected to the ebs.csi.aws.com CSI driver. More info: https://kubernetes.io/docs/concepts/storage/volumes#awselasticblockstore", - Ref: ref("k8s.io/api/core/v1.AWSElasticBlockStoreVolumeSource"), + Ref: ref(v1.AWSElasticBlockStoreVolumeSource{}.OpenAPIModelName()), }, }, "gitRepo": { SchemaProps: spec.SchemaProps{ Description: "gitRepo represents a git repository at a particular revision. Deprecated: GitRepo is deprecated. To provision a container with a git repo, mount an EmptyDir into an InitContainer that clones the repo using git, then mount the EmptyDir into the Pod's container.", - Ref: ref("k8s.io/api/core/v1.GitRepoVolumeSource"), + Ref: ref(v1.GitRepoVolumeSource{}.OpenAPIModelName()), }, }, "secret": { SchemaProps: spec.SchemaProps{ Description: "secret represents a secret that should populate this volume. More info: https://kubernetes.io/docs/concepts/storage/volumes#secret", - Ref: ref("k8s.io/api/core/v1.SecretVolumeSource"), + Ref: ref(v1.SecretVolumeSource{}.OpenAPIModelName()), }, }, "nfs": { SchemaProps: spec.SchemaProps{ Description: "nfs represents an NFS mount on the host that shares a pod's lifetime More info: https://kubernetes.io/docs/concepts/storage/volumes#nfs", - Ref: ref("k8s.io/api/core/v1.NFSVolumeSource"), + Ref: ref(v1.NFSVolumeSource{}.OpenAPIModelName()), }, }, "iscsi": { SchemaProps: spec.SchemaProps{ Description: "iscsi represents an ISCSI Disk resource that is attached to a kubelet's host machine and then exposed to the pod. More info: https://kubernetes.io/docs/concepts/storage/volumes/#iscsi", - Ref: ref("k8s.io/api/core/v1.ISCSIVolumeSource"), + Ref: ref(v1.ISCSIVolumeSource{}.OpenAPIModelName()), }, }, "glusterfs": { SchemaProps: spec.SchemaProps{ Description: "glusterfs represents a Glusterfs mount on the host that shares a pod's lifetime. Deprecated: Glusterfs is deprecated and the in-tree glusterfs type is no longer supported.", - Ref: ref("k8s.io/api/core/v1.GlusterfsVolumeSource"), + Ref: ref(v1.GlusterfsVolumeSource{}.OpenAPIModelName()), }, }, "persistentVolumeClaim": { SchemaProps: spec.SchemaProps{ Description: "persistentVolumeClaimVolumeSource represents a reference to a PersistentVolumeClaim in the same namespace. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#persistentvolumeclaims", - Ref: ref("k8s.io/api/core/v1.PersistentVolumeClaimVolumeSource"), + Ref: ref(v1.PersistentVolumeClaimVolumeSource{}.OpenAPIModelName()), }, }, "rbd": { SchemaProps: spec.SchemaProps{ Description: "rbd represents a Rados Block Device mount on the host that shares a pod's lifetime. Deprecated: RBD is deprecated and the in-tree rbd type is no longer supported.", - Ref: ref("k8s.io/api/core/v1.RBDVolumeSource"), + Ref: ref(v1.RBDVolumeSource{}.OpenAPIModelName()), }, }, "flexVolume": { SchemaProps: spec.SchemaProps{ Description: "flexVolume represents a generic volume resource that is provisioned/attached using an exec based plugin. Deprecated: FlexVolume is deprecated. Consider using a CSIDriver instead.", - Ref: ref("k8s.io/api/core/v1.FlexVolumeSource"), + Ref: ref(v1.FlexVolumeSource{}.OpenAPIModelName()), }, }, "cinder": { SchemaProps: spec.SchemaProps{ Description: "cinder represents a cinder volume attached and mounted on kubelets host machine. Deprecated: Cinder is deprecated. All operations for the in-tree cinder type are redirected to the cinder.csi.openstack.org CSI driver. More info: https://examples.k8s.io/mysql-cinder-pd/README.md", - Ref: ref("k8s.io/api/core/v1.CinderVolumeSource"), + Ref: ref(v1.CinderVolumeSource{}.OpenAPIModelName()), }, }, "cephfs": { SchemaProps: spec.SchemaProps{ Description: "cephFS represents a Ceph FS mount on the host that shares a pod's lifetime. Deprecated: CephFS is deprecated and the in-tree cephfs type is no longer supported.", - Ref: ref("k8s.io/api/core/v1.CephFSVolumeSource"), + Ref: ref(v1.CephFSVolumeSource{}.OpenAPIModelName()), }, }, "flocker": { SchemaProps: spec.SchemaProps{ Description: "flocker represents a Flocker volume attached to a kubelet's host machine. This depends on the Flocker control service being running. Deprecated: Flocker is deprecated and the in-tree flocker type is no longer supported.", - Ref: ref("k8s.io/api/core/v1.FlockerVolumeSource"), + Ref: ref(v1.FlockerVolumeSource{}.OpenAPIModelName()), }, }, "downwardAPI": { SchemaProps: spec.SchemaProps{ Description: "downwardAPI represents downward API about the pod that should populate this volume", - Ref: ref("k8s.io/api/core/v1.DownwardAPIVolumeSource"), + Ref: ref(v1.DownwardAPIVolumeSource{}.OpenAPIModelName()), }, }, "fc": { SchemaProps: spec.SchemaProps{ Description: "fc represents a Fibre Channel resource that is attached to a kubelet's host machine and then exposed to the pod.", - Ref: ref("k8s.io/api/core/v1.FCVolumeSource"), + Ref: ref(v1.FCVolumeSource{}.OpenAPIModelName()), }, }, "azureFile": { SchemaProps: spec.SchemaProps{ Description: "azureFile represents an Azure File Service mount on the host and bind mount to the pod. Deprecated: AzureFile is deprecated. All operations for the in-tree azureFile type are redirected to the file.csi.azure.com CSI driver.", - Ref: ref("k8s.io/api/core/v1.AzureFileVolumeSource"), + Ref: ref(v1.AzureFileVolumeSource{}.OpenAPIModelName()), }, }, "configMap": { SchemaProps: spec.SchemaProps{ Description: "configMap represents a configMap that should populate this volume", - Ref: ref("k8s.io/api/core/v1.ConfigMapVolumeSource"), + Ref: ref(v1.ConfigMapVolumeSource{}.OpenAPIModelName()), }, }, "vsphereVolume": { SchemaProps: spec.SchemaProps{ Description: "vsphereVolume represents a vSphere volume attached and mounted on kubelets host machine. Deprecated: VsphereVolume is deprecated. All operations for the in-tree vsphereVolume type are redirected to the csi.vsphere.vmware.com CSI driver.", - Ref: ref("k8s.io/api/core/v1.VsphereVirtualDiskVolumeSource"), + Ref: ref(v1.VsphereVirtualDiskVolumeSource{}.OpenAPIModelName()), }, }, "quobyte": { SchemaProps: spec.SchemaProps{ Description: "quobyte represents a Quobyte mount on the host that shares a pod's lifetime. Deprecated: Quobyte is deprecated and the in-tree quobyte type is no longer supported.", - Ref: ref("k8s.io/api/core/v1.QuobyteVolumeSource"), + Ref: ref(v1.QuobyteVolumeSource{}.OpenAPIModelName()), }, }, "azureDisk": { SchemaProps: spec.SchemaProps{ Description: "azureDisk represents an Azure Data Disk mount on the host and bind mount to the pod. Deprecated: AzureDisk is deprecated. All operations for the in-tree azureDisk type are redirected to the disk.csi.azure.com CSI driver.", - Ref: ref("k8s.io/api/core/v1.AzureDiskVolumeSource"), + Ref: ref(v1.AzureDiskVolumeSource{}.OpenAPIModelName()), }, }, "photonPersistentDisk": { SchemaProps: spec.SchemaProps{ Description: "photonPersistentDisk represents a PhotonController persistent disk attached and mounted on kubelets host machine. Deprecated: PhotonPersistentDisk is deprecated and the in-tree photonPersistentDisk type is no longer supported.", - Ref: ref("k8s.io/api/core/v1.PhotonPersistentDiskVolumeSource"), + Ref: ref(v1.PhotonPersistentDiskVolumeSource{}.OpenAPIModelName()), }, }, "projected": { SchemaProps: spec.SchemaProps{ Description: "projected items for all in one resources secrets, configmaps, and downward API", - Ref: ref("k8s.io/api/core/v1.ProjectedVolumeSource"), + Ref: ref(v1.ProjectedVolumeSource{}.OpenAPIModelName()), }, }, "portworxVolume": { SchemaProps: spec.SchemaProps{ Description: "portworxVolume represents a portworx volume attached and mounted on kubelets host machine. Deprecated: PortworxVolume is deprecated. All operations for the in-tree portworxVolume type are redirected to the pxd.portworx.com CSI driver when the CSIMigrationPortworx feature-gate is on.", - Ref: ref("k8s.io/api/core/v1.PortworxVolumeSource"), + Ref: ref(v1.PortworxVolumeSource{}.OpenAPIModelName()), }, }, "scaleIO": { SchemaProps: spec.SchemaProps{ Description: "scaleIO represents a ScaleIO persistent volume attached and mounted on Kubernetes nodes. Deprecated: ScaleIO is deprecated and the in-tree scaleIO type is no longer supported.", - Ref: ref("k8s.io/api/core/v1.ScaleIOVolumeSource"), + Ref: ref(v1.ScaleIOVolumeSource{}.OpenAPIModelName()), }, }, "storageos": { SchemaProps: spec.SchemaProps{ Description: "storageOS represents a StorageOS volume attached and mounted on Kubernetes nodes. Deprecated: StorageOS is deprecated and the in-tree storageos type is no longer supported.", - Ref: ref("k8s.io/api/core/v1.StorageOSVolumeSource"), + Ref: ref(v1.StorageOSVolumeSource{}.OpenAPIModelName()), }, }, "csi": { SchemaProps: spec.SchemaProps{ Description: "csi (Container Storage Interface) represents ephemeral storage that is handled by certain external CSI drivers.", - Ref: ref("k8s.io/api/core/v1.CSIVolumeSource"), + Ref: ref(v1.CSIVolumeSource{}.OpenAPIModelName()), }, }, "ephemeral": { SchemaProps: spec.SchemaProps{ Description: "ephemeral represents a volume that is handled by a cluster storage driver. The volume's lifecycle is tied to the pod that defines it - it will be created before the pod starts, and deleted when the pod is removed.\n\nUse this if: a) the volume is only needed while the pod runs, b) features of normal volumes like restoring from snapshot or capacity\n tracking are needed,\nc) the storage driver is specified through a storage class, and d) the storage driver supports dynamic volume provisioning through\n a PersistentVolumeClaim (see EphemeralVolumeSource for more\n information on the connection between this volume type\n and PersistentVolumeClaim).\n\nUse PersistentVolumeClaim or one of the vendor-specific APIs for volumes that persist for longer than the lifecycle of an individual pod.\n\nUse CSI for light-weight local ephemeral volumes if the CSI driver is meant to be used that way - see the documentation of the driver for more information.\n\nA pod can use both types of ephemeral volumes and persistent volumes at the same time.", - Ref: ref("k8s.io/api/core/v1.EphemeralVolumeSource"), + Ref: ref(v1.EphemeralVolumeSource{}.OpenAPIModelName()), }, }, "image": { SchemaProps: spec.SchemaProps{ Description: "image represents an OCI object (a container image or artifact) pulled and mounted on the kubelet's host machine. The volume is resolved at pod startup depending on which PullPolicy value is provided:\n\n- Always: the kubelet always attempts to pull the reference. Container creation will fail If the pull fails. - Never: the kubelet never pulls the reference and only uses a local image or artifact. Container creation will fail if the reference isn't present. - IfNotPresent: the kubelet pulls if the reference isn't already present on disk. Container creation will fail if the reference isn't present and the pull fails.\n\nThe volume gets re-resolved if the pod gets deleted and recreated, which means that new remote content will become available on pod recreation. A failure to resolve or pull the image during pod startup will block containers from starting and may add significant latency. Failures will be retried using normal volume backoff and will be reported on the pod reason and message. The types of objects that may be mounted by this volume are defined by the container runtime implementation on a host machine and at minimum must include all valid types supported by the container image field. The OCI object gets mounted in a single directory (spec.containers[*].volumeMounts.mountPath) by merging the manifest layers in the same way as for container images. The volume will be mounted read-only (ro) and non-executable files (noexec). Sub path mounts for containers are not supported (spec.containers[*].volumeMounts.subpath) before 1.33. The field spec.securityContext.fsGroupChangePolicy has no effect on this volume type.", - Ref: ref("k8s.io/api/core/v1.ImageVolumeSource"), + Ref: ref(v1.ImageVolumeSource{}.OpenAPIModelName()), }, }, }, }, }, Dependencies: []string{ - "k8s.io/api/core/v1.AWSElasticBlockStoreVolumeSource", "k8s.io/api/core/v1.AzureDiskVolumeSource", "k8s.io/api/core/v1.AzureFileVolumeSource", "k8s.io/api/core/v1.CSIVolumeSource", "k8s.io/api/core/v1.CephFSVolumeSource", "k8s.io/api/core/v1.CinderVolumeSource", "k8s.io/api/core/v1.ConfigMapVolumeSource", "k8s.io/api/core/v1.DownwardAPIVolumeSource", "k8s.io/api/core/v1.EmptyDirVolumeSource", "k8s.io/api/core/v1.EphemeralVolumeSource", "k8s.io/api/core/v1.FCVolumeSource", "k8s.io/api/core/v1.FlexVolumeSource", "k8s.io/api/core/v1.FlockerVolumeSource", "k8s.io/api/core/v1.GCEPersistentDiskVolumeSource", "k8s.io/api/core/v1.GitRepoVolumeSource", "k8s.io/api/core/v1.GlusterfsVolumeSource", "k8s.io/api/core/v1.HostPathVolumeSource", "k8s.io/api/core/v1.ISCSIVolumeSource", "k8s.io/api/core/v1.ImageVolumeSource", "k8s.io/api/core/v1.NFSVolumeSource", "k8s.io/api/core/v1.PersistentVolumeClaimVolumeSource", "k8s.io/api/core/v1.PhotonPersistentDiskVolumeSource", "k8s.io/api/core/v1.PortworxVolumeSource", "k8s.io/api/core/v1.ProjectedVolumeSource", "k8s.io/api/core/v1.QuobyteVolumeSource", "k8s.io/api/core/v1.RBDVolumeSource", "k8s.io/api/core/v1.ScaleIOVolumeSource", "k8s.io/api/core/v1.SecretVolumeSource", "k8s.io/api/core/v1.StorageOSVolumeSource", "k8s.io/api/core/v1.VsphereVirtualDiskVolumeSource"}, + v1.AWSElasticBlockStoreVolumeSource{}.OpenAPIModelName(), v1.AzureDiskVolumeSource{}.OpenAPIModelName(), v1.AzureFileVolumeSource{}.OpenAPIModelName(), v1.CSIVolumeSource{}.OpenAPIModelName(), v1.CephFSVolumeSource{}.OpenAPIModelName(), v1.CinderVolumeSource{}.OpenAPIModelName(), v1.ConfigMapVolumeSource{}.OpenAPIModelName(), v1.DownwardAPIVolumeSource{}.OpenAPIModelName(), v1.EmptyDirVolumeSource{}.OpenAPIModelName(), v1.EphemeralVolumeSource{}.OpenAPIModelName(), v1.FCVolumeSource{}.OpenAPIModelName(), v1.FlexVolumeSource{}.OpenAPIModelName(), v1.FlockerVolumeSource{}.OpenAPIModelName(), v1.GCEPersistentDiskVolumeSource{}.OpenAPIModelName(), v1.GitRepoVolumeSource{}.OpenAPIModelName(), v1.GlusterfsVolumeSource{}.OpenAPIModelName(), v1.HostPathVolumeSource{}.OpenAPIModelName(), v1.ISCSIVolumeSource{}.OpenAPIModelName(), v1.ImageVolumeSource{}.OpenAPIModelName(), v1.NFSVolumeSource{}.OpenAPIModelName(), v1.PersistentVolumeClaimVolumeSource{}.OpenAPIModelName(), v1.PhotonPersistentDiskVolumeSource{}.OpenAPIModelName(), v1.PortworxVolumeSource{}.OpenAPIModelName(), v1.ProjectedVolumeSource{}.OpenAPIModelName(), v1.QuobyteVolumeSource{}.OpenAPIModelName(), v1.RBDVolumeSource{}.OpenAPIModelName(), v1.ScaleIOVolumeSource{}.OpenAPIModelName(), v1.SecretVolumeSource{}.OpenAPIModelName(), v1.StorageOSVolumeSource{}.OpenAPIModelName(), v1.VsphereVirtualDiskVolumeSource{}.OpenAPIModelName()}, } } @@ -18336,7 +18322,7 @@ func schema_k8sio_api_core_v1_WeightedPodAffinityTerm(ref common.ReferenceCallba SchemaProps: spec.SchemaProps{ Description: "Required. A pod affinity term, associated with the corresponding weight.", Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.PodAffinityTerm"), + Ref: ref(v1.PodAffinityTerm{}.OpenAPIModelName()), }, }, }, @@ -18344,7 +18330,7 @@ func schema_k8sio_api_core_v1_WeightedPodAffinityTerm(ref common.ReferenceCallba }, }, Dependencies: []string{ - "k8s.io/api/core/v1.PodAffinityTerm"}, + v1.PodAffinityTerm{}.OpenAPIModelName()}, } } @@ -18516,7 +18502,7 @@ func schema_pkg_apis_meta_v1_APIGroup(ref common.ReferenceCallback) common.OpenA Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.GroupVersionForDiscovery"), + Ref: ref(metav1.GroupVersionForDiscovery{}.OpenAPIModelName()), }, }, }, @@ -18526,7 +18512,7 @@ func schema_pkg_apis_meta_v1_APIGroup(ref common.ReferenceCallback) common.OpenA SchemaProps: spec.SchemaProps{ Description: "preferredVersion is the version preferred by the API server, which probably is the storage version.", Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.GroupVersionForDiscovery"), + Ref: ref(metav1.GroupVersionForDiscovery{}.OpenAPIModelName()), }, }, "serverAddressByClientCIDRs": { @@ -18542,7 +18528,7 @@ func schema_pkg_apis_meta_v1_APIGroup(ref common.ReferenceCallback) common.OpenA Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ServerAddressByClientCIDR"), + Ref: ref(metav1.ServerAddressByClientCIDR{}.OpenAPIModelName()), }, }, }, @@ -18553,7 +18539,7 @@ func schema_pkg_apis_meta_v1_APIGroup(ref common.ReferenceCallback) common.OpenA }, }, Dependencies: []string{ - "k8s.io/apimachinery/pkg/apis/meta/v1.GroupVersionForDiscovery", "k8s.io/apimachinery/pkg/apis/meta/v1.ServerAddressByClientCIDR"}, + metav1.GroupVersionForDiscovery{}.OpenAPIModelName(), metav1.ServerAddressByClientCIDR{}.OpenAPIModelName()}, } } @@ -18591,7 +18577,7 @@ func schema_pkg_apis_meta_v1_APIGroupList(ref common.ReferenceCallback) common.O Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.APIGroup"), + Ref: ref(metav1.APIGroup{}.OpenAPIModelName()), }, }, }, @@ -18602,7 +18588,7 @@ func schema_pkg_apis_meta_v1_APIGroupList(ref common.ReferenceCallback) common.O }, }, Dependencies: []string{ - "k8s.io/apimachinery/pkg/apis/meta/v1.APIGroup"}, + metav1.APIGroup{}.OpenAPIModelName()}, } } @@ -18770,7 +18756,7 @@ func schema_pkg_apis_meta_v1_APIResourceList(ref common.ReferenceCallback) commo Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.APIResource"), + Ref: ref(metav1.APIResource{}.OpenAPIModelName()), }, }, }, @@ -18781,7 +18767,7 @@ func schema_pkg_apis_meta_v1_APIResourceList(ref common.ReferenceCallback) commo }, }, Dependencies: []string{ - "k8s.io/apimachinery/pkg/apis/meta/v1.APIResource"}, + metav1.APIResource{}.OpenAPIModelName()}, } } @@ -18839,7 +18825,7 @@ func schema_pkg_apis_meta_v1_APIVersions(ref common.ReferenceCallback) common.Op Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ServerAddressByClientCIDR"), + Ref: ref(metav1.ServerAddressByClientCIDR{}.OpenAPIModelName()), }, }, }, @@ -18850,7 +18836,7 @@ func schema_pkg_apis_meta_v1_APIVersions(ref common.ReferenceCallback) common.Op }, }, Dependencies: []string{ - "k8s.io/apimachinery/pkg/apis/meta/v1.ServerAddressByClientCIDR"}, + metav1.ServerAddressByClientCIDR{}.OpenAPIModelName()}, } } @@ -18951,7 +18937,7 @@ func schema_pkg_apis_meta_v1_Condition(ref common.ReferenceCallback) common.Open "lastTransitionTime": { SchemaProps: spec.SchemaProps{ Description: "lastTransitionTime is the last time the condition transitioned from one status to another. This should be when the underlying condition changed. If that is not known, then using the time when the API field changed is acceptable.", - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.Time"), + Ref: ref(metav1.Time{}.OpenAPIModelName()), }, }, "reason": { @@ -18975,7 +18961,7 @@ func schema_pkg_apis_meta_v1_Condition(ref common.ReferenceCallback) common.Open }, }, Dependencies: []string{ - "k8s.io/apimachinery/pkg/apis/meta/v1.Time"}, + metav1.Time{}.OpenAPIModelName()}, } } @@ -19071,7 +19057,7 @@ func schema_pkg_apis_meta_v1_DeleteOptions(ref common.ReferenceCallback) common. "preconditions": { SchemaProps: spec.SchemaProps{ Description: "Must be fulfilled before a deletion is carried out. If not possible, a 409 Conflict status will be returned.", - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.Preconditions"), + Ref: ref(metav1.Preconditions{}.OpenAPIModelName()), }, }, "orphanDependents": { @@ -19119,7 +19105,7 @@ func schema_pkg_apis_meta_v1_DeleteOptions(ref common.ReferenceCallback) common. }, }, Dependencies: []string{ - "k8s.io/apimachinery/pkg/apis/meta/v1.Preconditions"}, + metav1.Preconditions{}.OpenAPIModelName()}, } } @@ -19431,15 +19417,12 @@ func schema_pkg_apis_meta_v1_InternalEvent(ref common.ReferenceCallback) common. "Object": { SchemaProps: spec.SchemaProps{ Description: "Object is:\n * If Type is Added or Modified: the new state of the object.\n * If Type is Deleted: the state of the object immediately before deletion.\n * If Type is Bookmark: the object (instance of a type being watched) where\n only ResourceVersion field is set. On successful restart of watch from a\n bookmark resourceVersion, client is guaranteed to not get repeat event\n nor miss any events.\n * If Type is Error: *api.Status is recommended; other types may make sense\n depending on context.", - Ref: ref("k8s.io/apimachinery/pkg/runtime.Object"), }, }, }, Required: []string{"Type", "Object"}, }, }, - Dependencies: []string{ - "k8s.io/apimachinery/pkg/runtime.Object"}, } } @@ -19479,7 +19462,7 @@ func schema_pkg_apis_meta_v1_LabelSelector(ref common.ReferenceCallback) common. Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.LabelSelectorRequirement"), + Ref: ref(metav1.LabelSelectorRequirement{}.OpenAPIModelName()), }, }, }, @@ -19494,7 +19477,7 @@ func schema_pkg_apis_meta_v1_LabelSelector(ref common.ReferenceCallback) common. }, }, Dependencies: []string{ - "k8s.io/apimachinery/pkg/apis/meta/v1.LabelSelectorRequirement"}, + metav1.LabelSelectorRequirement{}.OpenAPIModelName()}, } } @@ -19573,7 +19556,7 @@ func schema_pkg_apis_meta_v1_List(ref common.ReferenceCallback) common.OpenAPIDe SchemaProps: spec.SchemaProps{ Description: "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"), + Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), }, }, "items": { @@ -19583,7 +19566,7 @@ func schema_pkg_apis_meta_v1_List(ref common.ReferenceCallback) common.OpenAPIDe Items: &spec.SchemaOrArray{ Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ - Ref: ref("k8s.io/apimachinery/pkg/runtime.RawExtension"), + Ref: ref(runtime.RawExtension{}.OpenAPIModelName()), }, }, }, @@ -19594,7 +19577,7 @@ func schema_pkg_apis_meta_v1_List(ref common.ReferenceCallback) common.OpenAPIDe }, }, Dependencies: []string{ - "k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta", "k8s.io/apimachinery/pkg/runtime.RawExtension"}, + metav1.ListMeta{}.OpenAPIModelName(), runtime.RawExtension{}.OpenAPIModelName()}, } } @@ -19767,7 +19750,7 @@ func schema_pkg_apis_meta_v1_ManagedFieldsEntry(ref common.ReferenceCallback) co "time": { SchemaProps: spec.SchemaProps{ Description: "Time is the timestamp of when the ManagedFields entry was added. The timestamp will also be updated if a field is added, the manager changes any of the owned fields value or removes a field. The timestamp does not update when a field is removed from the entry because another manager took it over.", - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.Time"), + Ref: ref(metav1.Time{}.OpenAPIModelName()), }, }, "fieldsType": { @@ -19780,7 +19763,7 @@ func schema_pkg_apis_meta_v1_ManagedFieldsEntry(ref common.ReferenceCallback) co "fieldsV1": { SchemaProps: spec.SchemaProps{ Description: "FieldsV1 holds the first JSON version format as described in the \"FieldsV1\" type.", - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.FieldsV1"), + Ref: ref(metav1.FieldsV1{}.OpenAPIModelName()), }, }, "subresource": { @@ -19794,7 +19777,7 @@ func schema_pkg_apis_meta_v1_ManagedFieldsEntry(ref common.ReferenceCallback) co }, }, Dependencies: []string{ - "k8s.io/apimachinery/pkg/apis/meta/v1.FieldsV1", "k8s.io/apimachinery/pkg/apis/meta/v1.Time"}, + metav1.FieldsV1{}.OpenAPIModelName(), metav1.Time{}.OpenAPIModelName()}, } } @@ -19869,13 +19852,13 @@ func schema_pkg_apis_meta_v1_ObjectMeta(ref common.ReferenceCallback) common.Ope "creationTimestamp": { SchemaProps: spec.SchemaProps{ Description: "CreationTimestamp is a timestamp representing the server time when this object was created. It is not guaranteed to be set in happens-before order across separate operations. Clients may not set this value. It is represented in RFC3339 form and is in UTC.\n\nPopulated by the system. Read-only. Null for lists. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata", - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.Time"), + Ref: ref(metav1.Time{}.OpenAPIModelName()), }, }, "deletionTimestamp": { SchemaProps: spec.SchemaProps{ Description: "DeletionTimestamp is RFC 3339 date and time at which this resource will be deleted. This field is set by the server when a graceful deletion is requested by the user, and is not directly settable by a client. The resource is expected to be deleted (no longer visible from resource lists, and not reachable by name) after the time in this field, once the finalizers list is empty. As long as the finalizers list contains items, deletion is blocked. Once the deletionTimestamp is set, this value may not be unset or be set further into the future, although it may be shortened or the resource may be deleted prior to this time. For example, a user may request that a pod is deleted in 30 seconds. The Kubelet will react by sending a graceful termination signal to the containers in the pod. After that 30 seconds, the Kubelet will send a hard termination signal (SIGKILL) to the container and after cleanup, remove the pod from the API. In the presence of network partitions, this object may still exist after this timestamp, until an administrator or automated process can determine the resource is fully terminated. If not set, graceful deletion of the object has not been requested.\n\nPopulated by the system when a graceful deletion is requested. Read-only. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata", - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.Time"), + Ref: ref(metav1.Time{}.OpenAPIModelName()), }, }, "deletionGracePeriodSeconds": { @@ -19935,7 +19918,7 @@ func schema_pkg_apis_meta_v1_ObjectMeta(ref common.ReferenceCallback) common.Ope Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.OwnerReference"), + Ref: ref(metav1.OwnerReference{}.OpenAPIModelName()), }, }, }, @@ -19975,7 +19958,7 @@ func schema_pkg_apis_meta_v1_ObjectMeta(ref common.ReferenceCallback) common.Ope Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ManagedFieldsEntry"), + Ref: ref(metav1.ManagedFieldsEntry{}.OpenAPIModelName()), }, }, }, @@ -19985,7 +19968,7 @@ func schema_pkg_apis_meta_v1_ObjectMeta(ref common.ReferenceCallback) common.Ope }, }, Dependencies: []string{ - "k8s.io/apimachinery/pkg/apis/meta/v1.ManagedFieldsEntry", "k8s.io/apimachinery/pkg/apis/meta/v1.OwnerReference", "k8s.io/apimachinery/pkg/apis/meta/v1.Time"}, + metav1.ManagedFieldsEntry{}.OpenAPIModelName(), metav1.OwnerReference{}.OpenAPIModelName(), metav1.Time{}.OpenAPIModelName()}, } } @@ -20079,14 +20062,14 @@ func schema_pkg_apis_meta_v1_PartialObjectMetadata(ref common.ReferenceCallback) SchemaProps: spec.SchemaProps{ Description: "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata", Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"), + Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), }, }, }, }, }, Dependencies: []string{ - "k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"}, + metav1.ObjectMeta{}.OpenAPIModelName()}, } } @@ -20115,7 +20098,7 @@ func schema_pkg_apis_meta_v1_PartialObjectMetadataList(ref common.ReferenceCallb SchemaProps: spec.SchemaProps{ Description: "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"), + Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), }, }, "items": { @@ -20126,7 +20109,7 @@ func schema_pkg_apis_meta_v1_PartialObjectMetadataList(ref common.ReferenceCallb Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.PartialObjectMetadata"), + Ref: ref(metav1.PartialObjectMetadata{}.OpenAPIModelName()), }, }, }, @@ -20137,7 +20120,7 @@ func schema_pkg_apis_meta_v1_PartialObjectMetadataList(ref common.ReferenceCallb }, }, Dependencies: []string{ - "k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta", "k8s.io/apimachinery/pkg/apis/meta/v1.PartialObjectMetadata"}, + metav1.ListMeta{}.OpenAPIModelName(), metav1.PartialObjectMetadata{}.OpenAPIModelName()}, } } @@ -20336,7 +20319,7 @@ func schema_pkg_apis_meta_v1_Status(ref common.ReferenceCallback) common.OpenAPI SchemaProps: spec.SchemaProps{ Description: "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"), + Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), }, }, "status": { @@ -20363,7 +20346,7 @@ func schema_pkg_apis_meta_v1_Status(ref common.ReferenceCallback) common.OpenAPI "details": { SchemaProps: spec.SchemaProps{ Description: "Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type.", - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.StatusDetails"), + Ref: ref(metav1.StatusDetails{}.OpenAPIModelName()), }, }, "code": { @@ -20377,7 +20360,7 @@ func schema_pkg_apis_meta_v1_Status(ref common.ReferenceCallback) common.OpenAPI }, }, Dependencies: []string{ - "k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta", "k8s.io/apimachinery/pkg/apis/meta/v1.StatusDetails"}, + metav1.ListMeta{}.OpenAPIModelName(), metav1.StatusDetails{}.OpenAPIModelName()}, } } @@ -20463,7 +20446,7 @@ func schema_pkg_apis_meta_v1_StatusDetails(ref common.ReferenceCallback) common. Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.StatusCause"), + Ref: ref(metav1.StatusCause{}.OpenAPIModelName()), }, }, }, @@ -20480,7 +20463,7 @@ func schema_pkg_apis_meta_v1_StatusDetails(ref common.ReferenceCallback) common. }, }, Dependencies: []string{ - "k8s.io/apimachinery/pkg/apis/meta/v1.StatusCause"}, + metav1.StatusCause{}.OpenAPIModelName()}, } } @@ -20509,7 +20492,7 @@ func schema_pkg_apis_meta_v1_Table(ref common.ReferenceCallback) common.OpenAPID SchemaProps: spec.SchemaProps{ Description: "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"), + Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), }, }, "columnDefinitions": { @@ -20525,7 +20508,7 @@ func schema_pkg_apis_meta_v1_Table(ref common.ReferenceCallback) common.OpenAPID Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.TableColumnDefinition"), + Ref: ref(metav1.TableColumnDefinition{}.OpenAPIModelName()), }, }, }, @@ -20544,7 +20527,7 @@ func schema_pkg_apis_meta_v1_Table(ref common.ReferenceCallback) common.OpenAPID Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.TableRow"), + Ref: ref(metav1.TableRow{}.OpenAPIModelName()), }, }, }, @@ -20555,7 +20538,7 @@ func schema_pkg_apis_meta_v1_Table(ref common.ReferenceCallback) common.OpenAPID }, }, Dependencies: []string{ - "k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta", "k8s.io/apimachinery/pkg/apis/meta/v1.TableColumnDefinition", "k8s.io/apimachinery/pkg/apis/meta/v1.TableRow"}, + metav1.ListMeta{}.OpenAPIModelName(), metav1.TableColumnDefinition{}.OpenAPIModelName(), metav1.TableRow{}.OpenAPIModelName()}, } } @@ -20686,7 +20669,7 @@ func schema_pkg_apis_meta_v1_TableRow(ref common.ReferenceCallback) common.OpenA Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.TableRowCondition"), + Ref: ref(metav1.TableRowCondition{}.OpenAPIModelName()), }, }, }, @@ -20695,7 +20678,7 @@ func schema_pkg_apis_meta_v1_TableRow(ref common.ReferenceCallback) common.OpenA "object": { SchemaProps: spec.SchemaProps{ Description: "This field contains the requested additional information about each object based on the includeObject policy when requesting the Table. If \"None\", this field is empty, if \"Object\" this will be the default serialization of the object for the current API version, and if \"Metadata\" (the default) will contain the object metadata. Check the returned kind and apiVersion of the object before parsing. The media type of the object will always match the enclosing list - if this as a JSON table, these will be JSON encoded objects.", - Ref: ref("k8s.io/apimachinery/pkg/runtime.RawExtension"), + Ref: ref(runtime.RawExtension{}.OpenAPIModelName()), }, }, }, @@ -20703,7 +20686,7 @@ func schema_pkg_apis_meta_v1_TableRow(ref common.ReferenceCallback) common.OpenA }, }, Dependencies: []string{ - "k8s.io/apimachinery/pkg/apis/meta/v1.TableRowCondition", "k8s.io/apimachinery/pkg/runtime.RawExtension"}, + metav1.TableRowCondition{}.OpenAPIModelName(), runtime.RawExtension{}.OpenAPIModelName()}, } } @@ -20898,7 +20881,7 @@ func schema_pkg_apis_meta_v1_WatchEvent(ref common.ReferenceCallback) common.Ope "object": { SchemaProps: spec.SchemaProps{ Description: "Object is:\n * If Type is Added or Modified: the new state of the object.\n * If Type is Deleted: the state of the object immediately before deletion.\n * If Type is Error: *Status is recommended; other types may make sense\n depending on context.", - Ref: ref("k8s.io/apimachinery/pkg/runtime.RawExtension"), + Ref: ref(runtime.RawExtension{}.OpenAPIModelName()), }, }, }, @@ -20906,7 +20889,7 @@ func schema_pkg_apis_meta_v1_WatchEvent(ref common.ReferenceCallback) common.Ope }, }, Dependencies: []string{ - "k8s.io/apimachinery/pkg/runtime.RawExtension"}, + runtime.RawExtension{}.OpenAPIModelName()}, } } From a4b06d4c05eac01cf3a51d13efe3fc1b0921442a Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Wed, 18 Feb 2026 16:59:59 +0100 Subject: [PATCH 019/135] updated openapigen --- pkg/generated/openapi/zz_generated.openapi.go | 19883 +--------------- tools/apiserver-runtime-gen/main.go | 4 +- 2 files changed, 69 insertions(+), 19818 deletions(-) diff --git a/pkg/generated/openapi/zz_generated.openapi.go b/pkg/generated/openapi/zz_generated.openapi.go index 5d3b215d..c6b6eaf2 100644 --- a/pkg/generated/openapi/zz_generated.openapi.go +++ b/pkg/generated/openapi/zz_generated.openapi.go @@ -21,520 +21,43 @@ limitations under the License. package openapi import ( - v1 "k8s.io/api/core/v1" - resource "k8s.io/apimachinery/pkg/api/resource" - metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" - runtime "k8s.io/apimachinery/pkg/runtime" - version "k8s.io/apimachinery/pkg/version" common "k8s.io/kube-openapi/pkg/common" spec "k8s.io/kube-openapi/pkg/validation/spec" ) func GetOpenAPIDefinitions(ref common.ReferenceCallback) map[string]common.OpenAPIDefinition { return map[string]common.OpenAPIDefinition{ - "github.com/sdcio/config-server/apis/condition/v1alpha1.Condition": schema_config_server_apis_condition_v1alpha1_Condition(ref), - "github.com/sdcio/config-server/apis/condition/v1alpha1.ConditionedStatus": schema_config_server_apis_condition_v1alpha1_ConditionedStatus(ref), - "github.com/sdcio/config-server/apis/condition/v1alpha1.UnrecoverableMessage": schema_config_server_apis_condition_v1alpha1_UnrecoverableMessage(ref), - "github.com/sdcio/config-server/apis/config/v1alpha1.Config": schema_config_server_apis_config_v1alpha1_Config(ref), - "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigBlame": schema_config_server_apis_config_v1alpha1_ConfigBlame(ref), - "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigBlameList": schema_config_server_apis_config_v1alpha1_ConfigBlameList(ref), - "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigBlameSpec": schema_config_server_apis_config_v1alpha1_ConfigBlameSpec(ref), - "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigBlameStatus": schema_config_server_apis_config_v1alpha1_ConfigBlameStatus(ref), - "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigBlob": schema_config_server_apis_config_v1alpha1_ConfigBlob(ref), - "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigDeviation": schema_config_server_apis_config_v1alpha1_ConfigDeviation(ref), - "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigList": schema_config_server_apis_config_v1alpha1_ConfigList(ref), - "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigSet": schema_config_server_apis_config_v1alpha1_ConfigSet(ref), - "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigSetList": schema_config_server_apis_config_v1alpha1_ConfigSetList(ref), - "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigSetSpec": schema_config_server_apis_config_v1alpha1_ConfigSetSpec(ref), - "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigSetStatus": schema_config_server_apis_config_v1alpha1_ConfigSetStatus(ref), - "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigSpec": schema_config_server_apis_config_v1alpha1_ConfigSpec(ref), - "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigStatus": schema_config_server_apis_config_v1alpha1_ConfigStatus(ref), - "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigStatusLastKnownGoodSchema": schema_config_server_apis_config_v1alpha1_ConfigStatusLastKnownGoodSchema(ref), - "github.com/sdcio/config-server/apis/config/v1alpha1.Deviation": schema_config_server_apis_config_v1alpha1_Deviation(ref), - "github.com/sdcio/config-server/apis/config/v1alpha1.DeviationList": schema_config_server_apis_config_v1alpha1_DeviationList(ref), - "github.com/sdcio/config-server/apis/config/v1alpha1.DeviationSpec": schema_config_server_apis_config_v1alpha1_DeviationSpec(ref), - "github.com/sdcio/config-server/apis/config/v1alpha1.DeviationStatus": schema_config_server_apis_config_v1alpha1_DeviationStatus(ref), - "github.com/sdcio/config-server/apis/config/v1alpha1.Lifecycle": schema_config_server_apis_config_v1alpha1_Lifecycle(ref), - "github.com/sdcio/config-server/apis/config/v1alpha1.RunningConfig": schema_config_server_apis_config_v1alpha1_RunningConfig(ref), - "github.com/sdcio/config-server/apis/config/v1alpha1.RunningConfigList": schema_config_server_apis_config_v1alpha1_RunningConfigList(ref), - "github.com/sdcio/config-server/apis/config/v1alpha1.RunningConfigSpec": schema_config_server_apis_config_v1alpha1_RunningConfigSpec(ref), - "github.com/sdcio/config-server/apis/config/v1alpha1.RunningConfigStatus": schema_config_server_apis_config_v1alpha1_RunningConfigStatus(ref), - "github.com/sdcio/config-server/apis/config/v1alpha1.SensitiveConfig": schema_config_server_apis_config_v1alpha1_SensitiveConfig(ref), - "github.com/sdcio/config-server/apis/config/v1alpha1.SensitiveConfigData": schema_config_server_apis_config_v1alpha1_SensitiveConfigData(ref), - "github.com/sdcio/config-server/apis/config/v1alpha1.SensitiveConfigList": schema_config_server_apis_config_v1alpha1_SensitiveConfigList(ref), - "github.com/sdcio/config-server/apis/config/v1alpha1.SensitiveConfigSpec": schema_config_server_apis_config_v1alpha1_SensitiveConfigSpec(ref), - "github.com/sdcio/config-server/apis/config/v1alpha1.SensitiveConfigStatus": schema_config_server_apis_config_v1alpha1_SensitiveConfigStatus(ref), - "github.com/sdcio/config-server/apis/config/v1alpha1.Target": schema_config_server_apis_config_v1alpha1_Target(ref), - "github.com/sdcio/config-server/apis/config/v1alpha1.TargetStatus": schema_config_server_apis_config_v1alpha1_TargetStatus(ref), - "github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryInfo": schema_config_server_apis_inv_v1alpha1_DiscoveryInfo(ref), - "github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryParameters": schema_config_server_apis_inv_v1alpha1_DiscoveryParameters(ref), - "github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryPathDefinition": schema_config_server_apis_inv_v1alpha1_DiscoveryPathDefinition(ref), - "github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryProfile": schema_config_server_apis_inv_v1alpha1_DiscoveryProfile(ref), - "github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryRule": schema_config_server_apis_inv_v1alpha1_DiscoveryRule(ref), - "github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryRuleAddress": schema_config_server_apis_inv_v1alpha1_DiscoveryRuleAddress(ref), - "github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryRuleList": schema_config_server_apis_inv_v1alpha1_DiscoveryRuleList(ref), - "github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryRulePrefix": schema_config_server_apis_inv_v1alpha1_DiscoveryRulePrefix(ref), - "github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryRuleSpec": schema_config_server_apis_inv_v1alpha1_DiscoveryRuleSpec(ref), - "github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryRuleStatus": schema_config_server_apis_inv_v1alpha1_DiscoveryRuleStatus(ref), - "github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryVendorProfile": schema_config_server_apis_inv_v1alpha1_DiscoveryVendorProfile(ref), - "github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryVendorProfileList": schema_config_server_apis_inv_v1alpha1_DiscoveryVendorProfileList(ref), - "github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryVendorProfileSpec": schema_config_server_apis_inv_v1alpha1_DiscoveryVendorProfileSpec(ref), - "github.com/sdcio/config-server/apis/inv/v1alpha1.GnmiDiscoveryVendorProfileParameters": schema_config_server_apis_inv_v1alpha1_GnmiDiscoveryVendorProfileParameters(ref), - "github.com/sdcio/config-server/apis/inv/v1alpha1.Proxy": schema_config_server_apis_inv_v1alpha1_Proxy(ref), - "github.com/sdcio/config-server/apis/inv/v1alpha1.Repository": schema_config_server_apis_inv_v1alpha1_Repository(ref), - "github.com/sdcio/config-server/apis/inv/v1alpha1.Rollout": schema_config_server_apis_inv_v1alpha1_Rollout(ref), - "github.com/sdcio/config-server/apis/inv/v1alpha1.RolloutList": schema_config_server_apis_inv_v1alpha1_RolloutList(ref), - "github.com/sdcio/config-server/apis/inv/v1alpha1.RolloutSpec": schema_config_server_apis_inv_v1alpha1_RolloutSpec(ref), - "github.com/sdcio/config-server/apis/inv/v1alpha1.RolloutStatus": schema_config_server_apis_inv_v1alpha1_RolloutStatus(ref), - "github.com/sdcio/config-server/apis/inv/v1alpha1.RolloutTargetStatus": schema_config_server_apis_inv_v1alpha1_RolloutTargetStatus(ref), - "github.com/sdcio/config-server/apis/inv/v1alpha1.Schema": schema_config_server_apis_inv_v1alpha1_Schema(ref), - "github.com/sdcio/config-server/apis/inv/v1alpha1.SchemaKey": schema_config_server_apis_inv_v1alpha1_SchemaKey(ref), - "github.com/sdcio/config-server/apis/inv/v1alpha1.SchemaList": schema_config_server_apis_inv_v1alpha1_SchemaList(ref), - "github.com/sdcio/config-server/apis/inv/v1alpha1.SchemaRepositoryStatus": schema_config_server_apis_inv_v1alpha1_SchemaRepositoryStatus(ref), - "github.com/sdcio/config-server/apis/inv/v1alpha1.SchemaSpec": schema_config_server_apis_inv_v1alpha1_SchemaSpec(ref), - "github.com/sdcio/config-server/apis/inv/v1alpha1.SchemaSpecRepository": schema_config_server_apis_inv_v1alpha1_SchemaSpecRepository(ref), - "github.com/sdcio/config-server/apis/inv/v1alpha1.SchemaSpecSchema": schema_config_server_apis_inv_v1alpha1_SchemaSpecSchema(ref), - "github.com/sdcio/config-server/apis/inv/v1alpha1.SchemaStatus": schema_config_server_apis_inv_v1alpha1_SchemaStatus(ref), - "github.com/sdcio/config-server/apis/inv/v1alpha1.SrcDstPath": schema_config_server_apis_inv_v1alpha1_SrcDstPath(ref), - "github.com/sdcio/config-server/apis/inv/v1alpha1.Subscription": schema_config_server_apis_inv_v1alpha1_Subscription(ref), - "github.com/sdcio/config-server/apis/inv/v1alpha1.SubscriptionList": schema_config_server_apis_inv_v1alpha1_SubscriptionList(ref), - "github.com/sdcio/config-server/apis/inv/v1alpha1.SubscriptionParameters": schema_config_server_apis_inv_v1alpha1_SubscriptionParameters(ref), - "github.com/sdcio/config-server/apis/inv/v1alpha1.SubscriptionSpec": schema_config_server_apis_inv_v1alpha1_SubscriptionSpec(ref), - "github.com/sdcio/config-server/apis/inv/v1alpha1.SubscriptionStatus": schema_config_server_apis_inv_v1alpha1_SubscriptionStatus(ref), - "github.com/sdcio/config-server/apis/inv/v1alpha1.SubscriptionTarget": schema_config_server_apis_inv_v1alpha1_SubscriptionTarget(ref), - "github.com/sdcio/config-server/apis/inv/v1alpha1.Target": schema_config_server_apis_inv_v1alpha1_Target(ref), - "github.com/sdcio/config-server/apis/inv/v1alpha1.TargetConnectionProfile": schema_config_server_apis_inv_v1alpha1_TargetConnectionProfile(ref), - "github.com/sdcio/config-server/apis/inv/v1alpha1.TargetConnectionProfileList": schema_config_server_apis_inv_v1alpha1_TargetConnectionProfileList(ref), - "github.com/sdcio/config-server/apis/inv/v1alpha1.TargetConnectionProfileSpec": schema_config_server_apis_inv_v1alpha1_TargetConnectionProfileSpec(ref), - "github.com/sdcio/config-server/apis/inv/v1alpha1.TargetList": schema_config_server_apis_inv_v1alpha1_TargetList(ref), - "github.com/sdcio/config-server/apis/inv/v1alpha1.TargetProfile": schema_config_server_apis_inv_v1alpha1_TargetProfile(ref), - "github.com/sdcio/config-server/apis/inv/v1alpha1.TargetSpec": schema_config_server_apis_inv_v1alpha1_TargetSpec(ref), - "github.com/sdcio/config-server/apis/inv/v1alpha1.TargetStatus": schema_config_server_apis_inv_v1alpha1_TargetStatus(ref), - "github.com/sdcio/config-server/apis/inv/v1alpha1.TargetStatusUsedReferences": schema_config_server_apis_inv_v1alpha1_TargetStatusUsedReferences(ref), - "github.com/sdcio/config-server/apis/inv/v1alpha1.TargetSyncProfile": schema_config_server_apis_inv_v1alpha1_TargetSyncProfile(ref), - "github.com/sdcio/config-server/apis/inv/v1alpha1.TargetSyncProfileList": schema_config_server_apis_inv_v1alpha1_TargetSyncProfileList(ref), - "github.com/sdcio/config-server/apis/inv/v1alpha1.TargetSyncProfileSpec": schema_config_server_apis_inv_v1alpha1_TargetSyncProfileSpec(ref), - "github.com/sdcio/config-server/apis/inv/v1alpha1.TargetSyncProfileSync": schema_config_server_apis_inv_v1alpha1_TargetSyncProfileSync(ref), - "github.com/sdcio/config-server/apis/inv/v1alpha1.TargetTemplate": schema_config_server_apis_inv_v1alpha1_TargetTemplate(ref), - "github.com/sdcio/config-server/apis/inv/v1alpha1.Workspace": schema_config_server_apis_inv_v1alpha1_Workspace(ref), - "github.com/sdcio/config-server/apis/inv/v1alpha1.WorkspaceList": schema_config_server_apis_inv_v1alpha1_WorkspaceList(ref), - "github.com/sdcio/config-server/apis/inv/v1alpha1.WorkspaceSpec": schema_config_server_apis_inv_v1alpha1_WorkspaceSpec(ref), - "github.com/sdcio/config-server/apis/inv/v1alpha1.WorkspaceStatus": schema_config_server_apis_inv_v1alpha1_WorkspaceStatus(ref), - v1.AWSElasticBlockStoreVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_AWSElasticBlockStoreVolumeSource(ref), - v1.Affinity{}.OpenAPIModelName(): schema_k8sio_api_core_v1_Affinity(ref), - v1.AppArmorProfile{}.OpenAPIModelName(): schema_k8sio_api_core_v1_AppArmorProfile(ref), - v1.AttachedVolume{}.OpenAPIModelName(): schema_k8sio_api_core_v1_AttachedVolume(ref), - v1.AvoidPods{}.OpenAPIModelName(): schema_k8sio_api_core_v1_AvoidPods(ref), - v1.AzureDiskVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_AzureDiskVolumeSource(ref), - v1.AzureFilePersistentVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_AzureFilePersistentVolumeSource(ref), - v1.AzureFileVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_AzureFileVolumeSource(ref), - v1.Binding{}.OpenAPIModelName(): schema_k8sio_api_core_v1_Binding(ref), - v1.CSIPersistentVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_CSIPersistentVolumeSource(ref), - v1.CSIVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_CSIVolumeSource(ref), - v1.Capabilities{}.OpenAPIModelName(): schema_k8sio_api_core_v1_Capabilities(ref), - v1.CephFSPersistentVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_CephFSPersistentVolumeSource(ref), - v1.CephFSVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_CephFSVolumeSource(ref), - v1.CinderPersistentVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_CinderPersistentVolumeSource(ref), - v1.CinderVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_CinderVolumeSource(ref), - v1.ClientIPConfig{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ClientIPConfig(ref), - v1.ClusterTrustBundleProjection{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ClusterTrustBundleProjection(ref), - v1.ComponentCondition{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ComponentCondition(ref), - v1.ComponentStatus{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ComponentStatus(ref), - v1.ComponentStatusList{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ComponentStatusList(ref), - v1.ConfigMap{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ConfigMap(ref), - v1.ConfigMapEnvSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ConfigMapEnvSource(ref), - v1.ConfigMapKeySelector{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ConfigMapKeySelector(ref), - v1.ConfigMapList{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ConfigMapList(ref), - v1.ConfigMapNodeConfigSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ConfigMapNodeConfigSource(ref), - v1.ConfigMapProjection{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ConfigMapProjection(ref), - v1.ConfigMapVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ConfigMapVolumeSource(ref), - v1.Container{}.OpenAPIModelName(): schema_k8sio_api_core_v1_Container(ref), - v1.ContainerExtendedResourceRequest{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ContainerExtendedResourceRequest(ref), - v1.ContainerImage{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ContainerImage(ref), - v1.ContainerPort{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ContainerPort(ref), - v1.ContainerResizePolicy{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ContainerResizePolicy(ref), - v1.ContainerRestartRule{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ContainerRestartRule(ref), - v1.ContainerRestartRuleOnExitCodes{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ContainerRestartRuleOnExitCodes(ref), - v1.ContainerState{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ContainerState(ref), - v1.ContainerStateRunning{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ContainerStateRunning(ref), - v1.ContainerStateTerminated{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ContainerStateTerminated(ref), - v1.ContainerStateWaiting{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ContainerStateWaiting(ref), - v1.ContainerStatus{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ContainerStatus(ref), - v1.ContainerUser{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ContainerUser(ref), - v1.DaemonEndpoint{}.OpenAPIModelName(): schema_k8sio_api_core_v1_DaemonEndpoint(ref), - v1.DownwardAPIProjection{}.OpenAPIModelName(): schema_k8sio_api_core_v1_DownwardAPIProjection(ref), - v1.DownwardAPIVolumeFile{}.OpenAPIModelName(): schema_k8sio_api_core_v1_DownwardAPIVolumeFile(ref), - v1.DownwardAPIVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_DownwardAPIVolumeSource(ref), - v1.EmptyDirVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_EmptyDirVolumeSource(ref), - v1.EndpointAddress{}.OpenAPIModelName(): schema_k8sio_api_core_v1_EndpointAddress(ref), - v1.EndpointPort{}.OpenAPIModelName(): schema_k8sio_api_core_v1_EndpointPort(ref), - v1.EndpointSubset{}.OpenAPIModelName(): schema_k8sio_api_core_v1_EndpointSubset(ref), - v1.Endpoints{}.OpenAPIModelName(): schema_k8sio_api_core_v1_Endpoints(ref), - v1.EndpointsList{}.OpenAPIModelName(): schema_k8sio_api_core_v1_EndpointsList(ref), - v1.EnvFromSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_EnvFromSource(ref), - v1.EnvVar{}.OpenAPIModelName(): schema_k8sio_api_core_v1_EnvVar(ref), - v1.EnvVarSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_EnvVarSource(ref), - v1.EphemeralContainer{}.OpenAPIModelName(): schema_k8sio_api_core_v1_EphemeralContainer(ref), - v1.EphemeralContainerCommon{}.OpenAPIModelName(): schema_k8sio_api_core_v1_EphemeralContainerCommon(ref), - v1.EphemeralVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_EphemeralVolumeSource(ref), - v1.Event{}.OpenAPIModelName(): schema_k8sio_api_core_v1_Event(ref), - v1.EventList{}.OpenAPIModelName(): schema_k8sio_api_core_v1_EventList(ref), - v1.EventSeries{}.OpenAPIModelName(): schema_k8sio_api_core_v1_EventSeries(ref), - v1.EventSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_EventSource(ref), - v1.ExecAction{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ExecAction(ref), - v1.FCVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_FCVolumeSource(ref), - v1.FileKeySelector{}.OpenAPIModelName(): schema_k8sio_api_core_v1_FileKeySelector(ref), - v1.FlexPersistentVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_FlexPersistentVolumeSource(ref), - v1.FlexVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_FlexVolumeSource(ref), - v1.FlockerVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_FlockerVolumeSource(ref), - v1.GCEPersistentDiskVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_GCEPersistentDiskVolumeSource(ref), - v1.GRPCAction{}.OpenAPIModelName(): schema_k8sio_api_core_v1_GRPCAction(ref), - v1.GitRepoVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_GitRepoVolumeSource(ref), - v1.GlusterfsPersistentVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_GlusterfsPersistentVolumeSource(ref), - v1.GlusterfsVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_GlusterfsVolumeSource(ref), - v1.HTTPGetAction{}.OpenAPIModelName(): schema_k8sio_api_core_v1_HTTPGetAction(ref), - v1.HTTPHeader{}.OpenAPIModelName(): schema_k8sio_api_core_v1_HTTPHeader(ref), - v1.HostAlias{}.OpenAPIModelName(): schema_k8sio_api_core_v1_HostAlias(ref), - v1.HostIP{}.OpenAPIModelName(): schema_k8sio_api_core_v1_HostIP(ref), - v1.HostPathVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_HostPathVolumeSource(ref), - v1.ISCSIPersistentVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ISCSIPersistentVolumeSource(ref), - v1.ISCSIVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ISCSIVolumeSource(ref), - v1.ImageVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ImageVolumeSource(ref), - v1.KeyToPath{}.OpenAPIModelName(): schema_k8sio_api_core_v1_KeyToPath(ref), - v1.Lifecycle{}.OpenAPIModelName(): schema_k8sio_api_core_v1_Lifecycle(ref), - v1.LifecycleHandler{}.OpenAPIModelName(): schema_k8sio_api_core_v1_LifecycleHandler(ref), - v1.LimitRange{}.OpenAPIModelName(): schema_k8sio_api_core_v1_LimitRange(ref), - v1.LimitRangeItem{}.OpenAPIModelName(): schema_k8sio_api_core_v1_LimitRangeItem(ref), - v1.LimitRangeList{}.OpenAPIModelName(): schema_k8sio_api_core_v1_LimitRangeList(ref), - v1.LimitRangeSpec{}.OpenAPIModelName(): schema_k8sio_api_core_v1_LimitRangeSpec(ref), - v1.LinuxContainerUser{}.OpenAPIModelName(): schema_k8sio_api_core_v1_LinuxContainerUser(ref), - v1.List{}.OpenAPIModelName(): schema_k8sio_api_core_v1_List(ref), - v1.LoadBalancerIngress{}.OpenAPIModelName(): schema_k8sio_api_core_v1_LoadBalancerIngress(ref), - v1.LoadBalancerStatus{}.OpenAPIModelName(): schema_k8sio_api_core_v1_LoadBalancerStatus(ref), - v1.LocalObjectReference{}.OpenAPIModelName(): schema_k8sio_api_core_v1_LocalObjectReference(ref), - v1.LocalVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_LocalVolumeSource(ref), - v1.ModifyVolumeStatus{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ModifyVolumeStatus(ref), - v1.NFSVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_NFSVolumeSource(ref), - v1.Namespace{}.OpenAPIModelName(): schema_k8sio_api_core_v1_Namespace(ref), - v1.NamespaceCondition{}.OpenAPIModelName(): schema_k8sio_api_core_v1_NamespaceCondition(ref), - v1.NamespaceList{}.OpenAPIModelName(): schema_k8sio_api_core_v1_NamespaceList(ref), - v1.NamespaceSpec{}.OpenAPIModelName(): schema_k8sio_api_core_v1_NamespaceSpec(ref), - v1.NamespaceStatus{}.OpenAPIModelName(): schema_k8sio_api_core_v1_NamespaceStatus(ref), - v1.Node{}.OpenAPIModelName(): schema_k8sio_api_core_v1_Node(ref), - v1.NodeAddress{}.OpenAPIModelName(): schema_k8sio_api_core_v1_NodeAddress(ref), - v1.NodeAffinity{}.OpenAPIModelName(): schema_k8sio_api_core_v1_NodeAffinity(ref), - v1.NodeCondition{}.OpenAPIModelName(): schema_k8sio_api_core_v1_NodeCondition(ref), - v1.NodeConfigSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_NodeConfigSource(ref), - v1.NodeConfigStatus{}.OpenAPIModelName(): schema_k8sio_api_core_v1_NodeConfigStatus(ref), - v1.NodeDaemonEndpoints{}.OpenAPIModelName(): schema_k8sio_api_core_v1_NodeDaemonEndpoints(ref), - v1.NodeFeatures{}.OpenAPIModelName(): schema_k8sio_api_core_v1_NodeFeatures(ref), - v1.NodeList{}.OpenAPIModelName(): schema_k8sio_api_core_v1_NodeList(ref), - v1.NodeProxyOptions{}.OpenAPIModelName(): schema_k8sio_api_core_v1_NodeProxyOptions(ref), - v1.NodeRuntimeHandler{}.OpenAPIModelName(): schema_k8sio_api_core_v1_NodeRuntimeHandler(ref), - v1.NodeRuntimeHandlerFeatures{}.OpenAPIModelName(): schema_k8sio_api_core_v1_NodeRuntimeHandlerFeatures(ref), - v1.NodeSelector{}.OpenAPIModelName(): schema_k8sio_api_core_v1_NodeSelector(ref), - v1.NodeSelectorRequirement{}.OpenAPIModelName(): schema_k8sio_api_core_v1_NodeSelectorRequirement(ref), - v1.NodeSelectorTerm{}.OpenAPIModelName(): schema_k8sio_api_core_v1_NodeSelectorTerm(ref), - v1.NodeSpec{}.OpenAPIModelName(): schema_k8sio_api_core_v1_NodeSpec(ref), - v1.NodeStatus{}.OpenAPIModelName(): schema_k8sio_api_core_v1_NodeStatus(ref), - v1.NodeSwapStatus{}.OpenAPIModelName(): schema_k8sio_api_core_v1_NodeSwapStatus(ref), - v1.NodeSystemInfo{}.OpenAPIModelName(): schema_k8sio_api_core_v1_NodeSystemInfo(ref), - v1.ObjectFieldSelector{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ObjectFieldSelector(ref), - v1.ObjectReference{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ObjectReference(ref), - v1.PersistentVolume{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PersistentVolume(ref), - v1.PersistentVolumeClaim{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PersistentVolumeClaim(ref), - v1.PersistentVolumeClaimCondition{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PersistentVolumeClaimCondition(ref), - v1.PersistentVolumeClaimList{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PersistentVolumeClaimList(ref), - v1.PersistentVolumeClaimSpec{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PersistentVolumeClaimSpec(ref), - v1.PersistentVolumeClaimStatus{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PersistentVolumeClaimStatus(ref), - v1.PersistentVolumeClaimTemplate{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PersistentVolumeClaimTemplate(ref), - v1.PersistentVolumeClaimVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PersistentVolumeClaimVolumeSource(ref), - v1.PersistentVolumeList{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PersistentVolumeList(ref), - v1.PersistentVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PersistentVolumeSource(ref), - v1.PersistentVolumeSpec{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PersistentVolumeSpec(ref), - v1.PersistentVolumeStatus{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PersistentVolumeStatus(ref), - v1.PhotonPersistentDiskVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PhotonPersistentDiskVolumeSource(ref), - v1.Pod{}.OpenAPIModelName(): schema_k8sio_api_core_v1_Pod(ref), - v1.PodAffinity{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PodAffinity(ref), - v1.PodAffinityTerm{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PodAffinityTerm(ref), - v1.PodAntiAffinity{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PodAntiAffinity(ref), - v1.PodAttachOptions{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PodAttachOptions(ref), - v1.PodCertificateProjection{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PodCertificateProjection(ref), - v1.PodCondition{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PodCondition(ref), - v1.PodDNSConfig{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PodDNSConfig(ref), - v1.PodDNSConfigOption{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PodDNSConfigOption(ref), - v1.PodExecOptions{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PodExecOptions(ref), - v1.PodExtendedResourceClaimStatus{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PodExtendedResourceClaimStatus(ref), - v1.PodIP{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PodIP(ref), - v1.PodList{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PodList(ref), - v1.PodLogOptions{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PodLogOptions(ref), - v1.PodOS{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PodOS(ref), - v1.PodPortForwardOptions{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PodPortForwardOptions(ref), - v1.PodProxyOptions{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PodProxyOptions(ref), - v1.PodReadinessGate{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PodReadinessGate(ref), - v1.PodResourceClaim{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PodResourceClaim(ref), - v1.PodResourceClaimStatus{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PodResourceClaimStatus(ref), - v1.PodSchedulingGate{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PodSchedulingGate(ref), - v1.PodSecurityContext{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PodSecurityContext(ref), - v1.PodSignature{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PodSignature(ref), - v1.PodSpec{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PodSpec(ref), - v1.PodStatus{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PodStatus(ref), - v1.PodStatusResult{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PodStatusResult(ref), - v1.PodTemplate{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PodTemplate(ref), - v1.PodTemplateList{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PodTemplateList(ref), - v1.PodTemplateSpec{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PodTemplateSpec(ref), - v1.PortStatus{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PortStatus(ref), - v1.PortworxVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PortworxVolumeSource(ref), - v1.PreferAvoidPodsEntry{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PreferAvoidPodsEntry(ref), - v1.PreferredSchedulingTerm{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PreferredSchedulingTerm(ref), - v1.Probe{}.OpenAPIModelName(): schema_k8sio_api_core_v1_Probe(ref), - v1.ProbeHandler{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ProbeHandler(ref), - v1.ProjectedVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ProjectedVolumeSource(ref), - v1.QuobyteVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_QuobyteVolumeSource(ref), - v1.RBDPersistentVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_RBDPersistentVolumeSource(ref), - v1.RBDVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_RBDVolumeSource(ref), - v1.RangeAllocation{}.OpenAPIModelName(): schema_k8sio_api_core_v1_RangeAllocation(ref), - v1.ReplicationController{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ReplicationController(ref), - v1.ReplicationControllerCondition{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ReplicationControllerCondition(ref), - v1.ReplicationControllerList{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ReplicationControllerList(ref), - v1.ReplicationControllerSpec{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ReplicationControllerSpec(ref), - v1.ReplicationControllerStatus{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ReplicationControllerStatus(ref), - v1.ResourceClaim{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ResourceClaim(ref), - v1.ResourceFieldSelector{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ResourceFieldSelector(ref), - v1.ResourceHealth{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ResourceHealth(ref), - v1.ResourceQuota{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ResourceQuota(ref), - v1.ResourceQuotaList{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ResourceQuotaList(ref), - v1.ResourceQuotaSpec{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ResourceQuotaSpec(ref), - v1.ResourceQuotaStatus{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ResourceQuotaStatus(ref), - v1.ResourceRequirements{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ResourceRequirements(ref), - v1.ResourceStatus{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ResourceStatus(ref), - v1.SELinuxOptions{}.OpenAPIModelName(): schema_k8sio_api_core_v1_SELinuxOptions(ref), - v1.ScaleIOPersistentVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ScaleIOPersistentVolumeSource(ref), - v1.ScaleIOVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ScaleIOVolumeSource(ref), - v1.ScopeSelector{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ScopeSelector(ref), - v1.ScopedResourceSelectorRequirement{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ScopedResourceSelectorRequirement(ref), - v1.SeccompProfile{}.OpenAPIModelName(): schema_k8sio_api_core_v1_SeccompProfile(ref), - v1.Secret{}.OpenAPIModelName(): schema_k8sio_api_core_v1_Secret(ref), - v1.SecretEnvSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_SecretEnvSource(ref), - v1.SecretKeySelector{}.OpenAPIModelName(): schema_k8sio_api_core_v1_SecretKeySelector(ref), - v1.SecretList{}.OpenAPIModelName(): schema_k8sio_api_core_v1_SecretList(ref), - v1.SecretProjection{}.OpenAPIModelName(): schema_k8sio_api_core_v1_SecretProjection(ref), - v1.SecretReference{}.OpenAPIModelName(): schema_k8sio_api_core_v1_SecretReference(ref), - v1.SecretVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_SecretVolumeSource(ref), - v1.SecurityContext{}.OpenAPIModelName(): schema_k8sio_api_core_v1_SecurityContext(ref), - v1.SerializedReference{}.OpenAPIModelName(): schema_k8sio_api_core_v1_SerializedReference(ref), - v1.Service{}.OpenAPIModelName(): schema_k8sio_api_core_v1_Service(ref), - v1.ServiceAccount{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ServiceAccount(ref), - v1.ServiceAccountList{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ServiceAccountList(ref), - v1.ServiceAccountTokenProjection{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ServiceAccountTokenProjection(ref), - v1.ServiceList{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ServiceList(ref), - v1.ServicePort{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ServicePort(ref), - v1.ServiceProxyOptions{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ServiceProxyOptions(ref), - v1.ServiceSpec{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ServiceSpec(ref), - v1.ServiceStatus{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ServiceStatus(ref), - v1.SessionAffinityConfig{}.OpenAPIModelName(): schema_k8sio_api_core_v1_SessionAffinityConfig(ref), - v1.SleepAction{}.OpenAPIModelName(): schema_k8sio_api_core_v1_SleepAction(ref), - v1.StorageOSPersistentVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_StorageOSPersistentVolumeSource(ref), - v1.StorageOSVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_StorageOSVolumeSource(ref), - v1.Sysctl{}.OpenAPIModelName(): schema_k8sio_api_core_v1_Sysctl(ref), - v1.TCPSocketAction{}.OpenAPIModelName(): schema_k8sio_api_core_v1_TCPSocketAction(ref), - v1.Taint{}.OpenAPIModelName(): schema_k8sio_api_core_v1_Taint(ref), - v1.Toleration{}.OpenAPIModelName(): schema_k8sio_api_core_v1_Toleration(ref), - v1.TopologySelectorLabelRequirement{}.OpenAPIModelName(): schema_k8sio_api_core_v1_TopologySelectorLabelRequirement(ref), - v1.TopologySelectorTerm{}.OpenAPIModelName(): schema_k8sio_api_core_v1_TopologySelectorTerm(ref), - v1.TopologySpreadConstraint{}.OpenAPIModelName(): schema_k8sio_api_core_v1_TopologySpreadConstraint(ref), - v1.TypedLocalObjectReference{}.OpenAPIModelName(): schema_k8sio_api_core_v1_TypedLocalObjectReference(ref), - v1.TypedObjectReference{}.OpenAPIModelName(): schema_k8sio_api_core_v1_TypedObjectReference(ref), - v1.Volume{}.OpenAPIModelName(): schema_k8sio_api_core_v1_Volume(ref), - v1.VolumeDevice{}.OpenAPIModelName(): schema_k8sio_api_core_v1_VolumeDevice(ref), - v1.VolumeMount{}.OpenAPIModelName(): schema_k8sio_api_core_v1_VolumeMount(ref), - v1.VolumeMountStatus{}.OpenAPIModelName(): schema_k8sio_api_core_v1_VolumeMountStatus(ref), - v1.VolumeNodeAffinity{}.OpenAPIModelName(): schema_k8sio_api_core_v1_VolumeNodeAffinity(ref), - v1.VolumeProjection{}.OpenAPIModelName(): schema_k8sio_api_core_v1_VolumeProjection(ref), - v1.VolumeResourceRequirements{}.OpenAPIModelName(): schema_k8sio_api_core_v1_VolumeResourceRequirements(ref), - v1.VolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_VolumeSource(ref), - v1.VsphereVirtualDiskVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_VsphereVirtualDiskVolumeSource(ref), - v1.WeightedPodAffinityTerm{}.OpenAPIModelName(): schema_k8sio_api_core_v1_WeightedPodAffinityTerm(ref), - v1.WindowsSecurityContextOptions{}.OpenAPIModelName(): schema_k8sio_api_core_v1_WindowsSecurityContextOptions(ref), - v1.WorkloadReference{}.OpenAPIModelName(): schema_k8sio_api_core_v1_WorkloadReference(ref), - resource.Quantity{}.OpenAPIModelName(): schema_apimachinery_pkg_api_resource_Quantity(ref), - metav1.APIGroup{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_APIGroup(ref), - metav1.APIGroupList{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_APIGroupList(ref), - metav1.APIResource{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_APIResource(ref), - metav1.APIResourceList{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_APIResourceList(ref), - metav1.APIVersions{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_APIVersions(ref), - metav1.ApplyOptions{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_ApplyOptions(ref), - metav1.Condition{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_Condition(ref), - metav1.CreateOptions{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_CreateOptions(ref), - metav1.DeleteOptions{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_DeleteOptions(ref), - metav1.Duration{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_Duration(ref), - metav1.FieldSelectorRequirement{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_FieldSelectorRequirement(ref), - metav1.FieldsV1{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_FieldsV1(ref), - metav1.GetOptions{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_GetOptions(ref), - metav1.GroupKind{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_GroupKind(ref), - metav1.GroupResource{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_GroupResource(ref), - metav1.GroupVersion{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_GroupVersion(ref), - metav1.GroupVersionForDiscovery{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_GroupVersionForDiscovery(ref), - metav1.GroupVersionKind{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_GroupVersionKind(ref), - metav1.GroupVersionResource{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_GroupVersionResource(ref), - metav1.InternalEvent{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_InternalEvent(ref), - metav1.LabelSelector{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_LabelSelector(ref), - metav1.LabelSelectorRequirement{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_LabelSelectorRequirement(ref), - metav1.List{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_List(ref), - metav1.ListMeta{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_ListMeta(ref), - metav1.ListOptions{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_ListOptions(ref), - metav1.ManagedFieldsEntry{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_ManagedFieldsEntry(ref), - metav1.MicroTime{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_MicroTime(ref), - metav1.ObjectMeta{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_ObjectMeta(ref), - metav1.OwnerReference{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_OwnerReference(ref), - metav1.PartialObjectMetadata{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_PartialObjectMetadata(ref), - metav1.PartialObjectMetadataList{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_PartialObjectMetadataList(ref), - metav1.Patch{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_Patch(ref), - metav1.PatchOptions{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_PatchOptions(ref), - metav1.Preconditions{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_Preconditions(ref), - metav1.RootPaths{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_RootPaths(ref), - metav1.ServerAddressByClientCIDR{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_ServerAddressByClientCIDR(ref), - metav1.Status{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_Status(ref), - metav1.StatusCause{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_StatusCause(ref), - metav1.StatusDetails{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_StatusDetails(ref), - metav1.Table{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_Table(ref), - metav1.TableColumnDefinition{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_TableColumnDefinition(ref), - metav1.TableOptions{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_TableOptions(ref), - metav1.TableRow{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_TableRow(ref), - metav1.TableRowCondition{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_TableRowCondition(ref), - metav1.Time{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_Time(ref), - metav1.Timestamp{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_Timestamp(ref), - metav1.TypeMeta{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_TypeMeta(ref), - metav1.UpdateOptions{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_UpdateOptions(ref), - metav1.WatchEvent{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_WatchEvent(ref), - runtime.RawExtension{}.OpenAPIModelName(): schema_k8sio_apimachinery_pkg_runtime_RawExtension(ref), - runtime.TypeMeta{}.OpenAPIModelName(): schema_k8sio_apimachinery_pkg_runtime_TypeMeta(ref), - runtime.Unknown{}.OpenAPIModelName(): schema_k8sio_apimachinery_pkg_runtime_Unknown(ref), - version.Info{}.OpenAPIModelName(): schema_k8sio_apimachinery_pkg_version_Info(ref), - } -} - -func schema_config_server_apis_condition_v1alpha1_Condition(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "type": { - SchemaProps: spec.SchemaProps{ - Description: "type of condition in CamelCase or in foo.example.com/CamelCase.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "status": { - SchemaProps: spec.SchemaProps{ - Description: "status of the condition, one of True, False, Unknown.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "observedGeneration": { - SchemaProps: spec.SchemaProps{ - Description: "observedGeneration represents the .metadata.generation that the condition was set based upon. For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date with respect to the current state of the instance.", - Type: []string{"integer"}, - Format: "int64", - }, - }, - "lastTransitionTime": { - SchemaProps: spec.SchemaProps{ - Description: "lastTransitionTime is the last time the condition transitioned from one status to another. This should be when the underlying condition changed. If that is not known, then using the time when the API field changed is acceptable.", - Ref: ref(metav1.Time{}.OpenAPIModelName()), - }, - }, - "reason": { - SchemaProps: spec.SchemaProps{ - Description: "reason contains a programmatic identifier indicating the reason for the condition's last transition. Producers of specific condition types may define expected values and meanings for this field, and whether the values are considered a guaranteed API. The value should be a CamelCase string. This field may not be empty.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "message": { - SchemaProps: spec.SchemaProps{ - Description: "message is a human readable message indicating details about the transition. This may be an empty string.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - Required: []string{"type", "status", "lastTransitionTime", "reason", "message"}, - }, - }, - Dependencies: []string{ - metav1.Time{}.OpenAPIModelName()}, - } -} - -func schema_config_server_apis_condition_v1alpha1_ConditionedStatus(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "A ConditionedStatus reflects the observed status of a resource. Only one condition of each type may exist.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "conditions": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-map-keys": []interface{}{ - "type", - }, - "x-kubernetes-list-type": "map", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "Conditions of the resource.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref("github.com/sdcio/config-server/apis/condition/v1alpha1.Condition"), - }, - }, - }, - }, - }, - }, - }, - }, - Dependencies: []string{ - "github.com/sdcio/config-server/apis/condition/v1alpha1.Condition"}, - } -} - -func schema_config_server_apis_condition_v1alpha1_UnrecoverableMessage(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "resourceVersion": { - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "message": { - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - Required: []string{"resourceVersion", "message"}, - }, - }, + "github.com/sdcio/config-server/apis/config/v1alpha1.Config": schema_config_server_apis_config_v1alpha1_Config(ref), + "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigBlame": schema_config_server_apis_config_v1alpha1_ConfigBlame(ref), + "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigBlameList": schema_config_server_apis_config_v1alpha1_ConfigBlameList(ref), + "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigBlameSpec": schema_config_server_apis_config_v1alpha1_ConfigBlameSpec(ref), + "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigBlameStatus": schema_config_server_apis_config_v1alpha1_ConfigBlameStatus(ref), + "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigBlob": schema_config_server_apis_config_v1alpha1_ConfigBlob(ref), + "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigDeviation": schema_config_server_apis_config_v1alpha1_ConfigDeviation(ref), + "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigList": schema_config_server_apis_config_v1alpha1_ConfigList(ref), + "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigSet": schema_config_server_apis_config_v1alpha1_ConfigSet(ref), + "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigSetList": schema_config_server_apis_config_v1alpha1_ConfigSetList(ref), + "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigSetSpec": schema_config_server_apis_config_v1alpha1_ConfigSetSpec(ref), + "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigSetStatus": schema_config_server_apis_config_v1alpha1_ConfigSetStatus(ref), + "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigSpec": schema_config_server_apis_config_v1alpha1_ConfigSpec(ref), + "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigStatus": schema_config_server_apis_config_v1alpha1_ConfigStatus(ref), + "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigStatusLastKnownGoodSchema": schema_config_server_apis_config_v1alpha1_ConfigStatusLastKnownGoodSchema(ref), + "github.com/sdcio/config-server/apis/config/v1alpha1.Deviation": schema_config_server_apis_config_v1alpha1_Deviation(ref), + "github.com/sdcio/config-server/apis/config/v1alpha1.DeviationList": schema_config_server_apis_config_v1alpha1_DeviationList(ref), + "github.com/sdcio/config-server/apis/config/v1alpha1.DeviationSpec": schema_config_server_apis_config_v1alpha1_DeviationSpec(ref), + "github.com/sdcio/config-server/apis/config/v1alpha1.DeviationStatus": schema_config_server_apis_config_v1alpha1_DeviationStatus(ref), + "github.com/sdcio/config-server/apis/config/v1alpha1.Lifecycle": schema_config_server_apis_config_v1alpha1_Lifecycle(ref), + "github.com/sdcio/config-server/apis/config/v1alpha1.RunningConfig": schema_config_server_apis_config_v1alpha1_RunningConfig(ref), + "github.com/sdcio/config-server/apis/config/v1alpha1.RunningConfigList": schema_config_server_apis_config_v1alpha1_RunningConfigList(ref), + "github.com/sdcio/config-server/apis/config/v1alpha1.RunningConfigSpec": schema_config_server_apis_config_v1alpha1_RunningConfigSpec(ref), + "github.com/sdcio/config-server/apis/config/v1alpha1.RunningConfigStatus": schema_config_server_apis_config_v1alpha1_RunningConfigStatus(ref), + "github.com/sdcio/config-server/apis/config/v1alpha1.SensitiveConfig": schema_config_server_apis_config_v1alpha1_SensitiveConfig(ref), + "github.com/sdcio/config-server/apis/config/v1alpha1.SensitiveConfigData": schema_config_server_apis_config_v1alpha1_SensitiveConfigData(ref), + "github.com/sdcio/config-server/apis/config/v1alpha1.SensitiveConfigList": schema_config_server_apis_config_v1alpha1_SensitiveConfigList(ref), + "github.com/sdcio/config-server/apis/config/v1alpha1.SensitiveConfigSpec": schema_config_server_apis_config_v1alpha1_SensitiveConfigSpec(ref), + "github.com/sdcio/config-server/apis/config/v1alpha1.SensitiveConfigStatus": schema_config_server_apis_config_v1alpha1_SensitiveConfigStatus(ref), + "github.com/sdcio/config-server/apis/config/v1alpha1.Target": schema_config_server_apis_config_v1alpha1_Target(ref), + "github.com/sdcio/config-server/apis/config/v1alpha1.TargetStatus": schema_config_server_apis_config_v1alpha1_TargetStatus(ref), } } @@ -562,7 +85,7 @@ func schema_config_server_apis_config_v1alpha1_Config(ref common.ReferenceCallba "metadata": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), + Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"), }, }, "spec": { @@ -581,7 +104,7 @@ func schema_config_server_apis_config_v1alpha1_Config(ref common.ReferenceCallba }, }, Dependencies: []string{ - "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigSpec", "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigStatus", metav1.ObjectMeta{}.OpenAPIModelName()}, + "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigSpec", "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigStatus", "k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"}, } } @@ -609,7 +132,7 @@ func schema_config_server_apis_config_v1alpha1_ConfigBlame(ref common.ReferenceC "metadata": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), + Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"), }, }, "spec": { @@ -628,7 +151,7 @@ func schema_config_server_apis_config_v1alpha1_ConfigBlame(ref common.ReferenceC }, }, Dependencies: []string{ - "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigBlameSpec", "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigBlameStatus", metav1.ObjectMeta{}.OpenAPIModelName()}, + "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigBlameSpec", "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigBlameStatus", "k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"}, } } @@ -656,7 +179,7 @@ func schema_config_server_apis_config_v1alpha1_ConfigBlameList(ref common.Refere "metadata": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), + Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"), }, }, "items": { @@ -677,7 +200,7 @@ func schema_config_server_apis_config_v1alpha1_ConfigBlameList(ref common.Refere }, }, Dependencies: []string{ - "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigBlame", metav1.ListMeta{}.OpenAPIModelName()}, + "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigBlame", "k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"}, } } @@ -701,7 +224,7 @@ func schema_config_server_apis_config_v1alpha1_ConfigBlameStatus(ref common.Refe Properties: map[string]spec.Schema{ "value": { SchemaProps: spec.SchemaProps{ - Ref: ref(runtime.RawExtension{}.OpenAPIModelName()), + Ref: ref("k8s.io/apimachinery/pkg/runtime.RawExtension"), }, }, }, @@ -709,7 +232,7 @@ func schema_config_server_apis_config_v1alpha1_ConfigBlameStatus(ref common.Refe }, }, Dependencies: []string{ - runtime.RawExtension{}.OpenAPIModelName()}, + "k8s.io/apimachinery/pkg/runtime.RawExtension"}, } } @@ -728,7 +251,7 @@ func schema_config_server_apis_config_v1alpha1_ConfigBlob(ref common.ReferenceCa }, "value": { SchemaProps: spec.SchemaProps{ - Ref: ref(runtime.RawExtension{}.OpenAPIModelName()), + Ref: ref("k8s.io/apimachinery/pkg/runtime.RawExtension"), }, }, }, @@ -736,7 +259,7 @@ func schema_config_server_apis_config_v1alpha1_ConfigBlob(ref common.ReferenceCa }, }, Dependencies: []string{ - runtime.RawExtension{}.OpenAPIModelName()}, + "k8s.io/apimachinery/pkg/runtime.RawExtension"}, } } @@ -804,7 +327,7 @@ func schema_config_server_apis_config_v1alpha1_ConfigList(ref common.ReferenceCa "metadata": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), + Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"), }, }, "items": { @@ -825,7 +348,7 @@ func schema_config_server_apis_config_v1alpha1_ConfigList(ref common.ReferenceCa }, }, Dependencies: []string{ - "github.com/sdcio/config-server/apis/config/v1alpha1.Config", metav1.ListMeta{}.OpenAPIModelName()}, + "github.com/sdcio/config-server/apis/config/v1alpha1.Config", "k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"}, } } @@ -853,7 +376,7 @@ func schema_config_server_apis_config_v1alpha1_ConfigSet(ref common.ReferenceCal "metadata": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), + Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"), }, }, "spec": { @@ -872,7 +395,7 @@ func schema_config_server_apis_config_v1alpha1_ConfigSet(ref common.ReferenceCal }, }, Dependencies: []string{ - "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigSetSpec", "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigSetStatus", metav1.ObjectMeta{}.OpenAPIModelName()}, + "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigSetSpec", "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigSetStatus", "k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"}, } } @@ -900,7 +423,7 @@ func schema_config_server_apis_config_v1alpha1_ConfigSetList(ref common.Referenc "metadata": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), + Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"), }, }, "items": { @@ -921,7 +444,7 @@ func schema_config_server_apis_config_v1alpha1_ConfigSetList(ref common.Referenc }, }, Dependencies: []string{ - "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigSet", metav1.ListMeta{}.OpenAPIModelName()}, + "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigSet", "k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"}, } } @@ -1196,7 +719,7 @@ func schema_config_server_apis_config_v1alpha1_Deviation(ref common.ReferenceCal "metadata": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), + Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"), }, }, "spec": { @@ -1215,7 +738,7 @@ func schema_config_server_apis_config_v1alpha1_Deviation(ref common.ReferenceCal }, }, Dependencies: []string{ - "github.com/sdcio/config-server/apis/config/v1alpha1.DeviationSpec", "github.com/sdcio/config-server/apis/config/v1alpha1.DeviationStatus", metav1.ObjectMeta{}.OpenAPIModelName()}, + "github.com/sdcio/config-server/apis/config/v1alpha1.DeviationSpec", "github.com/sdcio/config-server/apis/config/v1alpha1.DeviationStatus", "k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"}, } } @@ -1243,7 +766,7 @@ func schema_config_server_apis_config_v1alpha1_DeviationList(ref common.Referenc "metadata": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), + Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"), }, }, "items": { @@ -1264,7 +787,7 @@ func schema_config_server_apis_config_v1alpha1_DeviationList(ref common.Referenc }, }, Dependencies: []string{ - "github.com/sdcio/config-server/apis/config/v1alpha1.Deviation", metav1.ListMeta{}.OpenAPIModelName()}, + "github.com/sdcio/config-server/apis/config/v1alpha1.Deviation", "k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"}, } } @@ -1383,7 +906,7 @@ func schema_config_server_apis_config_v1alpha1_RunningConfig(ref common.Referenc "metadata": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), + Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"), }, }, "spec": { @@ -1402,7 +925,7 @@ func schema_config_server_apis_config_v1alpha1_RunningConfig(ref common.Referenc }, }, Dependencies: []string{ - "github.com/sdcio/config-server/apis/config/v1alpha1.RunningConfigSpec", "github.com/sdcio/config-server/apis/config/v1alpha1.RunningConfigStatus", metav1.ObjectMeta{}.OpenAPIModelName()}, + "github.com/sdcio/config-server/apis/config/v1alpha1.RunningConfigSpec", "github.com/sdcio/config-server/apis/config/v1alpha1.RunningConfigStatus", "k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"}, } } @@ -1430,7 +953,7 @@ func schema_config_server_apis_config_v1alpha1_RunningConfigList(ref common.Refe "metadata": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), + Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"), }, }, "items": { @@ -1451,7 +974,7 @@ func schema_config_server_apis_config_v1alpha1_RunningConfigList(ref common.Refe }, }, Dependencies: []string{ - "github.com/sdcio/config-server/apis/config/v1alpha1.RunningConfig", metav1.ListMeta{}.OpenAPIModelName()}, + "github.com/sdcio/config-server/apis/config/v1alpha1.RunningConfig", "k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"}, } } @@ -1475,7 +998,7 @@ func schema_config_server_apis_config_v1alpha1_RunningConfigStatus(ref common.Re Properties: map[string]spec.Schema{ "value": { SchemaProps: spec.SchemaProps{ - Ref: ref(runtime.RawExtension{}.OpenAPIModelName()), + Ref: ref("k8s.io/apimachinery/pkg/runtime.RawExtension"), }, }, }, @@ -1483,7 +1006,7 @@ func schema_config_server_apis_config_v1alpha1_RunningConfigStatus(ref common.Re }, }, Dependencies: []string{ - runtime.RawExtension{}.OpenAPIModelName()}, + "k8s.io/apimachinery/pkg/runtime.RawExtension"}, } } @@ -1511,7 +1034,7 @@ func schema_config_server_apis_config_v1alpha1_SensitiveConfig(ref common.Refere "metadata": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), + Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"), }, }, "spec": { @@ -1530,7 +1053,7 @@ func schema_config_server_apis_config_v1alpha1_SensitiveConfig(ref common.Refere }, }, Dependencies: []string{ - "github.com/sdcio/config-server/apis/config/v1alpha1.SensitiveConfigSpec", "github.com/sdcio/config-server/apis/config/v1alpha1.SensitiveConfigStatus", metav1.ObjectMeta{}.OpenAPIModelName()}, + "github.com/sdcio/config-server/apis/config/v1alpha1.SensitiveConfigSpec", "github.com/sdcio/config-server/apis/config/v1alpha1.SensitiveConfigStatus", "k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"}, } } @@ -1552,7 +1075,7 @@ func schema_config_server_apis_config_v1alpha1_SensitiveConfigData(ref common.Re SchemaProps: spec.SchemaProps{ Description: "SecretKeyRef refers to a secret in the same namesapce as the config", Default: map[string]interface{}{}, - Ref: ref(v1.SecretKeySelector{}.OpenAPIModelName()), + Ref: ref("k8s.io/api/core/v1.SecretKeySelector"), }, }, }, @@ -1560,7 +1083,7 @@ func schema_config_server_apis_config_v1alpha1_SensitiveConfigData(ref common.Re }, }, Dependencies: []string{ - v1.SecretKeySelector{}.OpenAPIModelName()}, + "k8s.io/api/core/v1.SecretKeySelector"}, } } @@ -1588,7 +1111,7 @@ func schema_config_server_apis_config_v1alpha1_SensitiveConfigList(ref common.Re "metadata": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), + Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"), }, }, "items": { @@ -1609,7 +1132,7 @@ func schema_config_server_apis_config_v1alpha1_SensitiveConfigList(ref common.Re }, }, Dependencies: []string{ - "github.com/sdcio/config-server/apis/config/v1alpha1.SensitiveConfig", metav1.ListMeta{}.OpenAPIModelName()}, + "github.com/sdcio/config-server/apis/config/v1alpha1.SensitiveConfig", "k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"}, } } @@ -1728,14 +1251,14 @@ func schema_config_server_apis_config_v1alpha1_Target(ref common.ReferenceCallba "targetSelector": { SchemaProps: spec.SchemaProps{ Description: "TargetSelector defines the selector used to select the targets to which the config applies", - Ref: ref(metav1.LabelSelector{}.OpenAPIModelName()), + Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.LabelSelector"), }, }, }, }, }, Dependencies: []string{ - metav1.LabelSelector{}.OpenAPIModelName()}, + "k8s.io/apimachinery/pkg/apis/meta/v1.LabelSelector"}, } } @@ -1778,7 +1301,7 @@ func schema_config_server_apis_config_v1alpha1_TargetStatus(ref common.Reference "lastTransitionTime": { SchemaProps: spec.SchemaProps{ Description: "lastTransitionTime is the last time the condition transitioned from one status to another. This should be when the underlying condition changed. If that is not known, then using the time when the API field changed is acceptable.", - Ref: ref(metav1.Time{}.OpenAPIModelName()), + Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.Time"), }, }, "reason": { @@ -1802,19278 +1325,6 @@ func schema_config_server_apis_config_v1alpha1_TargetStatus(ref common.Reference }, }, Dependencies: []string{ - metav1.Time{}.OpenAPIModelName()}, - } -} - -func schema_config_server_apis_inv_v1alpha1_DiscoveryInfo(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "protocol": { - SchemaProps: spec.SchemaProps{ - Description: "Protocol used for discovery", - Type: []string{"string"}, - Format: "", - }, - }, - "provider": { - SchemaProps: spec.SchemaProps{ - Description: "Type associated with the target", - Type: []string{"string"}, - Format: "", - }, - }, - "version": { - SchemaProps: spec.SchemaProps{ - Description: "Version associated with the target", - Type: []string{"string"}, - Format: "", - }, - }, - "hostname": { - SchemaProps: spec.SchemaProps{ - Description: "HostName associated with the target", - Type: []string{"string"}, - Format: "", - }, - }, - "platform": { - SchemaProps: spec.SchemaProps{ - Description: "Platform associated with the target", - Type: []string{"string"}, - Format: "", - }, - }, - "macAddress": { - SchemaProps: spec.SchemaProps{ - Description: "MacAddress associated with the target", - Type: []string{"string"}, - Format: "", - }, - }, - "serialNumber": { - SchemaProps: spec.SchemaProps{ - Description: "SerialNumber associated with the target", - Type: []string{"string"}, - Format: "", - }, - }, - "supportedEncodings": { - SchemaProps: spec.SchemaProps{ - Description: "Supported Encodings of the target", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - }, - }, - }, - } -} - -func schema_config_server_apis_inv_v1alpha1_DiscoveryParameters(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "defaultSchema": { - SchemaProps: spec.SchemaProps{ - Description: "DefaultSchema define the default schema used to connect to a target Indicates that discovery is disable; cannot be used for prefix based discovery rules", - Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.SchemaKey"), - }, - }, - "discoveryProfile": { - SchemaProps: spec.SchemaProps{ - Description: "DiscoveryProfile define the profiles the discovery controller uses to discover targets", - Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryProfile"), - }, - }, - "targetConnectionProfiles": { - SchemaProps: spec.SchemaProps{ - Description: "TargetConnectionProfiles define the profile the discovery controller uses to create targets once discovered", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.TargetProfile"), - }, - }, - }, - }, - }, - "targetTemplate": { - SchemaProps: spec.SchemaProps{ - Description: "TargetTemplate defines the template the discovery controller uses to create the targets as a result of the discovery", - Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.TargetTemplate"), - }, - }, - "period": { - SchemaProps: spec.SchemaProps{ - Description: "Period defines the wait period between discovery rule runs", - Ref: ref(metav1.Duration{}.OpenAPIModelName()), - }, - }, - "concurrentScans": { - SchemaProps: spec.SchemaProps{ - Description: "number of concurrent IP scan", - Type: []string{"integer"}, - Format: "int64", - }, - }, - }, - Required: []string{"targetConnectionProfiles"}, - }, - }, - Dependencies: []string{ - "github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryProfile", "github.com/sdcio/config-server/apis/inv/v1alpha1.SchemaKey", "github.com/sdcio/config-server/apis/inv/v1alpha1.TargetProfile", "github.com/sdcio/config-server/apis/inv/v1alpha1.TargetTemplate", metav1.Duration{}.OpenAPIModelName()}, - } -} - -func schema_config_server_apis_inv_v1alpha1_DiscoveryPathDefinition(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "key": { - SchemaProps: spec.SchemaProps{ - Description: "Key defines the key of the path for fast lookup", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "path": { - SchemaProps: spec.SchemaProps{ - Description: "Path associated with the key", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "script": { - SchemaProps: spec.SchemaProps{ - Description: "Script defines the starlark script to transform the value", - Type: []string{"string"}, - Format: "", - }, - }, - "regex": { - SchemaProps: spec.SchemaProps{ - Description: "Regex defines the regex to transform the value", - Type: []string{"string"}, - Format: "", - }, - }, - }, - Required: []string{"key", "path"}, - }, - }, - } -} - -func schema_config_server_apis_inv_v1alpha1_DiscoveryProfile(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "credentials": { - SchemaProps: spec.SchemaProps{ - Description: "Credentials defines the name of the secret that holds the credentials to connect to the target", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "tlsSecret": { - SchemaProps: spec.SchemaProps{ - Description: "TLSSecret defines the name of the TLS secret to connect to the target if mtls is used", - Type: []string{"string"}, - Format: "", - }, - }, - "connectionProfiles": { - SchemaProps: spec.SchemaProps{ - Description: "ConnectionProfiles define the list of profiles the discovery controller uses to discover the target. The order in which they are specified is the order in which discovery is executed.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - }, - Required: []string{"credentials", "connectionProfiles"}, - }, - }, - } -} - -func schema_config_server_apis_inv_v1alpha1_DiscoveryRule(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "DiscoveryRule is the Schema for the DiscoveryRule API", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Type: []string{"string"}, - Format: "", - }, - }, - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", - Type: []string{"string"}, - Format: "", - }, - }, - "metadata": { - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), - }, - }, - "spec": { - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryRuleSpec"), - }, - }, - "status": { - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryRuleStatus"), - }, - }, - }, - }, - }, - Dependencies: []string{ - "github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryRuleSpec", "github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryRuleStatus", metav1.ObjectMeta{}.OpenAPIModelName()}, - } -} - -func schema_config_server_apis_inv_v1alpha1_DiscoveryRuleAddress(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "address": { - SchemaProps: spec.SchemaProps{ - Description: "Address (specified as IP or DNS name) of the target/target(s)", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "hostName": { - SchemaProps: spec.SchemaProps{ - Description: "HostName of the ip prefix; used for /32 or /128 addresses with discovery disabled", - Type: []string{"string"}, - Format: "", - }, - }, - }, - Required: []string{"address"}, - }, - }, - } -} - -func schema_config_server_apis_inv_v1alpha1_DiscoveryRuleList(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "DiscoveryRuleList contains a list of DiscoveryRules", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Type: []string{"string"}, - Format: "", - }, - }, - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", - Type: []string{"string"}, - Format: "", - }, - }, - "metadata": { - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), - }, - }, - "items": { - SchemaProps: spec.SchemaProps{ - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryRule"), - }, - }, - }, - }, - }, - }, - Required: []string{"items"}, - }, - }, - Dependencies: []string{ - "github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryRule", metav1.ListMeta{}.OpenAPIModelName()}, - } -} - -func schema_config_server_apis_inv_v1alpha1_DiscoveryRulePrefix(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "prefix": { - SchemaProps: spec.SchemaProps{ - Description: "Prefix of the target/target(s)", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "excludes": { - SchemaProps: spec.SchemaProps{ - Description: "IP Prefixes to be excluded", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - }, - Required: []string{"prefix"}, - }, - }, - } -} - -func schema_config_server_apis_inv_v1alpha1_DiscoveryRuleSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "DiscoveryRuleSpec defines the desired state of DiscoveryRule", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "prefixes": { - SchemaProps: spec.SchemaProps{ - Description: "IP Prefixes for which this discovery rule applies", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryRulePrefix"), - }, - }, - }, - }, - }, - "addresses": { - SchemaProps: spec.SchemaProps{ - Description: "IP Prefixes for which this discovery rule applies", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryRuleAddress"), - }, - }, - }, - }, - }, - "podSelector": { - SchemaProps: spec.SchemaProps{ - Description: "PodSelector defines the pod selector for which this discovery rule applies", - Ref: ref(metav1.LabelSelector{}.OpenAPIModelName()), - }, - }, - "serviceSelector": { - SchemaProps: spec.SchemaProps{ - Description: "ServiceSelector defines the service selector for which this discovery rule applies", - Ref: ref(metav1.LabelSelector{}.OpenAPIModelName()), - }, - }, - "serviceDomain": { - SchemaProps: spec.SchemaProps{ - Description: "ServiceDomain defines the service domain of the cluster, used by svc discovery to identify the domain name in the k8s cluster where the service reside.", - Type: []string{"string"}, - Format: "", - }, - }, - "defaultSchema": { - SchemaProps: spec.SchemaProps{ - Description: "DefaultSchema define the default schema used to connect to a target Indicates that discovery is disable; cannot be used for prefix based discovery rules", - Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.SchemaKey"), - }, - }, - "discoveryProfile": { - SchemaProps: spec.SchemaProps{ - Description: "DiscoveryProfile define the profiles the discovery controller uses to discover targets", - Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryProfile"), - }, - }, - "targetConnectionProfiles": { - SchemaProps: spec.SchemaProps{ - Description: "TargetConnectionProfiles define the profile the discovery controller uses to create targets once discovered", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.TargetProfile"), - }, - }, - }, - }, - }, - "targetTemplate": { - SchemaProps: spec.SchemaProps{ - Description: "TargetTemplate defines the template the discovery controller uses to create the targets as a result of the discovery", - Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.TargetTemplate"), - }, - }, - "period": { - SchemaProps: spec.SchemaProps{ - Description: "Period defines the wait period between discovery rule runs", - Ref: ref(metav1.Duration{}.OpenAPIModelName()), - }, - }, - "concurrentScans": { - SchemaProps: spec.SchemaProps{ - Description: "number of concurrent IP scan", - Type: []string{"integer"}, - Format: "int64", - }, - }, - }, - Required: []string{"targetConnectionProfiles"}, - }, - }, - Dependencies: []string{ - "github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryProfile", "github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryRuleAddress", "github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryRulePrefix", "github.com/sdcio/config-server/apis/inv/v1alpha1.SchemaKey", "github.com/sdcio/config-server/apis/inv/v1alpha1.TargetProfile", "github.com/sdcio/config-server/apis/inv/v1alpha1.TargetTemplate", metav1.Duration{}.OpenAPIModelName(), metav1.LabelSelector{}.OpenAPIModelName()}, - } -} - -func schema_config_server_apis_inv_v1alpha1_DiscoveryRuleStatus(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "DiscoveryRuleStatus defines the observed state of DiscoveryRule", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "conditions": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-map-keys": []interface{}{ - "type", - }, - "x-kubernetes-list-type": "map", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "Conditions of the resource.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref("github.com/sdcio/config-server/apis/condition/v1alpha1.Condition"), - }, - }, - }, - }, - }, - "startTime": { - SchemaProps: spec.SchemaProps{ - Description: "StartTime identifies when the dr got started", - Ref: ref(metav1.Time{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - Dependencies: []string{ - "github.com/sdcio/config-server/apis/condition/v1alpha1.Condition", metav1.Time{}.OpenAPIModelName()}, - } -} - -func schema_config_server_apis_inv_v1alpha1_DiscoveryVendorProfile(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "DiscoveryVendorProfile is the Schema for the DiscoveryVendorProfile API", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Type: []string{"string"}, - Format: "", - }, - }, - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", - Type: []string{"string"}, - Format: "", - }, - }, - "metadata": { - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), - }, - }, - "spec": { - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryVendorProfileSpec"), - }, - }, - }, - }, - }, - Dependencies: []string{ - "github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryVendorProfileSpec", metav1.ObjectMeta{}.OpenAPIModelName()}, - } -} - -func schema_config_server_apis_inv_v1alpha1_DiscoveryVendorProfileList(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "DiscoveryVendorProfileList contains a list of DiscoveryVendorProfileList", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Type: []string{"string"}, - Format: "", - }, - }, - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", - Type: []string{"string"}, - Format: "", - }, - }, - "metadata": { - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), - }, - }, - "items": { - SchemaProps: spec.SchemaProps{ - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryVendorProfile"), - }, - }, - }, - }, - }, - }, - Required: []string{"items"}, - }, - }, - Dependencies: []string{ - "github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryVendorProfile", metav1.ListMeta{}.OpenAPIModelName()}, - } -} - -func schema_config_server_apis_inv_v1alpha1_DiscoveryVendorProfileSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "DiscoveryProfileSpec defines the desired state of DiscoveryProfile", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "gnmi": { - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.GnmiDiscoveryVendorProfileParameters"), - }, - }, - }, - Required: []string{"gnmi"}, - }, - }, - Dependencies: []string{ - "github.com/sdcio/config-server/apis/inv/v1alpha1.GnmiDiscoveryVendorProfileParameters"}, - } -} - -func schema_config_server_apis_inv_v1alpha1_GnmiDiscoveryVendorProfileParameters(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "organization": { - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "modelMatch": { - SchemaProps: spec.SchemaProps{ - Type: []string{"string"}, - Format: "", - }, - }, - "paths": { - SchemaProps: spec.SchemaProps{ - Description: "Paths DiscoveryPaths `json:\"paths\" protobuf:\"bytes,3,opt,name=paths\"`", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryPathDefinition"), - }, - }, - }, - }, - }, - "encoding": { - SchemaProps: spec.SchemaProps{ - Type: []string{"string"}, - Format: "", - }, - }, - "preserveNamespace": { - SchemaProps: spec.SchemaProps{ - Type: []string{"boolean"}, - Format: "", - }, - }, - }, - Required: []string{"organization", "paths"}, - }, - }, - Dependencies: []string{ - "github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryPathDefinition"}, - } -} - -func schema_config_server_apis_inv_v1alpha1_Proxy(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "URL": { - SchemaProps: spec.SchemaProps{ - Description: "URL specifies the base URL of the HTTP/HTTPS proxy server.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "credentials": { - SchemaProps: spec.SchemaProps{ - Description: "Credentials defines the name of the secret that holds the credentials to connect to the proxy server", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - Required: []string{"URL", "credentials"}, - }, - }, - } -} - -func schema_config_server_apis_inv_v1alpha1_Repository(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "repoURL": { - SchemaProps: spec.SchemaProps{ - Description: "RepositoryURL specifies the base URL for a given repository", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "credentials": { - SchemaProps: spec.SchemaProps{ - Description: "Credentials defines the name of the secret that holds the credentials to connect to the repo", - Type: []string{"string"}, - Format: "", - }, - }, - "proxy": { - SchemaProps: spec.SchemaProps{ - Description: "Proxy defines the HTTP/HTTPS proxy to be used to connect to the repo.", - Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.Proxy"), - }, - }, - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind defines the that the BranchOrTag string is a repository branch or a tag", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "ref": { - SchemaProps: spec.SchemaProps{ - Description: "Ref defines the branch or tag of the repository corresponding to the provider schema version", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - Required: []string{"repoURL", "kind", "ref"}, - }, - }, - Dependencies: []string{ - "github.com/sdcio/config-server/apis/inv/v1alpha1.Proxy"}, - } -} - -func schema_config_server_apis_inv_v1alpha1_Rollout(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "Rollout is the Rollout for the Rollout API", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Type: []string{"string"}, - Format: "", - }, - }, - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", - Type: []string{"string"}, - Format: "", - }, - }, - "metadata": { - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), - }, - }, - "spec": { - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.RolloutSpec"), - }, - }, - "status": { - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.RolloutStatus"), - }, - }, - }, - }, - }, - Dependencies: []string{ - "github.com/sdcio/config-server/apis/inv/v1alpha1.RolloutSpec", "github.com/sdcio/config-server/apis/inv/v1alpha1.RolloutStatus", metav1.ObjectMeta{}.OpenAPIModelName()}, - } -} - -func schema_config_server_apis_inv_v1alpha1_RolloutList(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "RolloutList contains a list of Rollouts", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Type: []string{"string"}, - Format: "", - }, - }, - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", - Type: []string{"string"}, - Format: "", - }, - }, - "metadata": { - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), - }, - }, - "items": { - SchemaProps: spec.SchemaProps{ - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.Rollout"), - }, - }, - }, - }, - }, - }, - Required: []string{"items"}, - }, - }, - Dependencies: []string{ - "github.com/sdcio/config-server/apis/inv/v1alpha1.Rollout", metav1.ListMeta{}.OpenAPIModelName()}, - } -} - -func schema_config_server_apis_inv_v1alpha1_RolloutSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "RolloutSpec defines the desired state of Rollout", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "repoURL": { - SchemaProps: spec.SchemaProps{ - Description: "RepositoryURL specifies the base URL for a given repository", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "credentials": { - SchemaProps: spec.SchemaProps{ - Description: "Credentials defines the name of the secret that holds the credentials to connect to the repo", - Type: []string{"string"}, - Format: "", - }, - }, - "proxy": { - SchemaProps: spec.SchemaProps{ - Description: "Proxy defines the HTTP/HTTPS proxy to be used to connect to the repo.", - Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.Proxy"), - }, - }, - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind defines the that the BranchOrTag string is a repository branch or a tag", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "ref": { - SchemaProps: spec.SchemaProps{ - Description: "Ref defines the branch or tag of the repository corresponding to the provider schema version", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "strategy": { - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "skipUnavailableTarget": { - SchemaProps: spec.SchemaProps{ - Type: []string{"boolean"}, - Format: "", - }, - }, - }, - Required: []string{"repoURL", "kind", "ref", "strategy"}, - }, - }, - Dependencies: []string{ - "github.com/sdcio/config-server/apis/inv/v1alpha1.Proxy"}, - } -} - -func schema_config_server_apis_inv_v1alpha1_RolloutStatus(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "RolloutStatus defines the observed state of Rollout", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "conditions": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-map-keys": []interface{}{ - "type", - }, - "x-kubernetes-list-type": "map", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "Conditions of the resource.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref("github.com/sdcio/config-server/apis/condition/v1alpha1.Condition"), - }, - }, - }, - }, - }, - "targets": { - SchemaProps: spec.SchemaProps{ - Description: "Targets defines the status of the rollout on the respective target", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.RolloutTargetStatus"), - }, - }, - }, - }, - }, - }, - }, - }, - Dependencies: []string{ - "github.com/sdcio/config-server/apis/condition/v1alpha1.Condition", "github.com/sdcio/config-server/apis/inv/v1alpha1.RolloutTargetStatus"}, - } -} - -func schema_config_server_apis_inv_v1alpha1_RolloutTargetStatus(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "name": { - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "conditions": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-map-keys": []interface{}{ - "type", - }, - "x-kubernetes-list-type": "map", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "Conditions of the resource.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref("github.com/sdcio/config-server/apis/condition/v1alpha1.Condition"), - }, - }, - }, - }, - }, - }, - Required: []string{"name"}, - }, - }, - Dependencies: []string{ - "github.com/sdcio/config-server/apis/condition/v1alpha1.Condition"}, - } -} - -func schema_config_server_apis_inv_v1alpha1_Schema(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "Schema is the Schema for the Schema API", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Type: []string{"string"}, - Format: "", - }, - }, - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", - Type: []string{"string"}, - Format: "", - }, - }, - "metadata": { - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), - }, - }, - "spec": { - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.SchemaSpec"), - }, - }, - "status": { - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.SchemaStatus"), - }, - }, - }, - }, - }, - Dependencies: []string{ - "github.com/sdcio/config-server/apis/inv/v1alpha1.SchemaSpec", "github.com/sdcio/config-server/apis/inv/v1alpha1.SchemaStatus", metav1.ObjectMeta{}.OpenAPIModelName()}, - } -} - -func schema_config_server_apis_inv_v1alpha1_SchemaKey(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "provider": { - SchemaProps: spec.SchemaProps{ - Description: "Provider specifies the provider of the schema.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "version": { - SchemaProps: spec.SchemaProps{ - Description: "Version defines the version of the schema", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - Required: []string{"provider", "version"}, - }, - }, - } -} - -func schema_config_server_apis_inv_v1alpha1_SchemaList(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "SchemaList contains a list of Schemas", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Type: []string{"string"}, - Format: "", - }, - }, - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", - Type: []string{"string"}, - Format: "", - }, - }, - "metadata": { - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), - }, - }, - "items": { - SchemaProps: spec.SchemaProps{ - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.Schema"), - }, - }, - }, - }, - }, - }, - Required: []string{"items"}, - }, - }, - Dependencies: []string{ - "github.com/sdcio/config-server/apis/inv/v1alpha1.Schema", metav1.ListMeta{}.OpenAPIModelName()}, - } -} - -func schema_config_server_apis_inv_v1alpha1_SchemaRepositoryStatus(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "SchemaRepositoryStatus provides the observed hash of a repository", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "repoURL": { - SchemaProps: spec.SchemaProps{ - Description: "RepoURL defines URL of the repository", - Type: []string{"string"}, - Format: "", - }, - }, - "reference": { - SchemaProps: spec.SchemaProps{ - Description: "Reference indicating version of loaded repository", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - } -} - -func schema_config_server_apis_inv_v1alpha1_SchemaSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "SchemaSpec defines the desired state of Schema", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "provider": { - SchemaProps: spec.SchemaProps{ - Description: "Provider specifies the provider of the schema.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "version": { - SchemaProps: spec.SchemaProps{ - Description: "Version defines the version of the schema", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "repositories": { - SchemaProps: spec.SchemaProps{ - Description: "Repositories define the repositories used for building the provider schema", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.SchemaSpecRepository"), - }, - }, - }, - }, - }, - }, - Required: []string{"provider", "version", "repositories"}, - }, - }, - Dependencies: []string{ - "github.com/sdcio/config-server/apis/inv/v1alpha1.SchemaSpecRepository"}, - } -} - -func schema_config_server_apis_inv_v1alpha1_SchemaSpecRepository(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "repoURL": { - SchemaProps: spec.SchemaProps{ - Description: "RepositoryURL specifies the base URL for a given repository", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "credentials": { - SchemaProps: spec.SchemaProps{ - Description: "Credentials defines the name of the secret that holds the credentials to connect to the repo", - Type: []string{"string"}, - Format: "", - }, - }, - "proxy": { - SchemaProps: spec.SchemaProps{ - Description: "Proxy defines the HTTP/HTTPS proxy to be used to connect to the repo.", - Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.Proxy"), - }, - }, - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind defines the that the BranchOrTag string is a repository branch or a tag", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "ref": { - SchemaProps: spec.SchemaProps{ - Description: "Ref defines the branch or tag of the repository corresponding to the provider schema version", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "dirs": { - SchemaProps: spec.SchemaProps{ - Description: "Dirs defines the list of directories that identified the provider schema in src/dst pairs relative within the repository", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.SrcDstPath"), - }, - }, - }, - }, - }, - "schema": { - SchemaProps: spec.SchemaProps{ - Description: "Schema provides the details of which files must be used for the models and which files/directories cana be excludes", - Default: map[string]interface{}{}, - Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.SchemaSpecSchema"), - }, - }, - }, - Required: []string{"repoURL", "kind", "ref", "schema"}, - }, - }, - Dependencies: []string{ - "github.com/sdcio/config-server/apis/inv/v1alpha1.Proxy", "github.com/sdcio/config-server/apis/inv/v1alpha1.SchemaSpecSchema", "github.com/sdcio/config-server/apis/inv/v1alpha1.SrcDstPath"}, - } -} - -func schema_config_server_apis_inv_v1alpha1_SchemaSpecSchema(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "models": { - SchemaProps: spec.SchemaProps{ - Description: "Models defines the list of files/directories to be used as a model", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - "includes": { - SchemaProps: spec.SchemaProps{ - Description: "Excludes defines the list of files/directories to be excluded", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - "excludes": { - SchemaProps: spec.SchemaProps{ - Description: "Excludes defines the list of files/directories to be excluded", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - }, - }, - }, - } -} - -func schema_config_server_apis_inv_v1alpha1_SchemaStatus(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "SchemaStatus defines the observed state of Schema", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "conditions": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-map-keys": []interface{}{ - "type", - }, - "x-kubernetes-list-type": "map", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "Conditions of the resource.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref("github.com/sdcio/config-server/apis/condition/v1alpha1.Condition"), - }, - }, - }, - }, - }, - "repositories": { - SchemaProps: spec.SchemaProps{ - Description: "SchemaRepositoryStatus provides the array of repositories", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.SchemaRepositoryStatus"), - }, - }, - }, - }, - }, - }, - }, - }, - Dependencies: []string{ - "github.com/sdcio/config-server/apis/condition/v1alpha1.Condition", "github.com/sdcio/config-server/apis/inv/v1alpha1.SchemaRepositoryStatus"}, - } -} - -func schema_config_server_apis_inv_v1alpha1_SrcDstPath(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "SrcDstPath provide a src/dst pair for the loader to download the schema from a specific src in the repository to a given destination in the schema server", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "src": { - SchemaProps: spec.SchemaProps{ - Description: "Src is the relative directory in the repository URL", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "dst": { - SchemaProps: spec.SchemaProps{ - Description: "Dst is the relative directory in the schema server", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - Required: []string{"src", "dst"}, - }, - }, - } -} - -func schema_config_server_apis_inv_v1alpha1_Subscription(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "Subscription is the Schema for the Subscription API", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Type: []string{"string"}, - Format: "", - }, - }, - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", - Type: []string{"string"}, - Format: "", - }, - }, - "metadata": { - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), - }, - }, - "spec": { - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.SubscriptionSpec"), - }, - }, - "status": { - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.SubscriptionStatus"), - }, - }, - }, - }, - }, - Dependencies: []string{ - "github.com/sdcio/config-server/apis/inv/v1alpha1.SubscriptionSpec", "github.com/sdcio/config-server/apis/inv/v1alpha1.SubscriptionStatus", metav1.ObjectMeta{}.OpenAPIModelName()}, - } -} - -func schema_config_server_apis_inv_v1alpha1_SubscriptionList(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "SubscriptionList contains a list of Subscriptions", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Type: []string{"string"}, - Format: "", - }, - }, - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", - Type: []string{"string"}, - Format: "", - }, - }, - "metadata": { - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), - }, - }, - "items": { - SchemaProps: spec.SchemaProps{ - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.Subscription"), - }, - }, - }, - }, - }, - }, - Required: []string{"items"}, - }, - }, - Dependencies: []string{ - "github.com/sdcio/config-server/apis/inv/v1alpha1.Subscription", metav1.ListMeta{}.OpenAPIModelName()}, - } -} - -func schema_config_server_apis_inv_v1alpha1_SubscriptionParameters(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "SubscriptionSync defines the desired Subscription of SubscriptionSync", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "name": { - SchemaProps: spec.SchemaProps{ - Description: "Name defines the name of the group of the Subscription to be collected", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "description": { - SchemaProps: spec.SchemaProps{ - Description: "Description details what the Subscription collection is about", - Type: []string{"string"}, - Format: "", - }, - }, - "labels": { - SchemaProps: spec.SchemaProps{ - Description: "Labels can be defined as user defined data to provide extra context", - Type: []string{"object"}, - AdditionalProperties: &spec.SchemaOrBool{ - Allows: true, - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - "adminState": { - SchemaProps: spec.SchemaProps{ - Description: "AdminState allows to disable the subscription", - Type: []string{"string"}, - Format: "", - }, - }, - "mode": { - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "interval": { - SchemaProps: spec.SchemaProps{ - Ref: ref(metav1.Duration{}.OpenAPIModelName()), - }, - }, - "paths": { - SchemaProps: spec.SchemaProps{ - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - }, - Required: []string{"name", "mode", "paths"}, - }, - }, - Dependencies: []string{ - metav1.Duration{}.OpenAPIModelName()}, - } -} - -func schema_config_server_apis_inv_v1alpha1_SubscriptionSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "SubscriptionSpec defines the desired Subscription of Subscription", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "target": { - SchemaProps: spec.SchemaProps{ - Description: "Targets defines the targets on which this Subscription applies", - Default: map[string]interface{}{}, - Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.SubscriptionTarget"), - }, - }, - "protocol": { - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "port": { - SchemaProps: spec.SchemaProps{ - Description: "Port defines the port on which the scan runs", - Default: 0, - Type: []string{"integer"}, - Format: "int64", - }, - }, - "encoding": { - SchemaProps: spec.SchemaProps{ - Type: []string{"string"}, - Format: "", - }, - }, - "subscriptions": { - SchemaProps: spec.SchemaProps{ - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.SubscriptionParameters"), - }, - }, - }, - }, - }, - }, - Required: []string{"target", "protocol", "port", "subscriptions"}, - }, - }, - Dependencies: []string{ - "github.com/sdcio/config-server/apis/inv/v1alpha1.SubscriptionParameters", "github.com/sdcio/config-server/apis/inv/v1alpha1.SubscriptionTarget"}, - } -} - -func schema_config_server_apis_inv_v1alpha1_SubscriptionStatus(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "conditions": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-map-keys": []interface{}{ - "type", - }, - "x-kubernetes-list-type": "map", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "Conditions of the resource.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref("github.com/sdcio/config-server/apis/condition/v1alpha1.Condition"), - }, - }, - }, - }, - }, - "targets": { - SchemaProps: spec.SchemaProps{ - Description: "Targets defines the list of targets this resource applies to", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - }, - }, - }, - Dependencies: []string{ - "github.com/sdcio/config-server/apis/condition/v1alpha1.Condition"}, - } -} - -func schema_config_server_apis_inv_v1alpha1_SubscriptionTarget(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "targetSelector": { - SchemaProps: spec.SchemaProps{ - Description: "TargetSelector defines the selector used to select the targets to which the config applies", - Ref: ref(metav1.LabelSelector{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - Dependencies: []string{ - metav1.LabelSelector{}.OpenAPIModelName()}, - } -} - -func schema_config_server_apis_inv_v1alpha1_Target(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "Target is the Schema for the Target API", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Type: []string{"string"}, - Format: "", - }, - }, - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", - Type: []string{"string"}, - Format: "", - }, - }, - "metadata": { - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), - }, - }, - "spec": { - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.TargetSpec"), - }, - }, - "status": { - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.TargetStatus"), - }, - }, - }, - }, - }, - Dependencies: []string{ - "github.com/sdcio/config-server/apis/inv/v1alpha1.TargetSpec", "github.com/sdcio/config-server/apis/inv/v1alpha1.TargetStatus", metav1.ObjectMeta{}.OpenAPIModelName()}, - } -} - -func schema_config_server_apis_inv_v1alpha1_TargetConnectionProfile(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "TargetConnectionProfile is the Schema for the TargetConnectionProfile API", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Type: []string{"string"}, - Format: "", - }, - }, - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", - Type: []string{"string"}, - Format: "", - }, - }, - "metadata": { - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), - }, - }, - "spec": { - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.TargetConnectionProfileSpec"), - }, - }, - }, - }, - }, - Dependencies: []string{ - "github.com/sdcio/config-server/apis/inv/v1alpha1.TargetConnectionProfileSpec", metav1.ObjectMeta{}.OpenAPIModelName()}, - } -} - -func schema_config_server_apis_inv_v1alpha1_TargetConnectionProfileList(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "TargetConnectionProfileList contains a list of TargetConnectionProfile", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Type: []string{"string"}, - Format: "", - }, - }, - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", - Type: []string{"string"}, - Format: "", - }, - }, - "metadata": { - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), - }, - }, - "items": { - SchemaProps: spec.SchemaProps{ - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.TargetConnectionProfile"), - }, - }, - }, - }, - }, - }, - Required: []string{"items"}, - }, - }, - Dependencies: []string{ - "github.com/sdcio/config-server/apis/inv/v1alpha1.TargetConnectionProfile", metav1.ListMeta{}.OpenAPIModelName()}, - } -} - -func schema_config_server_apis_inv_v1alpha1_TargetConnectionProfileSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "TargetConnectionProfileSpec defines the desired state of TargetConnectionProfile", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "connectRetry": { - SchemaProps: spec.SchemaProps{ - Ref: ref(metav1.Duration{}.OpenAPIModelName()), - }, - }, - "timeout": { - SchemaProps: spec.SchemaProps{ - Ref: ref(metav1.Duration{}.OpenAPIModelName()), - }, - }, - "protocol": { - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "port": { - SchemaProps: spec.SchemaProps{ - Description: "Port defines the port on which the scan runs", - Default: 0, - Type: []string{"integer"}, - Format: "int64", - }, - }, - "encoding": { - SchemaProps: spec.SchemaProps{ - Type: []string{"string"}, - Format: "", - }, - }, - "preferredNetconfVersion": { - SchemaProps: spec.SchemaProps{ - Type: []string{"string"}, - Format: "", - }, - }, - "insecure": { - SchemaProps: spec.SchemaProps{ - Type: []string{"boolean"}, - Format: "", - }, - }, - "skipVerify": { - SchemaProps: spec.SchemaProps{ - Type: []string{"boolean"}, - Format: "", - }, - }, - "includeNS": { - SchemaProps: spec.SchemaProps{ - Type: []string{"boolean"}, - Format: "", - }, - }, - "operationWithNS": { - SchemaProps: spec.SchemaProps{ - Type: []string{"boolean"}, - Format: "", - }, - }, - "useOperationRemove": { - SchemaProps: spec.SchemaProps{ - Type: []string{"boolean"}, - Format: "", - }, - }, - "commitCandidate": { - SchemaProps: spec.SchemaProps{ - Type: []string{"string"}, - Format: "", - }, - }, - "targetName": { - SchemaProps: spec.SchemaProps{ - Description: "TargetName specifies the target field value in gNMI Path prefix Examples: \"OC-YANG\" (SONiC), \"openconfig\" (some vendors), or empty", - Type: []string{"string"}, - Format: "", - }, - }, - }, - Required: []string{"protocol", "port"}, - }, - }, - Dependencies: []string{ - metav1.Duration{}.OpenAPIModelName()}, - } -} - -func schema_config_server_apis_inv_v1alpha1_TargetList(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "TargetList contains a list of Targets", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Type: []string{"string"}, - Format: "", - }, - }, - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", - Type: []string{"string"}, - Format: "", - }, - }, - "metadata": { - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), - }, - }, - "items": { - SchemaProps: spec.SchemaProps{ - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.Target"), - }, - }, - }, - }, - }, - }, - Required: []string{"items"}, - }, - }, - Dependencies: []string{ - "github.com/sdcio/config-server/apis/inv/v1alpha1.Target", metav1.ListMeta{}.OpenAPIModelName()}, - } -} - -func schema_config_server_apis_inv_v1alpha1_TargetProfile(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "credentials": { - SchemaProps: spec.SchemaProps{ - Description: "Credentials defines the name of the secret that holds the credentials to connect to the target", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "tlsSecret": { - SchemaProps: spec.SchemaProps{ - Description: "TLSSecret defines the name of the TLS secret to connect to the target if mtls is used", - Type: []string{"string"}, - Format: "", - }, - }, - "connectionProfile": { - SchemaProps: spec.SchemaProps{ - Description: "ConnectionProfile define the profile used to connect to the target once discovered", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "syncProfile": { - SchemaProps: spec.SchemaProps{ - Description: "SyncProfile define the profile used to sync to the target config once discovered", - Type: []string{"string"}, - Format: "", - }, - }, - }, - Required: []string{"credentials", "connectionProfile"}, - }, - }, - } -} - -func schema_config_server_apis_inv_v1alpha1_TargetSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "TargetSpec defines the desired state of Target", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "provider": { - SchemaProps: spec.SchemaProps{ - Description: "Provider specifies the provider using this target.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "address": { - SchemaProps: spec.SchemaProps{ - Description: "Address defines the address to connect to the target", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "credentials": { - SchemaProps: spec.SchemaProps{ - Description: "Credentials defines the name of the secret that holds the credentials to connect to the target", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "tlsSecret": { - SchemaProps: spec.SchemaProps{ - Description: "TLSSecret defines the name of the TLS secret to connect to the target if mtls is used", - Type: []string{"string"}, - Format: "", - }, - }, - "connectionProfile": { - SchemaProps: spec.SchemaProps{ - Description: "ConnectionProfile define the profile used to connect to the target once discovered", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "syncProfile": { - SchemaProps: spec.SchemaProps{ - Description: "SyncProfile define the profile used to sync to the target config once discovered", - Type: []string{"string"}, - Format: "", - }, - }, - }, - Required: []string{"provider", "address", "credentials", "connectionProfile"}, - }, - }, - } -} - -func schema_config_server_apis_inv_v1alpha1_TargetStatus(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "TargetStatus defines the observed state of Target", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "conditions": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-map-keys": []interface{}{ - "type", - }, - "x-kubernetes-list-type": "map", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "Conditions of the resource.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref("github.com/sdcio/config-server/apis/condition/v1alpha1.Condition"), - }, - }, - }, - }, - }, - "discoveryInfo": { - SchemaProps: spec.SchemaProps{ - Description: "Discovery info defines the information retrieved during discovery", - Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryInfo"), - }, - }, - "usedReferences": { - SchemaProps: spec.SchemaProps{ - Description: "UsedReferences track the resource used to reconcile the cr", - Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.TargetStatusUsedReferences"), - }, - }, - }, - }, - }, - Dependencies: []string{ - "github.com/sdcio/config-server/apis/condition/v1alpha1.Condition", "github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryInfo", "github.com/sdcio/config-server/apis/inv/v1alpha1.TargetStatusUsedReferences"}, - } -} - -func schema_config_server_apis_inv_v1alpha1_TargetStatusUsedReferences(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "secretResourceVersion": { - SchemaProps: spec.SchemaProps{ - Type: []string{"string"}, - Format: "", - }, - }, - "tlsSecretResourceVersion": { - SchemaProps: spec.SchemaProps{ - Type: []string{"string"}, - Format: "", - }, - }, - "connectionProfileResourceVersion": { - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "syncProfileResourceVersion": { - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - Required: []string{"connectionProfileResourceVersion", "syncProfileResourceVersion"}, - }, - }, - } -} - -func schema_config_server_apis_inv_v1alpha1_TargetSyncProfile(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "TargetSyncProfile is the Schema for the TargetSyncProfile API", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Type: []string{"string"}, - Format: "", - }, - }, - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", - Type: []string{"string"}, - Format: "", - }, - }, - "metadata": { - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), - }, - }, - "spec": { - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.TargetSyncProfileSpec"), - }, - }, - }, - }, - }, - Dependencies: []string{ - "github.com/sdcio/config-server/apis/inv/v1alpha1.TargetSyncProfileSpec", metav1.ObjectMeta{}.OpenAPIModelName()}, - } -} - -func schema_config_server_apis_inv_v1alpha1_TargetSyncProfileList(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "TargetSyncProfileList contains a list of TargetSyncProfiles", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Type: []string{"string"}, - Format: "", - }, - }, - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", - Type: []string{"string"}, - Format: "", - }, - }, - "metadata": { - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), - }, - }, - "items": { - SchemaProps: spec.SchemaProps{ - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.TargetSyncProfile"), - }, - }, - }, - }, - }, - }, - Required: []string{"items"}, - }, - }, - Dependencies: []string{ - "github.com/sdcio/config-server/apis/inv/v1alpha1.TargetSyncProfile", metav1.ListMeta{}.OpenAPIModelName()}, - } -} - -func schema_config_server_apis_inv_v1alpha1_TargetSyncProfileSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "TargetSyncProfileSpec defines the desired state of TargetSyncProfile", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "validate": { - SchemaProps: spec.SchemaProps{ - Type: []string{"boolean"}, - Format: "", - }, - }, - "buffer": { - SchemaProps: spec.SchemaProps{ - Type: []string{"integer"}, - Format: "int64", - }, - }, - "workers": { - SchemaProps: spec.SchemaProps{ - Type: []string{"integer"}, - Format: "int64", - }, - }, - "sync": { - SchemaProps: spec.SchemaProps{ - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.TargetSyncProfileSync"), - }, - }, - }, - }, - }, - }, - Required: []string{"sync"}, - }, - }, - Dependencies: []string{ - "github.com/sdcio/config-server/apis/inv/v1alpha1.TargetSyncProfileSync"}, - } -} - -func schema_config_server_apis_inv_v1alpha1_TargetSyncProfileSync(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "TargetSyncProfileSync defines the desired state of TargetSyncProfileSync", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "name": { - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "protocol": { - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "port": { - SchemaProps: spec.SchemaProps{ - Description: "Port defines the port on which the scan runs", - Default: 0, - Type: []string{"integer"}, - Format: "int64", - }, - }, - "paths": { - SchemaProps: spec.SchemaProps{ - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - "mode": { - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "encoding": { - SchemaProps: spec.SchemaProps{ - Type: []string{"string"}, - Format: "", - }, - }, - "interval": { - SchemaProps: spec.SchemaProps{ - Ref: ref(metav1.Duration{}.OpenAPIModelName()), - }, - }, - }, - Required: []string{"name", "protocol", "port", "paths", "mode"}, - }, - }, - Dependencies: []string{ - metav1.Duration{}.OpenAPIModelName()}, - } -} - -func schema_config_server_apis_inv_v1alpha1_TargetTemplate(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "TargetTemplate defines the template of the target", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "nameTemplate": { - SchemaProps: spec.SchemaProps{ - Description: "target name template", - Type: []string{"string"}, - Format: "", - }, - }, - "annotations": { - SchemaProps: spec.SchemaProps{ - Description: "Annotations is a key value map to be copied to the target CR.", - Type: []string{"object"}, - AdditionalProperties: &spec.SchemaOrBool{ - Allows: true, - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - "labels": { - SchemaProps: spec.SchemaProps{ - Description: "Labels is a key value map to be copied to the target CR.", - Type: []string{"object"}, - AdditionalProperties: &spec.SchemaOrBool{ - Allows: true, - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - }, - }, - }, - } -} - -func schema_config_server_apis_inv_v1alpha1_Workspace(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "Workspace is the Workspace for the Workspace API", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Type: []string{"string"}, - Format: "", - }, - }, - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", - Type: []string{"string"}, - Format: "", - }, - }, - "metadata": { - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), - }, - }, - "spec": { - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.WorkspaceSpec"), - }, - }, - "status": { - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.WorkspaceStatus"), - }, - }, - }, - }, - }, - Dependencies: []string{ - "github.com/sdcio/config-server/apis/inv/v1alpha1.WorkspaceSpec", "github.com/sdcio/config-server/apis/inv/v1alpha1.WorkspaceStatus", metav1.ObjectMeta{}.OpenAPIModelName()}, - } -} - -func schema_config_server_apis_inv_v1alpha1_WorkspaceList(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "WorkspaceList contains a list of Workspaces", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Type: []string{"string"}, - Format: "", - }, - }, - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", - Type: []string{"string"}, - Format: "", - }, - }, - "metadata": { - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), - }, - }, - "items": { - SchemaProps: spec.SchemaProps{ - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.Workspace"), - }, - }, - }, - }, - }, - }, - Required: []string{"items"}, - }, - }, - Dependencies: []string{ - "github.com/sdcio/config-server/apis/inv/v1alpha1.Workspace", metav1.ListMeta{}.OpenAPIModelName()}, - } -} - -func schema_config_server_apis_inv_v1alpha1_WorkspaceSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "WorkspaceSpec defines the desired state of Workspace", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "repoURL": { - SchemaProps: spec.SchemaProps{ - Description: "RepositoryURL specifies the base URL for a given repository", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "credentials": { - SchemaProps: spec.SchemaProps{ - Description: "Credentials defines the name of the secret that holds the credentials to connect to the repo", - Type: []string{"string"}, - Format: "", - }, - }, - "proxy": { - SchemaProps: spec.SchemaProps{ - Description: "Proxy defines the HTTP/HTTPS proxy to be used to connect to the repo.", - Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.Proxy"), - }, - }, - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind defines the that the BranchOrTag string is a repository branch or a tag", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "ref": { - SchemaProps: spec.SchemaProps{ - Description: "Ref defines the branch or tag of the repository corresponding to the provider schema version", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - Required: []string{"repoURL", "kind", "ref"}, - }, - }, - Dependencies: []string{ - "github.com/sdcio/config-server/apis/inv/v1alpha1.Proxy"}, - } -} - -func schema_config_server_apis_inv_v1alpha1_WorkspaceStatus(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "WorkspaceStatus defines the observed state of Workspace", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "conditions": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-map-keys": []interface{}{ - "type", - }, - "x-kubernetes-list-type": "map", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "Conditions of the resource.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref("github.com/sdcio/config-server/apis/condition/v1alpha1.Condition"), - }, - }, - }, - }, - }, - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind defines the that the BranchOrTag string is a repository branch or a tag", - Type: []string{"string"}, - Format: "", - }, - }, - "deployedRef": { - SchemaProps: spec.SchemaProps{ - Description: "DeployedRef is the reference that is deployed", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - Dependencies: []string{ - "github.com/sdcio/config-server/apis/condition/v1alpha1.Condition"}, - } -} - -func schema_k8sio_api_core_v1_AWSElasticBlockStoreVolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "Represents a Persistent Disk resource in AWS.\n\nAn AWS EBS disk must exist before mounting to a container. The disk must also be in the same AWS zone as the kubelet. An AWS EBS disk can only be mounted as read/write once. AWS EBS volumes support ownership management and SELinux relabeling.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "volumeID": { - SchemaProps: spec.SchemaProps{ - Description: "volumeID is unique ID of the persistent disk resource in AWS (Amazon EBS volume). More info: https://kubernetes.io/docs/concepts/storage/volumes#awselasticblockstore", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "fsType": { - SchemaProps: spec.SchemaProps{ - Description: "fsType is the filesystem type of the volume that you want to mount. Tip: Ensure that the filesystem type is supported by the host operating system. Examples: \"ext4\", \"xfs\", \"ntfs\". Implicitly inferred to be \"ext4\" if unspecified. More info: https://kubernetes.io/docs/concepts/storage/volumes#awselasticblockstore", - Type: []string{"string"}, - Format: "", - }, - }, - "partition": { - SchemaProps: spec.SchemaProps{ - Description: "partition is the partition in the volume that you want to mount. If omitted, the default is to mount by volume name. Examples: For volume /dev/sda1, you specify the partition as \"1\". Similarly, the volume partition for /dev/sda is \"0\" (or you can leave the property empty).", - Type: []string{"integer"}, - Format: "int32", - }, - }, - "readOnly": { - SchemaProps: spec.SchemaProps{ - Description: "readOnly value true will force the readOnly setting in VolumeMounts. More info: https://kubernetes.io/docs/concepts/storage/volumes#awselasticblockstore", - Type: []string{"boolean"}, - Format: "", - }, - }, - }, - Required: []string{"volumeID"}, - }, - }, - } -} - -func schema_k8sio_api_core_v1_Affinity(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "Affinity is a group of affinity scheduling rules.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "nodeAffinity": { - SchemaProps: spec.SchemaProps{ - Description: "Describes node affinity scheduling rules for the pod.", - Ref: ref(v1.NodeAffinity{}.OpenAPIModelName()), - }, - }, - "podAffinity": { - SchemaProps: spec.SchemaProps{ - Description: "Describes pod affinity scheduling rules (e.g. co-locate this pod in the same node, zone, etc. as some other pod(s)).", - Ref: ref(v1.PodAffinity{}.OpenAPIModelName()), - }, - }, - "podAntiAffinity": { - SchemaProps: spec.SchemaProps{ - Description: "Describes pod anti-affinity scheduling rules (e.g. avoid putting this pod in the same node, zone, etc. as some other pod(s)).", - Ref: ref(v1.PodAntiAffinity{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - Dependencies: []string{ - v1.NodeAffinity{}.OpenAPIModelName(), v1.PodAffinity{}.OpenAPIModelName(), v1.PodAntiAffinity{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_AppArmorProfile(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "AppArmorProfile defines a pod or container's AppArmor settings.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "type": { - SchemaProps: spec.SchemaProps{ - Description: "type indicates which kind of AppArmor profile will be applied. Valid options are:\n Localhost - a profile pre-loaded on the node.\n RuntimeDefault - the container runtime's default profile.\n Unconfined - no AppArmor enforcement.\n\nPossible enum values:\n - `\"Localhost\"` indicates that a profile pre-loaded on the node should be used.\n - `\"RuntimeDefault\"` indicates that the container runtime's default AppArmor profile should be used.\n - `\"Unconfined\"` indicates that no AppArmor profile should be enforced.", - Default: "", - Type: []string{"string"}, - Format: "", - Enum: []interface{}{"Localhost", "RuntimeDefault", "Unconfined"}, - }, - }, - "localhostProfile": { - SchemaProps: spec.SchemaProps{ - Description: "localhostProfile indicates a profile loaded on the node that should be used. The profile must be preconfigured on the node to work. Must match the loaded name of the profile. Must be set if and only if type is \"Localhost\".", - Type: []string{"string"}, - Format: "", - }, - }, - }, - Required: []string{"type"}, - }, - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-unions": []interface{}{ - map[string]interface{}{ - "discriminator": "type", - "fields-to-discriminateBy": map[string]interface{}{ - "localhostProfile": "LocalhostProfile", - }, - }, - }, - }, - }, - }, - } -} - -func schema_k8sio_api_core_v1_AttachedVolume(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "AttachedVolume describes a volume attached to a node", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "name": { - SchemaProps: spec.SchemaProps{ - Description: "Name of the attached volume", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "devicePath": { - SchemaProps: spec.SchemaProps{ - Description: "DevicePath represents the device path where the volume should be available", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - Required: []string{"name", "devicePath"}, - }, - }, - } -} - -func schema_k8sio_api_core_v1_AvoidPods(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "AvoidPods describes pods that should avoid this node. This is the value for a Node annotation with key scheduler.alpha.kubernetes.io/preferAvoidPods and will eventually become a field of NodeStatus.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "preferAvoidPods": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "Bounded-sized list of signatures of pods that should avoid this node, sorted in timestamp order from oldest to newest. Size of the slice is unspecified.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.PreferAvoidPodsEntry{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - }, - }, - }, - Dependencies: []string{ - v1.PreferAvoidPodsEntry{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_AzureDiskVolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "AzureDisk represents an Azure Data Disk mount on the host and bind mount to the pod.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "diskName": { - SchemaProps: spec.SchemaProps{ - Description: "diskName is the Name of the data disk in the blob storage", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "diskURI": { - SchemaProps: spec.SchemaProps{ - Description: "diskURI is the URI of data disk in the blob storage", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "cachingMode": { - SchemaProps: spec.SchemaProps{ - Description: "cachingMode is the Host Caching mode: None, Read Only, Read Write.\n\nPossible enum values:\n - `\"None\"`\n - `\"ReadOnly\"`\n - `\"ReadWrite\"`", - Default: v1.AzureDataDiskCachingReadWrite, - Type: []string{"string"}, - Format: "", - Enum: []interface{}{"None", "ReadOnly", "ReadWrite"}, - }, - }, - "fsType": { - SchemaProps: spec.SchemaProps{ - Description: "fsType is Filesystem type to mount. Must be a filesystem type supported by the host operating system. Ex. \"ext4\", \"xfs\", \"ntfs\". Implicitly inferred to be \"ext4\" if unspecified.", - Default: "ext4", - Type: []string{"string"}, - Format: "", - }, - }, - "readOnly": { - SchemaProps: spec.SchemaProps{ - Description: "readOnly Defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts.", - Default: false, - Type: []string{"boolean"}, - Format: "", - }, - }, - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "kind expected values are Shared: multiple blob disks per storage account Dedicated: single blob disk per storage account Managed: azure managed data disk (only in managed availability set). defaults to shared\n\nPossible enum values:\n - `\"Dedicated\"`\n - `\"Managed\"`\n - `\"Shared\"`", - Default: v1.AzureSharedBlobDisk, - Type: []string{"string"}, - Format: "", - Enum: []interface{}{"Dedicated", "Managed", "Shared"}, - }, - }, - }, - Required: []string{"diskName", "diskURI"}, - }, - }, - } -} - -func schema_k8sio_api_core_v1_AzureFilePersistentVolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "AzureFile represents an Azure File Service mount on the host and bind mount to the pod.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "secretName": { - SchemaProps: spec.SchemaProps{ - Description: "secretName is the name of secret that contains Azure Storage Account Name and Key", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "shareName": { - SchemaProps: spec.SchemaProps{ - Description: "shareName is the azure Share Name", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "readOnly": { - SchemaProps: spec.SchemaProps{ - Description: "readOnly defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts.", - Type: []string{"boolean"}, - Format: "", - }, - }, - "secretNamespace": { - SchemaProps: spec.SchemaProps{ - Description: "secretNamespace is the namespace of the secret that contains Azure Storage Account Name and Key default is the same as the Pod", - Type: []string{"string"}, - Format: "", - }, - }, - }, - Required: []string{"secretName", "shareName"}, - }, - }, - } -} - -func schema_k8sio_api_core_v1_AzureFileVolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "AzureFile represents an Azure File Service mount on the host and bind mount to the pod.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "secretName": { - SchemaProps: spec.SchemaProps{ - Description: "secretName is the name of secret that contains Azure Storage Account Name and Key", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "shareName": { - SchemaProps: spec.SchemaProps{ - Description: "shareName is the azure share Name", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "readOnly": { - SchemaProps: spec.SchemaProps{ - Description: "readOnly defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts.", - Type: []string{"boolean"}, - Format: "", - }, - }, - }, - Required: []string{"secretName", "shareName"}, - }, - }, - } -} - -func schema_k8sio_api_core_v1_Binding(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "Binding ties one object to another; for example, a pod is bound to a node by a scheduler.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Type: []string{"string"}, - Format: "", - }, - }, - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", - Type: []string{"string"}, - Format: "", - }, - }, - "metadata": { - SchemaProps: spec.SchemaProps{ - Description: "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata", - Default: map[string]interface{}{}, - Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), - }, - }, - "target": { - SchemaProps: spec.SchemaProps{ - Description: "The target object that you want to bind to the standard object.", - Default: map[string]interface{}{}, - Ref: ref(v1.ObjectReference{}.OpenAPIModelName()), - }, - }, - }, - Required: []string{"target"}, - }, - }, - Dependencies: []string{ - v1.ObjectReference{}.OpenAPIModelName(), metav1.ObjectMeta{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_CSIPersistentVolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "Represents storage that is managed by an external CSI volume driver", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "driver": { - SchemaProps: spec.SchemaProps{ - Description: "driver is the name of the driver to use for this volume. Required.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "volumeHandle": { - SchemaProps: spec.SchemaProps{ - Description: "volumeHandle is the unique volume name returned by the CSI volume plugin’s CreateVolume to refer to the volume on all subsequent calls. Required.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "readOnly": { - SchemaProps: spec.SchemaProps{ - Description: "readOnly value to pass to ControllerPublishVolumeRequest. Defaults to false (read/write).", - Type: []string{"boolean"}, - Format: "", - }, - }, - "fsType": { - SchemaProps: spec.SchemaProps{ - Description: "fsType to mount. Must be a filesystem type supported by the host operating system. Ex. \"ext4\", \"xfs\", \"ntfs\".", - Type: []string{"string"}, - Format: "", - }, - }, - "volumeAttributes": { - SchemaProps: spec.SchemaProps{ - Description: "volumeAttributes of the volume to publish.", - Type: []string{"object"}, - AdditionalProperties: &spec.SchemaOrBool{ - Allows: true, - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - "controllerPublishSecretRef": { - SchemaProps: spec.SchemaProps{ - Description: "controllerPublishSecretRef is a reference to the secret object containing sensitive information to pass to the CSI driver to complete the CSI ControllerPublishVolume and ControllerUnpublishVolume calls. This field is optional, and may be empty if no secret is required. If the secret object contains more than one secret, all secrets are passed.", - Ref: ref(v1.SecretReference{}.OpenAPIModelName()), - }, - }, - "nodeStageSecretRef": { - SchemaProps: spec.SchemaProps{ - Description: "nodeStageSecretRef is a reference to the secret object containing sensitive information to pass to the CSI driver to complete the CSI NodeStageVolume and NodeStageVolume and NodeUnstageVolume calls. This field is optional, and may be empty if no secret is required. If the secret object contains more than one secret, all secrets are passed.", - Ref: ref(v1.SecretReference{}.OpenAPIModelName()), - }, - }, - "nodePublishSecretRef": { - SchemaProps: spec.SchemaProps{ - Description: "nodePublishSecretRef is a reference to the secret object containing sensitive information to pass to the CSI driver to complete the CSI NodePublishVolume and NodeUnpublishVolume calls. This field is optional, and may be empty if no secret is required. If the secret object contains more than one secret, all secrets are passed.", - Ref: ref(v1.SecretReference{}.OpenAPIModelName()), - }, - }, - "controllerExpandSecretRef": { - SchemaProps: spec.SchemaProps{ - Description: "controllerExpandSecretRef is a reference to the secret object containing sensitive information to pass to the CSI driver to complete the CSI ControllerExpandVolume call. This field is optional, and may be empty if no secret is required. If the secret object contains more than one secret, all secrets are passed.", - Ref: ref(v1.SecretReference{}.OpenAPIModelName()), - }, - }, - "nodeExpandSecretRef": { - SchemaProps: spec.SchemaProps{ - Description: "nodeExpandSecretRef is a reference to the secret object containing sensitive information to pass to the CSI driver to complete the CSI NodeExpandVolume call. This field is optional, may be omitted if no secret is required. If the secret object contains more than one secret, all secrets are passed.", - Ref: ref(v1.SecretReference{}.OpenAPIModelName()), - }, - }, - }, - Required: []string{"driver", "volumeHandle"}, - }, - }, - Dependencies: []string{ - v1.SecretReference{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_CSIVolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "Represents a source location of a volume to mount, managed by an external CSI driver", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "driver": { - SchemaProps: spec.SchemaProps{ - Description: "driver is the name of the CSI driver that handles this volume. Consult with your admin for the correct name as registered in the cluster.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "readOnly": { - SchemaProps: spec.SchemaProps{ - Description: "readOnly specifies a read-only configuration for the volume. Defaults to false (read/write).", - Type: []string{"boolean"}, - Format: "", - }, - }, - "fsType": { - SchemaProps: spec.SchemaProps{ - Description: "fsType to mount. Ex. \"ext4\", \"xfs\", \"ntfs\". If not provided, the empty value is passed to the associated CSI driver which will determine the default filesystem to apply.", - Type: []string{"string"}, - Format: "", - }, - }, - "volumeAttributes": { - SchemaProps: spec.SchemaProps{ - Description: "volumeAttributes stores driver-specific properties that are passed to the CSI driver. Consult your driver's documentation for supported values.", - Type: []string{"object"}, - AdditionalProperties: &spec.SchemaOrBool{ - Allows: true, - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - "nodePublishSecretRef": { - SchemaProps: spec.SchemaProps{ - Description: "nodePublishSecretRef is a reference to the secret object containing sensitive information to pass to the CSI driver to complete the CSI NodePublishVolume and NodeUnpublishVolume calls. This field is optional, and may be empty if no secret is required. If the secret object contains more than one secret, all secret references are passed.", - Ref: ref(v1.LocalObjectReference{}.OpenAPIModelName()), - }, - }, - }, - Required: []string{"driver"}, - }, - }, - Dependencies: []string{ - v1.LocalObjectReference{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_Capabilities(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "Adds and removes POSIX capabilities from running containers.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "add": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "Added capabilities", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - "drop": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "Removed capabilities", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - }, - }, - }, - } -} - -func schema_k8sio_api_core_v1_CephFSPersistentVolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "Represents a Ceph Filesystem mount that lasts the lifetime of a pod Cephfs volumes do not support ownership management or SELinux relabeling.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "monitors": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "monitors is Required: Monitors is a collection of Ceph monitors More info: https://examples.k8s.io/volumes/cephfs/README.md#how-to-use-it", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - "path": { - SchemaProps: spec.SchemaProps{ - Description: "path is Optional: Used as the mounted root, rather than the full Ceph tree, default is /", - Type: []string{"string"}, - Format: "", - }, - }, - "user": { - SchemaProps: spec.SchemaProps{ - Description: "user is Optional: User is the rados user name, default is admin More info: https://examples.k8s.io/volumes/cephfs/README.md#how-to-use-it", - Type: []string{"string"}, - Format: "", - }, - }, - "secretFile": { - SchemaProps: spec.SchemaProps{ - Description: "secretFile is Optional: SecretFile is the path to key ring for User, default is /etc/ceph/user.secret More info: https://examples.k8s.io/volumes/cephfs/README.md#how-to-use-it", - Type: []string{"string"}, - Format: "", - }, - }, - "secretRef": { - SchemaProps: spec.SchemaProps{ - Description: "secretRef is Optional: SecretRef is reference to the authentication secret for User, default is empty. More info: https://examples.k8s.io/volumes/cephfs/README.md#how-to-use-it", - Ref: ref(v1.SecretReference{}.OpenAPIModelName()), - }, - }, - "readOnly": { - SchemaProps: spec.SchemaProps{ - Description: "readOnly is Optional: Defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts. More info: https://examples.k8s.io/volumes/cephfs/README.md#how-to-use-it", - Type: []string{"boolean"}, - Format: "", - }, - }, - }, - Required: []string{"monitors"}, - }, - }, - Dependencies: []string{ - v1.SecretReference{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_CephFSVolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "Represents a Ceph Filesystem mount that lasts the lifetime of a pod Cephfs volumes do not support ownership management or SELinux relabeling.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "monitors": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "monitors is Required: Monitors is a collection of Ceph monitors More info: https://examples.k8s.io/volumes/cephfs/README.md#how-to-use-it", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - "path": { - SchemaProps: spec.SchemaProps{ - Description: "path is Optional: Used as the mounted root, rather than the full Ceph tree, default is /", - Type: []string{"string"}, - Format: "", - }, - }, - "user": { - SchemaProps: spec.SchemaProps{ - Description: "user is optional: User is the rados user name, default is admin More info: https://examples.k8s.io/volumes/cephfs/README.md#how-to-use-it", - Type: []string{"string"}, - Format: "", - }, - }, - "secretFile": { - SchemaProps: spec.SchemaProps{ - Description: "secretFile is Optional: SecretFile is the path to key ring for User, default is /etc/ceph/user.secret More info: https://examples.k8s.io/volumes/cephfs/README.md#how-to-use-it", - Type: []string{"string"}, - Format: "", - }, - }, - "secretRef": { - SchemaProps: spec.SchemaProps{ - Description: "secretRef is Optional: SecretRef is reference to the authentication secret for User, default is empty. More info: https://examples.k8s.io/volumes/cephfs/README.md#how-to-use-it", - Ref: ref(v1.LocalObjectReference{}.OpenAPIModelName()), - }, - }, - "readOnly": { - SchemaProps: spec.SchemaProps{ - Description: "readOnly is Optional: Defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts. More info: https://examples.k8s.io/volumes/cephfs/README.md#how-to-use-it", - Type: []string{"boolean"}, - Format: "", - }, - }, - }, - Required: []string{"monitors"}, - }, - }, - Dependencies: []string{ - v1.LocalObjectReference{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_CinderPersistentVolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "Represents a cinder volume resource in Openstack. A Cinder volume must exist before mounting to a container. The volume must also be in the same region as the kubelet. Cinder volumes support ownership management and SELinux relabeling.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "volumeID": { - SchemaProps: spec.SchemaProps{ - Description: "volumeID used to identify the volume in cinder. More info: https://examples.k8s.io/mysql-cinder-pd/README.md", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "fsType": { - SchemaProps: spec.SchemaProps{ - Description: "fsType Filesystem type to mount. Must be a filesystem type supported by the host operating system. Examples: \"ext4\", \"xfs\", \"ntfs\". Implicitly inferred to be \"ext4\" if unspecified. More info: https://examples.k8s.io/mysql-cinder-pd/README.md", - Type: []string{"string"}, - Format: "", - }, - }, - "readOnly": { - SchemaProps: spec.SchemaProps{ - Description: "readOnly is Optional: Defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts. More info: https://examples.k8s.io/mysql-cinder-pd/README.md", - Type: []string{"boolean"}, - Format: "", - }, - }, - "secretRef": { - SchemaProps: spec.SchemaProps{ - Description: "secretRef is Optional: points to a secret object containing parameters used to connect to OpenStack.", - Ref: ref(v1.SecretReference{}.OpenAPIModelName()), - }, - }, - }, - Required: []string{"volumeID"}, - }, - }, - Dependencies: []string{ - v1.SecretReference{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_CinderVolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "Represents a cinder volume resource in Openstack. A Cinder volume must exist before mounting to a container. The volume must also be in the same region as the kubelet. Cinder volumes support ownership management and SELinux relabeling.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "volumeID": { - SchemaProps: spec.SchemaProps{ - Description: "volumeID used to identify the volume in cinder. More info: https://examples.k8s.io/mysql-cinder-pd/README.md", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "fsType": { - SchemaProps: spec.SchemaProps{ - Description: "fsType is the filesystem type to mount. Must be a filesystem type supported by the host operating system. Examples: \"ext4\", \"xfs\", \"ntfs\". Implicitly inferred to be \"ext4\" if unspecified. More info: https://examples.k8s.io/mysql-cinder-pd/README.md", - Type: []string{"string"}, - Format: "", - }, - }, - "readOnly": { - SchemaProps: spec.SchemaProps{ - Description: "readOnly defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts. More info: https://examples.k8s.io/mysql-cinder-pd/README.md", - Type: []string{"boolean"}, - Format: "", - }, - }, - "secretRef": { - SchemaProps: spec.SchemaProps{ - Description: "secretRef is optional: points to a secret object containing parameters used to connect to OpenStack.", - Ref: ref(v1.LocalObjectReference{}.OpenAPIModelName()), - }, - }, - }, - Required: []string{"volumeID"}, - }, - }, - Dependencies: []string{ - v1.LocalObjectReference{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_ClientIPConfig(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "ClientIPConfig represents the configurations of Client IP based session affinity.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "timeoutSeconds": { - SchemaProps: spec.SchemaProps{ - Description: "timeoutSeconds specifies the seconds of ClientIP type session sticky time. The value must be >0 && <=86400(for 1 day) if ServiceAffinity == \"ClientIP\". Default value is 10800(for 3 hours).", - Type: []string{"integer"}, - Format: "int32", - }, - }, - }, - }, - }, - } -} - -func schema_k8sio_api_core_v1_ClusterTrustBundleProjection(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "ClusterTrustBundleProjection describes how to select a set of ClusterTrustBundle objects and project their contents into the pod filesystem.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "name": { - SchemaProps: spec.SchemaProps{ - Description: "Select a single ClusterTrustBundle by object name. Mutually-exclusive with signerName and labelSelector.", - Type: []string{"string"}, - Format: "", - }, - }, - "signerName": { - SchemaProps: spec.SchemaProps{ - Description: "Select all ClusterTrustBundles that match this signer name. Mutually-exclusive with name. The contents of all selected ClusterTrustBundles will be unified and deduplicated.", - Type: []string{"string"}, - Format: "", - }, - }, - "labelSelector": { - SchemaProps: spec.SchemaProps{ - Description: "Select all ClusterTrustBundles that match this label selector. Only has effect if signerName is set. Mutually-exclusive with name. If unset, interpreted as \"match nothing\". If set but empty, interpreted as \"match everything\".", - Ref: ref(metav1.LabelSelector{}.OpenAPIModelName()), - }, - }, - "optional": { - SchemaProps: spec.SchemaProps{ - Description: "If true, don't block pod startup if the referenced ClusterTrustBundle(s) aren't available. If using name, then the named ClusterTrustBundle is allowed not to exist. If using signerName, then the combination of signerName and labelSelector is allowed to match zero ClusterTrustBundles.", - Type: []string{"boolean"}, - Format: "", - }, - }, - "path": { - SchemaProps: spec.SchemaProps{ - Description: "Relative path from the volume root to write the bundle.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - Required: []string{"path"}, - }, - }, - Dependencies: []string{ - metav1.LabelSelector{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_ComponentCondition(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "Information about the condition of a component.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "type": { - SchemaProps: spec.SchemaProps{ - Description: "Type of condition for a component. Valid value: \"Healthy\"", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "status": { - SchemaProps: spec.SchemaProps{ - Description: "Status of the condition for a component. Valid values for \"Healthy\": \"True\", \"False\", or \"Unknown\".", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "message": { - SchemaProps: spec.SchemaProps{ - Description: "Message about the condition for a component. For example, information about a health check.", - Type: []string{"string"}, - Format: "", - }, - }, - "error": { - SchemaProps: spec.SchemaProps{ - Description: "Condition error code for a component. For example, a health check error code.", - Type: []string{"string"}, - Format: "", - }, - }, - }, - Required: []string{"type", "status"}, - }, - }, - } -} - -func schema_k8sio_api_core_v1_ComponentStatus(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "ComponentStatus (and ComponentStatusList) holds the cluster validation info. Deprecated: This API is deprecated in v1.19+", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Type: []string{"string"}, - Format: "", - }, - }, - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", - Type: []string{"string"}, - Format: "", - }, - }, - "metadata": { - SchemaProps: spec.SchemaProps{ - Description: "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata", - Default: map[string]interface{}{}, - Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), - }, - }, - "conditions": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-map-keys": []interface{}{ - "type", - }, - "x-kubernetes-list-type": "map", - "x-kubernetes-patch-merge-key": "type", - "x-kubernetes-patch-strategy": "merge", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "List of component conditions observed", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.ComponentCondition{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - }, - }, - }, - Dependencies: []string{ - v1.ComponentCondition{}.OpenAPIModelName(), metav1.ObjectMeta{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_ComponentStatusList(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "Status of all the conditions for the component as a list of ComponentStatus objects. Deprecated: This API is deprecated in v1.19+", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Type: []string{"string"}, - Format: "", - }, - }, - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", - Type: []string{"string"}, - Format: "", - }, - }, - "metadata": { - SchemaProps: spec.SchemaProps{ - Description: "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Default: map[string]interface{}{}, - Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), - }, - }, - "items": { - SchemaProps: spec.SchemaProps{ - Description: "List of ComponentStatus objects.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.ComponentStatus{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - }, - Required: []string{"items"}, - }, - }, - Dependencies: []string{ - v1.ComponentStatus{}.OpenAPIModelName(), metav1.ListMeta{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_ConfigMap(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "ConfigMap holds configuration data for pods to consume.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Type: []string{"string"}, - Format: "", - }, - }, - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", - Type: []string{"string"}, - Format: "", - }, - }, - "metadata": { - SchemaProps: spec.SchemaProps{ - Description: "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata", - Default: map[string]interface{}{}, - Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), - }, - }, - "immutable": { - SchemaProps: spec.SchemaProps{ - Description: "Immutable, if set to true, ensures that data stored in the ConfigMap cannot be updated (only object metadata can be modified). If not set to true, the field can be modified at any time. Defaulted to nil.", - Type: []string{"boolean"}, - Format: "", - }, - }, - "data": { - SchemaProps: spec.SchemaProps{ - Description: "Data contains the configuration data. Each key must consist of alphanumeric characters, '-', '_' or '.'. Values with non-UTF-8 byte sequences must use the BinaryData field. The keys stored in Data must not overlap with the keys in the BinaryData field, this is enforced during validation process.", - Type: []string{"object"}, - AdditionalProperties: &spec.SchemaOrBool{ - Allows: true, - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - "binaryData": { - SchemaProps: spec.SchemaProps{ - Description: "BinaryData contains the binary data. Each key must consist of alphanumeric characters, '-', '_' or '.'. BinaryData can contain byte sequences that are not in the UTF-8 range. The keys stored in BinaryData must not overlap with the ones in the Data field, this is enforced during validation process. Using this field will require 1.10+ apiserver and kubelet.", - Type: []string{"object"}, - AdditionalProperties: &spec.SchemaOrBool{ - Allows: true, - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Type: []string{"string"}, - Format: "byte", - }, - }, - }, - }, - }, - }, - }, - }, - Dependencies: []string{ - metav1.ObjectMeta{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_ConfigMapEnvSource(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "ConfigMapEnvSource selects a ConfigMap to populate the environment variables with.\n\nThe contents of the target ConfigMap's Data field will represent the key-value pairs as environment variables.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "name": { - SchemaProps: spec.SchemaProps{ - Description: "Name of the referent. This field is effectively required, but due to backwards compatibility is allowed to be empty. Instances of this type with an empty value here are almost certainly wrong. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "optional": { - SchemaProps: spec.SchemaProps{ - Description: "Specify whether the ConfigMap must be defined", - Type: []string{"boolean"}, - Format: "", - }, - }, - }, - }, - }, - } -} - -func schema_k8sio_api_core_v1_ConfigMapKeySelector(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "Selects a key from a ConfigMap.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "name": { - SchemaProps: spec.SchemaProps{ - Description: "Name of the referent. This field is effectively required, but due to backwards compatibility is allowed to be empty. Instances of this type with an empty value here are almost certainly wrong. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "key": { - SchemaProps: spec.SchemaProps{ - Description: "The key to select.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "optional": { - SchemaProps: spec.SchemaProps{ - Description: "Specify whether the ConfigMap or its key must be defined", - Type: []string{"boolean"}, - Format: "", - }, - }, - }, - Required: []string{"key"}, - }, - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-map-type": "atomic", - }, - }, - }, - } -} - -func schema_k8sio_api_core_v1_ConfigMapList(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "ConfigMapList is a resource containing a list of ConfigMap objects.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Type: []string{"string"}, - Format: "", - }, - }, - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", - Type: []string{"string"}, - Format: "", - }, - }, - "metadata": { - SchemaProps: spec.SchemaProps{ - Description: "More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata", - Default: map[string]interface{}{}, - Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), - }, - }, - "items": { - SchemaProps: spec.SchemaProps{ - Description: "Items is the list of ConfigMaps.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.ConfigMap{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - }, - Required: []string{"items"}, - }, - }, - Dependencies: []string{ - v1.ConfigMap{}.OpenAPIModelName(), metav1.ListMeta{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_ConfigMapNodeConfigSource(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "ConfigMapNodeConfigSource contains the information to reference a ConfigMap as a config source for the Node. This API is deprecated since 1.22: https://git.k8s.io/enhancements/keps/sig-node/281-dynamic-kubelet-configuration", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "namespace": { - SchemaProps: spec.SchemaProps{ - Description: "Namespace is the metadata.namespace of the referenced ConfigMap. This field is required in all cases.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "name": { - SchemaProps: spec.SchemaProps{ - Description: "Name is the metadata.name of the referenced ConfigMap. This field is required in all cases.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "uid": { - SchemaProps: spec.SchemaProps{ - Description: "UID is the metadata.UID of the referenced ConfigMap. This field is forbidden in Node.Spec, and required in Node.Status.", - Type: []string{"string"}, - Format: "", - }, - }, - "resourceVersion": { - SchemaProps: spec.SchemaProps{ - Description: "ResourceVersion is the metadata.ResourceVersion of the referenced ConfigMap. This field is forbidden in Node.Spec, and required in Node.Status.", - Type: []string{"string"}, - Format: "", - }, - }, - "kubeletConfigKey": { - SchemaProps: spec.SchemaProps{ - Description: "KubeletConfigKey declares which key of the referenced ConfigMap corresponds to the KubeletConfiguration structure This field is required in all cases.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - Required: []string{"namespace", "name", "kubeletConfigKey"}, - }, - }, - } -} - -func schema_k8sio_api_core_v1_ConfigMapProjection(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "Adapts a ConfigMap into a projected volume.\n\nThe contents of the target ConfigMap's Data field will be presented in a projected volume as files using the keys in the Data field as the file names, unless the items element is populated with specific mappings of keys to paths. Note that this is identical to a configmap volume source without the default mode.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "name": { - SchemaProps: spec.SchemaProps{ - Description: "Name of the referent. This field is effectively required, but due to backwards compatibility is allowed to be empty. Instances of this type with an empty value here are almost certainly wrong. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "items": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "items if unspecified, each key-value pair in the Data field of the referenced ConfigMap will be projected into the volume as a file whose name is the key and content is the value. If specified, the listed keys will be projected into the specified paths, and unlisted keys will not be present. If a key is specified which is not present in the ConfigMap, the volume setup will error unless it is marked optional. Paths must be relative and may not contain the '..' path or start with '..'.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.KeyToPath{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "optional": { - SchemaProps: spec.SchemaProps{ - Description: "optional specify whether the ConfigMap or its keys must be defined", - Type: []string{"boolean"}, - Format: "", - }, - }, - }, - }, - }, - Dependencies: []string{ - v1.KeyToPath{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_ConfigMapVolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "Adapts a ConfigMap into a volume.\n\nThe contents of the target ConfigMap's Data field will be presented in a volume as files using the keys in the Data field as the file names, unless the items element is populated with specific mappings of keys to paths. ConfigMap volumes support ownership management and SELinux relabeling.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "name": { - SchemaProps: spec.SchemaProps{ - Description: "Name of the referent. This field is effectively required, but due to backwards compatibility is allowed to be empty. Instances of this type with an empty value here are almost certainly wrong. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "items": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "items if unspecified, each key-value pair in the Data field of the referenced ConfigMap will be projected into the volume as a file whose name is the key and content is the value. If specified, the listed keys will be projected into the specified paths, and unlisted keys will not be present. If a key is specified which is not present in the ConfigMap, the volume setup will error unless it is marked optional. Paths must be relative and may not contain the '..' path or start with '..'.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.KeyToPath{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "defaultMode": { - SchemaProps: spec.SchemaProps{ - Description: "defaultMode is optional: mode bits used to set permissions on created files by default. Must be an octal value between 0000 and 0777 or a decimal value between 0 and 511. YAML accepts both octal and decimal values, JSON requires decimal values for mode bits. Defaults to 0644. Directories within the path are not affected by this setting. This might be in conflict with other options that affect the file mode, like fsGroup, and the result can be other mode bits set.", - Type: []string{"integer"}, - Format: "int32", - }, - }, - "optional": { - SchemaProps: spec.SchemaProps{ - Description: "optional specify whether the ConfigMap or its keys must be defined", - Type: []string{"boolean"}, - Format: "", - }, - }, - }, - }, - }, - Dependencies: []string{ - v1.KeyToPath{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_Container(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "A single application container that you want to run within a pod.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "name": { - SchemaProps: spec.SchemaProps{ - Description: "Name of the container specified as a DNS_LABEL. Each container in a pod must have a unique name (DNS_LABEL). Cannot be updated.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "image": { - SchemaProps: spec.SchemaProps{ - Description: "Container image name. More info: https://kubernetes.io/docs/concepts/containers/images This field is optional to allow higher level config management to default or override container images in workload controllers like Deployments and StatefulSets.", - Type: []string{"string"}, - Format: "", - }, - }, - "command": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "Entrypoint array. Not executed within a shell. The container image's ENTRYPOINT is used if this is not provided. Variable references $(VAR_NAME) are expanded using the container's environment. If a variable cannot be resolved, the reference in the input string will be unchanged. Double $$ are reduced to a single $, which allows for escaping the $(VAR_NAME) syntax: i.e. \"$$(VAR_NAME)\" will produce the string literal \"$(VAR_NAME)\". Escaped references will never be expanded, regardless of whether the variable exists or not. Cannot be updated. More info: https://kubernetes.io/docs/tasks/inject-data-application/define-command-argument-container/#running-a-command-in-a-shell", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - "args": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "Arguments to the entrypoint. The container image's CMD is used if this is not provided. Variable references $(VAR_NAME) are expanded using the container's environment. If a variable cannot be resolved, the reference in the input string will be unchanged. Double $$ are reduced to a single $, which allows for escaping the $(VAR_NAME) syntax: i.e. \"$$(VAR_NAME)\" will produce the string literal \"$(VAR_NAME)\". Escaped references will never be expanded, regardless of whether the variable exists or not. Cannot be updated. More info: https://kubernetes.io/docs/tasks/inject-data-application/define-command-argument-container/#running-a-command-in-a-shell", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - "workingDir": { - SchemaProps: spec.SchemaProps{ - Description: "Container's working directory. If not specified, the container runtime's default will be used, which might be configured in the container image. Cannot be updated.", - Type: []string{"string"}, - Format: "", - }, - }, - "ports": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-map-keys": []interface{}{ - "containerPort", - "protocol", - }, - "x-kubernetes-list-type": "map", - "x-kubernetes-patch-merge-key": "containerPort", - "x-kubernetes-patch-strategy": "merge", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "List of ports to expose from the container. Not specifying a port here DOES NOT prevent that port from being exposed. Any port which is listening on the default \"0.0.0.0\" address inside a container will be accessible from the network. Modifying this array with strategic merge patch may corrupt the data. For more information See https://github.com/kubernetes/kubernetes/issues/108255. Cannot be updated.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.ContainerPort{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "envFrom": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "List of sources to populate environment variables in the container. The keys defined within a source may consist of any printable ASCII characters except '='. When a key exists in multiple sources, the value associated with the last source will take precedence. Values defined by an Env with a duplicate key will take precedence. Cannot be updated.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.EnvFromSource{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "env": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-map-keys": []interface{}{ - "name", - }, - "x-kubernetes-list-type": "map", - "x-kubernetes-patch-merge-key": "name", - "x-kubernetes-patch-strategy": "merge", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "List of environment variables to set in the container. Cannot be updated.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.EnvVar{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "resources": { - SchemaProps: spec.SchemaProps{ - Description: "Compute Resources required by this container. Cannot be updated. More info: https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/", - Default: map[string]interface{}{}, - Ref: ref(v1.ResourceRequirements{}.OpenAPIModelName()), - }, - }, - "resizePolicy": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "Resources resize policy for the container. This field cannot be set on ephemeral containers.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.ContainerResizePolicy{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "restartPolicy": { - SchemaProps: spec.SchemaProps{ - Description: "RestartPolicy defines the restart behavior of individual containers in a pod. This overrides the pod-level restart policy. When this field is not specified, the restart behavior is defined by the Pod's restart policy and the container type. Additionally, setting the RestartPolicy as \"Always\" for the init container will have the following effect: this init container will be continually restarted on exit until all regular containers have terminated. Once all regular containers have completed, all init containers with restartPolicy \"Always\" will be shut down. This lifecycle differs from normal init containers and is often referred to as a \"sidecar\" container. Although this init container still starts in the init container sequence, it does not wait for the container to complete before proceeding to the next init container. Instead, the next init container starts immediately after this init container is started, or after any startupProbe has successfully completed.", - Type: []string{"string"}, - Format: "", - }, - }, - "restartPolicyRules": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "Represents a list of rules to be checked to determine if the container should be restarted on exit. The rules are evaluated in order. Once a rule matches a container exit condition, the remaining rules are ignored. If no rule matches the container exit condition, the Container-level restart policy determines the whether the container is restarted or not. Constraints on the rules: - At most 20 rules are allowed. - Rules can have the same action. - Identical rules are not forbidden in validations. When rules are specified, container MUST set RestartPolicy explicitly even it if matches the Pod's RestartPolicy.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.ContainerRestartRule{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "volumeMounts": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-map-keys": []interface{}{ - "mountPath", - }, - "x-kubernetes-list-type": "map", - "x-kubernetes-patch-merge-key": "mountPath", - "x-kubernetes-patch-strategy": "merge", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "Pod volumes to mount into the container's filesystem. Cannot be updated.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.VolumeMount{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "volumeDevices": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-map-keys": []interface{}{ - "devicePath", - }, - "x-kubernetes-list-type": "map", - "x-kubernetes-patch-merge-key": "devicePath", - "x-kubernetes-patch-strategy": "merge", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "volumeDevices is the list of block devices to be used by the container.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.VolumeDevice{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "livenessProbe": { - SchemaProps: spec.SchemaProps{ - Description: "Periodic probe of container liveness. Container will be restarted if the probe fails. Cannot be updated. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#container-probes", - Ref: ref(v1.Probe{}.OpenAPIModelName()), - }, - }, - "readinessProbe": { - SchemaProps: spec.SchemaProps{ - Description: "Periodic probe of container service readiness. Container will be removed from service endpoints if the probe fails. Cannot be updated. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#container-probes", - Ref: ref(v1.Probe{}.OpenAPIModelName()), - }, - }, - "startupProbe": { - SchemaProps: spec.SchemaProps{ - Description: "StartupProbe indicates that the Pod has successfully initialized. If specified, no other probes are executed until this completes successfully. If this probe fails, the Pod will be restarted, just as if the livenessProbe failed. This can be used to provide different probe parameters at the beginning of a Pod's lifecycle, when it might take a long time to load data or warm a cache, than during steady-state operation. This cannot be updated. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#container-probes", - Ref: ref(v1.Probe{}.OpenAPIModelName()), - }, - }, - "lifecycle": { - SchemaProps: spec.SchemaProps{ - Description: "Actions that the management system should take in response to container lifecycle events. Cannot be updated.", - Ref: ref(v1.Lifecycle{}.OpenAPIModelName()), - }, - }, - "terminationMessagePath": { - SchemaProps: spec.SchemaProps{ - Description: "Optional: Path at which the file to which the container's termination message will be written is mounted into the container's filesystem. Message written is intended to be brief final status, such as an assertion failure message. Will be truncated by the node if greater than 4096 bytes. The total message length across all containers will be limited to 12kb. Defaults to /dev/termination-log. Cannot be updated.", - Type: []string{"string"}, - Format: "", - }, - }, - "terminationMessagePolicy": { - SchemaProps: spec.SchemaProps{ - Description: "Indicate how the termination message should be populated. File will use the contents of terminationMessagePath to populate the container status message on both success and failure. FallbackToLogsOnError will use the last chunk of container log output if the termination message file is empty and the container exited with an error. The log output is limited to 2048 bytes or 80 lines, whichever is smaller. Defaults to File. Cannot be updated.\n\nPossible enum values:\n - `\"FallbackToLogsOnError\"` will read the most recent contents of the container logs for the container status message when the container exits with an error and the terminationMessagePath has no contents.\n - `\"File\"` is the default behavior and will set the container status message to the contents of the container's terminationMessagePath when the container exits.", - Type: []string{"string"}, - Format: "", - Enum: []interface{}{"FallbackToLogsOnError", "File"}, - }, - }, - "imagePullPolicy": { - SchemaProps: spec.SchemaProps{ - Description: "Image pull policy. One of Always, Never, IfNotPresent. Defaults to Always if :latest tag is specified, or IfNotPresent otherwise. Cannot be updated. More info: https://kubernetes.io/docs/concepts/containers/images#updating-images\n\nPossible enum values:\n - `\"Always\"` means that kubelet always attempts to pull the latest image. Container will fail If the pull fails.\n - `\"IfNotPresent\"` means that kubelet pulls if the image isn't present on disk. Container will fail if the image isn't present and the pull fails.\n - `\"Never\"` means that kubelet never pulls an image, but only uses a local image. Container will fail if the image isn't present", - Type: []string{"string"}, - Format: "", - Enum: []interface{}{"Always", "IfNotPresent", "Never"}, - }, - }, - "securityContext": { - SchemaProps: spec.SchemaProps{ - Description: "SecurityContext defines the security options the container should be run with. If set, the fields of SecurityContext override the equivalent fields of PodSecurityContext. More info: https://kubernetes.io/docs/tasks/configure-pod-container/security-context/", - Ref: ref(v1.SecurityContext{}.OpenAPIModelName()), - }, - }, - "stdin": { - SchemaProps: spec.SchemaProps{ - Description: "Whether this container should allocate a buffer for stdin in the container runtime. If this is not set, reads from stdin in the container will always result in EOF. Default is false.", - Type: []string{"boolean"}, - Format: "", - }, - }, - "stdinOnce": { - SchemaProps: spec.SchemaProps{ - Description: "Whether the container runtime should close the stdin channel after it has been opened by a single attach. When stdin is true the stdin stream will remain open across multiple attach sessions. If stdinOnce is set to true, stdin is opened on container start, is empty until the first client attaches to stdin, and then remains open and accepts data until the client disconnects, at which time stdin is closed and remains closed until the container is restarted. If this flag is false, a container processes that reads from stdin will never receive an EOF. Default is false", - Type: []string{"boolean"}, - Format: "", - }, - }, - "tty": { - SchemaProps: spec.SchemaProps{ - Description: "Whether this container should allocate a TTY for itself, also requires 'stdin' to be true. Default is false.", - Type: []string{"boolean"}, - Format: "", - }, - }, - }, - Required: []string{"name"}, - }, - }, - Dependencies: []string{ - v1.ContainerPort{}.OpenAPIModelName(), v1.ContainerResizePolicy{}.OpenAPIModelName(), v1.ContainerRestartRule{}.OpenAPIModelName(), v1.EnvFromSource{}.OpenAPIModelName(), v1.EnvVar{}.OpenAPIModelName(), v1.Lifecycle{}.OpenAPIModelName(), v1.Probe{}.OpenAPIModelName(), v1.ResourceRequirements{}.OpenAPIModelName(), v1.SecurityContext{}.OpenAPIModelName(), v1.VolumeDevice{}.OpenAPIModelName(), v1.VolumeMount{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_ContainerExtendedResourceRequest(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "ContainerExtendedResourceRequest has the mapping of container name, extended resource name to the device request name.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "containerName": { - SchemaProps: spec.SchemaProps{ - Description: "The name of the container requesting resources.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "resourceName": { - SchemaProps: spec.SchemaProps{ - Description: "The name of the extended resource in that container which gets backed by DRA.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "requestName": { - SchemaProps: spec.SchemaProps{ - Description: "The name of the request in the special ResourceClaim which corresponds to the extended resource.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - Required: []string{"containerName", "resourceName", "requestName"}, - }, - }, - } -} - -func schema_k8sio_api_core_v1_ContainerImage(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "Describe a container image", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "names": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "Names by which this image is known. e.g. [\"kubernetes.example/hyperkube:v1.0.7\", \"cloud-vendor.registry.example/cloud-vendor/hyperkube:v1.0.7\"]", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - "sizeBytes": { - SchemaProps: spec.SchemaProps{ - Description: "The size of the image in bytes.", - Type: []string{"integer"}, - Format: "int64", - }, - }, - }, - }, - }, - } -} - -func schema_k8sio_api_core_v1_ContainerPort(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "ContainerPort represents a network port in a single container.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "name": { - SchemaProps: spec.SchemaProps{ - Description: "If specified, this must be an IANA_SVC_NAME and unique within the pod. Each named port in a pod must have a unique name. Name for the port that can be referred to by services.", - Type: []string{"string"}, - Format: "", - }, - }, - "hostPort": { - SchemaProps: spec.SchemaProps{ - Description: "Number of port to expose on the host. If specified, this must be a valid port number, 0 < x < 65536. If HostNetwork is specified, this must match ContainerPort. Most containers do not need this.", - Type: []string{"integer"}, - Format: "int32", - }, - }, - "containerPort": { - SchemaProps: spec.SchemaProps{ - Description: "Number of port to expose on the pod's IP address. This must be a valid port number, 0 < x < 65536.", - Default: 0, - Type: []string{"integer"}, - Format: "int32", - }, - }, - "protocol": { - SchemaProps: spec.SchemaProps{ - Description: "Protocol for port. Must be UDP, TCP, or SCTP. Defaults to \"TCP\".\n\nPossible enum values:\n - `\"SCTP\"` is the SCTP protocol.\n - `\"TCP\"` is the TCP protocol.\n - `\"UDP\"` is the UDP protocol.", - Default: "TCP", - Type: []string{"string"}, - Format: "", - Enum: []interface{}{"SCTP", "TCP", "UDP"}, - }, - }, - "hostIP": { - SchemaProps: spec.SchemaProps{ - Description: "What host IP to bind the external port to.", - Type: []string{"string"}, - Format: "", - }, - }, - }, - Required: []string{"containerPort"}, - }, - }, - } -} - -func schema_k8sio_api_core_v1_ContainerResizePolicy(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "ContainerResizePolicy represents resource resize policy for the container.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "resourceName": { - SchemaProps: spec.SchemaProps{ - Description: "Name of the resource to which this resource resize policy applies. Supported values: cpu, memory.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "restartPolicy": { - SchemaProps: spec.SchemaProps{ - Description: "Restart policy to apply when specified resource is resized. If not specified, it defaults to NotRequired.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - Required: []string{"resourceName", "restartPolicy"}, - }, - }, - } -} - -func schema_k8sio_api_core_v1_ContainerRestartRule(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "ContainerRestartRule describes how a container exit is handled.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "action": { - SchemaProps: spec.SchemaProps{ - Description: "Specifies the action taken on a container exit if the requirements are satisfied. The only possible value is \"Restart\" to restart the container.", - Type: []string{"string"}, - Format: "", - }, - }, - "exitCodes": { - SchemaProps: spec.SchemaProps{ - Description: "Represents the exit codes to check on container exits.", - Ref: ref(v1.ContainerRestartRuleOnExitCodes{}.OpenAPIModelName()), - }, - }, - }, - Required: []string{"action"}, - }, - }, - Dependencies: []string{ - v1.ContainerRestartRuleOnExitCodes{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_ContainerRestartRuleOnExitCodes(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "ContainerRestartRuleOnExitCodes describes the condition for handling an exited container based on its exit codes.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "operator": { - SchemaProps: spec.SchemaProps{ - Description: "Represents the relationship between the container exit code(s) and the specified values. Possible values are: - In: the requirement is satisfied if the container exit code is in the\n set of specified values.\n- NotIn: the requirement is satisfied if the container exit code is\n not in the set of specified values.", - Type: []string{"string"}, - Format: "", - }, - }, - "values": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "set", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "Specifies the set of values to check for container exit codes. At most 255 elements are allowed.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: 0, - Type: []string{"integer"}, - Format: "int32", - }, - }, - }, - }, - }, - }, - Required: []string{"operator"}, - }, - }, - } -} - -func schema_k8sio_api_core_v1_ContainerState(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "ContainerState holds a possible state of container. Only one of its members may be specified. If none of them is specified, the default one is ContainerStateWaiting.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "waiting": { - SchemaProps: spec.SchemaProps{ - Description: "Details about a waiting container", - Ref: ref(v1.ContainerStateWaiting{}.OpenAPIModelName()), - }, - }, - "running": { - SchemaProps: spec.SchemaProps{ - Description: "Details about a running container", - Ref: ref(v1.ContainerStateRunning{}.OpenAPIModelName()), - }, - }, - "terminated": { - SchemaProps: spec.SchemaProps{ - Description: "Details about a terminated container", - Ref: ref(v1.ContainerStateTerminated{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - Dependencies: []string{ - v1.ContainerStateRunning{}.OpenAPIModelName(), v1.ContainerStateTerminated{}.OpenAPIModelName(), v1.ContainerStateWaiting{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_ContainerStateRunning(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "ContainerStateRunning is a running state of a container.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "startedAt": { - SchemaProps: spec.SchemaProps{ - Description: "Time at which the container was last (re-)started", - Ref: ref(metav1.Time{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - Dependencies: []string{ - metav1.Time{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_ContainerStateTerminated(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "ContainerStateTerminated is a terminated state of a container.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "exitCode": { - SchemaProps: spec.SchemaProps{ - Description: "Exit status from the last termination of the container", - Default: 0, - Type: []string{"integer"}, - Format: "int32", - }, - }, - "signal": { - SchemaProps: spec.SchemaProps{ - Description: "Signal from the last termination of the container", - Type: []string{"integer"}, - Format: "int32", - }, - }, - "reason": { - SchemaProps: spec.SchemaProps{ - Description: "(brief) reason from the last termination of the container", - Type: []string{"string"}, - Format: "", - }, - }, - "message": { - SchemaProps: spec.SchemaProps{ - Description: "Message regarding the last termination of the container", - Type: []string{"string"}, - Format: "", - }, - }, - "startedAt": { - SchemaProps: spec.SchemaProps{ - Description: "Time at which previous execution of the container started", - Ref: ref(metav1.Time{}.OpenAPIModelName()), - }, - }, - "finishedAt": { - SchemaProps: spec.SchemaProps{ - Description: "Time at which the container last terminated", - Ref: ref(metav1.Time{}.OpenAPIModelName()), - }, - }, - "containerID": { - SchemaProps: spec.SchemaProps{ - Description: "Container's ID in the format '://'", - Type: []string{"string"}, - Format: "", - }, - }, - }, - Required: []string{"exitCode"}, - }, - }, - Dependencies: []string{ - metav1.Time{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_ContainerStateWaiting(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "ContainerStateWaiting is a waiting state of a container.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "reason": { - SchemaProps: spec.SchemaProps{ - Description: "(brief) reason the container is not yet running.", - Type: []string{"string"}, - Format: "", - }, - }, - "message": { - SchemaProps: spec.SchemaProps{ - Description: "Message regarding why the container is not yet running.", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - } -} - -func schema_k8sio_api_core_v1_ContainerStatus(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "ContainerStatus contains details for the current status of this container.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "name": { - SchemaProps: spec.SchemaProps{ - Description: "Name is a DNS_LABEL representing the unique name of the container. Each container in a pod must have a unique name across all container types. Cannot be updated.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "state": { - SchemaProps: spec.SchemaProps{ - Description: "State holds details about the container's current condition.", - Default: map[string]interface{}{}, - Ref: ref(v1.ContainerState{}.OpenAPIModelName()), - }, - }, - "lastState": { - SchemaProps: spec.SchemaProps{ - Description: "LastTerminationState holds the last termination state of the container to help debug container crashes and restarts. This field is not populated if the container is still running and RestartCount is 0.", - Default: map[string]interface{}{}, - Ref: ref(v1.ContainerState{}.OpenAPIModelName()), - }, - }, - "ready": { - SchemaProps: spec.SchemaProps{ - Description: "Ready specifies whether the container is currently passing its readiness check. The value will change as readiness probes keep executing. If no readiness probes are specified, this field defaults to true once the container is fully started (see Started field).\n\nThe value is typically used to determine whether a container is ready to accept traffic.", - Default: false, - Type: []string{"boolean"}, - Format: "", - }, - }, - "restartCount": { - SchemaProps: spec.SchemaProps{ - Description: "RestartCount holds the number of times the container has been restarted. Kubelet makes an effort to always increment the value, but there are cases when the state may be lost due to node restarts and then the value may be reset to 0. The value is never negative.", - Default: 0, - Type: []string{"integer"}, - Format: "int32", - }, - }, - "image": { - SchemaProps: spec.SchemaProps{ - Description: "Image is the name of container image that the container is running. The container image may not match the image used in the PodSpec, as it may have been resolved by the runtime. More info: https://kubernetes.io/docs/concepts/containers/images.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "imageID": { - SchemaProps: spec.SchemaProps{ - Description: "ImageID is the image ID of the container's image. The image ID may not match the image ID of the image used in the PodSpec, as it may have been resolved by the runtime.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "containerID": { - SchemaProps: spec.SchemaProps{ - Description: "ContainerID is the ID of the container in the format '://'. Where type is a container runtime identifier, returned from Version call of CRI API (for example \"containerd\").", - Type: []string{"string"}, - Format: "", - }, - }, - "started": { - SchemaProps: spec.SchemaProps{ - Description: "Started indicates whether the container has finished its postStart lifecycle hook and passed its startup probe. Initialized as false, becomes true after startupProbe is considered successful. Resets to false when the container is restarted, or if kubelet loses state temporarily. In both cases, startup probes will run again. Is always true when no startupProbe is defined and container is running and has passed the postStart lifecycle hook. The null value must be treated the same as false.", - Type: []string{"boolean"}, - Format: "", - }, - }, - "allocatedResources": { - SchemaProps: spec.SchemaProps{ - Description: "AllocatedResources represents the compute resources allocated for this container by the node. Kubelet sets this value to Container.Resources.Requests upon successful pod admission and after successfully admitting desired pod resize.", - Type: []string{"object"}, - AdditionalProperties: &spec.SchemaOrBool{ - Allows: true, - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Ref: ref(resource.Quantity{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "resources": { - SchemaProps: spec.SchemaProps{ - Description: "Resources represents the compute resource requests and limits that have been successfully enacted on the running container after it has been started or has been successfully resized.", - Ref: ref(v1.ResourceRequirements{}.OpenAPIModelName()), - }, - }, - "volumeMounts": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-map-keys": []interface{}{ - "mountPath", - }, - "x-kubernetes-list-type": "map", - "x-kubernetes-patch-merge-key": "mountPath", - "x-kubernetes-patch-strategy": "merge", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "Status of volume mounts.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.VolumeMountStatus{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "user": { - SchemaProps: spec.SchemaProps{ - Description: "User represents user identity information initially attached to the first process of the container", - Ref: ref(v1.ContainerUser{}.OpenAPIModelName()), - }, - }, - "allocatedResourcesStatus": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-map-keys": []interface{}{ - "name", - }, - "x-kubernetes-list-type": "map", - "x-kubernetes-patch-merge-key": "name", - "x-kubernetes-patch-strategy": "merge", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "AllocatedResourcesStatus represents the status of various resources allocated for this Pod.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.ResourceStatus{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "stopSignal": { - SchemaProps: spec.SchemaProps{ - Description: "StopSignal reports the effective stop signal for this container\n\nPossible enum values:\n - `\"SIGABRT\"`\n - `\"SIGALRM\"`\n - `\"SIGBUS\"`\n - `\"SIGCHLD\"`\n - `\"SIGCLD\"`\n - `\"SIGCONT\"`\n - `\"SIGFPE\"`\n - `\"SIGHUP\"`\n - `\"SIGILL\"`\n - `\"SIGINT\"`\n - `\"SIGIO\"`\n - `\"SIGIOT\"`\n - `\"SIGKILL\"`\n - `\"SIGPIPE\"`\n - `\"SIGPOLL\"`\n - `\"SIGPROF\"`\n - `\"SIGPWR\"`\n - `\"SIGQUIT\"`\n - `\"SIGRTMAX\"`\n - `\"SIGRTMAX-1\"`\n - `\"SIGRTMAX-10\"`\n - `\"SIGRTMAX-11\"`\n - `\"SIGRTMAX-12\"`\n - `\"SIGRTMAX-13\"`\n - `\"SIGRTMAX-14\"`\n - `\"SIGRTMAX-2\"`\n - `\"SIGRTMAX-3\"`\n - `\"SIGRTMAX-4\"`\n - `\"SIGRTMAX-5\"`\n - `\"SIGRTMAX-6\"`\n - `\"SIGRTMAX-7\"`\n - `\"SIGRTMAX-8\"`\n - `\"SIGRTMAX-9\"`\n - `\"SIGRTMIN\"`\n - `\"SIGRTMIN+1\"`\n - `\"SIGRTMIN+10\"`\n - `\"SIGRTMIN+11\"`\n - `\"SIGRTMIN+12\"`\n - `\"SIGRTMIN+13\"`\n - `\"SIGRTMIN+14\"`\n - `\"SIGRTMIN+15\"`\n - `\"SIGRTMIN+2\"`\n - `\"SIGRTMIN+3\"`\n - `\"SIGRTMIN+4\"`\n - `\"SIGRTMIN+5\"`\n - `\"SIGRTMIN+6\"`\n - `\"SIGRTMIN+7\"`\n - `\"SIGRTMIN+8\"`\n - `\"SIGRTMIN+9\"`\n - `\"SIGSEGV\"`\n - `\"SIGSTKFLT\"`\n - `\"SIGSTOP\"`\n - `\"SIGSYS\"`\n - `\"SIGTERM\"`\n - `\"SIGTRAP\"`\n - `\"SIGTSTP\"`\n - `\"SIGTTIN\"`\n - `\"SIGTTOU\"`\n - `\"SIGURG\"`\n - `\"SIGUSR1\"`\n - `\"SIGUSR2\"`\n - `\"SIGVTALRM\"`\n - `\"SIGWINCH\"`\n - `\"SIGXCPU\"`\n - `\"SIGXFSZ\"`", - Type: []string{"string"}, - Format: "", - Enum: []interface{}{"SIGABRT", "SIGALRM", "SIGBUS", "SIGCHLD", "SIGCLD", "SIGCONT", "SIGFPE", "SIGHUP", "SIGILL", "SIGINT", "SIGIO", "SIGIOT", "SIGKILL", "SIGPIPE", "SIGPOLL", "SIGPROF", "SIGPWR", "SIGQUIT", "SIGRTMAX", "SIGRTMAX-1", "SIGRTMAX-10", "SIGRTMAX-11", "SIGRTMAX-12", "SIGRTMAX-13", "SIGRTMAX-14", "SIGRTMAX-2", "SIGRTMAX-3", "SIGRTMAX-4", "SIGRTMAX-5", "SIGRTMAX-6", "SIGRTMAX-7", "SIGRTMAX-8", "SIGRTMAX-9", "SIGRTMIN", "SIGRTMIN+1", "SIGRTMIN+10", "SIGRTMIN+11", "SIGRTMIN+12", "SIGRTMIN+13", "SIGRTMIN+14", "SIGRTMIN+15", "SIGRTMIN+2", "SIGRTMIN+3", "SIGRTMIN+4", "SIGRTMIN+5", "SIGRTMIN+6", "SIGRTMIN+7", "SIGRTMIN+8", "SIGRTMIN+9", "SIGSEGV", "SIGSTKFLT", "SIGSTOP", "SIGSYS", "SIGTERM", "SIGTRAP", "SIGTSTP", "SIGTTIN", "SIGTTOU", "SIGURG", "SIGUSR1", "SIGUSR2", "SIGVTALRM", "SIGWINCH", "SIGXCPU", "SIGXFSZ"}, - }, - }, - }, - Required: []string{"name", "ready", "restartCount", "image", "imageID"}, - }, - }, - Dependencies: []string{ - v1.ContainerState{}.OpenAPIModelName(), v1.ContainerUser{}.OpenAPIModelName(), v1.ResourceRequirements{}.OpenAPIModelName(), v1.ResourceStatus{}.OpenAPIModelName(), v1.VolumeMountStatus{}.OpenAPIModelName(), resource.Quantity{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_ContainerUser(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "ContainerUser represents user identity information", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "linux": { - SchemaProps: spec.SchemaProps{ - Description: "Linux holds user identity information initially attached to the first process of the containers in Linux. Note that the actual running identity can be changed if the process has enough privilege to do so.", - Ref: ref(v1.LinuxContainerUser{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - Dependencies: []string{ - v1.LinuxContainerUser{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_DaemonEndpoint(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "DaemonEndpoint contains information about a single Daemon endpoint.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "Port": { - SchemaProps: spec.SchemaProps{ - Description: "Port number of the given endpoint.", - Default: 0, - Type: []string{"integer"}, - Format: "int32", - }, - }, - }, - Required: []string{"Port"}, - }, - }, - } -} - -func schema_k8sio_api_core_v1_DownwardAPIProjection(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "Represents downward API info for projecting into a projected volume. Note that this is identical to a downwardAPI volume source without the default mode.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "items": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "Items is a list of DownwardAPIVolume file", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.DownwardAPIVolumeFile{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - }, - }, - }, - Dependencies: []string{ - v1.DownwardAPIVolumeFile{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_DownwardAPIVolumeFile(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "DownwardAPIVolumeFile represents information to create the file containing the pod field", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "path": { - SchemaProps: spec.SchemaProps{ - Description: "Required: Path is the relative path name of the file to be created. Must not be absolute or contain the '..' path. Must be utf-8 encoded. The first item of the relative path must not start with '..'", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "fieldRef": { - SchemaProps: spec.SchemaProps{ - Description: "Required: Selects a field of the pod: only annotations, labels, name, namespace and uid are supported.", - Ref: ref(v1.ObjectFieldSelector{}.OpenAPIModelName()), - }, - }, - "resourceFieldRef": { - SchemaProps: spec.SchemaProps{ - Description: "Selects a resource of the container: only resources limits and requests (limits.cpu, limits.memory, requests.cpu and requests.memory) are currently supported.", - Ref: ref(v1.ResourceFieldSelector{}.OpenAPIModelName()), - }, - }, - "mode": { - SchemaProps: spec.SchemaProps{ - Description: "Optional: mode bits used to set permissions on this file, must be an octal value between 0000 and 0777 or a decimal value between 0 and 511. YAML accepts both octal and decimal values, JSON requires decimal values for mode bits. If not specified, the volume defaultMode will be used. This might be in conflict with other options that affect the file mode, like fsGroup, and the result can be other mode bits set.", - Type: []string{"integer"}, - Format: "int32", - }, - }, - }, - Required: []string{"path"}, - }, - }, - Dependencies: []string{ - v1.ObjectFieldSelector{}.OpenAPIModelName(), v1.ResourceFieldSelector{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_DownwardAPIVolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "DownwardAPIVolumeSource represents a volume containing downward API info. Downward API volumes support ownership management and SELinux relabeling.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "items": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "Items is a list of downward API volume file", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.DownwardAPIVolumeFile{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "defaultMode": { - SchemaProps: spec.SchemaProps{ - Description: "Optional: mode bits to use on created files by default. Must be a Optional: mode bits used to set permissions on created files by default. Must be an octal value between 0000 and 0777 or a decimal value between 0 and 511. YAML accepts both octal and decimal values, JSON requires decimal values for mode bits. Defaults to 0644. Directories within the path are not affected by this setting. This might be in conflict with other options that affect the file mode, like fsGroup, and the result can be other mode bits set.", - Type: []string{"integer"}, - Format: "int32", - }, - }, - }, - }, - }, - Dependencies: []string{ - v1.DownwardAPIVolumeFile{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_EmptyDirVolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "Represents an empty directory for a pod. Empty directory volumes support ownership management and SELinux relabeling.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "medium": { - SchemaProps: spec.SchemaProps{ - Description: "medium represents what type of storage medium should back this directory. The default is \"\" which means to use the node's default medium. Must be an empty string (default) or Memory. More info: https://kubernetes.io/docs/concepts/storage/volumes#emptydir", - Type: []string{"string"}, - Format: "", - }, - }, - "sizeLimit": { - SchemaProps: spec.SchemaProps{ - Description: "sizeLimit is the total amount of local storage required for this EmptyDir volume. The size limit is also applicable for memory medium. The maximum usage on memory medium EmptyDir would be the minimum value between the SizeLimit specified here and the sum of memory limits of all containers in a pod. The default is nil which means that the limit is undefined. More info: https://kubernetes.io/docs/concepts/storage/volumes#emptydir", - Ref: ref(resource.Quantity{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - Dependencies: []string{ - resource.Quantity{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_EndpointAddress(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "EndpointAddress is a tuple that describes single IP address. Deprecated: This API is deprecated in v1.33+.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "ip": { - SchemaProps: spec.SchemaProps{ - Description: "The IP of this endpoint. May not be loopback (127.0.0.0/8 or ::1), link-local (169.254.0.0/16 or fe80::/10), or link-local multicast (224.0.0.0/24 or ff02::/16).", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "hostname": { - SchemaProps: spec.SchemaProps{ - Description: "The Hostname of this endpoint", - Type: []string{"string"}, - Format: "", - }, - }, - "nodeName": { - SchemaProps: spec.SchemaProps{ - Description: "Optional: Node hosting this endpoint. This can be used to determine endpoints local to a node.", - Type: []string{"string"}, - Format: "", - }, - }, - "targetRef": { - SchemaProps: spec.SchemaProps{ - Description: "Reference to object providing the endpoint.", - Ref: ref(v1.ObjectReference{}.OpenAPIModelName()), - }, - }, - }, - Required: []string{"ip"}, - }, - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-map-type": "atomic", - }, - }, - }, - Dependencies: []string{ - v1.ObjectReference{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_EndpointPort(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "EndpointPort is a tuple that describes a single port. Deprecated: This API is deprecated in v1.33+.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "name": { - SchemaProps: spec.SchemaProps{ - Description: "The name of this port. This must match the 'name' field in the corresponding ServicePort. Must be a DNS_LABEL. Optional only if one port is defined.", - Type: []string{"string"}, - Format: "", - }, - }, - "port": { - SchemaProps: spec.SchemaProps{ - Description: "The port number of the endpoint.", - Default: 0, - Type: []string{"integer"}, - Format: "int32", - }, - }, - "protocol": { - SchemaProps: spec.SchemaProps{ - Description: "The IP protocol for this port. Must be UDP, TCP, or SCTP. Default is TCP.\n\nPossible enum values:\n - `\"SCTP\"` is the SCTP protocol.\n - `\"TCP\"` is the TCP protocol.\n - `\"UDP\"` is the UDP protocol.", - Type: []string{"string"}, - Format: "", - Enum: []interface{}{"SCTP", "TCP", "UDP"}, - }, - }, - "appProtocol": { - SchemaProps: spec.SchemaProps{ - Description: "The application protocol for this port. This is used as a hint for implementations to offer richer behavior for protocols that they understand. This field follows standard Kubernetes label syntax. Valid values are either:\n\n* Un-prefixed protocol names - reserved for IANA standard service names (as per RFC-6335 and https://www.iana.org/assignments/service-names).\n\n* Kubernetes-defined prefixed names:\n * 'kubernetes.io/h2c' - HTTP/2 prior knowledge over cleartext as described in https://www.rfc-editor.org/rfc/rfc9113.html#name-starting-http-2-with-prior-\n * 'kubernetes.io/ws' - WebSocket over cleartext as described in https://www.rfc-editor.org/rfc/rfc6455\n * 'kubernetes.io/wss' - WebSocket over TLS as described in https://www.rfc-editor.org/rfc/rfc6455\n\n* Other protocols should use implementation-defined prefixed names such as mycompany.com/my-custom-protocol.", - Type: []string{"string"}, - Format: "", - }, - }, - }, - Required: []string{"port"}, - }, - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-map-type": "atomic", - }, - }, - }, - } -} - -func schema_k8sio_api_core_v1_EndpointSubset(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "EndpointSubset is a group of addresses with a common set of ports. The expanded set of endpoints is the Cartesian product of Addresses x Ports. For example, given:\n\n\t{\n\t Addresses: [{\"ip\": \"10.10.1.1\"}, {\"ip\": \"10.10.2.2\"}],\n\t Ports: [{\"name\": \"a\", \"port\": 8675}, {\"name\": \"b\", \"port\": 309}]\n\t}\n\nThe resulting set of endpoints can be viewed as:\n\n\ta: [ 10.10.1.1:8675, 10.10.2.2:8675 ],\n\tb: [ 10.10.1.1:309, 10.10.2.2:309 ]\n\nDeprecated: This API is deprecated in v1.33+.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "addresses": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "IP addresses which offer the related ports that are marked as ready. These endpoints should be considered safe for load balancers and clients to utilize.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.EndpointAddress{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "notReadyAddresses": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "IP addresses which offer the related ports but are not currently marked as ready because they have not yet finished starting, have recently failed a readiness check, or have recently failed a liveness check.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.EndpointAddress{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "ports": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "Port numbers available on the related IP addresses.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.EndpointPort{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - }, - }, - }, - Dependencies: []string{ - v1.EndpointAddress{}.OpenAPIModelName(), v1.EndpointPort{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_Endpoints(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "Endpoints is a collection of endpoints that implement the actual service. Example:\n\n\t Name: \"mysvc\",\n\t Subsets: [\n\t {\n\t Addresses: [{\"ip\": \"10.10.1.1\"}, {\"ip\": \"10.10.2.2\"}],\n\t Ports: [{\"name\": \"a\", \"port\": 8675}, {\"name\": \"b\", \"port\": 309}]\n\t },\n\t {\n\t Addresses: [{\"ip\": \"10.10.3.3\"}],\n\t Ports: [{\"name\": \"a\", \"port\": 93}, {\"name\": \"b\", \"port\": 76}]\n\t },\n\t]\n\nEndpoints is a legacy API and does not contain information about all Service features. Use discoveryv1.EndpointSlice for complete information about Service endpoints.\n\nDeprecated: This API is deprecated in v1.33+. Use discoveryv1.EndpointSlice.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Type: []string{"string"}, - Format: "", - }, - }, - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", - Type: []string{"string"}, - Format: "", - }, - }, - "metadata": { - SchemaProps: spec.SchemaProps{ - Description: "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata", - Default: map[string]interface{}{}, - Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), - }, - }, - "subsets": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "The set of all endpoints is the union of all subsets. Addresses are placed into subsets according to the IPs they share. A single address with multiple ports, some of which are ready and some of which are not (because they come from different containers) will result in the address being displayed in different subsets for the different ports. No address will appear in both Addresses and NotReadyAddresses in the same subset. Sets of addresses and ports that comprise a service.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.EndpointSubset{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - }, - }, - }, - Dependencies: []string{ - v1.EndpointSubset{}.OpenAPIModelName(), metav1.ObjectMeta{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_EndpointsList(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "EndpointsList is a list of endpoints. Deprecated: This API is deprecated in v1.33+.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Type: []string{"string"}, - Format: "", - }, - }, - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", - Type: []string{"string"}, - Format: "", - }, - }, - "metadata": { - SchemaProps: spec.SchemaProps{ - Description: "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Default: map[string]interface{}{}, - Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), - }, - }, - "items": { - SchemaProps: spec.SchemaProps{ - Description: "List of endpoints.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.Endpoints{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - }, - Required: []string{"items"}, - }, - }, - Dependencies: []string{ - v1.Endpoints{}.OpenAPIModelName(), metav1.ListMeta{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_EnvFromSource(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "EnvFromSource represents the source of a set of ConfigMaps or Secrets", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "prefix": { - SchemaProps: spec.SchemaProps{ - Description: "Optional text to prepend to the name of each environment variable. May consist of any printable ASCII characters except '='.", - Type: []string{"string"}, - Format: "", - }, - }, - "configMapRef": { - SchemaProps: spec.SchemaProps{ - Description: "The ConfigMap to select from", - Ref: ref(v1.ConfigMapEnvSource{}.OpenAPIModelName()), - }, - }, - "secretRef": { - SchemaProps: spec.SchemaProps{ - Description: "The Secret to select from", - Ref: ref(v1.SecretEnvSource{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - Dependencies: []string{ - v1.ConfigMapEnvSource{}.OpenAPIModelName(), v1.SecretEnvSource{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_EnvVar(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "EnvVar represents an environment variable present in a Container.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "name": { - SchemaProps: spec.SchemaProps{ - Description: "Name of the environment variable. May consist of any printable ASCII characters except '='.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "value": { - SchemaProps: spec.SchemaProps{ - Description: "Variable references $(VAR_NAME) are expanded using the previously defined environment variables in the container and any service environment variables. If a variable cannot be resolved, the reference in the input string will be unchanged. Double $$ are reduced to a single $, which allows for escaping the $(VAR_NAME) syntax: i.e. \"$$(VAR_NAME)\" will produce the string literal \"$(VAR_NAME)\". Escaped references will never be expanded, regardless of whether the variable exists or not. Defaults to \"\".", - Type: []string{"string"}, - Format: "", - }, - }, - "valueFrom": { - SchemaProps: spec.SchemaProps{ - Description: "Source for the environment variable's value. Cannot be used if value is not empty.", - Ref: ref(v1.EnvVarSource{}.OpenAPIModelName()), - }, - }, - }, - Required: []string{"name"}, - }, - }, - Dependencies: []string{ - v1.EnvVarSource{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_EnvVarSource(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "EnvVarSource represents a source for the value of an EnvVar.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "fieldRef": { - SchemaProps: spec.SchemaProps{ - Description: "Selects a field of the pod: supports metadata.name, metadata.namespace, `metadata.labels['']`, `metadata.annotations['']`, spec.nodeName, spec.serviceAccountName, status.hostIP, status.podIP, status.podIPs.", - Ref: ref(v1.ObjectFieldSelector{}.OpenAPIModelName()), - }, - }, - "resourceFieldRef": { - SchemaProps: spec.SchemaProps{ - Description: "Selects a resource of the container: only resources limits and requests (limits.cpu, limits.memory, limits.ephemeral-storage, requests.cpu, requests.memory and requests.ephemeral-storage) are currently supported.", - Ref: ref(v1.ResourceFieldSelector{}.OpenAPIModelName()), - }, - }, - "configMapKeyRef": { - SchemaProps: spec.SchemaProps{ - Description: "Selects a key of a ConfigMap.", - Ref: ref(v1.ConfigMapKeySelector{}.OpenAPIModelName()), - }, - }, - "secretKeyRef": { - SchemaProps: spec.SchemaProps{ - Description: "Selects a key of a secret in the pod's namespace", - Ref: ref(v1.SecretKeySelector{}.OpenAPIModelName()), - }, - }, - "fileKeyRef": { - SchemaProps: spec.SchemaProps{ - Description: "FileKeyRef selects a key of the env file. Requires the EnvFiles feature gate to be enabled.", - Ref: ref(v1.FileKeySelector{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - Dependencies: []string{ - v1.ConfigMapKeySelector{}.OpenAPIModelName(), v1.FileKeySelector{}.OpenAPIModelName(), v1.ObjectFieldSelector{}.OpenAPIModelName(), v1.ResourceFieldSelector{}.OpenAPIModelName(), v1.SecretKeySelector{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_EphemeralContainer(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "An EphemeralContainer is a temporary container that you may add to an existing Pod for user-initiated activities such as debugging. Ephemeral containers have no resource or scheduling guarantees, and they will not be restarted when they exit or when a Pod is removed or restarted. The kubelet may evict a Pod if an ephemeral container causes the Pod to exceed its resource allocation.\n\nTo add an ephemeral container, use the ephemeralcontainers subresource of an existing Pod. Ephemeral containers may not be removed or restarted.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "name": { - SchemaProps: spec.SchemaProps{ - Description: "Name of the ephemeral container specified as a DNS_LABEL. This name must be unique among all containers, init containers and ephemeral containers.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "image": { - SchemaProps: spec.SchemaProps{ - Description: "Container image name. More info: https://kubernetes.io/docs/concepts/containers/images", - Type: []string{"string"}, - Format: "", - }, - }, - "command": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "Entrypoint array. Not executed within a shell. The image's ENTRYPOINT is used if this is not provided. Variable references $(VAR_NAME) are expanded using the container's environment. If a variable cannot be resolved, the reference in the input string will be unchanged. Double $$ are reduced to a single $, which allows for escaping the $(VAR_NAME) syntax: i.e. \"$$(VAR_NAME)\" will produce the string literal \"$(VAR_NAME)\". Escaped references will never be expanded, regardless of whether the variable exists or not. Cannot be updated. More info: https://kubernetes.io/docs/tasks/inject-data-application/define-command-argument-container/#running-a-command-in-a-shell", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - "args": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "Arguments to the entrypoint. The image's CMD is used if this is not provided. Variable references $(VAR_NAME) are expanded using the container's environment. If a variable cannot be resolved, the reference in the input string will be unchanged. Double $$ are reduced to a single $, which allows for escaping the $(VAR_NAME) syntax: i.e. \"$$(VAR_NAME)\" will produce the string literal \"$(VAR_NAME)\". Escaped references will never be expanded, regardless of whether the variable exists or not. Cannot be updated. More info: https://kubernetes.io/docs/tasks/inject-data-application/define-command-argument-container/#running-a-command-in-a-shell", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - "workingDir": { - SchemaProps: spec.SchemaProps{ - Description: "Container's working directory. If not specified, the container runtime's default will be used, which might be configured in the container image. Cannot be updated.", - Type: []string{"string"}, - Format: "", - }, - }, - "ports": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-map-keys": []interface{}{ - "containerPort", - "protocol", - }, - "x-kubernetes-list-type": "map", - "x-kubernetes-patch-merge-key": "containerPort", - "x-kubernetes-patch-strategy": "merge", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "Ports are not allowed for ephemeral containers.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.ContainerPort{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "envFrom": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "List of sources to populate environment variables in the container. The keys defined within a source may consist of any printable ASCII characters except '='. When a key exists in multiple sources, the value associated with the last source will take precedence. Values defined by an Env with a duplicate key will take precedence. Cannot be updated.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.EnvFromSource{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "env": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-map-keys": []interface{}{ - "name", - }, - "x-kubernetes-list-type": "map", - "x-kubernetes-patch-merge-key": "name", - "x-kubernetes-patch-strategy": "merge", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "List of environment variables to set in the container. Cannot be updated.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.EnvVar{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "resources": { - SchemaProps: spec.SchemaProps{ - Description: "Resources are not allowed for ephemeral containers. Ephemeral containers use spare resources already allocated to the pod.", - Default: map[string]interface{}{}, - Ref: ref(v1.ResourceRequirements{}.OpenAPIModelName()), - }, - }, - "resizePolicy": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "Resources resize policy for the container.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.ContainerResizePolicy{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "restartPolicy": { - SchemaProps: spec.SchemaProps{ - Description: "Restart policy for the container to manage the restart behavior of each container within a pod. You cannot set this field on ephemeral containers.", - Type: []string{"string"}, - Format: "", - }, - }, - "restartPolicyRules": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "Represents a list of rules to be checked to determine if the container should be restarted on exit. You cannot set this field on ephemeral containers.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.ContainerRestartRule{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "volumeMounts": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-map-keys": []interface{}{ - "mountPath", - }, - "x-kubernetes-list-type": "map", - "x-kubernetes-patch-merge-key": "mountPath", - "x-kubernetes-patch-strategy": "merge", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "Pod volumes to mount into the container's filesystem. Subpath mounts are not allowed for ephemeral containers. Cannot be updated.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.VolumeMount{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "volumeDevices": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-map-keys": []interface{}{ - "devicePath", - }, - "x-kubernetes-list-type": "map", - "x-kubernetes-patch-merge-key": "devicePath", - "x-kubernetes-patch-strategy": "merge", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "volumeDevices is the list of block devices to be used by the container.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.VolumeDevice{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "livenessProbe": { - SchemaProps: spec.SchemaProps{ - Description: "Probes are not allowed for ephemeral containers.", - Ref: ref(v1.Probe{}.OpenAPIModelName()), - }, - }, - "readinessProbe": { - SchemaProps: spec.SchemaProps{ - Description: "Probes are not allowed for ephemeral containers.", - Ref: ref(v1.Probe{}.OpenAPIModelName()), - }, - }, - "startupProbe": { - SchemaProps: spec.SchemaProps{ - Description: "Probes are not allowed for ephemeral containers.", - Ref: ref(v1.Probe{}.OpenAPIModelName()), - }, - }, - "lifecycle": { - SchemaProps: spec.SchemaProps{ - Description: "Lifecycle is not allowed for ephemeral containers.", - Ref: ref(v1.Lifecycle{}.OpenAPIModelName()), - }, - }, - "terminationMessagePath": { - SchemaProps: spec.SchemaProps{ - Description: "Optional: Path at which the file to which the container's termination message will be written is mounted into the container's filesystem. Message written is intended to be brief final status, such as an assertion failure message. Will be truncated by the node if greater than 4096 bytes. The total message length across all containers will be limited to 12kb. Defaults to /dev/termination-log. Cannot be updated.", - Type: []string{"string"}, - Format: "", - }, - }, - "terminationMessagePolicy": { - SchemaProps: spec.SchemaProps{ - Description: "Indicate how the termination message should be populated. File will use the contents of terminationMessagePath to populate the container status message on both success and failure. FallbackToLogsOnError will use the last chunk of container log output if the termination message file is empty and the container exited with an error. The log output is limited to 2048 bytes or 80 lines, whichever is smaller. Defaults to File. Cannot be updated.\n\nPossible enum values:\n - `\"FallbackToLogsOnError\"` will read the most recent contents of the container logs for the container status message when the container exits with an error and the terminationMessagePath has no contents.\n - `\"File\"` is the default behavior and will set the container status message to the contents of the container's terminationMessagePath when the container exits.", - Type: []string{"string"}, - Format: "", - Enum: []interface{}{"FallbackToLogsOnError", "File"}, - }, - }, - "imagePullPolicy": { - SchemaProps: spec.SchemaProps{ - Description: "Image pull policy. One of Always, Never, IfNotPresent. Defaults to Always if :latest tag is specified, or IfNotPresent otherwise. Cannot be updated. More info: https://kubernetes.io/docs/concepts/containers/images#updating-images\n\nPossible enum values:\n - `\"Always\"` means that kubelet always attempts to pull the latest image. Container will fail If the pull fails.\n - `\"IfNotPresent\"` means that kubelet pulls if the image isn't present on disk. Container will fail if the image isn't present and the pull fails.\n - `\"Never\"` means that kubelet never pulls an image, but only uses a local image. Container will fail if the image isn't present", - Type: []string{"string"}, - Format: "", - Enum: []interface{}{"Always", "IfNotPresent", "Never"}, - }, - }, - "securityContext": { - SchemaProps: spec.SchemaProps{ - Description: "Optional: SecurityContext defines the security options the ephemeral container should be run with. If set, the fields of SecurityContext override the equivalent fields of PodSecurityContext.", - Ref: ref(v1.SecurityContext{}.OpenAPIModelName()), - }, - }, - "stdin": { - SchemaProps: spec.SchemaProps{ - Description: "Whether this container should allocate a buffer for stdin in the container runtime. If this is not set, reads from stdin in the container will always result in EOF. Default is false.", - Type: []string{"boolean"}, - Format: "", - }, - }, - "stdinOnce": { - SchemaProps: spec.SchemaProps{ - Description: "Whether the container runtime should close the stdin channel after it has been opened by a single attach. When stdin is true the stdin stream will remain open across multiple attach sessions. If stdinOnce is set to true, stdin is opened on container start, is empty until the first client attaches to stdin, and then remains open and accepts data until the client disconnects, at which time stdin is closed and remains closed until the container is restarted. If this flag is false, a container processes that reads from stdin will never receive an EOF. Default is false", - Type: []string{"boolean"}, - Format: "", - }, - }, - "tty": { - SchemaProps: spec.SchemaProps{ - Description: "Whether this container should allocate a TTY for itself, also requires 'stdin' to be true. Default is false.", - Type: []string{"boolean"}, - Format: "", - }, - }, - "targetContainerName": { - SchemaProps: spec.SchemaProps{ - Description: "If set, the name of the container from PodSpec that this ephemeral container targets. The ephemeral container will be run in the namespaces (IPC, PID, etc) of this container. If not set then the ephemeral container uses the namespaces configured in the Pod spec.\n\nThe container runtime must implement support for this feature. If the runtime does not support namespace targeting then the result of setting this field is undefined.", - Type: []string{"string"}, - Format: "", - }, - }, - }, - Required: []string{"name"}, - }, - }, - Dependencies: []string{ - v1.ContainerPort{}.OpenAPIModelName(), v1.ContainerResizePolicy{}.OpenAPIModelName(), v1.ContainerRestartRule{}.OpenAPIModelName(), v1.EnvFromSource{}.OpenAPIModelName(), v1.EnvVar{}.OpenAPIModelName(), v1.Lifecycle{}.OpenAPIModelName(), v1.Probe{}.OpenAPIModelName(), v1.ResourceRequirements{}.OpenAPIModelName(), v1.SecurityContext{}.OpenAPIModelName(), v1.VolumeDevice{}.OpenAPIModelName(), v1.VolumeMount{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_EphemeralContainerCommon(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "EphemeralContainerCommon is a copy of all fields in Container to be inlined in EphemeralContainer. This separate type allows easy conversion from EphemeralContainer to Container and allows separate documentation for the fields of EphemeralContainer. When a new field is added to Container it must be added here as well.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "name": { - SchemaProps: spec.SchemaProps{ - Description: "Name of the ephemeral container specified as a DNS_LABEL. This name must be unique among all containers, init containers and ephemeral containers.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "image": { - SchemaProps: spec.SchemaProps{ - Description: "Container image name. More info: https://kubernetes.io/docs/concepts/containers/images", - Type: []string{"string"}, - Format: "", - }, - }, - "command": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "Entrypoint array. Not executed within a shell. The image's ENTRYPOINT is used if this is not provided. Variable references $(VAR_NAME) are expanded using the container's environment. If a variable cannot be resolved, the reference in the input string will be unchanged. Double $$ are reduced to a single $, which allows for escaping the $(VAR_NAME) syntax: i.e. \"$$(VAR_NAME)\" will produce the string literal \"$(VAR_NAME)\". Escaped references will never be expanded, regardless of whether the variable exists or not. Cannot be updated. More info: https://kubernetes.io/docs/tasks/inject-data-application/define-command-argument-container/#running-a-command-in-a-shell", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - "args": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "Arguments to the entrypoint. The image's CMD is used if this is not provided. Variable references $(VAR_NAME) are expanded using the container's environment. If a variable cannot be resolved, the reference in the input string will be unchanged. Double $$ are reduced to a single $, which allows for escaping the $(VAR_NAME) syntax: i.e. \"$$(VAR_NAME)\" will produce the string literal \"$(VAR_NAME)\". Escaped references will never be expanded, regardless of whether the variable exists or not. Cannot be updated. More info: https://kubernetes.io/docs/tasks/inject-data-application/define-command-argument-container/#running-a-command-in-a-shell", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - "workingDir": { - SchemaProps: spec.SchemaProps{ - Description: "Container's working directory. If not specified, the container runtime's default will be used, which might be configured in the container image. Cannot be updated.", - Type: []string{"string"}, - Format: "", - }, - }, - "ports": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-map-keys": []interface{}{ - "containerPort", - "protocol", - }, - "x-kubernetes-list-type": "map", - "x-kubernetes-patch-merge-key": "containerPort", - "x-kubernetes-patch-strategy": "merge", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "Ports are not allowed for ephemeral containers.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.ContainerPort{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "envFrom": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "List of sources to populate environment variables in the container. The keys defined within a source may consist of any printable ASCII characters except '='. When a key exists in multiple sources, the value associated with the last source will take precedence. Values defined by an Env with a duplicate key will take precedence. Cannot be updated.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.EnvFromSource{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "env": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-map-keys": []interface{}{ - "name", - }, - "x-kubernetes-list-type": "map", - "x-kubernetes-patch-merge-key": "name", - "x-kubernetes-patch-strategy": "merge", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "List of environment variables to set in the container. Cannot be updated.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.EnvVar{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "resources": { - SchemaProps: spec.SchemaProps{ - Description: "Resources are not allowed for ephemeral containers. Ephemeral containers use spare resources already allocated to the pod.", - Default: map[string]interface{}{}, - Ref: ref(v1.ResourceRequirements{}.OpenAPIModelName()), - }, - }, - "resizePolicy": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "Resources resize policy for the container.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.ContainerResizePolicy{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "restartPolicy": { - SchemaProps: spec.SchemaProps{ - Description: "Restart policy for the container to manage the restart behavior of each container within a pod. You cannot set this field on ephemeral containers.", - Type: []string{"string"}, - Format: "", - }, - }, - "restartPolicyRules": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "Represents a list of rules to be checked to determine if the container should be restarted on exit. You cannot set this field on ephemeral containers.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.ContainerRestartRule{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "volumeMounts": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-map-keys": []interface{}{ - "mountPath", - }, - "x-kubernetes-list-type": "map", - "x-kubernetes-patch-merge-key": "mountPath", - "x-kubernetes-patch-strategy": "merge", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "Pod volumes to mount into the container's filesystem. Subpath mounts are not allowed for ephemeral containers. Cannot be updated.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.VolumeMount{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "volumeDevices": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-map-keys": []interface{}{ - "devicePath", - }, - "x-kubernetes-list-type": "map", - "x-kubernetes-patch-merge-key": "devicePath", - "x-kubernetes-patch-strategy": "merge", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "volumeDevices is the list of block devices to be used by the container.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.VolumeDevice{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "livenessProbe": { - SchemaProps: spec.SchemaProps{ - Description: "Probes are not allowed for ephemeral containers.", - Ref: ref(v1.Probe{}.OpenAPIModelName()), - }, - }, - "readinessProbe": { - SchemaProps: spec.SchemaProps{ - Description: "Probes are not allowed for ephemeral containers.", - Ref: ref(v1.Probe{}.OpenAPIModelName()), - }, - }, - "startupProbe": { - SchemaProps: spec.SchemaProps{ - Description: "Probes are not allowed for ephemeral containers.", - Ref: ref(v1.Probe{}.OpenAPIModelName()), - }, - }, - "lifecycle": { - SchemaProps: spec.SchemaProps{ - Description: "Lifecycle is not allowed for ephemeral containers.", - Ref: ref(v1.Lifecycle{}.OpenAPIModelName()), - }, - }, - "terminationMessagePath": { - SchemaProps: spec.SchemaProps{ - Description: "Optional: Path at which the file to which the container's termination message will be written is mounted into the container's filesystem. Message written is intended to be brief final status, such as an assertion failure message. Will be truncated by the node if greater than 4096 bytes. The total message length across all containers will be limited to 12kb. Defaults to /dev/termination-log. Cannot be updated.", - Type: []string{"string"}, - Format: "", - }, - }, - "terminationMessagePolicy": { - SchemaProps: spec.SchemaProps{ - Description: "Indicate how the termination message should be populated. File will use the contents of terminationMessagePath to populate the container status message on both success and failure. FallbackToLogsOnError will use the last chunk of container log output if the termination message file is empty and the container exited with an error. The log output is limited to 2048 bytes or 80 lines, whichever is smaller. Defaults to File. Cannot be updated.\n\nPossible enum values:\n - `\"FallbackToLogsOnError\"` will read the most recent contents of the container logs for the container status message when the container exits with an error and the terminationMessagePath has no contents.\n - `\"File\"` is the default behavior and will set the container status message to the contents of the container's terminationMessagePath when the container exits.", - Type: []string{"string"}, - Format: "", - Enum: []interface{}{"FallbackToLogsOnError", "File"}, - }, - }, - "imagePullPolicy": { - SchemaProps: spec.SchemaProps{ - Description: "Image pull policy. One of Always, Never, IfNotPresent. Defaults to Always if :latest tag is specified, or IfNotPresent otherwise. Cannot be updated. More info: https://kubernetes.io/docs/concepts/containers/images#updating-images\n\nPossible enum values:\n - `\"Always\"` means that kubelet always attempts to pull the latest image. Container will fail If the pull fails.\n - `\"IfNotPresent\"` means that kubelet pulls if the image isn't present on disk. Container will fail if the image isn't present and the pull fails.\n - `\"Never\"` means that kubelet never pulls an image, but only uses a local image. Container will fail if the image isn't present", - Type: []string{"string"}, - Format: "", - Enum: []interface{}{"Always", "IfNotPresent", "Never"}, - }, - }, - "securityContext": { - SchemaProps: spec.SchemaProps{ - Description: "Optional: SecurityContext defines the security options the ephemeral container should be run with. If set, the fields of SecurityContext override the equivalent fields of PodSecurityContext.", - Ref: ref(v1.SecurityContext{}.OpenAPIModelName()), - }, - }, - "stdin": { - SchemaProps: spec.SchemaProps{ - Description: "Whether this container should allocate a buffer for stdin in the container runtime. If this is not set, reads from stdin in the container will always result in EOF. Default is false.", - Type: []string{"boolean"}, - Format: "", - }, - }, - "stdinOnce": { - SchemaProps: spec.SchemaProps{ - Description: "Whether the container runtime should close the stdin channel after it has been opened by a single attach. When stdin is true the stdin stream will remain open across multiple attach sessions. If stdinOnce is set to true, stdin is opened on container start, is empty until the first client attaches to stdin, and then remains open and accepts data until the client disconnects, at which time stdin is closed and remains closed until the container is restarted. If this flag is false, a container processes that reads from stdin will never receive an EOF. Default is false", - Type: []string{"boolean"}, - Format: "", - }, - }, - "tty": { - SchemaProps: spec.SchemaProps{ - Description: "Whether this container should allocate a TTY for itself, also requires 'stdin' to be true. Default is false.", - Type: []string{"boolean"}, - Format: "", - }, - }, - }, - Required: []string{"name"}, - }, - }, - Dependencies: []string{ - v1.ContainerPort{}.OpenAPIModelName(), v1.ContainerResizePolicy{}.OpenAPIModelName(), v1.ContainerRestartRule{}.OpenAPIModelName(), v1.EnvFromSource{}.OpenAPIModelName(), v1.EnvVar{}.OpenAPIModelName(), v1.Lifecycle{}.OpenAPIModelName(), v1.Probe{}.OpenAPIModelName(), v1.ResourceRequirements{}.OpenAPIModelName(), v1.SecurityContext{}.OpenAPIModelName(), v1.VolumeDevice{}.OpenAPIModelName(), v1.VolumeMount{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_EphemeralVolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "Represents an ephemeral volume that is handled by a normal storage driver.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "volumeClaimTemplate": { - SchemaProps: spec.SchemaProps{ - Description: "Will be used to create a stand-alone PVC to provision the volume. The pod in which this EphemeralVolumeSource is embedded will be the owner of the PVC, i.e. the PVC will be deleted together with the pod. The name of the PVC will be `-` where `` is the name from the `PodSpec.Volumes` array entry. Pod validation will reject the pod if the concatenated name is not valid for a PVC (for example, too long).\n\nAn existing PVC with that name that is not owned by the pod will *not* be used for the pod to avoid using an unrelated volume by mistake. Starting the pod is then blocked until the unrelated PVC is removed. If such a pre-created PVC is meant to be used by the pod, the PVC has to updated with an owner reference to the pod once the pod exists. Normally this should not be necessary, but it may be useful when manually reconstructing a broken cluster.\n\nThis field is read-only and no changes will be made by Kubernetes to the PVC after it has been created.\n\nRequired, must not be nil.", - Ref: ref(v1.PersistentVolumeClaimTemplate{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - Dependencies: []string{ - v1.PersistentVolumeClaimTemplate{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_Event(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "Event is a report of an event somewhere in the cluster. Events have a limited retention time and triggers and messages may evolve with time. Event consumers should not rely on the timing of an event with a given Reason reflecting a consistent underlying trigger, or the continued existence of events with that Reason. Events should be treated as informative, best-effort, supplemental data.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Type: []string{"string"}, - Format: "", - }, - }, - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", - Type: []string{"string"}, - Format: "", - }, - }, - "metadata": { - SchemaProps: spec.SchemaProps{ - Description: "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata", - Default: map[string]interface{}{}, - Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), - }, - }, - "involvedObject": { - SchemaProps: spec.SchemaProps{ - Description: "The object that this event is about.", - Default: map[string]interface{}{}, - Ref: ref(v1.ObjectReference{}.OpenAPIModelName()), - }, - }, - "reason": { - SchemaProps: spec.SchemaProps{ - Description: "This should be a short, machine understandable string that gives the reason for the transition into the object's current status.", - Type: []string{"string"}, - Format: "", - }, - }, - "message": { - SchemaProps: spec.SchemaProps{ - Description: "A human-readable description of the status of this operation.", - Type: []string{"string"}, - Format: "", - }, - }, - "source": { - SchemaProps: spec.SchemaProps{ - Description: "The component reporting this event. Should be a short machine understandable string.", - Default: map[string]interface{}{}, - Ref: ref(v1.EventSource{}.OpenAPIModelName()), - }, - }, - "firstTimestamp": { - SchemaProps: spec.SchemaProps{ - Description: "The time at which the event was first recorded. (Time of server receipt is in TypeMeta.)", - Ref: ref(metav1.Time{}.OpenAPIModelName()), - }, - }, - "lastTimestamp": { - SchemaProps: spec.SchemaProps{ - Description: "The time at which the most recent occurrence of this event was recorded.", - Ref: ref(metav1.Time{}.OpenAPIModelName()), - }, - }, - "count": { - SchemaProps: spec.SchemaProps{ - Description: "The number of times this event has occurred.", - Type: []string{"integer"}, - Format: "int32", - }, - }, - "type": { - SchemaProps: spec.SchemaProps{ - Description: "Type of this event (Normal, Warning), new types could be added in the future", - Type: []string{"string"}, - Format: "", - }, - }, - "eventTime": { - SchemaProps: spec.SchemaProps{ - Description: "Time when this Event was first observed.", - Ref: ref(metav1.MicroTime{}.OpenAPIModelName()), - }, - }, - "series": { - SchemaProps: spec.SchemaProps{ - Description: "Data about the Event series this event represents or nil if it's a singleton Event.", - Ref: ref(v1.EventSeries{}.OpenAPIModelName()), - }, - }, - "action": { - SchemaProps: spec.SchemaProps{ - Description: "What action was taken/failed regarding to the Regarding object.", - Type: []string{"string"}, - Format: "", - }, - }, - "related": { - SchemaProps: spec.SchemaProps{ - Description: "Optional secondary object for more complex actions.", - Ref: ref(v1.ObjectReference{}.OpenAPIModelName()), - }, - }, - "reportingComponent": { - SchemaProps: spec.SchemaProps{ - Description: "Name of the controller that emitted this Event, e.g. `kubernetes.io/kubelet`.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "reportingInstance": { - SchemaProps: spec.SchemaProps{ - Description: "ID of the controller instance, e.g. `kubelet-xyzf`.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - Required: []string{"metadata", "involvedObject"}, - }, - }, - Dependencies: []string{ - v1.EventSeries{}.OpenAPIModelName(), v1.EventSource{}.OpenAPIModelName(), v1.ObjectReference{}.OpenAPIModelName(), metav1.MicroTime{}.OpenAPIModelName(), metav1.ObjectMeta{}.OpenAPIModelName(), metav1.Time{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_EventList(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "EventList is a list of events.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Type: []string{"string"}, - Format: "", - }, - }, - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", - Type: []string{"string"}, - Format: "", - }, - }, - "metadata": { - SchemaProps: spec.SchemaProps{ - Description: "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Default: map[string]interface{}{}, - Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), - }, - }, - "items": { - SchemaProps: spec.SchemaProps{ - Description: "List of events", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.Event{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - }, - Required: []string{"items"}, - }, - }, - Dependencies: []string{ - v1.Event{}.OpenAPIModelName(), metav1.ListMeta{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_EventSeries(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "EventSeries contain information on series of events, i.e. thing that was/is happening continuously for some time.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "count": { - SchemaProps: spec.SchemaProps{ - Description: "Number of occurrences in this series up to the last heartbeat time", - Type: []string{"integer"}, - Format: "int32", - }, - }, - "lastObservedTime": { - SchemaProps: spec.SchemaProps{ - Description: "Time of the last occurrence observed", - Ref: ref(metav1.MicroTime{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - Dependencies: []string{ - metav1.MicroTime{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_EventSource(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "EventSource contains information for an event.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "component": { - SchemaProps: spec.SchemaProps{ - Description: "Component from which the event is generated.", - Type: []string{"string"}, - Format: "", - }, - }, - "host": { - SchemaProps: spec.SchemaProps{ - Description: "Node name on which the event is generated.", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - } -} - -func schema_k8sio_api_core_v1_ExecAction(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "ExecAction describes a \"run in container\" action.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "command": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "Command is the command line to execute inside the container, the working directory for the command is root ('/') in the container's filesystem. The command is simply exec'd, it is not run inside a shell, so traditional shell instructions ('|', etc) won't work. To use a shell, you need to explicitly call out to that shell. Exit status of 0 is treated as live/healthy and non-zero is unhealthy.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - }, - }, - }, - } -} - -func schema_k8sio_api_core_v1_FCVolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "Represents a Fibre Channel volume. Fibre Channel volumes can only be mounted as read/write once. Fibre Channel volumes support ownership management and SELinux relabeling.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "targetWWNs": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "targetWWNs is Optional: FC target worldwide names (WWNs)", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - "lun": { - SchemaProps: spec.SchemaProps{ - Description: "lun is Optional: FC target lun number", - Type: []string{"integer"}, - Format: "int32", - }, - }, - "fsType": { - SchemaProps: spec.SchemaProps{ - Description: "fsType is the filesystem type to mount. Must be a filesystem type supported by the host operating system. Ex. \"ext4\", \"xfs\", \"ntfs\". Implicitly inferred to be \"ext4\" if unspecified.", - Type: []string{"string"}, - Format: "", - }, - }, - "readOnly": { - SchemaProps: spec.SchemaProps{ - Description: "readOnly is Optional: Defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts.", - Type: []string{"boolean"}, - Format: "", - }, - }, - "wwids": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "wwids Optional: FC volume world wide identifiers (wwids) Either wwids or combination of targetWWNs and lun must be set, but not both simultaneously.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - }, - }, - }, - } -} - -func schema_k8sio_api_core_v1_FileKeySelector(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "FileKeySelector selects a key of the env file.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "volumeName": { - SchemaProps: spec.SchemaProps{ - Description: "The name of the volume mount containing the env file.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "path": { - SchemaProps: spec.SchemaProps{ - Description: "The path within the volume from which to select the file. Must be relative and may not contain the '..' path or start with '..'.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "key": { - SchemaProps: spec.SchemaProps{ - Description: "The key within the env file. An invalid key will prevent the pod from starting. The keys defined within a source may consist of any printable ASCII characters except '='. During Alpha stage of the EnvFiles feature gate, the key size is limited to 128 characters.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "optional": { - SchemaProps: spec.SchemaProps{ - Description: "Specify whether the file or its key must be defined. If the file or key does not exist, then the env var is not published. If optional is set to true and the specified key does not exist, the environment variable will not be set in the Pod's containers.\n\nIf optional is set to false and the specified key does not exist, an error will be returned during Pod creation.", - Default: false, - Type: []string{"boolean"}, - Format: "", - }, - }, - }, - Required: []string{"volumeName", "path", "key"}, - }, - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-map-type": "atomic", - }, - }, - }, - } -} - -func schema_k8sio_api_core_v1_FlexPersistentVolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "FlexPersistentVolumeSource represents a generic persistent volume resource that is provisioned/attached using an exec based plugin.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "driver": { - SchemaProps: spec.SchemaProps{ - Description: "driver is the name of the driver to use for this volume.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "fsType": { - SchemaProps: spec.SchemaProps{ - Description: "fsType is the Filesystem type to mount. Must be a filesystem type supported by the host operating system. Ex. \"ext4\", \"xfs\", \"ntfs\". The default filesystem depends on FlexVolume script.", - Type: []string{"string"}, - Format: "", - }, - }, - "secretRef": { - SchemaProps: spec.SchemaProps{ - Description: "secretRef is Optional: SecretRef is reference to the secret object containing sensitive information to pass to the plugin scripts. This may be empty if no secret object is specified. If the secret object contains more than one secret, all secrets are passed to the plugin scripts.", - Ref: ref(v1.SecretReference{}.OpenAPIModelName()), - }, - }, - "readOnly": { - SchemaProps: spec.SchemaProps{ - Description: "readOnly is Optional: defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts.", - Type: []string{"boolean"}, - Format: "", - }, - }, - "options": { - SchemaProps: spec.SchemaProps{ - Description: "options is Optional: this field holds extra command options if any.", - Type: []string{"object"}, - AdditionalProperties: &spec.SchemaOrBool{ - Allows: true, - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - }, - Required: []string{"driver"}, - }, - }, - Dependencies: []string{ - v1.SecretReference{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_FlexVolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "FlexVolume represents a generic volume resource that is provisioned/attached using an exec based plugin.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "driver": { - SchemaProps: spec.SchemaProps{ - Description: "driver is the name of the driver to use for this volume.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "fsType": { - SchemaProps: spec.SchemaProps{ - Description: "fsType is the filesystem type to mount. Must be a filesystem type supported by the host operating system. Ex. \"ext4\", \"xfs\", \"ntfs\". The default filesystem depends on FlexVolume script.", - Type: []string{"string"}, - Format: "", - }, - }, - "secretRef": { - SchemaProps: spec.SchemaProps{ - Description: "secretRef is Optional: secretRef is reference to the secret object containing sensitive information to pass to the plugin scripts. This may be empty if no secret object is specified. If the secret object contains more than one secret, all secrets are passed to the plugin scripts.", - Ref: ref(v1.LocalObjectReference{}.OpenAPIModelName()), - }, - }, - "readOnly": { - SchemaProps: spec.SchemaProps{ - Description: "readOnly is Optional: defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts.", - Type: []string{"boolean"}, - Format: "", - }, - }, - "options": { - SchemaProps: spec.SchemaProps{ - Description: "options is Optional: this field holds extra command options if any.", - Type: []string{"object"}, - AdditionalProperties: &spec.SchemaOrBool{ - Allows: true, - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - }, - Required: []string{"driver"}, - }, - }, - Dependencies: []string{ - v1.LocalObjectReference{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_FlockerVolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "Represents a Flocker volume mounted by the Flocker agent. One and only one of datasetName and datasetUUID should be set. Flocker volumes do not support ownership management or SELinux relabeling.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "datasetName": { - SchemaProps: spec.SchemaProps{ - Description: "datasetName is Name of the dataset stored as metadata -> name on the dataset for Flocker should be considered as deprecated", - Type: []string{"string"}, - Format: "", - }, - }, - "datasetUUID": { - SchemaProps: spec.SchemaProps{ - Description: "datasetUUID is the UUID of the dataset. This is unique identifier of a Flocker dataset", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - } -} - -func schema_k8sio_api_core_v1_GCEPersistentDiskVolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "Represents a Persistent Disk resource in Google Compute Engine.\n\nA GCE PD must exist before mounting to a container. The disk must also be in the same GCE project and zone as the kubelet. A GCE PD can only be mounted as read/write once or read-only many times. GCE PDs support ownership management and SELinux relabeling.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "pdName": { - SchemaProps: spec.SchemaProps{ - Description: "pdName is unique name of the PD resource in GCE. Used to identify the disk in GCE. More info: https://kubernetes.io/docs/concepts/storage/volumes#gcepersistentdisk", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "fsType": { - SchemaProps: spec.SchemaProps{ - Description: "fsType is filesystem type of the volume that you want to mount. Tip: Ensure that the filesystem type is supported by the host operating system. Examples: \"ext4\", \"xfs\", \"ntfs\". Implicitly inferred to be \"ext4\" if unspecified. More info: https://kubernetes.io/docs/concepts/storage/volumes#gcepersistentdisk", - Type: []string{"string"}, - Format: "", - }, - }, - "partition": { - SchemaProps: spec.SchemaProps{ - Description: "partition is the partition in the volume that you want to mount. If omitted, the default is to mount by volume name. Examples: For volume /dev/sda1, you specify the partition as \"1\". Similarly, the volume partition for /dev/sda is \"0\" (or you can leave the property empty). More info: https://kubernetes.io/docs/concepts/storage/volumes#gcepersistentdisk", - Type: []string{"integer"}, - Format: "int32", - }, - }, - "readOnly": { - SchemaProps: spec.SchemaProps{ - Description: "readOnly here will force the ReadOnly setting in VolumeMounts. Defaults to false. More info: https://kubernetes.io/docs/concepts/storage/volumes#gcepersistentdisk", - Type: []string{"boolean"}, - Format: "", - }, - }, - }, - Required: []string{"pdName"}, - }, - }, - } -} - -func schema_k8sio_api_core_v1_GRPCAction(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "GRPCAction specifies an action involving a GRPC service.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "port": { - SchemaProps: spec.SchemaProps{ - Description: "Port number of the gRPC service. Number must be in the range 1 to 65535.", - Default: 0, - Type: []string{"integer"}, - Format: "int32", - }, - }, - "service": { - SchemaProps: spec.SchemaProps{ - Description: "Service is the name of the service to place in the gRPC HealthCheckRequest (see https://github.com/grpc/grpc/blob/master/doc/health-checking.md).\n\nIf this is not specified, the default behavior is defined by gRPC.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - Required: []string{"port"}, - }, - }, - } -} - -func schema_k8sio_api_core_v1_GitRepoVolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "Represents a volume that is populated with the contents of a git repository. Git repo volumes do not support ownership management. Git repo volumes support SELinux relabeling.\n\nDEPRECATED: GitRepo is deprecated. To provision a container with a git repo, mount an EmptyDir into an InitContainer that clones the repo using git, then mount the EmptyDir into the Pod's container.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "repository": { - SchemaProps: spec.SchemaProps{ - Description: "repository is the URL", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "revision": { - SchemaProps: spec.SchemaProps{ - Description: "revision is the commit hash for the specified revision.", - Type: []string{"string"}, - Format: "", - }, - }, - "directory": { - SchemaProps: spec.SchemaProps{ - Description: "directory is the target directory name. Must not contain or start with '..'. If '.' is supplied, the volume directory will be the git repository. Otherwise, if specified, the volume will contain the git repository in the subdirectory with the given name.", - Type: []string{"string"}, - Format: "", - }, - }, - }, - Required: []string{"repository"}, - }, - }, - } -} - -func schema_k8sio_api_core_v1_GlusterfsPersistentVolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "Represents a Glusterfs mount that lasts the lifetime of a pod. Glusterfs volumes do not support ownership management or SELinux relabeling.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "endpoints": { - SchemaProps: spec.SchemaProps{ - Description: "endpoints is the endpoint name that details Glusterfs topology. More info: https://examples.k8s.io/volumes/glusterfs/README.md#create-a-pod", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "path": { - SchemaProps: spec.SchemaProps{ - Description: "path is the Glusterfs volume path. More info: https://examples.k8s.io/volumes/glusterfs/README.md#create-a-pod", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "readOnly": { - SchemaProps: spec.SchemaProps{ - Description: "readOnly here will force the Glusterfs volume to be mounted with read-only permissions. Defaults to false. More info: https://examples.k8s.io/volumes/glusterfs/README.md#create-a-pod", - Type: []string{"boolean"}, - Format: "", - }, - }, - "endpointsNamespace": { - SchemaProps: spec.SchemaProps{ - Description: "endpointsNamespace is the namespace that contains Glusterfs endpoint. If this field is empty, the EndpointNamespace defaults to the same namespace as the bound PVC. More info: https://examples.k8s.io/volumes/glusterfs/README.md#create-a-pod", - Type: []string{"string"}, - Format: "", - }, - }, - }, - Required: []string{"endpoints", "path"}, - }, - }, - } -} - -func schema_k8sio_api_core_v1_GlusterfsVolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "Represents a Glusterfs mount that lasts the lifetime of a pod. Glusterfs volumes do not support ownership management or SELinux relabeling.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "endpoints": { - SchemaProps: spec.SchemaProps{ - Description: "endpoints is the endpoint name that details Glusterfs topology.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "path": { - SchemaProps: spec.SchemaProps{ - Description: "path is the Glusterfs volume path. More info: https://examples.k8s.io/volumes/glusterfs/README.md#create-a-pod", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "readOnly": { - SchemaProps: spec.SchemaProps{ - Description: "readOnly here will force the Glusterfs volume to be mounted with read-only permissions. Defaults to false. More info: https://examples.k8s.io/volumes/glusterfs/README.md#create-a-pod", - Type: []string{"boolean"}, - Format: "", - }, - }, - }, - Required: []string{"endpoints", "path"}, - }, - }, - } -} - -func schema_k8sio_api_core_v1_HTTPGetAction(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "HTTPGetAction describes an action based on HTTP Get requests.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "path": { - SchemaProps: spec.SchemaProps{ - Description: "Path to access on the HTTP server.", - Type: []string{"string"}, - Format: "", - }, - }, - "port": { - SchemaProps: spec.SchemaProps{ - Description: "Name or number of the port to access on the container. Number must be in the range 1 to 65535. Name must be an IANA_SVC_NAME.", - Ref: ref("k8s.io/apimachinery/pkg/util/intstr.IntOrString"), - }, - }, - "host": { - SchemaProps: spec.SchemaProps{ - Description: "Host name to connect to, defaults to the pod IP. You probably want to set \"Host\" in httpHeaders instead.", - Type: []string{"string"}, - Format: "", - }, - }, - "scheme": { - SchemaProps: spec.SchemaProps{ - Description: "Scheme to use for connecting to the host. Defaults to HTTP.\n\nPossible enum values:\n - `\"HTTP\"` means that the scheme used will be http://\n - `\"HTTPS\"` means that the scheme used will be https://", - Type: []string{"string"}, - Format: "", - Enum: []interface{}{"HTTP", "HTTPS"}, - }, - }, - "httpHeaders": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "Custom headers to set in the request. HTTP allows repeated headers.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.HTTPHeader{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - }, - Required: []string{"port"}, - }, - }, - Dependencies: []string{ - v1.HTTPHeader{}.OpenAPIModelName(), "k8s.io/apimachinery/pkg/util/intstr.IntOrString"}, - } -} - -func schema_k8sio_api_core_v1_HTTPHeader(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "HTTPHeader describes a custom header to be used in HTTP probes", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "name": { - SchemaProps: spec.SchemaProps{ - Description: "The header field name. This will be canonicalized upon output, so case-variant names will be understood as the same header.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "value": { - SchemaProps: spec.SchemaProps{ - Description: "The header field value", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - Required: []string{"name", "value"}, - }, - }, - } -} - -func schema_k8sio_api_core_v1_HostAlias(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "HostAlias holds the mapping between IP and hostnames that will be injected as an entry in the pod's hosts file.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "ip": { - SchemaProps: spec.SchemaProps{ - Description: "IP address of the host file entry.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "hostnames": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "Hostnames for the above IP address.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - }, - Required: []string{"ip"}, - }, - }, - } -} - -func schema_k8sio_api_core_v1_HostIP(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "HostIP represents a single IP address allocated to the host.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "ip": { - SchemaProps: spec.SchemaProps{ - Description: "IP is the IP address assigned to the host", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - Required: []string{"ip"}, - }, - }, - } -} - -func schema_k8sio_api_core_v1_HostPathVolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "Represents a host path mapped into a pod. Host path volumes do not support ownership management or SELinux relabeling.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "path": { - SchemaProps: spec.SchemaProps{ - Description: "path of the directory on the host. If the path is a symlink, it will follow the link to the real path. More info: https://kubernetes.io/docs/concepts/storage/volumes#hostpath", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "type": { - SchemaProps: spec.SchemaProps{ - Description: "type for HostPath Volume Defaults to \"\" More info: https://kubernetes.io/docs/concepts/storage/volumes#hostpath\n\nPossible enum values:\n - `\"\"` For backwards compatible, leave it empty if unset\n - `\"BlockDevice\"` A block device must exist at the given path\n - `\"CharDevice\"` A character device must exist at the given path\n - `\"Directory\"` A directory must exist at the given path\n - `\"DirectoryOrCreate\"` If nothing exists at the given path, an empty directory will be created there as needed with file mode 0755, having the same group and ownership with Kubelet.\n - `\"File\"` A file must exist at the given path\n - `\"FileOrCreate\"` If nothing exists at the given path, an empty file will be created there as needed with file mode 0644, having the same group and ownership with Kubelet.\n - `\"Socket\"` A UNIX socket must exist at the given path", - Type: []string{"string"}, - Format: "", - Enum: []interface{}{"", "BlockDevice", "CharDevice", "Directory", "DirectoryOrCreate", "File", "FileOrCreate", "Socket"}, - }, - }, - }, - Required: []string{"path"}, - }, - }, - } -} - -func schema_k8sio_api_core_v1_ISCSIPersistentVolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "ISCSIPersistentVolumeSource represents an ISCSI disk. ISCSI volumes can only be mounted as read/write once. ISCSI volumes support ownership management and SELinux relabeling.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "targetPortal": { - SchemaProps: spec.SchemaProps{ - Description: "targetPortal is iSCSI Target Portal. The Portal is either an IP or ip_addr:port if the port is other than default (typically TCP ports 860 and 3260).", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "iqn": { - SchemaProps: spec.SchemaProps{ - Description: "iqn is Target iSCSI Qualified Name.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "lun": { - SchemaProps: spec.SchemaProps{ - Description: "lun is iSCSI Target Lun number.", - Default: 0, - Type: []string{"integer"}, - Format: "int32", - }, - }, - "iscsiInterface": { - SchemaProps: spec.SchemaProps{ - Description: "iscsiInterface is the interface Name that uses an iSCSI transport. Defaults to 'default' (tcp).", - Default: "default", - Type: []string{"string"}, - Format: "", - }, - }, - "fsType": { - SchemaProps: spec.SchemaProps{ - Description: "fsType is the filesystem type of the volume that you want to mount. Tip: Ensure that the filesystem type is supported by the host operating system. Examples: \"ext4\", \"xfs\", \"ntfs\". Implicitly inferred to be \"ext4\" if unspecified. More info: https://kubernetes.io/docs/concepts/storage/volumes#iscsi", - Type: []string{"string"}, - Format: "", - }, - }, - "readOnly": { - SchemaProps: spec.SchemaProps{ - Description: "readOnly here will force the ReadOnly setting in VolumeMounts. Defaults to false.", - Type: []string{"boolean"}, - Format: "", - }, - }, - "portals": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "portals is the iSCSI Target Portal List. The Portal is either an IP or ip_addr:port if the port is other than default (typically TCP ports 860 and 3260).", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - "chapAuthDiscovery": { - SchemaProps: spec.SchemaProps{ - Description: "chapAuthDiscovery defines whether support iSCSI Discovery CHAP authentication", - Type: []string{"boolean"}, - Format: "", - }, - }, - "chapAuthSession": { - SchemaProps: spec.SchemaProps{ - Description: "chapAuthSession defines whether support iSCSI Session CHAP authentication", - Type: []string{"boolean"}, - Format: "", - }, - }, - "secretRef": { - SchemaProps: spec.SchemaProps{ - Description: "secretRef is the CHAP Secret for iSCSI target and initiator authentication", - Ref: ref(v1.SecretReference{}.OpenAPIModelName()), - }, - }, - "initiatorName": { - SchemaProps: spec.SchemaProps{ - Description: "initiatorName is the custom iSCSI Initiator Name. If initiatorName is specified with iscsiInterface simultaneously, new iSCSI interface : will be created for the connection.", - Type: []string{"string"}, - Format: "", - }, - }, - }, - Required: []string{"targetPortal", "iqn", "lun"}, - }, - }, - Dependencies: []string{ - v1.SecretReference{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_ISCSIVolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "Represents an ISCSI disk. ISCSI volumes can only be mounted as read/write once. ISCSI volumes support ownership management and SELinux relabeling.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "targetPortal": { - SchemaProps: spec.SchemaProps{ - Description: "targetPortal is iSCSI Target Portal. The Portal is either an IP or ip_addr:port if the port is other than default (typically TCP ports 860 and 3260).", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "iqn": { - SchemaProps: spec.SchemaProps{ - Description: "iqn is the target iSCSI Qualified Name.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "lun": { - SchemaProps: spec.SchemaProps{ - Description: "lun represents iSCSI Target Lun number.", - Default: 0, - Type: []string{"integer"}, - Format: "int32", - }, - }, - "iscsiInterface": { - SchemaProps: spec.SchemaProps{ - Description: "iscsiInterface is the interface Name that uses an iSCSI transport. Defaults to 'default' (tcp).", - Default: "default", - Type: []string{"string"}, - Format: "", - }, - }, - "fsType": { - SchemaProps: spec.SchemaProps{ - Description: "fsType is the filesystem type of the volume that you want to mount. Tip: Ensure that the filesystem type is supported by the host operating system. Examples: \"ext4\", \"xfs\", \"ntfs\". Implicitly inferred to be \"ext4\" if unspecified. More info: https://kubernetes.io/docs/concepts/storage/volumes#iscsi", - Type: []string{"string"}, - Format: "", - }, - }, - "readOnly": { - SchemaProps: spec.SchemaProps{ - Description: "readOnly here will force the ReadOnly setting in VolumeMounts. Defaults to false.", - Type: []string{"boolean"}, - Format: "", - }, - }, - "portals": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "portals is the iSCSI Target Portal List. The portal is either an IP or ip_addr:port if the port is other than default (typically TCP ports 860 and 3260).", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - "chapAuthDiscovery": { - SchemaProps: spec.SchemaProps{ - Description: "chapAuthDiscovery defines whether support iSCSI Discovery CHAP authentication", - Type: []string{"boolean"}, - Format: "", - }, - }, - "chapAuthSession": { - SchemaProps: spec.SchemaProps{ - Description: "chapAuthSession defines whether support iSCSI Session CHAP authentication", - Type: []string{"boolean"}, - Format: "", - }, - }, - "secretRef": { - SchemaProps: spec.SchemaProps{ - Description: "secretRef is the CHAP Secret for iSCSI target and initiator authentication", - Ref: ref(v1.LocalObjectReference{}.OpenAPIModelName()), - }, - }, - "initiatorName": { - SchemaProps: spec.SchemaProps{ - Description: "initiatorName is the custom iSCSI Initiator Name. If initiatorName is specified with iscsiInterface simultaneously, new iSCSI interface : will be created for the connection.", - Type: []string{"string"}, - Format: "", - }, - }, - }, - Required: []string{"targetPortal", "iqn", "lun"}, - }, - }, - Dependencies: []string{ - v1.LocalObjectReference{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_ImageVolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "ImageVolumeSource represents a image volume resource.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "reference": { - SchemaProps: spec.SchemaProps{ - Description: "Required: Image or artifact reference to be used. Behaves in the same way as pod.spec.containers[*].image. Pull secrets will be assembled in the same way as for the container image by looking up node credentials, SA image pull secrets, and pod spec image pull secrets. More info: https://kubernetes.io/docs/concepts/containers/images This field is optional to allow higher level config management to default or override container images in workload controllers like Deployments and StatefulSets.", - Type: []string{"string"}, - Format: "", - }, - }, - "pullPolicy": { - SchemaProps: spec.SchemaProps{ - Description: "Policy for pulling OCI objects. Possible values are: Always: the kubelet always attempts to pull the reference. Container creation will fail If the pull fails. Never: the kubelet never pulls the reference and only uses a local image or artifact. Container creation will fail if the reference isn't present. IfNotPresent: the kubelet pulls if the reference isn't already present on disk. Container creation will fail if the reference isn't present and the pull fails. Defaults to Always if :latest tag is specified, or IfNotPresent otherwise.\n\nPossible enum values:\n - `\"Always\"` means that kubelet always attempts to pull the latest image. Container will fail If the pull fails.\n - `\"IfNotPresent\"` means that kubelet pulls if the image isn't present on disk. Container will fail if the image isn't present and the pull fails.\n - `\"Never\"` means that kubelet never pulls an image, but only uses a local image. Container will fail if the image isn't present", - Type: []string{"string"}, - Format: "", - Enum: []interface{}{"Always", "IfNotPresent", "Never"}, - }, - }, - }, - }, - }, - } -} - -func schema_k8sio_api_core_v1_KeyToPath(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "Maps a string key to a path within a volume.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "key": { - SchemaProps: spec.SchemaProps{ - Description: "key is the key to project.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "path": { - SchemaProps: spec.SchemaProps{ - Description: "path is the relative path of the file to map the key to. May not be an absolute path. May not contain the path element '..'. May not start with the string '..'.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "mode": { - SchemaProps: spec.SchemaProps{ - Description: "mode is Optional: mode bits used to set permissions on this file. Must be an octal value between 0000 and 0777 or a decimal value between 0 and 511. YAML accepts both octal and decimal values, JSON requires decimal values for mode bits. If not specified, the volume defaultMode will be used. This might be in conflict with other options that affect the file mode, like fsGroup, and the result can be other mode bits set.", - Type: []string{"integer"}, - Format: "int32", - }, - }, - }, - Required: []string{"key", "path"}, - }, - }, - } -} - -func schema_k8sio_api_core_v1_Lifecycle(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "Lifecycle describes actions that the management system should take in response to container lifecycle events. For the PostStart and PreStop lifecycle handlers, management of the container blocks until the action is complete, unless the container process fails, in which case the handler is aborted.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "postStart": { - SchemaProps: spec.SchemaProps{ - Description: "PostStart is called immediately after a container is created. If the handler fails, the container is terminated and restarted according to its restart policy. Other management of the container blocks until the hook completes. More info: https://kubernetes.io/docs/concepts/containers/container-lifecycle-hooks/#container-hooks", - Ref: ref(v1.LifecycleHandler{}.OpenAPIModelName()), - }, - }, - "preStop": { - SchemaProps: spec.SchemaProps{ - Description: "PreStop is called immediately before a container is terminated due to an API request or management event such as liveness/startup probe failure, preemption, resource contention, etc. The handler is not called if the container crashes or exits. The Pod's termination grace period countdown begins before the PreStop hook is executed. Regardless of the outcome of the handler, the container will eventually terminate within the Pod's termination grace period (unless delayed by finalizers). Other management of the container blocks until the hook completes or until the termination grace period is reached. More info: https://kubernetes.io/docs/concepts/containers/container-lifecycle-hooks/#container-hooks", - Ref: ref(v1.LifecycleHandler{}.OpenAPIModelName()), - }, - }, - "stopSignal": { - SchemaProps: spec.SchemaProps{ - Description: "StopSignal defines which signal will be sent to a container when it is being stopped. If not specified, the default is defined by the container runtime in use. StopSignal can only be set for Pods with a non-empty .spec.os.name\n\nPossible enum values:\n - `\"SIGABRT\"`\n - `\"SIGALRM\"`\n - `\"SIGBUS\"`\n - `\"SIGCHLD\"`\n - `\"SIGCLD\"`\n - `\"SIGCONT\"`\n - `\"SIGFPE\"`\n - `\"SIGHUP\"`\n - `\"SIGILL\"`\n - `\"SIGINT\"`\n - `\"SIGIO\"`\n - `\"SIGIOT\"`\n - `\"SIGKILL\"`\n - `\"SIGPIPE\"`\n - `\"SIGPOLL\"`\n - `\"SIGPROF\"`\n - `\"SIGPWR\"`\n - `\"SIGQUIT\"`\n - `\"SIGRTMAX\"`\n - `\"SIGRTMAX-1\"`\n - `\"SIGRTMAX-10\"`\n - `\"SIGRTMAX-11\"`\n - `\"SIGRTMAX-12\"`\n - `\"SIGRTMAX-13\"`\n - `\"SIGRTMAX-14\"`\n - `\"SIGRTMAX-2\"`\n - `\"SIGRTMAX-3\"`\n - `\"SIGRTMAX-4\"`\n - `\"SIGRTMAX-5\"`\n - `\"SIGRTMAX-6\"`\n - `\"SIGRTMAX-7\"`\n - `\"SIGRTMAX-8\"`\n - `\"SIGRTMAX-9\"`\n - `\"SIGRTMIN\"`\n - `\"SIGRTMIN+1\"`\n - `\"SIGRTMIN+10\"`\n - `\"SIGRTMIN+11\"`\n - `\"SIGRTMIN+12\"`\n - `\"SIGRTMIN+13\"`\n - `\"SIGRTMIN+14\"`\n - `\"SIGRTMIN+15\"`\n - `\"SIGRTMIN+2\"`\n - `\"SIGRTMIN+3\"`\n - `\"SIGRTMIN+4\"`\n - `\"SIGRTMIN+5\"`\n - `\"SIGRTMIN+6\"`\n - `\"SIGRTMIN+7\"`\n - `\"SIGRTMIN+8\"`\n - `\"SIGRTMIN+9\"`\n - `\"SIGSEGV\"`\n - `\"SIGSTKFLT\"`\n - `\"SIGSTOP\"`\n - `\"SIGSYS\"`\n - `\"SIGTERM\"`\n - `\"SIGTRAP\"`\n - `\"SIGTSTP\"`\n - `\"SIGTTIN\"`\n - `\"SIGTTOU\"`\n - `\"SIGURG\"`\n - `\"SIGUSR1\"`\n - `\"SIGUSR2\"`\n - `\"SIGVTALRM\"`\n - `\"SIGWINCH\"`\n - `\"SIGXCPU\"`\n - `\"SIGXFSZ\"`", - Type: []string{"string"}, - Format: "", - Enum: []interface{}{"SIGABRT", "SIGALRM", "SIGBUS", "SIGCHLD", "SIGCLD", "SIGCONT", "SIGFPE", "SIGHUP", "SIGILL", "SIGINT", "SIGIO", "SIGIOT", "SIGKILL", "SIGPIPE", "SIGPOLL", "SIGPROF", "SIGPWR", "SIGQUIT", "SIGRTMAX", "SIGRTMAX-1", "SIGRTMAX-10", "SIGRTMAX-11", "SIGRTMAX-12", "SIGRTMAX-13", "SIGRTMAX-14", "SIGRTMAX-2", "SIGRTMAX-3", "SIGRTMAX-4", "SIGRTMAX-5", "SIGRTMAX-6", "SIGRTMAX-7", "SIGRTMAX-8", "SIGRTMAX-9", "SIGRTMIN", "SIGRTMIN+1", "SIGRTMIN+10", "SIGRTMIN+11", "SIGRTMIN+12", "SIGRTMIN+13", "SIGRTMIN+14", "SIGRTMIN+15", "SIGRTMIN+2", "SIGRTMIN+3", "SIGRTMIN+4", "SIGRTMIN+5", "SIGRTMIN+6", "SIGRTMIN+7", "SIGRTMIN+8", "SIGRTMIN+9", "SIGSEGV", "SIGSTKFLT", "SIGSTOP", "SIGSYS", "SIGTERM", "SIGTRAP", "SIGTSTP", "SIGTTIN", "SIGTTOU", "SIGURG", "SIGUSR1", "SIGUSR2", "SIGVTALRM", "SIGWINCH", "SIGXCPU", "SIGXFSZ"}, - }, - }, - }, - }, - }, - Dependencies: []string{ - v1.LifecycleHandler{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_LifecycleHandler(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "LifecycleHandler defines a specific action that should be taken in a lifecycle hook. One and only one of the fields, except TCPSocket must be specified.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "exec": { - SchemaProps: spec.SchemaProps{ - Description: "Exec specifies a command to execute in the container.", - Ref: ref(v1.ExecAction{}.OpenAPIModelName()), - }, - }, - "httpGet": { - SchemaProps: spec.SchemaProps{ - Description: "HTTPGet specifies an HTTP GET request to perform.", - Ref: ref(v1.HTTPGetAction{}.OpenAPIModelName()), - }, - }, - "tcpSocket": { - SchemaProps: spec.SchemaProps{ - Description: "Deprecated. TCPSocket is NOT supported as a LifecycleHandler and kept for backward compatibility. There is no validation of this field and lifecycle hooks will fail at runtime when it is specified.", - Ref: ref(v1.TCPSocketAction{}.OpenAPIModelName()), - }, - }, - "sleep": { - SchemaProps: spec.SchemaProps{ - Description: "Sleep represents a duration that the container should sleep.", - Ref: ref(v1.SleepAction{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - Dependencies: []string{ - v1.ExecAction{}.OpenAPIModelName(), v1.HTTPGetAction{}.OpenAPIModelName(), v1.SleepAction{}.OpenAPIModelName(), v1.TCPSocketAction{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_LimitRange(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "LimitRange sets resource usage limits for each kind of resource in a Namespace.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Type: []string{"string"}, - Format: "", - }, - }, - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", - Type: []string{"string"}, - Format: "", - }, - }, - "metadata": { - SchemaProps: spec.SchemaProps{ - Description: "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata", - Default: map[string]interface{}{}, - Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), - }, - }, - "spec": { - SchemaProps: spec.SchemaProps{ - Description: "Spec defines the limits enforced. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status", - Default: map[string]interface{}{}, - Ref: ref(v1.LimitRangeSpec{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - Dependencies: []string{ - v1.LimitRangeSpec{}.OpenAPIModelName(), metav1.ObjectMeta{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_LimitRangeItem(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "LimitRangeItem defines a min/max usage limit for any resource that matches on kind.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "type": { - SchemaProps: spec.SchemaProps{ - Description: "Type of resource that this limit applies to.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "max": { - SchemaProps: spec.SchemaProps{ - Description: "Max usage constraints on this kind by resource name.", - Type: []string{"object"}, - AdditionalProperties: &spec.SchemaOrBool{ - Allows: true, - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Ref: ref(resource.Quantity{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "min": { - SchemaProps: spec.SchemaProps{ - Description: "Min usage constraints on this kind by resource name.", - Type: []string{"object"}, - AdditionalProperties: &spec.SchemaOrBool{ - Allows: true, - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Ref: ref(resource.Quantity{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "default": { - SchemaProps: spec.SchemaProps{ - Description: "Default resource requirement limit value by resource name if resource limit is omitted.", - Type: []string{"object"}, - AdditionalProperties: &spec.SchemaOrBool{ - Allows: true, - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Ref: ref(resource.Quantity{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "defaultRequest": { - SchemaProps: spec.SchemaProps{ - Description: "DefaultRequest is the default resource requirement request value by resource name if resource request is omitted.", - Type: []string{"object"}, - AdditionalProperties: &spec.SchemaOrBool{ - Allows: true, - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Ref: ref(resource.Quantity{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "maxLimitRequestRatio": { - SchemaProps: spec.SchemaProps{ - Description: "MaxLimitRequestRatio if specified, the named resource must have a request and limit that are both non-zero where limit divided by request is less than or equal to the enumerated value; this represents the max burst for the named resource.", - Type: []string{"object"}, - AdditionalProperties: &spec.SchemaOrBool{ - Allows: true, - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Ref: ref(resource.Quantity{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - }, - Required: []string{"type"}, - }, - }, - Dependencies: []string{ - resource.Quantity{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_LimitRangeList(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "LimitRangeList is a list of LimitRange items.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Type: []string{"string"}, - Format: "", - }, - }, - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", - Type: []string{"string"}, - Format: "", - }, - }, - "metadata": { - SchemaProps: spec.SchemaProps{ - Description: "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Default: map[string]interface{}{}, - Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), - }, - }, - "items": { - SchemaProps: spec.SchemaProps{ - Description: "Items is a list of LimitRange objects. More info: https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.LimitRange{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - }, - Required: []string{"items"}, - }, - }, - Dependencies: []string{ - v1.LimitRange{}.OpenAPIModelName(), metav1.ListMeta{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_LimitRangeSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "LimitRangeSpec defines a min/max usage limit for resources that match on kind.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "limits": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "Limits is the list of LimitRangeItem objects that are enforced.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.LimitRangeItem{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - }, - Required: []string{"limits"}, - }, - }, - Dependencies: []string{ - v1.LimitRangeItem{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_LinuxContainerUser(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "LinuxContainerUser represents user identity information in Linux containers", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "uid": { - SchemaProps: spec.SchemaProps{ - Description: "UID is the primary uid initially attached to the first process in the container", - Default: 0, - Type: []string{"integer"}, - Format: "int64", - }, - }, - "gid": { - SchemaProps: spec.SchemaProps{ - Description: "GID is the primary gid initially attached to the first process in the container", - Default: 0, - Type: []string{"integer"}, - Format: "int64", - }, - }, - "supplementalGroups": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "SupplementalGroups are the supplemental groups initially attached to the first process in the container", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: 0, - Type: []string{"integer"}, - Format: "int64", - }, - }, - }, - }, - }, - }, - Required: []string{"uid", "gid"}, - }, - }, - } -} - -func schema_k8sio_api_core_v1_List(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "List holds a list of objects, which may not be known by the server.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Type: []string{"string"}, - Format: "", - }, - }, - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", - Type: []string{"string"}, - Format: "", - }, - }, - "metadata": { - SchemaProps: spec.SchemaProps{ - Description: "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Default: map[string]interface{}{}, - Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), - }, - }, - "items": { - SchemaProps: spec.SchemaProps{ - Description: "List of objects", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Ref: ref(runtime.RawExtension{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - }, - Required: []string{"items"}, - }, - }, - Dependencies: []string{ - metav1.ListMeta{}.OpenAPIModelName(), runtime.RawExtension{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_LoadBalancerIngress(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "LoadBalancerIngress represents the status of a load-balancer ingress point: traffic intended for the service should be sent to an ingress point.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "ip": { - SchemaProps: spec.SchemaProps{ - Description: "IP is set for load-balancer ingress points that are IP based (typically GCE or OpenStack load-balancers)", - Type: []string{"string"}, - Format: "", - }, - }, - "hostname": { - SchemaProps: spec.SchemaProps{ - Description: "Hostname is set for load-balancer ingress points that are DNS based (typically AWS load-balancers)", - Type: []string{"string"}, - Format: "", - }, - }, - "ipMode": { - SchemaProps: spec.SchemaProps{ - Description: "IPMode specifies how the load-balancer IP behaves, and may only be specified when the ip field is specified. Setting this to \"VIP\" indicates that traffic is delivered to the node with the destination set to the load-balancer's IP and port. Setting this to \"Proxy\" indicates that traffic is delivered to the node or pod with the destination set to the node's IP and node port or the pod's IP and port. Service implementations may use this information to adjust traffic routing.", - Type: []string{"string"}, - Format: "", - }, - }, - "ports": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "Ports is a list of records of service ports If used, every port defined in the service should have an entry in it", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.PortStatus{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - }, - }, - }, - Dependencies: []string{ - v1.PortStatus{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_LoadBalancerStatus(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "LoadBalancerStatus represents the status of a load-balancer.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "ingress": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "Ingress is a list containing ingress points for the load-balancer. Traffic intended for the service should be sent to these ingress points.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.LoadBalancerIngress{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - }, - }, - }, - Dependencies: []string{ - v1.LoadBalancerIngress{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_LocalObjectReference(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "LocalObjectReference contains enough information to let you locate the referenced object inside the same namespace.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "name": { - SchemaProps: spec.SchemaProps{ - Description: "Name of the referent. This field is effectively required, but due to backwards compatibility is allowed to be empty. Instances of this type with an empty value here are almost certainly wrong. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-map-type": "atomic", - }, - }, - }, - } -} - -func schema_k8sio_api_core_v1_LocalVolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "Local represents directly-attached storage with node affinity", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "path": { - SchemaProps: spec.SchemaProps{ - Description: "path of the full path to the volume on the node. It can be either a directory or block device (disk, partition, ...).", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "fsType": { - SchemaProps: spec.SchemaProps{ - Description: "fsType is the filesystem type to mount. It applies only when the Path is a block device. Must be a filesystem type supported by the host operating system. Ex. \"ext4\", \"xfs\", \"ntfs\". The default value is to auto-select a filesystem if unspecified.", - Type: []string{"string"}, - Format: "", - }, - }, - }, - Required: []string{"path"}, - }, - }, - } -} - -func schema_k8sio_api_core_v1_ModifyVolumeStatus(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "ModifyVolumeStatus represents the status object of ControllerModifyVolume operation", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "targetVolumeAttributesClassName": { - SchemaProps: spec.SchemaProps{ - Description: "targetVolumeAttributesClassName is the name of the VolumeAttributesClass the PVC currently being reconciled", - Type: []string{"string"}, - Format: "", - }, - }, - "status": { - SchemaProps: spec.SchemaProps{ - Description: "status is the status of the ControllerModifyVolume operation. It can be in any of following states:\n - Pending\n Pending indicates that the PersistentVolumeClaim cannot be modified due to unmet requirements, such as\n the specified VolumeAttributesClass not existing.\n - InProgress\n InProgress indicates that the volume is being modified.\n - Infeasible\n Infeasible indicates that the request has been rejected as invalid by the CSI driver. To\n\t resolve the error, a valid VolumeAttributesClass needs to be specified.\nNote: New statuses can be added in the future. Consumers should check for unknown statuses and fail appropriately.\n\nPossible enum values:\n - `\"InProgress\"` InProgress indicates that the volume is being modified\n - `\"Infeasible\"` Infeasible indicates that the request has been rejected as invalid by the CSI driver. To resolve the error, a valid VolumeAttributesClass needs to be specified\n - `\"Pending\"` Pending indicates that the PersistentVolumeClaim cannot be modified due to unmet requirements, such as the specified VolumeAttributesClass not existing", - Default: "", - Type: []string{"string"}, - Format: "", - Enum: []interface{}{"InProgress", "Infeasible", "Pending"}, - }, - }, - }, - Required: []string{"status"}, - }, - }, - } -} - -func schema_k8sio_api_core_v1_NFSVolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "Represents an NFS mount that lasts the lifetime of a pod. NFS volumes do not support ownership management or SELinux relabeling.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "server": { - SchemaProps: spec.SchemaProps{ - Description: "server is the hostname or IP address of the NFS server. More info: https://kubernetes.io/docs/concepts/storage/volumes#nfs", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "path": { - SchemaProps: spec.SchemaProps{ - Description: "path that is exported by the NFS server. More info: https://kubernetes.io/docs/concepts/storage/volumes#nfs", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "readOnly": { - SchemaProps: spec.SchemaProps{ - Description: "readOnly here will force the NFS export to be mounted with read-only permissions. Defaults to false. More info: https://kubernetes.io/docs/concepts/storage/volumes#nfs", - Type: []string{"boolean"}, - Format: "", - }, - }, - }, - Required: []string{"server", "path"}, - }, - }, - } -} - -func schema_k8sio_api_core_v1_Namespace(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "Namespace provides a scope for Names. Use of multiple namespaces is optional.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Type: []string{"string"}, - Format: "", - }, - }, - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", - Type: []string{"string"}, - Format: "", - }, - }, - "metadata": { - SchemaProps: spec.SchemaProps{ - Description: "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata", - Default: map[string]interface{}{}, - Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), - }, - }, - "spec": { - SchemaProps: spec.SchemaProps{ - Description: "Spec defines the behavior of the Namespace. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status", - Default: map[string]interface{}{}, - Ref: ref(v1.NamespaceSpec{}.OpenAPIModelName()), - }, - }, - "status": { - SchemaProps: spec.SchemaProps{ - Description: "Status describes the current status of a Namespace. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status", - Default: map[string]interface{}{}, - Ref: ref(v1.NamespaceStatus{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - Dependencies: []string{ - v1.NamespaceSpec{}.OpenAPIModelName(), v1.NamespaceStatus{}.OpenAPIModelName(), metav1.ObjectMeta{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_NamespaceCondition(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "NamespaceCondition contains details about state of namespace.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "type": { - SchemaProps: spec.SchemaProps{ - Description: "Type of namespace controller condition.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "status": { - SchemaProps: spec.SchemaProps{ - Description: "Status of the condition, one of True, False, Unknown.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "lastTransitionTime": { - SchemaProps: spec.SchemaProps{ - Description: "Last time the condition transitioned from one status to another.", - Ref: ref(metav1.Time{}.OpenAPIModelName()), - }, - }, - "reason": { - SchemaProps: spec.SchemaProps{ - Description: "Unique, one-word, CamelCase reason for the condition's last transition.", - Type: []string{"string"}, - Format: "", - }, - }, - "message": { - SchemaProps: spec.SchemaProps{ - Description: "Human-readable message indicating details about last transition.", - Type: []string{"string"}, - Format: "", - }, - }, - }, - Required: []string{"type", "status"}, - }, - }, - Dependencies: []string{ - metav1.Time{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_NamespaceList(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "NamespaceList is a list of Namespaces.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Type: []string{"string"}, - Format: "", - }, - }, - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", - Type: []string{"string"}, - Format: "", - }, - }, - "metadata": { - SchemaProps: spec.SchemaProps{ - Description: "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Default: map[string]interface{}{}, - Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), - }, - }, - "items": { - SchemaProps: spec.SchemaProps{ - Description: "Items is the list of Namespace objects in the list. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/namespaces/", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.Namespace{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - }, - Required: []string{"items"}, - }, - }, - Dependencies: []string{ - v1.Namespace{}.OpenAPIModelName(), metav1.ListMeta{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_NamespaceSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "NamespaceSpec describes the attributes on a Namespace.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "finalizers": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "Finalizers is an opaque list of values that must be empty to permanently remove object from storage. More info: https://kubernetes.io/docs/tasks/administer-cluster/namespaces/", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - }, - }, - }, - } -} - -func schema_k8sio_api_core_v1_NamespaceStatus(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "NamespaceStatus is information about the current status of a Namespace.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "phase": { - SchemaProps: spec.SchemaProps{ - Description: "Phase is the current lifecycle phase of the namespace. More info: https://kubernetes.io/docs/tasks/administer-cluster/namespaces/\n\nPossible enum values:\n - `\"Active\"` means the namespace is available for use in the system\n - `\"Terminating\"` means the namespace is undergoing graceful termination", - Type: []string{"string"}, - Format: "", - Enum: []interface{}{"Active", "Terminating"}, - }, - }, - "conditions": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-map-keys": []interface{}{ - "type", - }, - "x-kubernetes-list-type": "map", - "x-kubernetes-patch-merge-key": "type", - "x-kubernetes-patch-strategy": "merge", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "Represents the latest available observations of a namespace's current state.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.NamespaceCondition{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - }, - }, - }, - Dependencies: []string{ - v1.NamespaceCondition{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_Node(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "Node is a worker node in Kubernetes. Each node will have a unique identifier in the cache (i.e. in etcd).", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Type: []string{"string"}, - Format: "", - }, - }, - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", - Type: []string{"string"}, - Format: "", - }, - }, - "metadata": { - SchemaProps: spec.SchemaProps{ - Description: "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata", - Default: map[string]interface{}{}, - Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), - }, - }, - "spec": { - SchemaProps: spec.SchemaProps{ - Description: "Spec defines the behavior of a node. https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status", - Default: map[string]interface{}{}, - Ref: ref(v1.NodeSpec{}.OpenAPIModelName()), - }, - }, - "status": { - SchemaProps: spec.SchemaProps{ - Description: "Most recently observed status of the node. Populated by the system. Read-only. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status", - Default: map[string]interface{}{}, - Ref: ref(v1.NodeStatus{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - Dependencies: []string{ - v1.NodeSpec{}.OpenAPIModelName(), v1.NodeStatus{}.OpenAPIModelName(), metav1.ObjectMeta{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_NodeAddress(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "NodeAddress contains information for the node's address.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "type": { - SchemaProps: spec.SchemaProps{ - Description: "Node address type, one of Hostname, ExternalIP or InternalIP.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "address": { - SchemaProps: spec.SchemaProps{ - Description: "The node address.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - Required: []string{"type", "address"}, - }, - }, - } -} - -func schema_k8sio_api_core_v1_NodeAffinity(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "Node affinity is a group of node affinity scheduling rules.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "requiredDuringSchedulingIgnoredDuringExecution": { - SchemaProps: spec.SchemaProps{ - Description: "If the affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to an update), the system may or may not try to eventually evict the pod from its node.", - Ref: ref(v1.NodeSelector{}.OpenAPIModelName()), - }, - }, - "preferredDuringSchedulingIgnoredDuringExecution": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "The scheduler will prefer to schedule pods to nodes that satisfy the affinity expressions specified by this field, but it may choose a node that violates one or more of the expressions. The node that is most preferred is the one with the greatest sum of weights, i.e. for each node that meets all of the scheduling requirements (resource request, requiredDuringScheduling affinity expressions, etc.), compute a sum by iterating through the elements of this field and adding \"weight\" to the sum if the node matches the corresponding matchExpressions; the node(s) with the highest sum are the most preferred.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.PreferredSchedulingTerm{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - }, - }, - }, - Dependencies: []string{ - v1.NodeSelector{}.OpenAPIModelName(), v1.PreferredSchedulingTerm{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_NodeCondition(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "NodeCondition contains condition information for a node.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "type": { - SchemaProps: spec.SchemaProps{ - Description: "Type of node condition.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "status": { - SchemaProps: spec.SchemaProps{ - Description: "Status of the condition, one of True, False, Unknown.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "lastHeartbeatTime": { - SchemaProps: spec.SchemaProps{ - Description: "Last time we got an update on a given condition.", - Ref: ref(metav1.Time{}.OpenAPIModelName()), - }, - }, - "lastTransitionTime": { - SchemaProps: spec.SchemaProps{ - Description: "Last time the condition transit from one status to another.", - Ref: ref(metav1.Time{}.OpenAPIModelName()), - }, - }, - "reason": { - SchemaProps: spec.SchemaProps{ - Description: "(brief) reason for the condition's last transition.", - Type: []string{"string"}, - Format: "", - }, - }, - "message": { - SchemaProps: spec.SchemaProps{ - Description: "Human readable message indicating details about last transition.", - Type: []string{"string"}, - Format: "", - }, - }, - }, - Required: []string{"type", "status"}, - }, - }, - Dependencies: []string{ - metav1.Time{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_NodeConfigSource(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "NodeConfigSource specifies a source of node configuration. Exactly one subfield (excluding metadata) must be non-nil. This API is deprecated since 1.22", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "configMap": { - SchemaProps: spec.SchemaProps{ - Description: "ConfigMap is a reference to a Node's ConfigMap", - Ref: ref(v1.ConfigMapNodeConfigSource{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - Dependencies: []string{ - v1.ConfigMapNodeConfigSource{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_NodeConfigStatus(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "NodeConfigStatus describes the status of the config assigned by Node.Spec.ConfigSource.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "assigned": { - SchemaProps: spec.SchemaProps{ - Description: "Assigned reports the checkpointed config the node will try to use. When Node.Spec.ConfigSource is updated, the node checkpoints the associated config payload to local disk, along with a record indicating intended config. The node refers to this record to choose its config checkpoint, and reports this record in Assigned. Assigned only updates in the status after the record has been checkpointed to disk. When the Kubelet is restarted, it tries to make the Assigned config the Active config by loading and validating the checkpointed payload identified by Assigned.", - Ref: ref(v1.NodeConfigSource{}.OpenAPIModelName()), - }, - }, - "active": { - SchemaProps: spec.SchemaProps{ - Description: "Active reports the checkpointed config the node is actively using. Active will represent either the current version of the Assigned config, or the current LastKnownGood config, depending on whether attempting to use the Assigned config results in an error.", - Ref: ref(v1.NodeConfigSource{}.OpenAPIModelName()), - }, - }, - "lastKnownGood": { - SchemaProps: spec.SchemaProps{ - Description: "LastKnownGood reports the checkpointed config the node will fall back to when it encounters an error attempting to use the Assigned config. The Assigned config becomes the LastKnownGood config when the node determines that the Assigned config is stable and correct. This is currently implemented as a 10-minute soak period starting when the local record of Assigned config is updated. If the Assigned config is Active at the end of this period, it becomes the LastKnownGood. Note that if Spec.ConfigSource is reset to nil (use local defaults), the LastKnownGood is also immediately reset to nil, because the local default config is always assumed good. You should not make assumptions about the node's method of determining config stability and correctness, as this may change or become configurable in the future.", - Ref: ref(v1.NodeConfigSource{}.OpenAPIModelName()), - }, - }, - "error": { - SchemaProps: spec.SchemaProps{ - Description: "Error describes any problems reconciling the Spec.ConfigSource to the Active config. Errors may occur, for example, attempting to checkpoint Spec.ConfigSource to the local Assigned record, attempting to checkpoint the payload associated with Spec.ConfigSource, attempting to load or validate the Assigned config, etc. Errors may occur at different points while syncing config. Earlier errors (e.g. download or checkpointing errors) will not result in a rollback to LastKnownGood, and may resolve across Kubelet retries. Later errors (e.g. loading or validating a checkpointed config) will result in a rollback to LastKnownGood. In the latter case, it is usually possible to resolve the error by fixing the config assigned in Spec.ConfigSource. You can find additional information for debugging by searching the error message in the Kubelet log. Error is a human-readable description of the error state; machines can check whether or not Error is empty, but should not rely on the stability of the Error text across Kubelet versions.", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - Dependencies: []string{ - v1.NodeConfigSource{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_NodeDaemonEndpoints(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "NodeDaemonEndpoints lists ports opened by daemons running on the Node.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "kubeletEndpoint": { - SchemaProps: spec.SchemaProps{ - Description: "Endpoint on which Kubelet is listening.", - Default: map[string]interface{}{}, - Ref: ref(v1.DaemonEndpoint{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - Dependencies: []string{ - v1.DaemonEndpoint{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_NodeFeatures(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "NodeFeatures describes the set of features implemented by the CRI implementation. The features contained in the NodeFeatures should depend only on the cri implementation independent of runtime handlers.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "supplementalGroupsPolicy": { - SchemaProps: spec.SchemaProps{ - Description: "SupplementalGroupsPolicy is set to true if the runtime supports SupplementalGroupsPolicy and ContainerUser.", - Type: []string{"boolean"}, - Format: "", - }, - }, - }, - }, - }, - } -} - -func schema_k8sio_api_core_v1_NodeList(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "NodeList is the whole list of all Nodes which have been registered with master.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Type: []string{"string"}, - Format: "", - }, - }, - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", - Type: []string{"string"}, - Format: "", - }, - }, - "metadata": { - SchemaProps: spec.SchemaProps{ - Description: "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Default: map[string]interface{}{}, - Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), - }, - }, - "items": { - SchemaProps: spec.SchemaProps{ - Description: "List of nodes", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.Node{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - }, - Required: []string{"items"}, - }, - }, - Dependencies: []string{ - v1.Node{}.OpenAPIModelName(), metav1.ListMeta{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_NodeProxyOptions(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "NodeProxyOptions is the query options to a Node's proxy call.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Type: []string{"string"}, - Format: "", - }, - }, - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", - Type: []string{"string"}, - Format: "", - }, - }, - "path": { - SchemaProps: spec.SchemaProps{ - Description: "Path is the URL path to use for the current proxy request to node.", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - } -} - -func schema_k8sio_api_core_v1_NodeRuntimeHandler(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "NodeRuntimeHandler is a set of runtime handler information.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "name": { - SchemaProps: spec.SchemaProps{ - Description: "Runtime handler name. Empty for the default runtime handler.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "features": { - SchemaProps: spec.SchemaProps{ - Description: "Supported features.", - Ref: ref(v1.NodeRuntimeHandlerFeatures{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - Dependencies: []string{ - v1.NodeRuntimeHandlerFeatures{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_NodeRuntimeHandlerFeatures(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "NodeRuntimeHandlerFeatures is a set of features implemented by the runtime handler.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "recursiveReadOnlyMounts": { - SchemaProps: spec.SchemaProps{ - Description: "RecursiveReadOnlyMounts is set to true if the runtime handler supports RecursiveReadOnlyMounts.", - Type: []string{"boolean"}, - Format: "", - }, - }, - "userNamespaces": { - SchemaProps: spec.SchemaProps{ - Description: "UserNamespaces is set to true if the runtime handler supports UserNamespaces, including for volumes.", - Type: []string{"boolean"}, - Format: "", - }, - }, - }, - }, - }, - } -} - -func schema_k8sio_api_core_v1_NodeSelector(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "A node selector represents the union of the results of one or more label queries over a set of nodes; that is, it represents the OR of the selectors represented by the node selector terms.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "nodeSelectorTerms": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "Required. A list of node selector terms. The terms are ORed.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.NodeSelectorTerm{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - }, - Required: []string{"nodeSelectorTerms"}, - }, - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-map-type": "atomic", - }, - }, - }, - Dependencies: []string{ - v1.NodeSelectorTerm{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_NodeSelectorRequirement(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "A node selector requirement is a selector that contains values, a key, and an operator that relates the key and values.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "key": { - SchemaProps: spec.SchemaProps{ - Description: "The label key that the selector applies to.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "operator": { - SchemaProps: spec.SchemaProps{ - Description: "Represents a key's relationship to a set of values. Valid operators are In, NotIn, Exists, DoesNotExist. Gt, and Lt.\n\nPossible enum values:\n - `\"DoesNotExist\"`\n - `\"Exists\"`\n - `\"Gt\"`\n - `\"In\"`\n - `\"Lt\"`\n - `\"NotIn\"`", - Default: "", - Type: []string{"string"}, - Format: "", - Enum: []interface{}{"DoesNotExist", "Exists", "Gt", "In", "Lt", "NotIn"}, - }, - }, - "values": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "An array of string values. If the operator is In or NotIn, the values array must be non-empty. If the operator is Exists or DoesNotExist, the values array must be empty. If the operator is Gt or Lt, the values array must have a single element, which will be interpreted as an integer. This array is replaced during a strategic merge patch.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - }, - Required: []string{"key", "operator"}, - }, - }, - } -} - -func schema_k8sio_api_core_v1_NodeSelectorTerm(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "A null or empty node selector term matches no objects. The requirements of them are ANDed. The TopologySelectorTerm type implements a subset of the NodeSelectorTerm.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "matchExpressions": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "A list of node selector requirements by node's labels.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.NodeSelectorRequirement{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "matchFields": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "A list of node selector requirements by node's fields.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.NodeSelectorRequirement{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - }, - }, - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-map-type": "atomic", - }, - }, - }, - Dependencies: []string{ - v1.NodeSelectorRequirement{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_NodeSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "NodeSpec describes the attributes that a node is created with.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "podCIDR": { - SchemaProps: spec.SchemaProps{ - Description: "PodCIDR represents the pod IP range assigned to the node.", - Type: []string{"string"}, - Format: "", - }, - }, - "podCIDRs": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "set", - "x-kubernetes-patch-strategy": "merge", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "podCIDRs represents the IP ranges assigned to the node for usage by Pods on that node. If this field is specified, the 0th entry must match the podCIDR field. It may contain at most 1 value for each of IPv4 and IPv6.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - "providerID": { - SchemaProps: spec.SchemaProps{ - Description: "ID of the node assigned by the cloud provider in the format: ://", - Type: []string{"string"}, - Format: "", - }, - }, - "unschedulable": { - SchemaProps: spec.SchemaProps{ - Description: "Unschedulable controls node schedulability of new pods. By default, node is schedulable. More info: https://kubernetes.io/docs/concepts/nodes/node/#manual-node-administration", - Type: []string{"boolean"}, - Format: "", - }, - }, - "taints": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "If specified, the node's taints.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.Taint{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "configSource": { - SchemaProps: spec.SchemaProps{ - Description: "Deprecated: Previously used to specify the source of the node's configuration for the DynamicKubeletConfig feature. This feature is removed.", - Ref: ref(v1.NodeConfigSource{}.OpenAPIModelName()), - }, - }, - "externalID": { - SchemaProps: spec.SchemaProps{ - Description: "Deprecated. Not all kubelets will set this field. Remove field after 1.13. see: https://issues.k8s.io/61966", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - Dependencies: []string{ - v1.NodeConfigSource{}.OpenAPIModelName(), v1.Taint{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_NodeStatus(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "NodeStatus is information about the current status of a node.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "capacity": { - SchemaProps: spec.SchemaProps{ - Description: "Capacity represents the total resources of a node. More info: https://kubernetes.io/docs/reference/node/node-status/#capacity", - Type: []string{"object"}, - AdditionalProperties: &spec.SchemaOrBool{ - Allows: true, - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Ref: ref(resource.Quantity{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "allocatable": { - SchemaProps: spec.SchemaProps{ - Description: "Allocatable represents the resources of a node that are available for scheduling. Defaults to Capacity.", - Type: []string{"object"}, - AdditionalProperties: &spec.SchemaOrBool{ - Allows: true, - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Ref: ref(resource.Quantity{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "phase": { - SchemaProps: spec.SchemaProps{ - Description: "NodePhase is the recently observed lifecycle phase of the node. More info: https://kubernetes.io/docs/concepts/nodes/node/#phase The field is never populated, and now is deprecated.\n\nPossible enum values:\n - `\"Pending\"` means the node has been created/added by the system, but not configured.\n - `\"Running\"` means the node has been configured and has Kubernetes components running.\n - `\"Terminated\"` means the node has been removed from the cluster.", - Type: []string{"string"}, - Format: "", - Enum: []interface{}{"Pending", "Running", "Terminated"}, - }, - }, - "conditions": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-map-keys": []interface{}{ - "type", - }, - "x-kubernetes-list-type": "map", - "x-kubernetes-patch-merge-key": "type", - "x-kubernetes-patch-strategy": "merge", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "Conditions is an array of current observed node conditions. More info: https://kubernetes.io/docs/reference/node/node-status/#condition", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.NodeCondition{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "addresses": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-map-keys": []interface{}{ - "type", - }, - "x-kubernetes-list-type": "map", - "x-kubernetes-patch-merge-key": "type", - "x-kubernetes-patch-strategy": "merge", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "List of addresses reachable to the node. Queried from cloud provider, if available. More info: https://kubernetes.io/docs/reference/node/node-status/#addresses Note: This field is declared as mergeable, but the merge key is not sufficiently unique, which can cause data corruption when it is merged. Callers should instead use a full-replacement patch. See https://pr.k8s.io/79391 for an example. Consumers should assume that addresses can change during the lifetime of a Node. However, there are some exceptions where this may not be possible, such as Pods that inherit a Node's address in its own status or consumers of the downward API (status.hostIP).", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.NodeAddress{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "daemonEndpoints": { - SchemaProps: spec.SchemaProps{ - Description: "Endpoints of daemons running on the Node.", - Default: map[string]interface{}{}, - Ref: ref(v1.NodeDaemonEndpoints{}.OpenAPIModelName()), - }, - }, - "nodeInfo": { - SchemaProps: spec.SchemaProps{ - Description: "Set of ids/uuids to uniquely identify the node. More info: https://kubernetes.io/docs/reference/node/node-status/#info", - Default: map[string]interface{}{}, - Ref: ref(v1.NodeSystemInfo{}.OpenAPIModelName()), - }, - }, - "images": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "List of container images on this node", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.ContainerImage{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "volumesInUse": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "List of attachable volumes in use (mounted) by the node.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - "volumesAttached": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "List of volumes that are attached to the node.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.AttachedVolume{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "config": { - SchemaProps: spec.SchemaProps{ - Description: "Status of the config assigned to the node via the dynamic Kubelet config feature.", - Ref: ref(v1.NodeConfigStatus{}.OpenAPIModelName()), - }, - }, - "runtimeHandlers": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "The available runtime handlers.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.NodeRuntimeHandler{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "features": { - SchemaProps: spec.SchemaProps{ - Description: "Features describes the set of features implemented by the CRI implementation.", - Ref: ref(v1.NodeFeatures{}.OpenAPIModelName()), - }, - }, - "declaredFeatures": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "DeclaredFeatures represents the features related to feature gates that are declared by the node.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - }, - }, - }, - Dependencies: []string{ - v1.AttachedVolume{}.OpenAPIModelName(), v1.ContainerImage{}.OpenAPIModelName(), v1.NodeAddress{}.OpenAPIModelName(), v1.NodeCondition{}.OpenAPIModelName(), v1.NodeConfigStatus{}.OpenAPIModelName(), v1.NodeDaemonEndpoints{}.OpenAPIModelName(), v1.NodeFeatures{}.OpenAPIModelName(), v1.NodeRuntimeHandler{}.OpenAPIModelName(), v1.NodeSystemInfo{}.OpenAPIModelName(), resource.Quantity{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_NodeSwapStatus(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "NodeSwapStatus represents swap memory information.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "capacity": { - SchemaProps: spec.SchemaProps{ - Description: "Total amount of swap memory in bytes.", - Type: []string{"integer"}, - Format: "int64", - }, - }, - }, - }, - }, - } -} - -func schema_k8sio_api_core_v1_NodeSystemInfo(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "NodeSystemInfo is a set of ids/uuids to uniquely identify the node.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "machineID": { - SchemaProps: spec.SchemaProps{ - Description: "MachineID reported by the node. For unique machine identification in the cluster this field is preferred. Learn more from man(5) machine-id: http://man7.org/linux/man-pages/man5/machine-id.5.html", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "systemUUID": { - SchemaProps: spec.SchemaProps{ - Description: "SystemUUID reported by the node. For unique machine identification MachineID is preferred. This field is specific to Red Hat hosts https://access.redhat.com/documentation/en-us/red_hat_subscription_management/1/html/rhsm/uuid", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "bootID": { - SchemaProps: spec.SchemaProps{ - Description: "Boot ID reported by the node.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "kernelVersion": { - SchemaProps: spec.SchemaProps{ - Description: "Kernel Version reported by the node from 'uname -r' (e.g. 3.16.0-0.bpo.4-amd64).", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "osImage": { - SchemaProps: spec.SchemaProps{ - Description: "OS Image reported by the node from /etc/os-release (e.g. Debian GNU/Linux 7 (wheezy)).", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "containerRuntimeVersion": { - SchemaProps: spec.SchemaProps{ - Description: "ContainerRuntime Version reported by the node through runtime remote API (e.g. containerd://1.4.2).", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "kubeletVersion": { - SchemaProps: spec.SchemaProps{ - Description: "Kubelet Version reported by the node.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "kubeProxyVersion": { - SchemaProps: spec.SchemaProps{ - Description: "Deprecated: KubeProxy Version reported by the node.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "operatingSystem": { - SchemaProps: spec.SchemaProps{ - Description: "The Operating System reported by the node", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "architecture": { - SchemaProps: spec.SchemaProps{ - Description: "The Architecture reported by the node", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "swap": { - SchemaProps: spec.SchemaProps{ - Description: "Swap Info reported by the node.", - Ref: ref(v1.NodeSwapStatus{}.OpenAPIModelName()), - }, - }, - }, - Required: []string{"machineID", "systemUUID", "bootID", "kernelVersion", "osImage", "containerRuntimeVersion", "kubeletVersion", "kubeProxyVersion", "operatingSystem", "architecture"}, - }, - }, - Dependencies: []string{ - v1.NodeSwapStatus{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_ObjectFieldSelector(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "ObjectFieldSelector selects an APIVersioned field of an object.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "Version of the schema the FieldPath is written in terms of, defaults to \"v1\".", - Type: []string{"string"}, - Format: "", - }, - }, - "fieldPath": { - SchemaProps: spec.SchemaProps{ - Description: "Path of the field to select in the specified API version.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - Required: []string{"fieldPath"}, - }, - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-map-type": "atomic", - }, - }, - }, - } -} - -func schema_k8sio_api_core_v1_ObjectReference(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "ObjectReference contains enough information to let you inspect or modify the referred object.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind of the referent. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Type: []string{"string"}, - Format: "", - }, - }, - "namespace": { - SchemaProps: spec.SchemaProps{ - Description: "Namespace of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/namespaces/", - Type: []string{"string"}, - Format: "", - }, - }, - "name": { - SchemaProps: spec.SchemaProps{ - Description: "Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names", - Type: []string{"string"}, - Format: "", - }, - }, - "uid": { - SchemaProps: spec.SchemaProps{ - Description: "UID of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#uids", - Type: []string{"string"}, - Format: "", - }, - }, - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "API version of the referent.", - Type: []string{"string"}, - Format: "", - }, - }, - "resourceVersion": { - SchemaProps: spec.SchemaProps{ - Description: "Specific resourceVersion to which this reference is made, if any. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#concurrency-control-and-consistency", - Type: []string{"string"}, - Format: "", - }, - }, - "fieldPath": { - SchemaProps: spec.SchemaProps{ - Description: "If referring to a piece of an object instead of an entire object, this string should contain a valid JSON/Go field access statement, such as desiredState.manifest.containers[2]. For example, if the object reference is to a container within a pod, this would take on a value like: \"spec.containers{name}\" (where \"name\" refers to the name of the container that triggered the event) or if no container name is specified \"spec.containers[2]\" (container with index 2 in this pod). This syntax is chosen only to have some well-defined way of referencing a part of an object.", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-map-type": "atomic", - }, - }, - }, - } -} - -func schema_k8sio_api_core_v1_PersistentVolume(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "PersistentVolume (PV) is a storage resource provisioned by an administrator. It is analogous to a node. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Type: []string{"string"}, - Format: "", - }, - }, - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", - Type: []string{"string"}, - Format: "", - }, - }, - "metadata": { - SchemaProps: spec.SchemaProps{ - Description: "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata", - Default: map[string]interface{}{}, - Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), - }, - }, - "spec": { - SchemaProps: spec.SchemaProps{ - Description: "spec defines a specification of a persistent volume owned by the cluster. Provisioned by an administrator. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#persistent-volumes", - Default: map[string]interface{}{}, - Ref: ref(v1.PersistentVolumeSpec{}.OpenAPIModelName()), - }, - }, - "status": { - SchemaProps: spec.SchemaProps{ - Description: "status represents the current information/status for the persistent volume. Populated by the system. Read-only. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#persistent-volumes", - Default: map[string]interface{}{}, - Ref: ref(v1.PersistentVolumeStatus{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - Dependencies: []string{ - v1.PersistentVolumeSpec{}.OpenAPIModelName(), v1.PersistentVolumeStatus{}.OpenAPIModelName(), metav1.ObjectMeta{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_PersistentVolumeClaim(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "PersistentVolumeClaim is a user's request for and claim to a persistent volume", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Type: []string{"string"}, - Format: "", - }, - }, - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", - Type: []string{"string"}, - Format: "", - }, - }, - "metadata": { - SchemaProps: spec.SchemaProps{ - Description: "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata", - Default: map[string]interface{}{}, - Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), - }, - }, - "spec": { - SchemaProps: spec.SchemaProps{ - Description: "spec defines the desired characteristics of a volume requested by a pod author. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#persistentvolumeclaims", - Default: map[string]interface{}{}, - Ref: ref(v1.PersistentVolumeClaimSpec{}.OpenAPIModelName()), - }, - }, - "status": { - SchemaProps: spec.SchemaProps{ - Description: "status represents the current information/status of a persistent volume claim. Read-only. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#persistentvolumeclaims", - Default: map[string]interface{}{}, - Ref: ref(v1.PersistentVolumeClaimStatus{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - Dependencies: []string{ - v1.PersistentVolumeClaimSpec{}.OpenAPIModelName(), v1.PersistentVolumeClaimStatus{}.OpenAPIModelName(), metav1.ObjectMeta{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_PersistentVolumeClaimCondition(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "PersistentVolumeClaimCondition contains details about state of pvc", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "type": { - SchemaProps: spec.SchemaProps{ - Description: "Type is the type of the condition. More info: https://kubernetes.io/docs/reference/kubernetes-api/config-and-storage-resources/persistent-volume-claim-v1/#:~:text=set%20to%20%27ResizeStarted%27.-,PersistentVolumeClaimCondition,-contains%20details%20about", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "status": { - SchemaProps: spec.SchemaProps{ - Description: "Status is the status of the condition. Can be True, False, Unknown. More info: https://kubernetes.io/docs/reference/kubernetes-api/config-and-storage-resources/persistent-volume-claim-v1/#:~:text=state%20of%20pvc-,conditions.status,-(string)%2C%20required", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "lastProbeTime": { - SchemaProps: spec.SchemaProps{ - Description: "lastProbeTime is the time we probed the condition.", - Ref: ref(metav1.Time{}.OpenAPIModelName()), - }, - }, - "lastTransitionTime": { - SchemaProps: spec.SchemaProps{ - Description: "lastTransitionTime is the time the condition transitioned from one status to another.", - Ref: ref(metav1.Time{}.OpenAPIModelName()), - }, - }, - "reason": { - SchemaProps: spec.SchemaProps{ - Description: "reason is a unique, this should be a short, machine understandable string that gives the reason for condition's last transition. If it reports \"Resizing\" that means the underlying persistent volume is being resized.", - Type: []string{"string"}, - Format: "", - }, - }, - "message": { - SchemaProps: spec.SchemaProps{ - Description: "message is the human-readable message indicating details about last transition.", - Type: []string{"string"}, - Format: "", - }, - }, - }, - Required: []string{"type", "status"}, - }, - }, - Dependencies: []string{ - metav1.Time{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_PersistentVolumeClaimList(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "PersistentVolumeClaimList is a list of PersistentVolumeClaim items.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Type: []string{"string"}, - Format: "", - }, - }, - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", - Type: []string{"string"}, - Format: "", - }, - }, - "metadata": { - SchemaProps: spec.SchemaProps{ - Description: "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Default: map[string]interface{}{}, - Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), - }, - }, - "items": { - SchemaProps: spec.SchemaProps{ - Description: "items is a list of persistent volume claims. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#persistentvolumeclaims", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.PersistentVolumeClaim{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - }, - Required: []string{"items"}, - }, - }, - Dependencies: []string{ - v1.PersistentVolumeClaim{}.OpenAPIModelName(), metav1.ListMeta{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_PersistentVolumeClaimSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "PersistentVolumeClaimSpec describes the common attributes of storage devices and allows a Source for provider-specific attributes", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "accessModes": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "accessModes contains the desired access modes the volume should have. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#access-modes-1", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - Enum: []interface{}{"ReadOnlyMany", "ReadWriteMany", "ReadWriteOnce", "ReadWriteOncePod"}, - }, - }, - }, - }, - }, - "selector": { - SchemaProps: spec.SchemaProps{ - Description: "selector is a label query over volumes to consider for binding.", - Ref: ref(metav1.LabelSelector{}.OpenAPIModelName()), - }, - }, - "resources": { - SchemaProps: spec.SchemaProps{ - Description: "resources represents the minimum resources the volume should have. Users are allowed to specify resource requirements that are lower than previous value but must still be higher than capacity recorded in the status field of the claim. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#resources", - Default: map[string]interface{}{}, - Ref: ref(v1.VolumeResourceRequirements{}.OpenAPIModelName()), - }, - }, - "volumeName": { - SchemaProps: spec.SchemaProps{ - Description: "volumeName is the binding reference to the PersistentVolume backing this claim.", - Type: []string{"string"}, - Format: "", - }, - }, - "storageClassName": { - SchemaProps: spec.SchemaProps{ - Description: "storageClassName is the name of the StorageClass required by the claim. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#class-1", - Type: []string{"string"}, - Format: "", - }, - }, - "volumeMode": { - SchemaProps: spec.SchemaProps{ - Description: "volumeMode defines what type of volume is required by the claim. Value of Filesystem is implied when not included in claim spec.\n\nPossible enum values:\n - `\"Block\"` means the volume will not be formatted with a filesystem and will remain a raw block device.\n - `\"Filesystem\"` means the volume will be or is formatted with a filesystem.", - Type: []string{"string"}, - Format: "", - Enum: []interface{}{"Block", "Filesystem"}, - }, - }, - "dataSource": { - SchemaProps: spec.SchemaProps{ - Description: "dataSource field can be used to specify either: * An existing VolumeSnapshot object (snapshot.storage.k8s.io/VolumeSnapshot) * An existing PVC (PersistentVolumeClaim) If the provisioner or an external controller can support the specified data source, it will create a new volume based on the contents of the specified data source. When the AnyVolumeDataSource feature gate is enabled, dataSource contents will be copied to dataSourceRef, and dataSourceRef contents will be copied to dataSource when dataSourceRef.namespace is not specified. If the namespace is specified, then dataSourceRef will not be copied to dataSource.", - Ref: ref(v1.TypedLocalObjectReference{}.OpenAPIModelName()), - }, - }, - "dataSourceRef": { - SchemaProps: spec.SchemaProps{ - Description: "dataSourceRef specifies the object from which to populate the volume with data, if a non-empty volume is desired. This may be any object from a non-empty API group (non core object) or a PersistentVolumeClaim object. When this field is specified, volume binding will only succeed if the type of the specified object matches some installed volume populator or dynamic provisioner. This field will replace the functionality of the dataSource field and as such if both fields are non-empty, they must have the same value. For backwards compatibility, when namespace isn't specified in dataSourceRef, both fields (dataSource and dataSourceRef) will be set to the same value automatically if one of them is empty and the other is non-empty. When namespace is specified in dataSourceRef, dataSource isn't set to the same value and must be empty. There are three important differences between dataSource and dataSourceRef: * While dataSource only allows two specific types of objects, dataSourceRef\n allows any non-core object, as well as PersistentVolumeClaim objects.\n* While dataSource ignores disallowed values (dropping them), dataSourceRef\n preserves all values, and generates an error if a disallowed value is\n specified.\n* While dataSource only allows local objects, dataSourceRef allows objects\n in any namespaces.\n(Beta) Using this field requires the AnyVolumeDataSource feature gate to be enabled. (Alpha) Using the namespace field of dataSourceRef requires the CrossNamespaceVolumeDataSource feature gate to be enabled.", - Ref: ref(v1.TypedObjectReference{}.OpenAPIModelName()), - }, - }, - "volumeAttributesClassName": { - SchemaProps: spec.SchemaProps{ - Description: "volumeAttributesClassName may be used to set the VolumeAttributesClass used by this claim. If specified, the CSI driver will create or update the volume with the attributes defined in the corresponding VolumeAttributesClass. This has a different purpose than storageClassName, it can be changed after the claim is created. An empty string or nil value indicates that no VolumeAttributesClass will be applied to the claim. If the claim enters an Infeasible error state, this field can be reset to its previous value (including nil) to cancel the modification. If the resource referred to by volumeAttributesClass does not exist, this PersistentVolumeClaim will be set to a Pending state, as reflected by the modifyVolumeStatus field, until such as a resource exists. More info: https://kubernetes.io/docs/concepts/storage/volume-attributes-classes/", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - Dependencies: []string{ - v1.TypedLocalObjectReference{}.OpenAPIModelName(), v1.TypedObjectReference{}.OpenAPIModelName(), v1.VolumeResourceRequirements{}.OpenAPIModelName(), metav1.LabelSelector{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_PersistentVolumeClaimStatus(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "PersistentVolumeClaimStatus is the current status of a persistent volume claim.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "phase": { - SchemaProps: spec.SchemaProps{ - Description: "phase represents the current phase of PersistentVolumeClaim.\n\nPossible enum values:\n - `\"Bound\"` used for PersistentVolumeClaims that are bound\n - `\"Lost\"` used for PersistentVolumeClaims that lost their underlying PersistentVolume. The claim was bound to a PersistentVolume and this volume does not exist any longer and all data on it was lost.\n - `\"Pending\"` used for PersistentVolumeClaims that are not yet bound", - Type: []string{"string"}, - Format: "", - Enum: []interface{}{"Bound", "Lost", "Pending"}, - }, - }, - "accessModes": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "accessModes contains the actual access modes the volume backing the PVC has. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#access-modes-1", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - Enum: []interface{}{"ReadOnlyMany", "ReadWriteMany", "ReadWriteOnce", "ReadWriteOncePod"}, - }, - }, - }, - }, - }, - "capacity": { - SchemaProps: spec.SchemaProps{ - Description: "capacity represents the actual resources of the underlying volume.", - Type: []string{"object"}, - AdditionalProperties: &spec.SchemaOrBool{ - Allows: true, - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Ref: ref(resource.Quantity{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "conditions": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-map-keys": []interface{}{ - "type", - }, - "x-kubernetes-list-type": "map", - "x-kubernetes-patch-merge-key": "type", - "x-kubernetes-patch-strategy": "merge", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "conditions is the current Condition of persistent volume claim. If underlying persistent volume is being resized then the Condition will be set to 'Resizing'.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.PersistentVolumeClaimCondition{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "allocatedResources": { - SchemaProps: spec.SchemaProps{ - Description: "allocatedResources tracks the resources allocated to a PVC including its capacity. Key names follow standard Kubernetes label syntax. Valid values are either:\n\t* Un-prefixed keys:\n\t\t- storage - the capacity of the volume.\n\t* Custom resources must use implementation-defined prefixed names such as \"example.com/my-custom-resource\"\nApart from above values - keys that are unprefixed or have kubernetes.io prefix are considered reserved and hence may not be used.\n\nCapacity reported here may be larger than the actual capacity when a volume expansion operation is requested. For storage quota, the larger value from allocatedResources and PVC.spec.resources is used. If allocatedResources is not set, PVC.spec.resources alone is used for quota calculation. If a volume expansion capacity request is lowered, allocatedResources is only lowered if there are no expansion operations in progress and if the actual volume capacity is equal or lower than the requested capacity.\n\nA controller that receives PVC update with previously unknown resourceName should ignore the update for the purpose it was designed. For example - a controller that only is responsible for resizing capacity of the volume, should ignore PVC updates that change other valid resources associated with PVC.", - Type: []string{"object"}, - AdditionalProperties: &spec.SchemaOrBool{ - Allows: true, - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Ref: ref(resource.Quantity{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "allocatedResourceStatuses": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-map-type": "granular", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "allocatedResourceStatuses stores status of resource being resized for the given PVC. Key names follow standard Kubernetes label syntax. Valid values are either:\n\t* Un-prefixed keys:\n\t\t- storage - the capacity of the volume.\n\t* Custom resources must use implementation-defined prefixed names such as \"example.com/my-custom-resource\"\nApart from above values - keys that are unprefixed or have kubernetes.io prefix are considered reserved and hence may not be used.\n\nClaimResourceStatus can be in any of following states:\n\t- ControllerResizeInProgress:\n\t\tState set when resize controller starts resizing the volume in control-plane.\n\t- ControllerResizeFailed:\n\t\tState set when resize has failed in resize controller with a terminal error.\n\t- NodeResizePending:\n\t\tState set when resize controller has finished resizing the volume but further resizing of\n\t\tvolume is needed on the node.\n\t- NodeResizeInProgress:\n\t\tState set when kubelet starts resizing the volume.\n\t- NodeResizeFailed:\n\t\tState set when resizing has failed in kubelet with a terminal error. Transient errors don't set\n\t\tNodeResizeFailed.\nFor example: if expanding a PVC for more capacity - this field can be one of the following states:\n\t- pvc.status.allocatedResourceStatus['storage'] = \"ControllerResizeInProgress\"\n - pvc.status.allocatedResourceStatus['storage'] = \"ControllerResizeFailed\"\n - pvc.status.allocatedResourceStatus['storage'] = \"NodeResizePending\"\n - pvc.status.allocatedResourceStatus['storage'] = \"NodeResizeInProgress\"\n - pvc.status.allocatedResourceStatus['storage'] = \"NodeResizeFailed\"\nWhen this field is not set, it means that no resize operation is in progress for the given PVC.\n\nA controller that receives PVC update with previously unknown resourceName or ClaimResourceStatus should ignore the update for the purpose it was designed. For example - a controller that only is responsible for resizing capacity of the volume, should ignore PVC updates that change other valid resources associated with PVC.", - Type: []string{"object"}, - AdditionalProperties: &spec.SchemaOrBool{ - Allows: true, - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - Enum: []interface{}{"ControllerResizeInProgress", "ControllerResizeInfeasible", "NodeResizeInProgress", "NodeResizeInfeasible", "NodeResizePending"}, - }, - }, - }, - }, - }, - "currentVolumeAttributesClassName": { - SchemaProps: spec.SchemaProps{ - Description: "currentVolumeAttributesClassName is the current name of the VolumeAttributesClass the PVC is using. When unset, there is no VolumeAttributeClass applied to this PersistentVolumeClaim", - Type: []string{"string"}, - Format: "", - }, - }, - "modifyVolumeStatus": { - SchemaProps: spec.SchemaProps{ - Description: "ModifyVolumeStatus represents the status object of ControllerModifyVolume operation. When this is unset, there is no ModifyVolume operation being attempted.", - Ref: ref(v1.ModifyVolumeStatus{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - Dependencies: []string{ - v1.ModifyVolumeStatus{}.OpenAPIModelName(), v1.PersistentVolumeClaimCondition{}.OpenAPIModelName(), resource.Quantity{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_PersistentVolumeClaimTemplate(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "PersistentVolumeClaimTemplate is used to produce PersistentVolumeClaim objects as part of an EphemeralVolumeSource.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "metadata": { - SchemaProps: spec.SchemaProps{ - Description: "May contain labels and annotations that will be copied into the PVC when creating it. No other fields are allowed and will be rejected during validation.", - Default: map[string]interface{}{}, - Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), - }, - }, - "spec": { - SchemaProps: spec.SchemaProps{ - Description: "The specification for the PersistentVolumeClaim. The entire content is copied unchanged into the PVC that gets created from this template. The same fields as in a PersistentVolumeClaim are also valid here.", - Default: map[string]interface{}{}, - Ref: ref(v1.PersistentVolumeClaimSpec{}.OpenAPIModelName()), - }, - }, - }, - Required: []string{"spec"}, - }, - }, - Dependencies: []string{ - v1.PersistentVolumeClaimSpec{}.OpenAPIModelName(), metav1.ObjectMeta{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_PersistentVolumeClaimVolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "PersistentVolumeClaimVolumeSource references the user's PVC in the same namespace. This volume finds the bound PV and mounts that volume for the pod. A PersistentVolumeClaimVolumeSource is, essentially, a wrapper around another type of volume that is owned by someone else (the system).", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "claimName": { - SchemaProps: spec.SchemaProps{ - Description: "claimName is the name of a PersistentVolumeClaim in the same namespace as the pod using this volume. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#persistentvolumeclaims", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "readOnly": { - SchemaProps: spec.SchemaProps{ - Description: "readOnly Will force the ReadOnly setting in VolumeMounts. Default false.", - Type: []string{"boolean"}, - Format: "", - }, - }, - }, - Required: []string{"claimName"}, - }, - }, - } -} - -func schema_k8sio_api_core_v1_PersistentVolumeList(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "PersistentVolumeList is a list of PersistentVolume items.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Type: []string{"string"}, - Format: "", - }, - }, - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", - Type: []string{"string"}, - Format: "", - }, - }, - "metadata": { - SchemaProps: spec.SchemaProps{ - Description: "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Default: map[string]interface{}{}, - Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), - }, - }, - "items": { - SchemaProps: spec.SchemaProps{ - Description: "items is a list of persistent volumes. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.PersistentVolume{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - }, - Required: []string{"items"}, - }, - }, - Dependencies: []string{ - v1.PersistentVolume{}.OpenAPIModelName(), metav1.ListMeta{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_PersistentVolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "PersistentVolumeSource is similar to VolumeSource but meant for the administrator who creates PVs. Exactly one of its members must be set.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "gcePersistentDisk": { - SchemaProps: spec.SchemaProps{ - Description: "gcePersistentDisk represents a GCE Disk resource that is attached to a kubelet's host machine and then exposed to the pod. Provisioned by an admin. Deprecated: GCEPersistentDisk is deprecated. All operations for the in-tree gcePersistentDisk type are redirected to the pd.csi.storage.gke.io CSI driver. More info: https://kubernetes.io/docs/concepts/storage/volumes#gcepersistentdisk", - Ref: ref(v1.GCEPersistentDiskVolumeSource{}.OpenAPIModelName()), - }, - }, - "awsElasticBlockStore": { - SchemaProps: spec.SchemaProps{ - Description: "awsElasticBlockStore represents an AWS Disk resource that is attached to a kubelet's host machine and then exposed to the pod. Deprecated: AWSElasticBlockStore is deprecated. All operations for the in-tree awsElasticBlockStore type are redirected to the ebs.csi.aws.com CSI driver. More info: https://kubernetes.io/docs/concepts/storage/volumes#awselasticblockstore", - Ref: ref(v1.AWSElasticBlockStoreVolumeSource{}.OpenAPIModelName()), - }, - }, - "hostPath": { - SchemaProps: spec.SchemaProps{ - Description: "hostPath represents a directory on the host. Provisioned by a developer or tester. This is useful for single-node development and testing only! On-host storage is not supported in any way and WILL NOT WORK in a multi-node cluster. More info: https://kubernetes.io/docs/concepts/storage/volumes#hostpath", - Ref: ref(v1.HostPathVolumeSource{}.OpenAPIModelName()), - }, - }, - "glusterfs": { - SchemaProps: spec.SchemaProps{ - Description: "glusterfs represents a Glusterfs volume that is attached to a host and exposed to the pod. Provisioned by an admin. Deprecated: Glusterfs is deprecated and the in-tree glusterfs type is no longer supported. More info: https://examples.k8s.io/volumes/glusterfs/README.md", - Ref: ref(v1.GlusterfsPersistentVolumeSource{}.OpenAPIModelName()), - }, - }, - "nfs": { - SchemaProps: spec.SchemaProps{ - Description: "nfs represents an NFS mount on the host. Provisioned by an admin. More info: https://kubernetes.io/docs/concepts/storage/volumes#nfs", - Ref: ref(v1.NFSVolumeSource{}.OpenAPIModelName()), - }, - }, - "rbd": { - SchemaProps: spec.SchemaProps{ - Description: "rbd represents a Rados Block Device mount on the host that shares a pod's lifetime. Deprecated: RBD is deprecated and the in-tree rbd type is no longer supported. More info: https://examples.k8s.io/volumes/rbd/README.md", - Ref: ref(v1.RBDPersistentVolumeSource{}.OpenAPIModelName()), - }, - }, - "iscsi": { - SchemaProps: spec.SchemaProps{ - Description: "iscsi represents an ISCSI Disk resource that is attached to a kubelet's host machine and then exposed to the pod. Provisioned by an admin.", - Ref: ref(v1.ISCSIPersistentVolumeSource{}.OpenAPIModelName()), - }, - }, - "cinder": { - SchemaProps: spec.SchemaProps{ - Description: "cinder represents a cinder volume attached and mounted on kubelets host machine. Deprecated: Cinder is deprecated. All operations for the in-tree cinder type are redirected to the cinder.csi.openstack.org CSI driver. More info: https://examples.k8s.io/mysql-cinder-pd/README.md", - Ref: ref(v1.CinderPersistentVolumeSource{}.OpenAPIModelName()), - }, - }, - "cephfs": { - SchemaProps: spec.SchemaProps{ - Description: "cephFS represents a Ceph FS mount on the host that shares a pod's lifetime. Deprecated: CephFS is deprecated and the in-tree cephfs type is no longer supported.", - Ref: ref(v1.CephFSPersistentVolumeSource{}.OpenAPIModelName()), - }, - }, - "fc": { - SchemaProps: spec.SchemaProps{ - Description: "fc represents a Fibre Channel resource that is attached to a kubelet's host machine and then exposed to the pod.", - Ref: ref(v1.FCVolumeSource{}.OpenAPIModelName()), - }, - }, - "flocker": { - SchemaProps: spec.SchemaProps{ - Description: "flocker represents a Flocker volume attached to a kubelet's host machine and exposed to the pod for its usage. This depends on the Flocker control service being running. Deprecated: Flocker is deprecated and the in-tree flocker type is no longer supported.", - Ref: ref(v1.FlockerVolumeSource{}.OpenAPIModelName()), - }, - }, - "flexVolume": { - SchemaProps: spec.SchemaProps{ - Description: "flexVolume represents a generic volume resource that is provisioned/attached using an exec based plugin. Deprecated: FlexVolume is deprecated. Consider using a CSIDriver instead.", - Ref: ref(v1.FlexPersistentVolumeSource{}.OpenAPIModelName()), - }, - }, - "azureFile": { - SchemaProps: spec.SchemaProps{ - Description: "azureFile represents an Azure File Service mount on the host and bind mount to the pod. Deprecated: AzureFile is deprecated. All operations for the in-tree azureFile type are redirected to the file.csi.azure.com CSI driver.", - Ref: ref(v1.AzureFilePersistentVolumeSource{}.OpenAPIModelName()), - }, - }, - "vsphereVolume": { - SchemaProps: spec.SchemaProps{ - Description: "vsphereVolume represents a vSphere volume attached and mounted on kubelets host machine. Deprecated: VsphereVolume is deprecated. All operations for the in-tree vsphereVolume type are redirected to the csi.vsphere.vmware.com CSI driver.", - Ref: ref(v1.VsphereVirtualDiskVolumeSource{}.OpenAPIModelName()), - }, - }, - "quobyte": { - SchemaProps: spec.SchemaProps{ - Description: "quobyte represents a Quobyte mount on the host that shares a pod's lifetime. Deprecated: Quobyte is deprecated and the in-tree quobyte type is no longer supported.", - Ref: ref(v1.QuobyteVolumeSource{}.OpenAPIModelName()), - }, - }, - "azureDisk": { - SchemaProps: spec.SchemaProps{ - Description: "azureDisk represents an Azure Data Disk mount on the host and bind mount to the pod. Deprecated: AzureDisk is deprecated. All operations for the in-tree azureDisk type are redirected to the disk.csi.azure.com CSI driver.", - Ref: ref(v1.AzureDiskVolumeSource{}.OpenAPIModelName()), - }, - }, - "photonPersistentDisk": { - SchemaProps: spec.SchemaProps{ - Description: "photonPersistentDisk represents a PhotonController persistent disk attached and mounted on kubelets host machine. Deprecated: PhotonPersistentDisk is deprecated and the in-tree photonPersistentDisk type is no longer supported.", - Ref: ref(v1.PhotonPersistentDiskVolumeSource{}.OpenAPIModelName()), - }, - }, - "portworxVolume": { - SchemaProps: spec.SchemaProps{ - Description: "portworxVolume represents a portworx volume attached and mounted on kubelets host machine. Deprecated: PortworxVolume is deprecated. All operations for the in-tree portworxVolume type are redirected to the pxd.portworx.com CSI driver when the CSIMigrationPortworx feature-gate is on.", - Ref: ref(v1.PortworxVolumeSource{}.OpenAPIModelName()), - }, - }, - "scaleIO": { - SchemaProps: spec.SchemaProps{ - Description: "scaleIO represents a ScaleIO persistent volume attached and mounted on Kubernetes nodes. Deprecated: ScaleIO is deprecated and the in-tree scaleIO type is no longer supported.", - Ref: ref(v1.ScaleIOPersistentVolumeSource{}.OpenAPIModelName()), - }, - }, - "local": { - SchemaProps: spec.SchemaProps{ - Description: "local represents directly-attached storage with node affinity", - Ref: ref(v1.LocalVolumeSource{}.OpenAPIModelName()), - }, - }, - "storageos": { - SchemaProps: spec.SchemaProps{ - Description: "storageOS represents a StorageOS volume that is attached to the kubelet's host machine and mounted into the pod. Deprecated: StorageOS is deprecated and the in-tree storageos type is no longer supported. More info: https://examples.k8s.io/volumes/storageos/README.md", - Ref: ref(v1.StorageOSPersistentVolumeSource{}.OpenAPIModelName()), - }, - }, - "csi": { - SchemaProps: spec.SchemaProps{ - Description: "csi represents storage that is handled by an external CSI driver.", - Ref: ref(v1.CSIPersistentVolumeSource{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - Dependencies: []string{ - v1.AWSElasticBlockStoreVolumeSource{}.OpenAPIModelName(), v1.AzureDiskVolumeSource{}.OpenAPIModelName(), v1.AzureFilePersistentVolumeSource{}.OpenAPIModelName(), v1.CSIPersistentVolumeSource{}.OpenAPIModelName(), v1.CephFSPersistentVolumeSource{}.OpenAPIModelName(), v1.CinderPersistentVolumeSource{}.OpenAPIModelName(), v1.FCVolumeSource{}.OpenAPIModelName(), v1.FlexPersistentVolumeSource{}.OpenAPIModelName(), v1.FlockerVolumeSource{}.OpenAPIModelName(), v1.GCEPersistentDiskVolumeSource{}.OpenAPIModelName(), v1.GlusterfsPersistentVolumeSource{}.OpenAPIModelName(), v1.HostPathVolumeSource{}.OpenAPIModelName(), v1.ISCSIPersistentVolumeSource{}.OpenAPIModelName(), v1.LocalVolumeSource{}.OpenAPIModelName(), v1.NFSVolumeSource{}.OpenAPIModelName(), v1.PhotonPersistentDiskVolumeSource{}.OpenAPIModelName(), v1.PortworxVolumeSource{}.OpenAPIModelName(), v1.QuobyteVolumeSource{}.OpenAPIModelName(), v1.RBDPersistentVolumeSource{}.OpenAPIModelName(), v1.ScaleIOPersistentVolumeSource{}.OpenAPIModelName(), v1.StorageOSPersistentVolumeSource{}.OpenAPIModelName(), v1.VsphereVirtualDiskVolumeSource{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_PersistentVolumeSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "PersistentVolumeSpec is the specification of a persistent volume.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "capacity": { - SchemaProps: spec.SchemaProps{ - Description: "capacity is the description of the persistent volume's resources and capacity. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#capacity", - Type: []string{"object"}, - AdditionalProperties: &spec.SchemaOrBool{ - Allows: true, - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Ref: ref(resource.Quantity{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "gcePersistentDisk": { - SchemaProps: spec.SchemaProps{ - Description: "gcePersistentDisk represents a GCE Disk resource that is attached to a kubelet's host machine and then exposed to the pod. Provisioned by an admin. Deprecated: GCEPersistentDisk is deprecated. All operations for the in-tree gcePersistentDisk type are redirected to the pd.csi.storage.gke.io CSI driver. More info: https://kubernetes.io/docs/concepts/storage/volumes#gcepersistentdisk", - Ref: ref(v1.GCEPersistentDiskVolumeSource{}.OpenAPIModelName()), - }, - }, - "awsElasticBlockStore": { - SchemaProps: spec.SchemaProps{ - Description: "awsElasticBlockStore represents an AWS Disk resource that is attached to a kubelet's host machine and then exposed to the pod. Deprecated: AWSElasticBlockStore is deprecated. All operations for the in-tree awsElasticBlockStore type are redirected to the ebs.csi.aws.com CSI driver. More info: https://kubernetes.io/docs/concepts/storage/volumes#awselasticblockstore", - Ref: ref(v1.AWSElasticBlockStoreVolumeSource{}.OpenAPIModelName()), - }, - }, - "hostPath": { - SchemaProps: spec.SchemaProps{ - Description: "hostPath represents a directory on the host. Provisioned by a developer or tester. This is useful for single-node development and testing only! On-host storage is not supported in any way and WILL NOT WORK in a multi-node cluster. More info: https://kubernetes.io/docs/concepts/storage/volumes#hostpath", - Ref: ref(v1.HostPathVolumeSource{}.OpenAPIModelName()), - }, - }, - "glusterfs": { - SchemaProps: spec.SchemaProps{ - Description: "glusterfs represents a Glusterfs volume that is attached to a host and exposed to the pod. Provisioned by an admin. Deprecated: Glusterfs is deprecated and the in-tree glusterfs type is no longer supported. More info: https://examples.k8s.io/volumes/glusterfs/README.md", - Ref: ref(v1.GlusterfsPersistentVolumeSource{}.OpenAPIModelName()), - }, - }, - "nfs": { - SchemaProps: spec.SchemaProps{ - Description: "nfs represents an NFS mount on the host. Provisioned by an admin. More info: https://kubernetes.io/docs/concepts/storage/volumes#nfs", - Ref: ref(v1.NFSVolumeSource{}.OpenAPIModelName()), - }, - }, - "rbd": { - SchemaProps: spec.SchemaProps{ - Description: "rbd represents a Rados Block Device mount on the host that shares a pod's lifetime. Deprecated: RBD is deprecated and the in-tree rbd type is no longer supported. More info: https://examples.k8s.io/volumes/rbd/README.md", - Ref: ref(v1.RBDPersistentVolumeSource{}.OpenAPIModelName()), - }, - }, - "iscsi": { - SchemaProps: spec.SchemaProps{ - Description: "iscsi represents an ISCSI Disk resource that is attached to a kubelet's host machine and then exposed to the pod. Provisioned by an admin.", - Ref: ref(v1.ISCSIPersistentVolumeSource{}.OpenAPIModelName()), - }, - }, - "cinder": { - SchemaProps: spec.SchemaProps{ - Description: "cinder represents a cinder volume attached and mounted on kubelets host machine. Deprecated: Cinder is deprecated. All operations for the in-tree cinder type are redirected to the cinder.csi.openstack.org CSI driver. More info: https://examples.k8s.io/mysql-cinder-pd/README.md", - Ref: ref(v1.CinderPersistentVolumeSource{}.OpenAPIModelName()), - }, - }, - "cephfs": { - SchemaProps: spec.SchemaProps{ - Description: "cephFS represents a Ceph FS mount on the host that shares a pod's lifetime. Deprecated: CephFS is deprecated and the in-tree cephfs type is no longer supported.", - Ref: ref(v1.CephFSPersistentVolumeSource{}.OpenAPIModelName()), - }, - }, - "fc": { - SchemaProps: spec.SchemaProps{ - Description: "fc represents a Fibre Channel resource that is attached to a kubelet's host machine and then exposed to the pod.", - Ref: ref(v1.FCVolumeSource{}.OpenAPIModelName()), - }, - }, - "flocker": { - SchemaProps: spec.SchemaProps{ - Description: "flocker represents a Flocker volume attached to a kubelet's host machine and exposed to the pod for its usage. This depends on the Flocker control service being running. Deprecated: Flocker is deprecated and the in-tree flocker type is no longer supported.", - Ref: ref(v1.FlockerVolumeSource{}.OpenAPIModelName()), - }, - }, - "flexVolume": { - SchemaProps: spec.SchemaProps{ - Description: "flexVolume represents a generic volume resource that is provisioned/attached using an exec based plugin. Deprecated: FlexVolume is deprecated. Consider using a CSIDriver instead.", - Ref: ref(v1.FlexPersistentVolumeSource{}.OpenAPIModelName()), - }, - }, - "azureFile": { - SchemaProps: spec.SchemaProps{ - Description: "azureFile represents an Azure File Service mount on the host and bind mount to the pod. Deprecated: AzureFile is deprecated. All operations for the in-tree azureFile type are redirected to the file.csi.azure.com CSI driver.", - Ref: ref(v1.AzureFilePersistentVolumeSource{}.OpenAPIModelName()), - }, - }, - "vsphereVolume": { - SchemaProps: spec.SchemaProps{ - Description: "vsphereVolume represents a vSphere volume attached and mounted on kubelets host machine. Deprecated: VsphereVolume is deprecated. All operations for the in-tree vsphereVolume type are redirected to the csi.vsphere.vmware.com CSI driver.", - Ref: ref(v1.VsphereVirtualDiskVolumeSource{}.OpenAPIModelName()), - }, - }, - "quobyte": { - SchemaProps: spec.SchemaProps{ - Description: "quobyte represents a Quobyte mount on the host that shares a pod's lifetime. Deprecated: Quobyte is deprecated and the in-tree quobyte type is no longer supported.", - Ref: ref(v1.QuobyteVolumeSource{}.OpenAPIModelName()), - }, - }, - "azureDisk": { - SchemaProps: spec.SchemaProps{ - Description: "azureDisk represents an Azure Data Disk mount on the host and bind mount to the pod. Deprecated: AzureDisk is deprecated. All operations for the in-tree azureDisk type are redirected to the disk.csi.azure.com CSI driver.", - Ref: ref(v1.AzureDiskVolumeSource{}.OpenAPIModelName()), - }, - }, - "photonPersistentDisk": { - SchemaProps: spec.SchemaProps{ - Description: "photonPersistentDisk represents a PhotonController persistent disk attached and mounted on kubelets host machine. Deprecated: PhotonPersistentDisk is deprecated and the in-tree photonPersistentDisk type is no longer supported.", - Ref: ref(v1.PhotonPersistentDiskVolumeSource{}.OpenAPIModelName()), - }, - }, - "portworxVolume": { - SchemaProps: spec.SchemaProps{ - Description: "portworxVolume represents a portworx volume attached and mounted on kubelets host machine. Deprecated: PortworxVolume is deprecated. All operations for the in-tree portworxVolume type are redirected to the pxd.portworx.com CSI driver when the CSIMigrationPortworx feature-gate is on.", - Ref: ref(v1.PortworxVolumeSource{}.OpenAPIModelName()), - }, - }, - "scaleIO": { - SchemaProps: spec.SchemaProps{ - Description: "scaleIO represents a ScaleIO persistent volume attached and mounted on Kubernetes nodes. Deprecated: ScaleIO is deprecated and the in-tree scaleIO type is no longer supported.", - Ref: ref(v1.ScaleIOPersistentVolumeSource{}.OpenAPIModelName()), - }, - }, - "local": { - SchemaProps: spec.SchemaProps{ - Description: "local represents directly-attached storage with node affinity", - Ref: ref(v1.LocalVolumeSource{}.OpenAPIModelName()), - }, - }, - "storageos": { - SchemaProps: spec.SchemaProps{ - Description: "storageOS represents a StorageOS volume that is attached to the kubelet's host machine and mounted into the pod. Deprecated: StorageOS is deprecated and the in-tree storageos type is no longer supported. More info: https://examples.k8s.io/volumes/storageos/README.md", - Ref: ref(v1.StorageOSPersistentVolumeSource{}.OpenAPIModelName()), - }, - }, - "csi": { - SchemaProps: spec.SchemaProps{ - Description: "csi represents storage that is handled by an external CSI driver.", - Ref: ref(v1.CSIPersistentVolumeSource{}.OpenAPIModelName()), - }, - }, - "accessModes": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "accessModes contains all ways the volume can be mounted. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#access-modes", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - Enum: []interface{}{"ReadOnlyMany", "ReadWriteMany", "ReadWriteOnce", "ReadWriteOncePod"}, - }, - }, - }, - }, - }, - "claimRef": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-map-type": "granular", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "claimRef is part of a bi-directional binding between PersistentVolume and PersistentVolumeClaim. Expected to be non-nil when bound. claim.VolumeName is the authoritative bind between PV and PVC. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#binding", - Ref: ref(v1.ObjectReference{}.OpenAPIModelName()), - }, - }, - "persistentVolumeReclaimPolicy": { - SchemaProps: spec.SchemaProps{ - Description: "persistentVolumeReclaimPolicy defines what happens to a persistent volume when released from its claim. Valid options are Retain (default for manually created PersistentVolumes), Delete (default for dynamically provisioned PersistentVolumes), and Recycle (deprecated). Recycle must be supported by the volume plugin underlying this PersistentVolume. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#reclaiming\n\nPossible enum values:\n - `\"Delete\"` means the volume will be deleted from Kubernetes on release from its claim. The volume plugin must support Deletion.\n - `\"Recycle\"` means the volume will be recycled back into the pool of unbound persistent volumes on release from its claim. The volume plugin must support Recycling.\n - `\"Retain\"` means the volume will be left in its current phase (Released) for manual reclamation by the administrator. The default policy is Retain.", - Type: []string{"string"}, - Format: "", - Enum: []interface{}{"Delete", "Recycle", "Retain"}, - }, - }, - "storageClassName": { - SchemaProps: spec.SchemaProps{ - Description: "storageClassName is the name of StorageClass to which this persistent volume belongs. Empty value means that this volume does not belong to any StorageClass.", - Type: []string{"string"}, - Format: "", - }, - }, - "mountOptions": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "mountOptions is the list of mount options, e.g. [\"ro\", \"soft\"]. Not validated - mount will simply fail if one is invalid. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes/#mount-options", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - "volumeMode": { - SchemaProps: spec.SchemaProps{ - Description: "volumeMode defines if a volume is intended to be used with a formatted filesystem or to remain in raw block state. Value of Filesystem is implied when not included in spec.\n\nPossible enum values:\n - `\"Block\"` means the volume will not be formatted with a filesystem and will remain a raw block device.\n - `\"Filesystem\"` means the volume will be or is formatted with a filesystem.", - Type: []string{"string"}, - Format: "", - Enum: []interface{}{"Block", "Filesystem"}, - }, - }, - "nodeAffinity": { - SchemaProps: spec.SchemaProps{ - Description: "nodeAffinity defines constraints that limit what nodes this volume can be accessed from. This field influences the scheduling of pods that use this volume. This field is mutable if MutablePVNodeAffinity feature gate is enabled.", - Ref: ref(v1.VolumeNodeAffinity{}.OpenAPIModelName()), - }, - }, - "volumeAttributesClassName": { - SchemaProps: spec.SchemaProps{ - Description: "Name of VolumeAttributesClass to which this persistent volume belongs. Empty value is not allowed. When this field is not set, it indicates that this volume does not belong to any VolumeAttributesClass. This field is mutable and can be changed by the CSI driver after a volume has been updated successfully to a new class. For an unbound PersistentVolume, the volumeAttributesClassName will be matched with unbound PersistentVolumeClaims during the binding process.", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - Dependencies: []string{ - v1.AWSElasticBlockStoreVolumeSource{}.OpenAPIModelName(), v1.AzureDiskVolumeSource{}.OpenAPIModelName(), v1.AzureFilePersistentVolumeSource{}.OpenAPIModelName(), v1.CSIPersistentVolumeSource{}.OpenAPIModelName(), v1.CephFSPersistentVolumeSource{}.OpenAPIModelName(), v1.CinderPersistentVolumeSource{}.OpenAPIModelName(), v1.FCVolumeSource{}.OpenAPIModelName(), v1.FlexPersistentVolumeSource{}.OpenAPIModelName(), v1.FlockerVolumeSource{}.OpenAPIModelName(), v1.GCEPersistentDiskVolumeSource{}.OpenAPIModelName(), v1.GlusterfsPersistentVolumeSource{}.OpenAPIModelName(), v1.HostPathVolumeSource{}.OpenAPIModelName(), v1.ISCSIPersistentVolumeSource{}.OpenAPIModelName(), v1.LocalVolumeSource{}.OpenAPIModelName(), v1.NFSVolumeSource{}.OpenAPIModelName(), v1.ObjectReference{}.OpenAPIModelName(), v1.PhotonPersistentDiskVolumeSource{}.OpenAPIModelName(), v1.PortworxVolumeSource{}.OpenAPIModelName(), v1.QuobyteVolumeSource{}.OpenAPIModelName(), v1.RBDPersistentVolumeSource{}.OpenAPIModelName(), v1.ScaleIOPersistentVolumeSource{}.OpenAPIModelName(), v1.StorageOSPersistentVolumeSource{}.OpenAPIModelName(), v1.VolumeNodeAffinity{}.OpenAPIModelName(), v1.VsphereVirtualDiskVolumeSource{}.OpenAPIModelName(), resource.Quantity{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_PersistentVolumeStatus(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "PersistentVolumeStatus is the current status of a persistent volume.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "phase": { - SchemaProps: spec.SchemaProps{ - Description: "phase indicates if a volume is available, bound to a claim, or released by a claim. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#phase\n\nPossible enum values:\n - `\"Available\"` used for PersistentVolumes that are not yet bound Available volumes are held by the binder and matched to PersistentVolumeClaims\n - `\"Bound\"` used for PersistentVolumes that are bound\n - `\"Failed\"` used for PersistentVolumes that failed to be correctly recycled or deleted after being released from a claim\n - `\"Pending\"` used for PersistentVolumes that are not available\n - `\"Released\"` used for PersistentVolumes where the bound PersistentVolumeClaim was deleted released volumes must be recycled before becoming available again this phase is used by the persistent volume claim binder to signal to another process to reclaim the resource", - Type: []string{"string"}, - Format: "", - Enum: []interface{}{"Available", "Bound", "Failed", "Pending", "Released"}, - }, - }, - "message": { - SchemaProps: spec.SchemaProps{ - Description: "message is a human-readable message indicating details about why the volume is in this state.", - Type: []string{"string"}, - Format: "", - }, - }, - "reason": { - SchemaProps: spec.SchemaProps{ - Description: "reason is a brief CamelCase string that describes any failure and is meant for machine parsing and tidy display in the CLI.", - Type: []string{"string"}, - Format: "", - }, - }, - "lastPhaseTransitionTime": { - SchemaProps: spec.SchemaProps{ - Description: "lastPhaseTransitionTime is the time the phase transitioned from one to another and automatically resets to current time everytime a volume phase transitions.", - Ref: ref(metav1.Time{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - Dependencies: []string{ - metav1.Time{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_PhotonPersistentDiskVolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "Represents a Photon Controller persistent disk resource.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "pdID": { - SchemaProps: spec.SchemaProps{ - Description: "pdID is the ID that identifies Photon Controller persistent disk", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "fsType": { - SchemaProps: spec.SchemaProps{ - Description: "fsType is the filesystem type to mount. Must be a filesystem type supported by the host operating system. Ex. \"ext4\", \"xfs\", \"ntfs\". Implicitly inferred to be \"ext4\" if unspecified.", - Type: []string{"string"}, - Format: "", - }, - }, - }, - Required: []string{"pdID"}, - }, - }, - } -} - -func schema_k8sio_api_core_v1_Pod(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "Pod is a collection of containers that can run on a host. This resource is created by clients and scheduled onto hosts.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Type: []string{"string"}, - Format: "", - }, - }, - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", - Type: []string{"string"}, - Format: "", - }, - }, - "metadata": { - SchemaProps: spec.SchemaProps{ - Description: "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata", - Default: map[string]interface{}{}, - Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), - }, - }, - "spec": { - SchemaProps: spec.SchemaProps{ - Description: "Specification of the desired behavior of the pod. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status", - Default: map[string]interface{}{}, - Ref: ref(v1.PodSpec{}.OpenAPIModelName()), - }, - }, - "status": { - SchemaProps: spec.SchemaProps{ - Description: "Most recently observed status of the pod. This data may not be up to date. Populated by the system. Read-only. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status", - Default: map[string]interface{}{}, - Ref: ref(v1.PodStatus{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - Dependencies: []string{ - v1.PodSpec{}.OpenAPIModelName(), v1.PodStatus{}.OpenAPIModelName(), metav1.ObjectMeta{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_PodAffinity(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "Pod affinity is a group of inter pod affinity scheduling rules.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "requiredDuringSchedulingIgnoredDuringExecution": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "If the affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system may or may not try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.PodAffinityTerm{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "preferredDuringSchedulingIgnoredDuringExecution": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "The scheduler will prefer to schedule pods to nodes that satisfy the affinity expressions specified by this field, but it may choose a node that violates one or more of the expressions. The node that is most preferred is the one with the greatest sum of weights, i.e. for each node that meets all of the scheduling requirements (resource request, requiredDuringScheduling affinity expressions, etc.), compute a sum by iterating through the elements of this field and adding \"weight\" to the sum if the node has pods which matches the corresponding podAffinityTerm; the node(s) with the highest sum are the most preferred.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.WeightedPodAffinityTerm{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - }, - }, - }, - Dependencies: []string{ - v1.PodAffinityTerm{}.OpenAPIModelName(), v1.WeightedPodAffinityTerm{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_PodAffinityTerm(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "Defines a set of pods (namely those matching the labelSelector relative to the given namespace(s)) that this pod should be co-located (affinity) or not co-located (anti-affinity) with, where co-located is defined as running on a node whose value of the label with key matches that of any node on which a pod of the set of pods is running", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "labelSelector": { - SchemaProps: spec.SchemaProps{ - Description: "A label query over a set of resources, in this case pods. If it's null, this PodAffinityTerm matches with no Pods.", - Ref: ref(metav1.LabelSelector{}.OpenAPIModelName()), - }, - }, - "namespaces": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "namespaces specifies a static list of namespace names that the term applies to. The term is applied to the union of the namespaces listed in this field and the ones selected by namespaceSelector. null or empty namespaces list and null namespaceSelector means \"this pod's namespace\".", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - "topologyKey": { - SchemaProps: spec.SchemaProps{ - Description: "This pod should be co-located (affinity) or not co-located (anti-affinity) with the pods matching the labelSelector in the specified namespaces, where co-located is defined as running on a node whose value of the label with key topologyKey matches that of any node on which any of the selected pods is running. Empty topologyKey is not allowed.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "namespaceSelector": { - SchemaProps: spec.SchemaProps{ - Description: "A label query over the set of namespaces that the term applies to. The term is applied to the union of the namespaces selected by this field and the ones listed in the namespaces field. null selector and null or empty namespaces list means \"this pod's namespace\". An empty selector ({}) matches all namespaces.", - Ref: ref(metav1.LabelSelector{}.OpenAPIModelName()), - }, - }, - "matchLabelKeys": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "MatchLabelKeys is a set of pod label keys to select which pods will be taken into consideration. The keys are used to lookup values from the incoming pod labels, those key-value labels are merged with `labelSelector` as `key in (value)` to select the group of existing pods which pods will be taken into consideration for the incoming pod's pod (anti) affinity. Keys that don't exist in the incoming pod labels will be ignored. The default value is empty. The same key is forbidden to exist in both matchLabelKeys and labelSelector. Also, matchLabelKeys cannot be set when labelSelector isn't set.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - "mismatchLabelKeys": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "MismatchLabelKeys is a set of pod label keys to select which pods will be taken into consideration. The keys are used to lookup values from the incoming pod labels, those key-value labels are merged with `labelSelector` as `key notin (value)` to select the group of existing pods which pods will be taken into consideration for the incoming pod's pod (anti) affinity. Keys that don't exist in the incoming pod labels will be ignored. The default value is empty. The same key is forbidden to exist in both mismatchLabelKeys and labelSelector. Also, mismatchLabelKeys cannot be set when labelSelector isn't set.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - }, - Required: []string{"topologyKey"}, - }, - }, - Dependencies: []string{ - metav1.LabelSelector{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_PodAntiAffinity(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "Pod anti affinity is a group of inter pod anti affinity scheduling rules.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "requiredDuringSchedulingIgnoredDuringExecution": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "If the anti-affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the anti-affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system may or may not try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.PodAffinityTerm{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "preferredDuringSchedulingIgnoredDuringExecution": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "The scheduler will prefer to schedule pods to nodes that satisfy the anti-affinity expressions specified by this field, but it may choose a node that violates one or more of the expressions. The node that is most preferred is the one with the greatest sum of weights, i.e. for each node that meets all of the scheduling requirements (resource request, requiredDuringScheduling anti-affinity expressions, etc.), compute a sum by iterating through the elements of this field and subtracting \"weight\" from the sum if the node has pods which matches the corresponding podAffinityTerm; the node(s) with the highest sum are the most preferred.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.WeightedPodAffinityTerm{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - }, - }, - }, - Dependencies: []string{ - v1.PodAffinityTerm{}.OpenAPIModelName(), v1.WeightedPodAffinityTerm{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_PodAttachOptions(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "PodAttachOptions is the query options to a Pod's remote attach call.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Type: []string{"string"}, - Format: "", - }, - }, - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", - Type: []string{"string"}, - Format: "", - }, - }, - "stdin": { - SchemaProps: spec.SchemaProps{ - Description: "Stdin if true, redirects the standard input stream of the pod for this call. Defaults to false.", - Type: []string{"boolean"}, - Format: "", - }, - }, - "stdout": { - SchemaProps: spec.SchemaProps{ - Description: "Stdout if true indicates that stdout is to be redirected for the attach call. Defaults to true.", - Type: []string{"boolean"}, - Format: "", - }, - }, - "stderr": { - SchemaProps: spec.SchemaProps{ - Description: "Stderr if true indicates that stderr is to be redirected for the attach call. Defaults to true.", - Type: []string{"boolean"}, - Format: "", - }, - }, - "tty": { - SchemaProps: spec.SchemaProps{ - Description: "TTY if true indicates that a tty will be allocated for the attach call. This is passed through the container runtime so the tty is allocated on the worker node by the container runtime. Defaults to false.", - Type: []string{"boolean"}, - Format: "", - }, - }, - "container": { - SchemaProps: spec.SchemaProps{ - Description: "The container in which to execute the command. Defaults to only container if there is only one container in the pod.", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - } -} - -func schema_k8sio_api_core_v1_PodCertificateProjection(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "PodCertificateProjection provides a private key and X.509 certificate in the pod filesystem.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "signerName": { - SchemaProps: spec.SchemaProps{ - Description: "Kubelet's generated CSRs will be addressed to this signer.", - Type: []string{"string"}, - Format: "", - }, - }, - "keyType": { - SchemaProps: spec.SchemaProps{ - Description: "The type of keypair Kubelet will generate for the pod.\n\nValid values are \"RSA3072\", \"RSA4096\", \"ECDSAP256\", \"ECDSAP384\", \"ECDSAP521\", and \"ED25519\".", - Type: []string{"string"}, - Format: "", - }, - }, - "maxExpirationSeconds": { - SchemaProps: spec.SchemaProps{ - Description: "maxExpirationSeconds is the maximum lifetime permitted for the certificate.\n\nKubelet copies this value verbatim into the PodCertificateRequests it generates for this projection.\n\nIf omitted, kube-apiserver will set it to 86400(24 hours). kube-apiserver will reject values shorter than 3600 (1 hour). The maximum allowable value is 7862400 (91 days).\n\nThe signer implementation is then free to issue a certificate with any lifetime *shorter* than MaxExpirationSeconds, but no shorter than 3600 seconds (1 hour). This constraint is enforced by kube-apiserver. `kubernetes.io` signers will never issue certificates with a lifetime longer than 24 hours.", - Type: []string{"integer"}, - Format: "int32", - }, - }, - "credentialBundlePath": { - SchemaProps: spec.SchemaProps{ - Description: "Write the credential bundle at this path in the projected volume.\n\nThe credential bundle is a single file that contains multiple PEM blocks. The first PEM block is a PRIVATE KEY block, containing a PKCS#8 private key.\n\nThe remaining blocks are CERTIFICATE blocks, containing the issued certificate chain from the signer (leaf and any intermediates).\n\nUsing credentialBundlePath lets your Pod's application code make a single atomic read that retrieves a consistent key and certificate chain. If you project them to separate files, your application code will need to additionally check that the leaf certificate was issued to the key.", - Type: []string{"string"}, - Format: "", - }, - }, - "keyPath": { - SchemaProps: spec.SchemaProps{ - Description: "Write the key at this path in the projected volume.\n\nMost applications should use credentialBundlePath. When using keyPath and certificateChainPath, your application needs to check that the key and leaf certificate are consistent, because it is possible to read the files mid-rotation.", - Type: []string{"string"}, - Format: "", - }, - }, - "certificateChainPath": { - SchemaProps: spec.SchemaProps{ - Description: "Write the certificate chain at this path in the projected volume.\n\nMost applications should use credentialBundlePath. When using keyPath and certificateChainPath, your application needs to check that the key and leaf certificate are consistent, because it is possible to read the files mid-rotation.", - Type: []string{"string"}, - Format: "", - }, - }, - "userAnnotations": { - SchemaProps: spec.SchemaProps{ - Description: "userAnnotations allow pod authors to pass additional information to the signer implementation. Kubernetes does not restrict or validate this metadata in any way.\n\nThese values are copied verbatim into the `spec.unverifiedUserAnnotations` field of the PodCertificateRequest objects that Kubelet creates.\n\nEntries are subject to the same validation as object metadata annotations, with the addition that all keys must be domain-prefixed. No restrictions are placed on values, except an overall size limitation on the entire field.\n\nSigners should document the keys and values they support. Signers should deny requests that contain keys they do not recognize.", - Type: []string{"object"}, - AdditionalProperties: &spec.SchemaOrBool{ - Allows: true, - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - }, - Required: []string{"signerName", "keyType"}, - }, - }, - } -} - -func schema_k8sio_api_core_v1_PodCondition(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "PodCondition contains details for the current condition of this pod.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "type": { - SchemaProps: spec.SchemaProps{ - Description: "Type is the type of the condition. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#pod-conditions", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "observedGeneration": { - SchemaProps: spec.SchemaProps{ - Description: "If set, this represents the .metadata.generation that the pod condition was set based upon. The PodObservedGenerationTracking feature gate must be enabled to use this field.", - Type: []string{"integer"}, - Format: "int64", - }, - }, - "status": { - SchemaProps: spec.SchemaProps{ - Description: "Status is the status of the condition. Can be True, False, Unknown. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#pod-conditions", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "lastProbeTime": { - SchemaProps: spec.SchemaProps{ - Description: "Last time we probed the condition.", - Ref: ref(metav1.Time{}.OpenAPIModelName()), - }, - }, - "lastTransitionTime": { - SchemaProps: spec.SchemaProps{ - Description: "Last time the condition transitioned from one status to another.", - Ref: ref(metav1.Time{}.OpenAPIModelName()), - }, - }, - "reason": { - SchemaProps: spec.SchemaProps{ - Description: "Unique, one-word, CamelCase reason for the condition's last transition.", - Type: []string{"string"}, - Format: "", - }, - }, - "message": { - SchemaProps: spec.SchemaProps{ - Description: "Human-readable message indicating details about last transition.", - Type: []string{"string"}, - Format: "", - }, - }, - }, - Required: []string{"type", "status"}, - }, - }, - Dependencies: []string{ - metav1.Time{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_PodDNSConfig(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "PodDNSConfig defines the DNS parameters of a pod in addition to those generated from DNSPolicy.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "nameservers": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "A list of DNS name server IP addresses. This will be appended to the base nameservers generated from DNSPolicy. Duplicated nameservers will be removed.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - "searches": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "A list of DNS search domains for host-name lookup. This will be appended to the base search paths generated from DNSPolicy. Duplicated search paths will be removed.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - "options": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "A list of DNS resolver options. This will be merged with the base options generated from DNSPolicy. Duplicated entries will be removed. Resolution options given in Options will override those that appear in the base DNSPolicy.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.PodDNSConfigOption{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - }, - }, - }, - Dependencies: []string{ - v1.PodDNSConfigOption{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_PodDNSConfigOption(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "PodDNSConfigOption defines DNS resolver options of a pod.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "name": { - SchemaProps: spec.SchemaProps{ - Description: "Name is this DNS resolver option's name. Required.", - Type: []string{"string"}, - Format: "", - }, - }, - "value": { - SchemaProps: spec.SchemaProps{ - Description: "Value is this DNS resolver option's value.", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - } -} - -func schema_k8sio_api_core_v1_PodExecOptions(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "PodExecOptions is the query options to a Pod's remote exec call.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Type: []string{"string"}, - Format: "", - }, - }, - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", - Type: []string{"string"}, - Format: "", - }, - }, - "stdin": { - SchemaProps: spec.SchemaProps{ - Description: "Redirect the standard input stream of the pod for this call. Defaults to false.", - Type: []string{"boolean"}, - Format: "", - }, - }, - "stdout": { - SchemaProps: spec.SchemaProps{ - Description: "Redirect the standard output stream of the pod for this call.", - Type: []string{"boolean"}, - Format: "", - }, - }, - "stderr": { - SchemaProps: spec.SchemaProps{ - Description: "Redirect the standard error stream of the pod for this call.", - Type: []string{"boolean"}, - Format: "", - }, - }, - "tty": { - SchemaProps: spec.SchemaProps{ - Description: "TTY if true indicates that a tty will be allocated for the exec call. Defaults to false.", - Type: []string{"boolean"}, - Format: "", - }, - }, - "container": { - SchemaProps: spec.SchemaProps{ - Description: "Container in which to execute the command. Defaults to only container if there is only one container in the pod.", - Type: []string{"string"}, - Format: "", - }, - }, - "command": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "Command is the remote command to execute. argv array. Not executed within a shell.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - }, - Required: []string{"command"}, - }, - }, - } -} - -func schema_k8sio_api_core_v1_PodExtendedResourceClaimStatus(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "PodExtendedResourceClaimStatus is stored in the PodStatus for the extended resource requests backed by DRA. It stores the generated name for the corresponding special ResourceClaim created by the scheduler.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "requestMappings": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "RequestMappings identifies the mapping of to device request in the generated ResourceClaim.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.ContainerExtendedResourceRequest{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "resourceClaimName": { - SchemaProps: spec.SchemaProps{ - Description: "ResourceClaimName is the name of the ResourceClaim that was generated for the Pod in the namespace of the Pod.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - Required: []string{"requestMappings", "resourceClaimName"}, - }, - }, - Dependencies: []string{ - v1.ContainerExtendedResourceRequest{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_PodIP(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "PodIP represents a single IP address allocated to the pod.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "ip": { - SchemaProps: spec.SchemaProps{ - Description: "IP is the IP address assigned to the pod", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - Required: []string{"ip"}, - }, - }, - } -} - -func schema_k8sio_api_core_v1_PodList(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "PodList is a list of Pods.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Type: []string{"string"}, - Format: "", - }, - }, - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", - Type: []string{"string"}, - Format: "", - }, - }, - "metadata": { - SchemaProps: spec.SchemaProps{ - Description: "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Default: map[string]interface{}{}, - Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), - }, - }, - "items": { - SchemaProps: spec.SchemaProps{ - Description: "List of pods. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.Pod{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - }, - Required: []string{"items"}, - }, - }, - Dependencies: []string{ - v1.Pod{}.OpenAPIModelName(), metav1.ListMeta{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_PodLogOptions(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "PodLogOptions is the query options for a Pod's logs REST call.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Type: []string{"string"}, - Format: "", - }, - }, - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", - Type: []string{"string"}, - Format: "", - }, - }, - "container": { - SchemaProps: spec.SchemaProps{ - Description: "The container for which to stream logs. Defaults to only container if there is one container in the pod.", - Type: []string{"string"}, - Format: "", - }, - }, - "follow": { - SchemaProps: spec.SchemaProps{ - Description: "Follow the log stream of the pod. Defaults to false.", - Type: []string{"boolean"}, - Format: "", - }, - }, - "previous": { - SchemaProps: spec.SchemaProps{ - Description: "Return previous terminated container logs. Defaults to false.", - Type: []string{"boolean"}, - Format: "", - }, - }, - "sinceSeconds": { - SchemaProps: spec.SchemaProps{ - Description: "A relative time in seconds before the current time from which to show logs. If this value precedes the time a pod was started, only logs since the pod start will be returned. If this value is in the future, no logs will be returned. Only one of sinceSeconds or sinceTime may be specified.", - Type: []string{"integer"}, - Format: "int64", - }, - }, - "sinceTime": { - SchemaProps: spec.SchemaProps{ - Description: "An RFC3339 timestamp from which to show logs. If this value precedes the time a pod was started, only logs since the pod start will be returned. If this value is in the future, no logs will be returned. Only one of sinceSeconds or sinceTime may be specified.", - Ref: ref(metav1.Time{}.OpenAPIModelName()), - }, - }, - "timestamps": { - SchemaProps: spec.SchemaProps{ - Description: "If true, add an RFC3339 or RFC3339Nano timestamp at the beginning of every line of log output. Defaults to false.", - Type: []string{"boolean"}, - Format: "", - }, - }, - "tailLines": { - SchemaProps: spec.SchemaProps{ - Description: "If set, the number of lines from the end of the logs to show. If not specified, logs are shown from the creation of the container or sinceSeconds or sinceTime. Note that when \"TailLines\" is specified, \"Stream\" can only be set to nil or \"All\".", - Type: []string{"integer"}, - Format: "int64", - }, - }, - "limitBytes": { - SchemaProps: spec.SchemaProps{ - Description: "If set, the number of bytes to read from the server before terminating the log output. This may not display a complete final line of logging, and may return slightly more or slightly less than the specified limit.", - Type: []string{"integer"}, - Format: "int64", - }, - }, - "insecureSkipTLSVerifyBackend": { - SchemaProps: spec.SchemaProps{ - Description: "insecureSkipTLSVerifyBackend indicates that the apiserver should not confirm the validity of the serving certificate of the backend it is connecting to. This will make the HTTPS connection between the apiserver and the backend insecure. This means the apiserver cannot verify the log data it is receiving came from the real kubelet. If the kubelet is configured to verify the apiserver's TLS credentials, it does not mean the connection to the real kubelet is vulnerable to a man in the middle attack (e.g. an attacker could not intercept the actual log data coming from the real kubelet).", - Type: []string{"boolean"}, - Format: "", - }, - }, - "stream": { - SchemaProps: spec.SchemaProps{ - Description: "Specify which container log stream to return to the client. Acceptable values are \"All\", \"Stdout\" and \"Stderr\". If not specified, \"All\" is used, and both stdout and stderr are returned interleaved. Note that when \"TailLines\" is specified, \"Stream\" can only be set to nil or \"All\".", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - Dependencies: []string{ - metav1.Time{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_PodOS(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "PodOS defines the OS parameters of a pod.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "name": { - SchemaProps: spec.SchemaProps{ - Description: "Name is the name of the operating system. The currently supported values are linux and windows. Additional value may be defined in future and can be one of: https://github.com/opencontainers/runtime-spec/blob/master/config.md#platform-specific-configuration Clients should expect to handle additional values and treat unrecognized values in this field as os: null", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - Required: []string{"name"}, - }, - }, - } -} - -func schema_k8sio_api_core_v1_PodPortForwardOptions(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "PodPortForwardOptions is the query options to a Pod's port forward call when using WebSockets. The `port` query parameter must specify the port or ports (comma separated) to forward over. Port forwarding over SPDY does not use these options. It requires the port to be passed in the `port` header as part of request.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Type: []string{"string"}, - Format: "", - }, - }, - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", - Type: []string{"string"}, - Format: "", - }, - }, - "ports": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "List of ports to forward Required when using WebSockets", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: 0, - Type: []string{"integer"}, - Format: "int32", - }, - }, - }, - }, - }, - }, - }, - }, - } -} - -func schema_k8sio_api_core_v1_PodProxyOptions(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "PodProxyOptions is the query options to a Pod's proxy call.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Type: []string{"string"}, - Format: "", - }, - }, - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", - Type: []string{"string"}, - Format: "", - }, - }, - "path": { - SchemaProps: spec.SchemaProps{ - Description: "Path is the URL path to use for the current proxy request to pod.", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - } -} - -func schema_k8sio_api_core_v1_PodReadinessGate(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "PodReadinessGate contains the reference to a pod condition", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "conditionType": { - SchemaProps: spec.SchemaProps{ - Description: "ConditionType refers to a condition in the pod's condition list with matching type.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - Required: []string{"conditionType"}, - }, - }, - } -} - -func schema_k8sio_api_core_v1_PodResourceClaim(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "PodResourceClaim references exactly one ResourceClaim, either directly or by naming a ResourceClaimTemplate which is then turned into a ResourceClaim for the pod.\n\nIt adds a name to it that uniquely identifies the ResourceClaim inside the Pod. Containers that need access to the ResourceClaim reference it with this name.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "name": { - SchemaProps: spec.SchemaProps{ - Description: "Name uniquely identifies this resource claim inside the pod. This must be a DNS_LABEL.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "resourceClaimName": { - SchemaProps: spec.SchemaProps{ - Description: "ResourceClaimName is the name of a ResourceClaim object in the same namespace as this pod.\n\nExactly one of ResourceClaimName and ResourceClaimTemplateName must be set.", - Type: []string{"string"}, - Format: "", - }, - }, - "resourceClaimTemplateName": { - SchemaProps: spec.SchemaProps{ - Description: "ResourceClaimTemplateName is the name of a ResourceClaimTemplate object in the same namespace as this pod.\n\nThe template will be used to create a new ResourceClaim, which will be bound to this pod. When this pod is deleted, the ResourceClaim will also be deleted. The pod name and resource name, along with a generated component, will be used to form a unique name for the ResourceClaim, which will be recorded in pod.status.resourceClaimStatuses.\n\nThis field is immutable and no changes will be made to the corresponding ResourceClaim by the control plane after creating the ResourceClaim.\n\nExactly one of ResourceClaimName and ResourceClaimTemplateName must be set.", - Type: []string{"string"}, - Format: "", - }, - }, - }, - Required: []string{"name"}, - }, - }, - } -} - -func schema_k8sio_api_core_v1_PodResourceClaimStatus(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "PodResourceClaimStatus is stored in the PodStatus for each PodResourceClaim which references a ResourceClaimTemplate. It stores the generated name for the corresponding ResourceClaim.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "name": { - SchemaProps: spec.SchemaProps{ - Description: "Name uniquely identifies this resource claim inside the pod. This must match the name of an entry in pod.spec.resourceClaims, which implies that the string must be a DNS_LABEL.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "resourceClaimName": { - SchemaProps: spec.SchemaProps{ - Description: "ResourceClaimName is the name of the ResourceClaim that was generated for the Pod in the namespace of the Pod. If this is unset, then generating a ResourceClaim was not necessary. The pod.spec.resourceClaims entry can be ignored in this case.", - Type: []string{"string"}, - Format: "", - }, - }, - }, - Required: []string{"name"}, - }, - }, - } -} - -func schema_k8sio_api_core_v1_PodSchedulingGate(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "PodSchedulingGate is associated to a Pod to guard its scheduling.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "name": { - SchemaProps: spec.SchemaProps{ - Description: "Name of the scheduling gate. Each scheduling gate must have a unique name field.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - Required: []string{"name"}, - }, - }, - } -} - -func schema_k8sio_api_core_v1_PodSecurityContext(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "PodSecurityContext holds pod-level security attributes and common container settings. Some fields are also present in container.securityContext. Field values of container.securityContext take precedence over field values of PodSecurityContext.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "seLinuxOptions": { - SchemaProps: spec.SchemaProps{ - Description: "The SELinux context to be applied to all containers. If unspecified, the container runtime will allocate a random SELinux context for each container. May also be set in SecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence for that container. Note that this field cannot be set when spec.os.name is windows.", - Ref: ref(v1.SELinuxOptions{}.OpenAPIModelName()), - }, - }, - "windowsOptions": { - SchemaProps: spec.SchemaProps{ - Description: "The Windows specific settings applied to all containers. If unspecified, the options within a container's SecurityContext will be used. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence. Note that this field cannot be set when spec.os.name is linux.", - Ref: ref(v1.WindowsSecurityContextOptions{}.OpenAPIModelName()), - }, - }, - "runAsUser": { - SchemaProps: spec.SchemaProps{ - Description: "The UID to run the entrypoint of the container process. Defaults to user specified in image metadata if unspecified. May also be set in SecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence for that container. Note that this field cannot be set when spec.os.name is windows.", - Type: []string{"integer"}, - Format: "int64", - }, - }, - "runAsGroup": { - SchemaProps: spec.SchemaProps{ - Description: "The GID to run the entrypoint of the container process. Uses runtime default if unset. May also be set in SecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence for that container. Note that this field cannot be set when spec.os.name is windows.", - Type: []string{"integer"}, - Format: "int64", - }, - }, - "runAsNonRoot": { - SchemaProps: spec.SchemaProps{ - Description: "Indicates that the container must run as a non-root user. If true, the Kubelet will validate the image at runtime to ensure that it does not run as UID 0 (root) and fail to start the container if it does. If unset or false, no such validation will be performed. May also be set in SecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence.", - Type: []string{"boolean"}, - Format: "", - }, - }, - "supplementalGroups": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "A list of groups applied to the first process run in each container, in addition to the container's primary GID and fsGroup (if specified). If the SupplementalGroupsPolicy feature is enabled, the supplementalGroupsPolicy field determines whether these are in addition to or instead of any group memberships defined in the container image. If unspecified, no additional groups are added, though group memberships defined in the container image may still be used, depending on the supplementalGroupsPolicy field. Note that this field cannot be set when spec.os.name is windows.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: 0, - Type: []string{"integer"}, - Format: "int64", - }, - }, - }, - }, - }, - "supplementalGroupsPolicy": { - SchemaProps: spec.SchemaProps{ - Description: "Defines how supplemental groups of the first container processes are calculated. Valid values are \"Merge\" and \"Strict\". If not specified, \"Merge\" is used. (Alpha) Using the field requires the SupplementalGroupsPolicy feature gate to be enabled and the container runtime must implement support for this feature. Note that this field cannot be set when spec.os.name is windows.\n\nPossible enum values:\n - `\"Merge\"` means that the container's provided SupplementalGroups and FsGroup (specified in SecurityContext) will be merged with the primary user's groups as defined in the container image (in /etc/group).\n - `\"Strict\"` means that the container's provided SupplementalGroups and FsGroup (specified in SecurityContext) will be used instead of any groups defined in the container image.", - Type: []string{"string"}, - Format: "", - Enum: []interface{}{"Merge", "Strict"}, - }, - }, - "fsGroup": { - SchemaProps: spec.SchemaProps{ - Description: "A special supplemental group that applies to all containers in a pod. Some volume types allow the Kubelet to change the ownership of that volume to be owned by the pod:\n\n1. The owning GID will be the FSGroup 2. The setgid bit is set (new files created in the volume will be owned by FSGroup) 3. The permission bits are OR'd with rw-rw----\n\nIf unset, the Kubelet will not modify the ownership and permissions of any volume. Note that this field cannot be set when spec.os.name is windows.", - Type: []string{"integer"}, - Format: "int64", - }, - }, - "sysctls": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "Sysctls hold a list of namespaced sysctls used for the pod. Pods with unsupported sysctls (by the container runtime) might fail to launch. Note that this field cannot be set when spec.os.name is windows.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.Sysctl{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "fsGroupChangePolicy": { - SchemaProps: spec.SchemaProps{ - Description: "fsGroupChangePolicy defines behavior of changing ownership and permission of the volume before being exposed inside Pod. This field will only apply to volume types which support fsGroup based ownership(and permissions). It will have no effect on ephemeral volume types such as: secret, configmaps and emptydir. Valid values are \"OnRootMismatch\" and \"Always\". If not specified, \"Always\" is used. Note that this field cannot be set when spec.os.name is windows.\n\nPossible enum values:\n - `\"Always\"` indicates that volume's ownership and permissions should always be changed whenever volume is mounted inside a Pod. This the default behavior.\n - `\"OnRootMismatch\"` indicates that volume's ownership and permissions will be changed only when permission and ownership of root directory does not match with expected permissions on the volume. This can help shorten the time it takes to change ownership and permissions of a volume.", - Type: []string{"string"}, - Format: "", - Enum: []interface{}{"Always", "OnRootMismatch"}, - }, - }, - "seccompProfile": { - SchemaProps: spec.SchemaProps{ - Description: "The seccomp options to use by the containers in this pod. Note that this field cannot be set when spec.os.name is windows.", - Ref: ref(v1.SeccompProfile{}.OpenAPIModelName()), - }, - }, - "appArmorProfile": { - SchemaProps: spec.SchemaProps{ - Description: "appArmorProfile is the AppArmor options to use by the containers in this pod. Note that this field cannot be set when spec.os.name is windows.", - Ref: ref(v1.AppArmorProfile{}.OpenAPIModelName()), - }, - }, - "seLinuxChangePolicy": { - SchemaProps: spec.SchemaProps{ - Description: "seLinuxChangePolicy defines how the container's SELinux label is applied to all volumes used by the Pod. It has no effect on nodes that do not support SELinux or to volumes does not support SELinux. Valid values are \"MountOption\" and \"Recursive\".\n\n\"Recursive\" means relabeling of all files on all Pod volumes by the container runtime. This may be slow for large volumes, but allows mixing privileged and unprivileged Pods sharing the same volume on the same node.\n\n\"MountOption\" mounts all eligible Pod volumes with `-o context` mount option. This requires all Pods that share the same volume to use the same SELinux label. It is not possible to share the same volume among privileged and unprivileged Pods. Eligible volumes are in-tree FibreChannel and iSCSI volumes, and all CSI volumes whose CSI driver announces SELinux support by setting spec.seLinuxMount: true in their CSIDriver instance. Other volumes are always re-labelled recursively. \"MountOption\" value is allowed only when SELinuxMount feature gate is enabled.\n\nIf not specified and SELinuxMount feature gate is enabled, \"MountOption\" is used. If not specified and SELinuxMount feature gate is disabled, \"MountOption\" is used for ReadWriteOncePod volumes and \"Recursive\" for all other volumes.\n\nThis field affects only Pods that have SELinux label set, either in PodSecurityContext or in SecurityContext of all containers.\n\nAll Pods that use the same volume should use the same seLinuxChangePolicy, otherwise some pods can get stuck in ContainerCreating state. Note that this field cannot be set when spec.os.name is windows.", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - Dependencies: []string{ - v1.AppArmorProfile{}.OpenAPIModelName(), v1.SELinuxOptions{}.OpenAPIModelName(), v1.SeccompProfile{}.OpenAPIModelName(), v1.Sysctl{}.OpenAPIModelName(), v1.WindowsSecurityContextOptions{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_PodSignature(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "Describes the class of pods that should avoid this node. Exactly one field should be set.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "podController": { - SchemaProps: spec.SchemaProps{ - Description: "Reference to controller whose pods should avoid this node.", - Ref: ref(metav1.OwnerReference{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - Dependencies: []string{ - metav1.OwnerReference{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_PodSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "PodSpec is a description of a pod.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "volumes": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-map-keys": []interface{}{ - "name", - }, - "x-kubernetes-list-type": "map", - "x-kubernetes-patch-merge-key": "name", - "x-kubernetes-patch-strategy": "merge,retainKeys", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "List of volumes that can be mounted by containers belonging to the pod. More info: https://kubernetes.io/docs/concepts/storage/volumes", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.Volume{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "initContainers": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-map-keys": []interface{}{ - "name", - }, - "x-kubernetes-list-type": "map", - "x-kubernetes-patch-merge-key": "name", - "x-kubernetes-patch-strategy": "merge", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "List of initialization containers belonging to the pod. Init containers are executed in order prior to containers being started. If any init container fails, the pod is considered to have failed and is handled according to its restartPolicy. The name for an init container or normal container must be unique among all containers. Init containers may not have Lifecycle actions, Readiness probes, Liveness probes, or Startup probes. The resourceRequirements of an init container are taken into account during scheduling by finding the highest request/limit for each resource type, and then using the max of that value or the sum of the normal containers. Limits are applied to init containers in a similar fashion. Init containers cannot currently be added or removed. Cannot be updated. More info: https://kubernetes.io/docs/concepts/workloads/pods/init-containers/", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.Container{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "containers": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-map-keys": []interface{}{ - "name", - }, - "x-kubernetes-list-type": "map", - "x-kubernetes-patch-merge-key": "name", - "x-kubernetes-patch-strategy": "merge", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "List of containers belonging to the pod. Containers cannot currently be added or removed. There must be at least one container in a Pod. Cannot be updated.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.Container{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "ephemeralContainers": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-map-keys": []interface{}{ - "name", - }, - "x-kubernetes-list-type": "map", - "x-kubernetes-patch-merge-key": "name", - "x-kubernetes-patch-strategy": "merge", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "List of ephemeral containers run in this pod. Ephemeral containers may be run in an existing pod to perform user-initiated actions such as debugging. This list cannot be specified when creating a pod, and it cannot be modified by updating the pod spec. In order to add an ephemeral container to an existing pod, use the pod's ephemeralcontainers subresource.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.EphemeralContainer{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "restartPolicy": { - SchemaProps: spec.SchemaProps{ - Description: "Restart policy for all containers within the pod. One of Always, OnFailure, Never. In some contexts, only a subset of those values may be permitted. Default to Always. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle/#restart-policy\n\nPossible enum values:\n - `\"Always\"`\n - `\"Never\"`\n - `\"OnFailure\"`", - Type: []string{"string"}, - Format: "", - Enum: []interface{}{"Always", "Never", "OnFailure"}, - }, - }, - "terminationGracePeriodSeconds": { - SchemaProps: spec.SchemaProps{ - Description: "Optional duration in seconds the pod needs to terminate gracefully. May be decreased in delete request. Value must be non-negative integer. The value zero indicates stop immediately via the kill signal (no opportunity to shut down). If this value is nil, the default grace period will be used instead. The grace period is the duration in seconds after the processes running in the pod are sent a termination signal and the time when the processes are forcibly halted with a kill signal. Set this value longer than the expected cleanup time for your process. Defaults to 30 seconds.", - Type: []string{"integer"}, - Format: "int64", - }, - }, - "activeDeadlineSeconds": { - SchemaProps: spec.SchemaProps{ - Description: "Optional duration in seconds the pod may be active on the node relative to StartTime before the system will actively try to mark it failed and kill associated containers. Value must be a positive integer.", - Type: []string{"integer"}, - Format: "int64", - }, - }, - "dnsPolicy": { - SchemaProps: spec.SchemaProps{ - Description: "Set DNS policy for the pod. Defaults to \"ClusterFirst\". Valid values are 'ClusterFirstWithHostNet', 'ClusterFirst', 'Default' or 'None'. DNS parameters given in DNSConfig will be merged with the policy selected with DNSPolicy. To have DNS options set along with hostNetwork, you have to specify DNS policy explicitly to 'ClusterFirstWithHostNet'.\n\nPossible enum values:\n - `\"ClusterFirst\"` indicates that the pod should use cluster DNS first unless hostNetwork is true, if it is available, then fall back on the default (as determined by kubelet) DNS settings.\n - `\"ClusterFirstWithHostNet\"` indicates that the pod should use cluster DNS first, if it is available, then fall back on the default (as determined by kubelet) DNS settings.\n - `\"Default\"` indicates that the pod should use the default (as determined by kubelet) DNS settings.\n - `\"None\"` indicates that the pod should use empty DNS settings. DNS parameters such as nameservers and search paths should be defined via DNSConfig.", - Type: []string{"string"}, - Format: "", - Enum: []interface{}{"ClusterFirst", "ClusterFirstWithHostNet", "Default", "None"}, - }, - }, - "nodeSelector": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-map-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "NodeSelector is a selector which must be true for the pod to fit on a node. Selector which must match a node's labels for the pod to be scheduled on that node. More info: https://kubernetes.io/docs/concepts/configuration/assign-pod-node/", - Type: []string{"object"}, - AdditionalProperties: &spec.SchemaOrBool{ - Allows: true, - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - "serviceAccountName": { - SchemaProps: spec.SchemaProps{ - Description: "ServiceAccountName is the name of the ServiceAccount to use to run this pod. More info: https://kubernetes.io/docs/tasks/configure-pod-container/configure-service-account/", - Type: []string{"string"}, - Format: "", - }, - }, - "serviceAccount": { - SchemaProps: spec.SchemaProps{ - Description: "DeprecatedServiceAccount is a deprecated alias for ServiceAccountName. Deprecated: Use serviceAccountName instead.", - Type: []string{"string"}, - Format: "", - }, - }, - "automountServiceAccountToken": { - SchemaProps: spec.SchemaProps{ - Description: "AutomountServiceAccountToken indicates whether a service account token should be automatically mounted.", - Type: []string{"boolean"}, - Format: "", - }, - }, - "nodeName": { - SchemaProps: spec.SchemaProps{ - Description: "NodeName indicates in which node this pod is scheduled. If empty, this pod is a candidate for scheduling by the scheduler defined in schedulerName. Once this field is set, the kubelet for this node becomes responsible for the lifecycle of this pod. This field should not be used to express a desire for the pod to be scheduled on a specific node. https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/#nodename", - Type: []string{"string"}, - Format: "", - }, - }, - "hostNetwork": { - SchemaProps: spec.SchemaProps{ - Description: "Host networking requested for this pod. Use the host's network namespace. When using HostNetwork you should specify ports so the scheduler is aware. When `hostNetwork` is true, specified `hostPort` fields in port definitions must match `containerPort`, and unspecified `hostPort` fields in port definitions are defaulted to match `containerPort`. Default to false.", - Type: []string{"boolean"}, - Format: "", - }, - }, - "hostPID": { - SchemaProps: spec.SchemaProps{ - Description: "Use the host's pid namespace. Optional: Default to false.", - Type: []string{"boolean"}, - Format: "", - }, - }, - "hostIPC": { - SchemaProps: spec.SchemaProps{ - Description: "Use the host's ipc namespace. Optional: Default to false.", - Type: []string{"boolean"}, - Format: "", - }, - }, - "shareProcessNamespace": { - SchemaProps: spec.SchemaProps{ - Description: "Share a single process namespace between all of the containers in a pod. When this is set containers will be able to view and signal processes from other containers in the same pod, and the first process in each container will not be assigned PID 1. HostPID and ShareProcessNamespace cannot both be set. Optional: Default to false.", - Type: []string{"boolean"}, - Format: "", - }, - }, - "securityContext": { - SchemaProps: spec.SchemaProps{ - Description: "SecurityContext holds pod-level security attributes and common container settings. Optional: Defaults to empty. See type description for default values of each field.", - Ref: ref(v1.PodSecurityContext{}.OpenAPIModelName()), - }, - }, - "imagePullSecrets": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-map-keys": []interface{}{ - "name", - }, - "x-kubernetes-list-type": "map", - "x-kubernetes-patch-merge-key": "name", - "x-kubernetes-patch-strategy": "merge", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "ImagePullSecrets is an optional list of references to secrets in the same namespace to use for pulling any of the images used by this PodSpec. If specified, these secrets will be passed to individual puller implementations for them to use. More info: https://kubernetes.io/docs/concepts/containers/images#specifying-imagepullsecrets-on-a-pod", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.LocalObjectReference{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "hostname": { - SchemaProps: spec.SchemaProps{ - Description: "Specifies the hostname of the Pod If not specified, the pod's hostname will be set to a system-defined value.", - Type: []string{"string"}, - Format: "", - }, - }, - "subdomain": { - SchemaProps: spec.SchemaProps{ - Description: "If specified, the fully qualified Pod hostname will be \"...svc.\". If not specified, the pod will not have a domainname at all.", - Type: []string{"string"}, - Format: "", - }, - }, - "affinity": { - SchemaProps: spec.SchemaProps{ - Description: "If specified, the pod's scheduling constraints", - Ref: ref(v1.Affinity{}.OpenAPIModelName()), - }, - }, - "schedulerName": { - SchemaProps: spec.SchemaProps{ - Description: "If specified, the pod will be dispatched by specified scheduler. If not specified, the pod will be dispatched by default scheduler.", - Type: []string{"string"}, - Format: "", - }, - }, - "tolerations": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "If specified, the pod's tolerations.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.Toleration{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "hostAliases": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-map-keys": []interface{}{ - "ip", - }, - "x-kubernetes-list-type": "map", - "x-kubernetes-patch-merge-key": "ip", - "x-kubernetes-patch-strategy": "merge", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "HostAliases is an optional list of hosts and IPs that will be injected into the pod's hosts file if specified.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.HostAlias{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "priorityClassName": { - SchemaProps: spec.SchemaProps{ - Description: "If specified, indicates the pod's priority. \"system-node-critical\" and \"system-cluster-critical\" are two special keywords which indicate the highest priorities with the former being the highest priority. Any other name must be defined by creating a PriorityClass object with that name. If not specified, the pod priority will be default or zero if there is no default.", - Type: []string{"string"}, - Format: "", - }, - }, - "priority": { - SchemaProps: spec.SchemaProps{ - Description: "The priority value. Various system components use this field to find the priority of the pod. When Priority Admission Controller is enabled, it prevents users from setting this field. The admission controller populates this field from PriorityClassName. The higher the value, the higher the priority.", - Type: []string{"integer"}, - Format: "int32", - }, - }, - "dnsConfig": { - SchemaProps: spec.SchemaProps{ - Description: "Specifies the DNS parameters of a pod. Parameters specified here will be merged to the generated DNS configuration based on DNSPolicy.", - Ref: ref(v1.PodDNSConfig{}.OpenAPIModelName()), - }, - }, - "readinessGates": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "If specified, all readiness gates will be evaluated for pod readiness. A pod is ready when all its containers are ready AND all conditions specified in the readiness gates have status equal to \"True\" More info: https://git.k8s.io/enhancements/keps/sig-network/580-pod-readiness-gates", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.PodReadinessGate{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "runtimeClassName": { - SchemaProps: spec.SchemaProps{ - Description: "RuntimeClassName refers to a RuntimeClass object in the node.k8s.io group, which should be used to run this pod. If no RuntimeClass resource matches the named class, the pod will not be run. If unset or empty, the \"legacy\" RuntimeClass will be used, which is an implicit class with an empty definition that uses the default runtime handler. More info: https://git.k8s.io/enhancements/keps/sig-node/585-runtime-class", - Type: []string{"string"}, - Format: "", - }, - }, - "enableServiceLinks": { - SchemaProps: spec.SchemaProps{ - Description: "EnableServiceLinks indicates whether information about services should be injected into pod's environment variables, matching the syntax of Docker links. Optional: Defaults to true.", - Type: []string{"boolean"}, - Format: "", - }, - }, - "preemptionPolicy": { - SchemaProps: spec.SchemaProps{ - Description: "PreemptionPolicy is the Policy for preempting pods with lower priority. One of Never, PreemptLowerPriority. Defaults to PreemptLowerPriority if unset.\n\nPossible enum values:\n - `\"Never\"` means that pod never preempts other pods with lower priority.\n - `\"PreemptLowerPriority\"` means that pod can preempt other pods with lower priority.", - Type: []string{"string"}, - Format: "", - Enum: []interface{}{"Never", "PreemptLowerPriority"}, - }, - }, - "overhead": { - SchemaProps: spec.SchemaProps{ - Description: "Overhead represents the resource overhead associated with running a pod for a given RuntimeClass. This field will be autopopulated at admission time by the RuntimeClass admission controller. If the RuntimeClass admission controller is enabled, overhead must not be set in Pod create requests. The RuntimeClass admission controller will reject Pod create requests which have the overhead already set. If RuntimeClass is configured and selected in the PodSpec, Overhead will be set to the value defined in the corresponding RuntimeClass, otherwise it will remain unset and treated as zero. More info: https://git.k8s.io/enhancements/keps/sig-node/688-pod-overhead/README.md", - Type: []string{"object"}, - AdditionalProperties: &spec.SchemaOrBool{ - Allows: true, - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Ref: ref(resource.Quantity{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "topologySpreadConstraints": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-map-keys": []interface{}{ - "topologyKey", - "whenUnsatisfiable", - }, - "x-kubernetes-list-type": "map", - "x-kubernetes-patch-merge-key": "topologyKey", - "x-kubernetes-patch-strategy": "merge", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "TopologySpreadConstraints describes how a group of pods ought to spread across topology domains. Scheduler will schedule pods in a way which abides by the constraints. All topologySpreadConstraints are ANDed.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.TopologySpreadConstraint{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "setHostnameAsFQDN": { - SchemaProps: spec.SchemaProps{ - Description: "If true the pod's hostname will be configured as the pod's FQDN, rather than the leaf name (the default). In Linux containers, this means setting the FQDN in the hostname field of the kernel (the nodename field of struct utsname). In Windows containers, this means setting the registry value of hostname for the registry key HKEY_LOCAL_MACHINE\\\\SYSTEM\\\\CurrentControlSet\\\\Services\\\\Tcpip\\\\Parameters to FQDN. If a pod does not have FQDN, this has no effect. Default to false.", - Type: []string{"boolean"}, - Format: "", - }, - }, - "os": { - SchemaProps: spec.SchemaProps{ - Description: "Specifies the OS of the containers in the pod. Some pod and container fields are restricted if this is set.\n\nIf the OS field is set to linux, the following fields must be unset: -securityContext.windowsOptions\n\nIf the OS field is set to windows, following fields must be unset: - spec.hostPID - spec.hostIPC - spec.hostUsers - spec.resources - spec.securityContext.appArmorProfile - spec.securityContext.seLinuxOptions - spec.securityContext.seccompProfile - spec.securityContext.fsGroup - spec.securityContext.fsGroupChangePolicy - spec.securityContext.sysctls - spec.shareProcessNamespace - spec.securityContext.runAsUser - spec.securityContext.runAsGroup - spec.securityContext.supplementalGroups - spec.securityContext.supplementalGroupsPolicy - spec.containers[*].securityContext.appArmorProfile - spec.containers[*].securityContext.seLinuxOptions - spec.containers[*].securityContext.seccompProfile - spec.containers[*].securityContext.capabilities - spec.containers[*].securityContext.readOnlyRootFilesystem - spec.containers[*].securityContext.privileged - spec.containers[*].securityContext.allowPrivilegeEscalation - spec.containers[*].securityContext.procMount - spec.containers[*].securityContext.runAsUser - spec.containers[*].securityContext.runAsGroup", - Ref: ref(v1.PodOS{}.OpenAPIModelName()), - }, - }, - "hostUsers": { - SchemaProps: spec.SchemaProps{ - Description: "Use the host's user namespace. Optional: Default to true. If set to true or not present, the pod will be run in the host user namespace, useful for when the pod needs a feature only available to the host user namespace, such as loading a kernel module with CAP_SYS_MODULE. When set to false, a new userns is created for the pod. Setting false is useful for mitigating container breakout vulnerabilities even allowing users to run their containers as root without actually having root privileges on the host. This field is alpha-level and is only honored by servers that enable the UserNamespacesSupport feature.", - Type: []string{"boolean"}, - Format: "", - }, - }, - "schedulingGates": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-map-keys": []interface{}{ - "name", - }, - "x-kubernetes-list-type": "map", - "x-kubernetes-patch-merge-key": "name", - "x-kubernetes-patch-strategy": "merge", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "SchedulingGates is an opaque list of values that if specified will block scheduling the pod. If schedulingGates is not empty, the pod will stay in the SchedulingGated state and the scheduler will not attempt to schedule the pod.\n\nSchedulingGates can only be set at pod creation time, and be removed only afterwards.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.PodSchedulingGate{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "resourceClaims": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-map-keys": []interface{}{ - "name", - }, - "x-kubernetes-list-type": "map", - "x-kubernetes-patch-merge-key": "name", - "x-kubernetes-patch-strategy": "merge,retainKeys", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "ResourceClaims defines which ResourceClaims must be allocated and reserved before the Pod is allowed to start. The resources will be made available to those containers which consume them by name.\n\nThis is a stable field but requires that the DynamicResourceAllocation feature gate is enabled.\n\nThis field is immutable.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.PodResourceClaim{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "resources": { - SchemaProps: spec.SchemaProps{ - Description: "Resources is the total amount of CPU and Memory resources required by all containers in the pod. It supports specifying Requests and Limits for \"cpu\", \"memory\" and \"hugepages-\" resource names only. ResourceClaims are not supported.\n\nThis field enables fine-grained control over resource allocation for the entire pod, allowing resource sharing among containers in a pod.\n\nThis is an alpha field and requires enabling the PodLevelResources feature gate.", - Ref: ref(v1.ResourceRequirements{}.OpenAPIModelName()), - }, - }, - "hostnameOverride": { - SchemaProps: spec.SchemaProps{ - Description: "HostnameOverride specifies an explicit override for the pod's hostname as perceived by the pod. This field only specifies the pod's hostname and does not affect its DNS records. When this field is set to a non-empty string: - It takes precedence over the values set in `hostname` and `subdomain`. - The Pod's hostname will be set to this value. - `setHostnameAsFQDN` must be nil or set to false. - `hostNetwork` must be set to false.\n\nThis field must be a valid DNS subdomain as defined in RFC 1123 and contain at most 64 characters. Requires the HostnameOverride feature gate to be enabled.", - Type: []string{"string"}, - Format: "", - }, - }, - "workloadRef": { - SchemaProps: spec.SchemaProps{ - Description: "WorkloadRef provides a reference to the Workload object that this Pod belongs to. This field is used by the scheduler to identify the PodGroup and apply the correct group scheduling policies. The Workload object referenced by this field may not exist at the time the Pod is created. This field is immutable, but a Workload object with the same name may be recreated with different policies. Doing this during pod scheduling may result in the placement not conforming to the expected policies.", - Ref: ref(v1.WorkloadReference{}.OpenAPIModelName()), - }, - }, - }, - Required: []string{"containers"}, - }, - }, - Dependencies: []string{ - v1.Affinity{}.OpenAPIModelName(), v1.Container{}.OpenAPIModelName(), v1.EphemeralContainer{}.OpenAPIModelName(), v1.HostAlias{}.OpenAPIModelName(), v1.LocalObjectReference{}.OpenAPIModelName(), v1.PodDNSConfig{}.OpenAPIModelName(), v1.PodOS{}.OpenAPIModelName(), v1.PodReadinessGate{}.OpenAPIModelName(), v1.PodResourceClaim{}.OpenAPIModelName(), v1.PodSchedulingGate{}.OpenAPIModelName(), v1.PodSecurityContext{}.OpenAPIModelName(), v1.ResourceRequirements{}.OpenAPIModelName(), v1.Toleration{}.OpenAPIModelName(), v1.TopologySpreadConstraint{}.OpenAPIModelName(), v1.Volume{}.OpenAPIModelName(), v1.WorkloadReference{}.OpenAPIModelName(), resource.Quantity{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_PodStatus(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "PodStatus represents information about the status of a pod. Status may trail the actual state of a system, especially if the node that hosts the pod cannot contact the control plane.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "observedGeneration": { - SchemaProps: spec.SchemaProps{ - Description: "If set, this represents the .metadata.generation that the pod status was set based upon. The PodObservedGenerationTracking feature gate must be enabled to use this field.", - Type: []string{"integer"}, - Format: "int64", - }, - }, - "phase": { - SchemaProps: spec.SchemaProps{ - Description: "The phase of a Pod is a simple, high-level summary of where the Pod is in its lifecycle. The conditions array, the reason and message fields, and the individual container status arrays contain more detail about the pod's status. There are five possible phase values:\n\nPending: The pod has been accepted by the Kubernetes system, but one or more of the container images has not been created. This includes time before being scheduled as well as time spent downloading images over the network, which could take a while. Running: The pod has been bound to a node, and all of the containers have been created. At least one container is still running, or is in the process of starting or restarting. Succeeded: All containers in the pod have terminated in success, and will not be restarted. Failed: All containers in the pod have terminated, and at least one container has terminated in failure. The container either exited with non-zero status or was terminated by the system. Unknown: For some reason the state of the pod could not be obtained, typically due to an error in communicating with the host of the pod.\n\nMore info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#pod-phase\n\nPossible enum values:\n - `\"Failed\"` means that all containers in the pod have terminated, and at least one container has terminated in a failure (exited with a non-zero exit code or was stopped by the system).\n - `\"Pending\"` means the pod has been accepted by the system, but one or more of the containers has not been started. This includes time before being bound to a node, as well as time spent pulling images onto the host.\n - `\"Running\"` means the pod has been bound to a node and all of the containers have been started. At least one container is still running or is in the process of being restarted.\n - `\"Succeeded\"` means that all containers in the pod have voluntarily terminated with a container exit code of 0, and the system is not going to restart any of these containers.\n - `\"Unknown\"` means that for some reason the state of the pod could not be obtained, typically due to an error in communicating with the host of the pod. Deprecated: It isn't being set since 2015 (74da3b14b0c0f658b3bb8d2def5094686d0e9095)", - Type: []string{"string"}, - Format: "", - Enum: []interface{}{"Failed", "Pending", "Running", "Succeeded", "Unknown"}, - }, - }, - "conditions": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-map-keys": []interface{}{ - "type", - }, - "x-kubernetes-list-type": "map", - "x-kubernetes-patch-merge-key": "type", - "x-kubernetes-patch-strategy": "merge", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "Current service state of pod. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#pod-conditions", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.PodCondition{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "message": { - SchemaProps: spec.SchemaProps{ - Description: "A human readable message indicating details about why the pod is in this condition.", - Type: []string{"string"}, - Format: "", - }, - }, - "reason": { - SchemaProps: spec.SchemaProps{ - Description: "A brief CamelCase message indicating details about why the pod is in this state. e.g. 'Evicted'", - Type: []string{"string"}, - Format: "", - }, - }, - "nominatedNodeName": { - SchemaProps: spec.SchemaProps{ - Description: "nominatedNodeName is set only when this pod preempts other pods on the node, but it cannot be scheduled right away as preemption victims receive their graceful termination periods. This field does not guarantee that the pod will be scheduled on this node. Scheduler may decide to place the pod elsewhere if other nodes become available sooner. Scheduler may also decide to give the resources on this node to a higher priority pod that is created after preemption. As a result, this field may be different than PodSpec.nodeName when the pod is scheduled.", - Type: []string{"string"}, - Format: "", - }, - }, - "hostIP": { - SchemaProps: spec.SchemaProps{ - Description: "hostIP holds the IP address of the host to which the pod is assigned. Empty if the pod has not started yet. A pod can be assigned to a node that has a problem in kubelet which in turns mean that HostIP will not be updated even if there is a node is assigned to pod", - Type: []string{"string"}, - Format: "", - }, - }, - "hostIPs": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - "x-kubernetes-patch-merge-key": "ip", - "x-kubernetes-patch-strategy": "merge", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "hostIPs holds the IP addresses allocated to the host. If this field is specified, the first entry must match the hostIP field. This list is empty if the pod has not started yet. A pod can be assigned to a node that has a problem in kubelet which in turns means that HostIPs will not be updated even if there is a node is assigned to this pod.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.HostIP{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "podIP": { - SchemaProps: spec.SchemaProps{ - Description: "podIP address allocated to the pod. Routable at least within the cluster. Empty if not yet allocated.", - Type: []string{"string"}, - Format: "", - }, - }, - "podIPs": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-map-keys": []interface{}{ - "ip", - }, - "x-kubernetes-list-type": "map", - "x-kubernetes-patch-merge-key": "ip", - "x-kubernetes-patch-strategy": "merge", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "podIPs holds the IP addresses allocated to the pod. If this field is specified, the 0th entry must match the podIP field. Pods may be allocated at most 1 value for each of IPv4 and IPv6. This list is empty if no IPs have been allocated yet.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.PodIP{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "startTime": { - SchemaProps: spec.SchemaProps{ - Description: "RFC 3339 date and time at which the object was acknowledged by the Kubelet. This is before the Kubelet pulled the container image(s) for the pod.", - Ref: ref(metav1.Time{}.OpenAPIModelName()), - }, - }, - "initContainerStatuses": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "Statuses of init containers in this pod. The most recent successful non-restartable init container will have ready = true, the most recently started container will have startTime set. Each init container in the pod should have at most one status in this list, and all statuses should be for containers in the pod. However this is not enforced. If a status for a non-existent container is present in the list, or the list has duplicate names, the behavior of various Kubernetes components is not defined and those statuses might be ignored. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle/#pod-and-container-status", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.ContainerStatus{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "containerStatuses": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "Statuses of containers in this pod. Each container in the pod should have at most one status in this list, and all statuses should be for containers in the pod. However this is not enforced. If a status for a non-existent container is present in the list, or the list has duplicate names, the behavior of various Kubernetes components is not defined and those statuses might be ignored. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#pod-and-container-status", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.ContainerStatus{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "qosClass": { - SchemaProps: spec.SchemaProps{ - Description: "The Quality of Service (QOS) classification assigned to the pod based on resource requirements See PodQOSClass type for available QOS classes More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-qos/#quality-of-service-classes\n\nPossible enum values:\n - `\"BestEffort\"` is the BestEffort qos class.\n - `\"Burstable\"` is the Burstable qos class.\n - `\"Guaranteed\"` is the Guaranteed qos class.", - Type: []string{"string"}, - Format: "", - Enum: []interface{}{"BestEffort", "Burstable", "Guaranteed"}, - }, - }, - "ephemeralContainerStatuses": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "Statuses for any ephemeral containers that have run in this pod. Each ephemeral container in the pod should have at most one status in this list, and all statuses should be for containers in the pod. However this is not enforced. If a status for a non-existent container is present in the list, or the list has duplicate names, the behavior of various Kubernetes components is not defined and those statuses might be ignored. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#pod-and-container-status", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.ContainerStatus{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "resize": { - SchemaProps: spec.SchemaProps{ - Description: "Status of resources resize desired for pod's containers. It is empty if no resources resize is pending. Any changes to container resources will automatically set this to \"Proposed\" Deprecated: Resize status is moved to two pod conditions PodResizePending and PodResizeInProgress. PodResizePending will track states where the spec has been resized, but the Kubelet has not yet allocated the resources. PodResizeInProgress will track in-progress resizes, and should be present whenever allocated resources != acknowledged resources.", - Type: []string{"string"}, - Format: "", - }, - }, - "resourceClaimStatuses": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-map-keys": []interface{}{ - "name", - }, - "x-kubernetes-list-type": "map", - "x-kubernetes-patch-merge-key": "name", - "x-kubernetes-patch-strategy": "merge,retainKeys", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "Status of resource claims.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.PodResourceClaimStatus{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "extendedResourceClaimStatus": { - SchemaProps: spec.SchemaProps{ - Description: "Status of extended resource claim backed by DRA.", - Ref: ref(v1.PodExtendedResourceClaimStatus{}.OpenAPIModelName()), - }, - }, - "allocatedResources": { - SchemaProps: spec.SchemaProps{ - Description: "AllocatedResources is the total requests allocated for this pod by the node. If pod-level requests are not set, this will be the total requests aggregated across containers in the pod.", - Type: []string{"object"}, - AdditionalProperties: &spec.SchemaOrBool{ - Allows: true, - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Ref: ref(resource.Quantity{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "resources": { - SchemaProps: spec.SchemaProps{ - Description: "Resources represents the compute resource requests and limits that have been applied at the pod level if pod-level requests or limits are set in PodSpec.Resources", - Ref: ref(v1.ResourceRequirements{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - Dependencies: []string{ - v1.ContainerStatus{}.OpenAPIModelName(), v1.HostIP{}.OpenAPIModelName(), v1.PodCondition{}.OpenAPIModelName(), v1.PodExtendedResourceClaimStatus{}.OpenAPIModelName(), v1.PodIP{}.OpenAPIModelName(), v1.PodResourceClaimStatus{}.OpenAPIModelName(), v1.ResourceRequirements{}.OpenAPIModelName(), resource.Quantity{}.OpenAPIModelName(), metav1.Time{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_PodStatusResult(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "PodStatusResult is a wrapper for PodStatus returned by kubelet that can be encode/decoded", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Type: []string{"string"}, - Format: "", - }, - }, - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", - Type: []string{"string"}, - Format: "", - }, - }, - "metadata": { - SchemaProps: spec.SchemaProps{ - Description: "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata", - Default: map[string]interface{}{}, - Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), - }, - }, - "status": { - SchemaProps: spec.SchemaProps{ - Description: "Most recently observed status of the pod. This data may not be up to date. Populated by the system. Read-only. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status", - Default: map[string]interface{}{}, - Ref: ref(v1.PodStatus{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - Dependencies: []string{ - v1.PodStatus{}.OpenAPIModelName(), metav1.ObjectMeta{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_PodTemplate(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "PodTemplate describes a template for creating copies of a predefined pod.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Type: []string{"string"}, - Format: "", - }, - }, - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", - Type: []string{"string"}, - Format: "", - }, - }, - "metadata": { - SchemaProps: spec.SchemaProps{ - Description: "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata", - Default: map[string]interface{}{}, - Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), - }, - }, - "template": { - SchemaProps: spec.SchemaProps{ - Description: "Template defines the pods that will be created from this pod template. https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status", - Default: map[string]interface{}{}, - Ref: ref(v1.PodTemplateSpec{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - Dependencies: []string{ - v1.PodTemplateSpec{}.OpenAPIModelName(), metav1.ObjectMeta{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_PodTemplateList(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "PodTemplateList is a list of PodTemplates.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Type: []string{"string"}, - Format: "", - }, - }, - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", - Type: []string{"string"}, - Format: "", - }, - }, - "metadata": { - SchemaProps: spec.SchemaProps{ - Description: "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Default: map[string]interface{}{}, - Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), - }, - }, - "items": { - SchemaProps: spec.SchemaProps{ - Description: "List of pod templates", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.PodTemplate{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - }, - Required: []string{"items"}, - }, - }, - Dependencies: []string{ - v1.PodTemplate{}.OpenAPIModelName(), metav1.ListMeta{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_PodTemplateSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "PodTemplateSpec describes the data a pod should have when created from a template", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "metadata": { - SchemaProps: spec.SchemaProps{ - Description: "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata", - Default: map[string]interface{}{}, - Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), - }, - }, - "spec": { - SchemaProps: spec.SchemaProps{ - Description: "Specification of the desired behavior of the pod. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status", - Default: map[string]interface{}{}, - Ref: ref(v1.PodSpec{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - Dependencies: []string{ - v1.PodSpec{}.OpenAPIModelName(), metav1.ObjectMeta{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_PortStatus(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "PortStatus represents the error condition of a service port", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "port": { - SchemaProps: spec.SchemaProps{ - Description: "Port is the port number of the service port of which status is recorded here", - Default: 0, - Type: []string{"integer"}, - Format: "int32", - }, - }, - "protocol": { - SchemaProps: spec.SchemaProps{ - Description: "Protocol is the protocol of the service port of which status is recorded here The supported values are: \"TCP\", \"UDP\", \"SCTP\"\n\nPossible enum values:\n - `\"SCTP\"` is the SCTP protocol.\n - `\"TCP\"` is the TCP protocol.\n - `\"UDP\"` is the UDP protocol.", - Default: "", - Type: []string{"string"}, - Format: "", - Enum: []interface{}{"SCTP", "TCP", "UDP"}, - }, - }, - "error": { - SchemaProps: spec.SchemaProps{ - Description: "Error is to record the problem with the service port The format of the error shall comply with the following rules: - built-in error values shall be specified in this file and those shall use\n CamelCase names\n- cloud provider specific error values must have names that comply with the\n format foo.example.com/CamelCase.", - Type: []string{"string"}, - Format: "", - }, - }, - }, - Required: []string{"port", "protocol"}, - }, - }, - } -} - -func schema_k8sio_api_core_v1_PortworxVolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "PortworxVolumeSource represents a Portworx volume resource.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "volumeID": { - SchemaProps: spec.SchemaProps{ - Description: "volumeID uniquely identifies a Portworx volume", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "fsType": { - SchemaProps: spec.SchemaProps{ - Description: "fSType represents the filesystem type to mount Must be a filesystem type supported by the host operating system. Ex. \"ext4\", \"xfs\". Implicitly inferred to be \"ext4\" if unspecified.", - Type: []string{"string"}, - Format: "", - }, - }, - "readOnly": { - SchemaProps: spec.SchemaProps{ - Description: "readOnly defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts.", - Type: []string{"boolean"}, - Format: "", - }, - }, - }, - Required: []string{"volumeID"}, - }, - }, - } -} - -func schema_k8sio_api_core_v1_PreferAvoidPodsEntry(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "Describes a class of pods that should avoid this node.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "podSignature": { - SchemaProps: spec.SchemaProps{ - Description: "The class of pods.", - Default: map[string]interface{}{}, - Ref: ref(v1.PodSignature{}.OpenAPIModelName()), - }, - }, - "evictionTime": { - SchemaProps: spec.SchemaProps{ - Description: "Time at which this entry was added to the list.", - Ref: ref(metav1.Time{}.OpenAPIModelName()), - }, - }, - "reason": { - SchemaProps: spec.SchemaProps{ - Description: "(brief) reason why this entry was added to the list.", - Type: []string{"string"}, - Format: "", - }, - }, - "message": { - SchemaProps: spec.SchemaProps{ - Description: "Human readable message indicating why this entry was added to the list.", - Type: []string{"string"}, - Format: "", - }, - }, - }, - Required: []string{"podSignature"}, - }, - }, - Dependencies: []string{ - v1.PodSignature{}.OpenAPIModelName(), metav1.Time{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_PreferredSchedulingTerm(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "An empty preferred scheduling term matches all objects with implicit weight 0 (i.e. it's a no-op). A null preferred scheduling term matches no objects (i.e. is also a no-op).", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "weight": { - SchemaProps: spec.SchemaProps{ - Description: "Weight associated with matching the corresponding nodeSelectorTerm, in the range 1-100.", - Default: 0, - Type: []string{"integer"}, - Format: "int32", - }, - }, - "preference": { - SchemaProps: spec.SchemaProps{ - Description: "A node selector term, associated with the corresponding weight.", - Default: map[string]interface{}{}, - Ref: ref(v1.NodeSelectorTerm{}.OpenAPIModelName()), - }, - }, - }, - Required: []string{"weight", "preference"}, - }, - }, - Dependencies: []string{ - v1.NodeSelectorTerm{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_Probe(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "Probe describes a health check to be performed against a container to determine whether it is alive or ready to receive traffic.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "exec": { - SchemaProps: spec.SchemaProps{ - Description: "Exec specifies a command to execute in the container.", - Ref: ref(v1.ExecAction{}.OpenAPIModelName()), - }, - }, - "httpGet": { - SchemaProps: spec.SchemaProps{ - Description: "HTTPGet specifies an HTTP GET request to perform.", - Ref: ref(v1.HTTPGetAction{}.OpenAPIModelName()), - }, - }, - "tcpSocket": { - SchemaProps: spec.SchemaProps{ - Description: "TCPSocket specifies a connection to a TCP port.", - Ref: ref(v1.TCPSocketAction{}.OpenAPIModelName()), - }, - }, - "grpc": { - SchemaProps: spec.SchemaProps{ - Description: "GRPC specifies a GRPC HealthCheckRequest.", - Ref: ref(v1.GRPCAction{}.OpenAPIModelName()), - }, - }, - "initialDelaySeconds": { - SchemaProps: spec.SchemaProps{ - Description: "Number of seconds after the container has started before liveness probes are initiated. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#container-probes", - Type: []string{"integer"}, - Format: "int32", - }, - }, - "timeoutSeconds": { - SchemaProps: spec.SchemaProps{ - Description: "Number of seconds after which the probe times out. Defaults to 1 second. Minimum value is 1. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#container-probes", - Type: []string{"integer"}, - Format: "int32", - }, - }, - "periodSeconds": { - SchemaProps: spec.SchemaProps{ - Description: "How often (in seconds) to perform the probe. Default to 10 seconds. Minimum value is 1.", - Type: []string{"integer"}, - Format: "int32", - }, - }, - "successThreshold": { - SchemaProps: spec.SchemaProps{ - Description: "Minimum consecutive successes for the probe to be considered successful after having failed. Defaults to 1. Must be 1 for liveness and startup. Minimum value is 1.", - Type: []string{"integer"}, - Format: "int32", - }, - }, - "failureThreshold": { - SchemaProps: spec.SchemaProps{ - Description: "Minimum consecutive failures for the probe to be considered failed after having succeeded. Defaults to 3. Minimum value is 1.", - Type: []string{"integer"}, - Format: "int32", - }, - }, - "terminationGracePeriodSeconds": { - SchemaProps: spec.SchemaProps{ - Description: "Optional duration in seconds the pod needs to terminate gracefully upon probe failure. The grace period is the duration in seconds after the processes running in the pod are sent a termination signal and the time when the processes are forcibly halted with a kill signal. Set this value longer than the expected cleanup time for your process. If this value is nil, the pod's terminationGracePeriodSeconds will be used. Otherwise, this value overrides the value provided by the pod spec. Value must be non-negative integer. The value zero indicates stop immediately via the kill signal (no opportunity to shut down). This is a beta field and requires enabling ProbeTerminationGracePeriod feature gate. Minimum value is 1. spec.terminationGracePeriodSeconds is used if unset.", - Type: []string{"integer"}, - Format: "int64", - }, - }, - }, - }, - }, - Dependencies: []string{ - v1.ExecAction{}.OpenAPIModelName(), v1.GRPCAction{}.OpenAPIModelName(), v1.HTTPGetAction{}.OpenAPIModelName(), v1.TCPSocketAction{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_ProbeHandler(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "ProbeHandler defines a specific action that should be taken in a probe. One and only one of the fields must be specified.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "exec": { - SchemaProps: spec.SchemaProps{ - Description: "Exec specifies a command to execute in the container.", - Ref: ref(v1.ExecAction{}.OpenAPIModelName()), - }, - }, - "httpGet": { - SchemaProps: spec.SchemaProps{ - Description: "HTTPGet specifies an HTTP GET request to perform.", - Ref: ref(v1.HTTPGetAction{}.OpenAPIModelName()), - }, - }, - "tcpSocket": { - SchemaProps: spec.SchemaProps{ - Description: "TCPSocket specifies a connection to a TCP port.", - Ref: ref(v1.TCPSocketAction{}.OpenAPIModelName()), - }, - }, - "grpc": { - SchemaProps: spec.SchemaProps{ - Description: "GRPC specifies a GRPC HealthCheckRequest.", - Ref: ref(v1.GRPCAction{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - Dependencies: []string{ - v1.ExecAction{}.OpenAPIModelName(), v1.GRPCAction{}.OpenAPIModelName(), v1.HTTPGetAction{}.OpenAPIModelName(), v1.TCPSocketAction{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_ProjectedVolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "Represents a projected volume source", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "sources": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "sources is the list of volume projections. Each entry in this list handles one source.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.VolumeProjection{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "defaultMode": { - SchemaProps: spec.SchemaProps{ - Description: "defaultMode are the mode bits used to set permissions on created files by default. Must be an octal value between 0000 and 0777 or a decimal value between 0 and 511. YAML accepts both octal and decimal values, JSON requires decimal values for mode bits. Directories within the path are not affected by this setting. This might be in conflict with other options that affect the file mode, like fsGroup, and the result can be other mode bits set.", - Type: []string{"integer"}, - Format: "int32", - }, - }, - }, - }, - }, - Dependencies: []string{ - v1.VolumeProjection{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_QuobyteVolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "Represents a Quobyte mount that lasts the lifetime of a pod. Quobyte volumes do not support ownership management or SELinux relabeling.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "registry": { - SchemaProps: spec.SchemaProps{ - Description: "registry represents a single or multiple Quobyte Registry services specified as a string as host:port pair (multiple entries are separated with commas) which acts as the central registry for volumes", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "volume": { - SchemaProps: spec.SchemaProps{ - Description: "volume is a string that references an already created Quobyte volume by name.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "readOnly": { - SchemaProps: spec.SchemaProps{ - Description: "readOnly here will force the Quobyte volume to be mounted with read-only permissions. Defaults to false.", - Type: []string{"boolean"}, - Format: "", - }, - }, - "user": { - SchemaProps: spec.SchemaProps{ - Description: "user to map volume access to Defaults to serivceaccount user", - Type: []string{"string"}, - Format: "", - }, - }, - "group": { - SchemaProps: spec.SchemaProps{ - Description: "group to map volume access to Default is no group", - Type: []string{"string"}, - Format: "", - }, - }, - "tenant": { - SchemaProps: spec.SchemaProps{ - Description: "tenant owning the given Quobyte volume in the Backend Used with dynamically provisioned Quobyte volumes, value is set by the plugin", - Type: []string{"string"}, - Format: "", - }, - }, - }, - Required: []string{"registry", "volume"}, - }, - }, - } -} - -func schema_k8sio_api_core_v1_RBDPersistentVolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "Represents a Rados Block Device mount that lasts the lifetime of a pod. RBD volumes support ownership management and SELinux relabeling.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "monitors": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "monitors is a collection of Ceph monitors. More info: https://examples.k8s.io/volumes/rbd/README.md#how-to-use-it", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - "image": { - SchemaProps: spec.SchemaProps{ - Description: "image is the rados image name. More info: https://examples.k8s.io/volumes/rbd/README.md#how-to-use-it", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "fsType": { - SchemaProps: spec.SchemaProps{ - Description: "fsType is the filesystem type of the volume that you want to mount. Tip: Ensure that the filesystem type is supported by the host operating system. Examples: \"ext4\", \"xfs\", \"ntfs\". Implicitly inferred to be \"ext4\" if unspecified. More info: https://kubernetes.io/docs/concepts/storage/volumes#rbd", - Type: []string{"string"}, - Format: "", - }, - }, - "pool": { - SchemaProps: spec.SchemaProps{ - Description: "pool is the rados pool name. Default is rbd. More info: https://examples.k8s.io/volumes/rbd/README.md#how-to-use-it", - Default: "rbd", - Type: []string{"string"}, - Format: "", - }, - }, - "user": { - SchemaProps: spec.SchemaProps{ - Description: "user is the rados user name. Default is admin. More info: https://examples.k8s.io/volumes/rbd/README.md#how-to-use-it", - Default: "admin", - Type: []string{"string"}, - Format: "", - }, - }, - "keyring": { - SchemaProps: spec.SchemaProps{ - Description: "keyring is the path to key ring for RBDUser. Default is /etc/ceph/keyring. More info: https://examples.k8s.io/volumes/rbd/README.md#how-to-use-it", - Default: "/etc/ceph/keyring", - Type: []string{"string"}, - Format: "", - }, - }, - "secretRef": { - SchemaProps: spec.SchemaProps{ - Description: "secretRef is name of the authentication secret for RBDUser. If provided overrides keyring. Default is nil. More info: https://examples.k8s.io/volumes/rbd/README.md#how-to-use-it", - Ref: ref(v1.SecretReference{}.OpenAPIModelName()), - }, - }, - "readOnly": { - SchemaProps: spec.SchemaProps{ - Description: "readOnly here will force the ReadOnly setting in VolumeMounts. Defaults to false. More info: https://examples.k8s.io/volumes/rbd/README.md#how-to-use-it", - Type: []string{"boolean"}, - Format: "", - }, - }, - }, - Required: []string{"monitors", "image"}, - }, - }, - Dependencies: []string{ - v1.SecretReference{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_RBDVolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "Represents a Rados Block Device mount that lasts the lifetime of a pod. RBD volumes support ownership management and SELinux relabeling.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "monitors": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "monitors is a collection of Ceph monitors. More info: https://examples.k8s.io/volumes/rbd/README.md#how-to-use-it", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - "image": { - SchemaProps: spec.SchemaProps{ - Description: "image is the rados image name. More info: https://examples.k8s.io/volumes/rbd/README.md#how-to-use-it", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "fsType": { - SchemaProps: spec.SchemaProps{ - Description: "fsType is the filesystem type of the volume that you want to mount. Tip: Ensure that the filesystem type is supported by the host operating system. Examples: \"ext4\", \"xfs\", \"ntfs\". Implicitly inferred to be \"ext4\" if unspecified. More info: https://kubernetes.io/docs/concepts/storage/volumes#rbd", - Type: []string{"string"}, - Format: "", - }, - }, - "pool": { - SchemaProps: spec.SchemaProps{ - Description: "pool is the rados pool name. Default is rbd. More info: https://examples.k8s.io/volumes/rbd/README.md#how-to-use-it", - Default: "rbd", - Type: []string{"string"}, - Format: "", - }, - }, - "user": { - SchemaProps: spec.SchemaProps{ - Description: "user is the rados user name. Default is admin. More info: https://examples.k8s.io/volumes/rbd/README.md#how-to-use-it", - Default: "admin", - Type: []string{"string"}, - Format: "", - }, - }, - "keyring": { - SchemaProps: spec.SchemaProps{ - Description: "keyring is the path to key ring for RBDUser. Default is /etc/ceph/keyring. More info: https://examples.k8s.io/volumes/rbd/README.md#how-to-use-it", - Default: "/etc/ceph/keyring", - Type: []string{"string"}, - Format: "", - }, - }, - "secretRef": { - SchemaProps: spec.SchemaProps{ - Description: "secretRef is name of the authentication secret for RBDUser. If provided overrides keyring. Default is nil. More info: https://examples.k8s.io/volumes/rbd/README.md#how-to-use-it", - Ref: ref(v1.LocalObjectReference{}.OpenAPIModelName()), - }, - }, - "readOnly": { - SchemaProps: spec.SchemaProps{ - Description: "readOnly here will force the ReadOnly setting in VolumeMounts. Defaults to false. More info: https://examples.k8s.io/volumes/rbd/README.md#how-to-use-it", - Type: []string{"boolean"}, - Format: "", - }, - }, - }, - Required: []string{"monitors", "image"}, - }, - }, - Dependencies: []string{ - v1.LocalObjectReference{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_RangeAllocation(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "RangeAllocation is not a public type.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Type: []string{"string"}, - Format: "", - }, - }, - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", - Type: []string{"string"}, - Format: "", - }, - }, - "metadata": { - SchemaProps: spec.SchemaProps{ - Description: "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata", - Default: map[string]interface{}{}, - Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), - }, - }, - "range": { - SchemaProps: spec.SchemaProps{ - Description: "Range is string that identifies the range represented by 'data'.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "data": { - SchemaProps: spec.SchemaProps{ - Description: "Data is a bit array containing all allocated addresses in the previous segment.", - Type: []string{"string"}, - Format: "byte", - }, - }, - }, - Required: []string{"range", "data"}, - }, - }, - Dependencies: []string{ - metav1.ObjectMeta{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_ReplicationController(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "ReplicationController represents the configuration of a replication controller.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Type: []string{"string"}, - Format: "", - }, - }, - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", - Type: []string{"string"}, - Format: "", - }, - }, - "metadata": { - SchemaProps: spec.SchemaProps{ - Description: "If the Labels of a ReplicationController are empty, they are defaulted to be the same as the Pod(s) that the replication controller manages. Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata", - Default: map[string]interface{}{}, - Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), - }, - }, - "spec": { - SchemaProps: spec.SchemaProps{ - Description: "Spec defines the specification of the desired behavior of the replication controller. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status", - Default: map[string]interface{}{}, - Ref: ref(v1.ReplicationControllerSpec{}.OpenAPIModelName()), - }, - }, - "status": { - SchemaProps: spec.SchemaProps{ - Description: "Status is the most recently observed status of the replication controller. This data may be out of date by some window of time. Populated by the system. Read-only. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status", - Default: map[string]interface{}{}, - Ref: ref(v1.ReplicationControllerStatus{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - Dependencies: []string{ - v1.ReplicationControllerSpec{}.OpenAPIModelName(), v1.ReplicationControllerStatus{}.OpenAPIModelName(), metav1.ObjectMeta{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_ReplicationControllerCondition(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "ReplicationControllerCondition describes the state of a replication controller at a certain point.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "type": { - SchemaProps: spec.SchemaProps{ - Description: "Type of replication controller condition.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "status": { - SchemaProps: spec.SchemaProps{ - Description: "Status of the condition, one of True, False, Unknown.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "lastTransitionTime": { - SchemaProps: spec.SchemaProps{ - Description: "The last time the condition transitioned from one status to another.", - Ref: ref(metav1.Time{}.OpenAPIModelName()), - }, - }, - "reason": { - SchemaProps: spec.SchemaProps{ - Description: "The reason for the condition's last transition.", - Type: []string{"string"}, - Format: "", - }, - }, - "message": { - SchemaProps: spec.SchemaProps{ - Description: "A human readable message indicating details about the transition.", - Type: []string{"string"}, - Format: "", - }, - }, - }, - Required: []string{"type", "status"}, - }, - }, - Dependencies: []string{ - metav1.Time{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_ReplicationControllerList(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "ReplicationControllerList is a collection of replication controllers.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Type: []string{"string"}, - Format: "", - }, - }, - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", - Type: []string{"string"}, - Format: "", - }, - }, - "metadata": { - SchemaProps: spec.SchemaProps{ - Description: "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Default: map[string]interface{}{}, - Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), - }, - }, - "items": { - SchemaProps: spec.SchemaProps{ - Description: "List of replication controllers. More info: https://kubernetes.io/docs/concepts/workloads/controllers/replicationcontroller", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.ReplicationController{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - }, - Required: []string{"items"}, - }, - }, - Dependencies: []string{ - v1.ReplicationController{}.OpenAPIModelName(), metav1.ListMeta{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_ReplicationControllerSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "ReplicationControllerSpec is the specification of a replication controller.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "replicas": { - SchemaProps: spec.SchemaProps{ - Description: "Replicas is the number of desired replicas. This is a pointer to distinguish between explicit zero and unspecified. Defaults to 1. More info: https://kubernetes.io/docs/concepts/workloads/controllers/replicationcontroller#what-is-a-replicationcontroller", - Default: 1, - Type: []string{"integer"}, - Format: "int32", - }, - }, - "minReadySeconds": { - SchemaProps: spec.SchemaProps{ - Description: "Minimum number of seconds for which a newly created pod should be ready without any of its container crashing, for it to be considered available. Defaults to 0 (pod will be considered available as soon as it is ready)", - Default: 0, - Type: []string{"integer"}, - Format: "int32", - }, - }, - "selector": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-map-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "Selector is a label query over pods that should match the Replicas count. If Selector is empty, it is defaulted to the labels present on the Pod template. Label keys and values that must match in order to be controlled by this replication controller, if empty defaulted to labels on Pod template. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/#label-selectors", - Type: []string{"object"}, - AdditionalProperties: &spec.SchemaOrBool{ - Allows: true, - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - "template": { - SchemaProps: spec.SchemaProps{ - Description: "Template is the object that describes the pod that will be created if insufficient replicas are detected. This takes precedence over a TemplateRef. The only allowed template.spec.restartPolicy value is \"Always\". More info: https://kubernetes.io/docs/concepts/workloads/controllers/replicationcontroller#pod-template", - Ref: ref(v1.PodTemplateSpec{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - Dependencies: []string{ - v1.PodTemplateSpec{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_ReplicationControllerStatus(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "ReplicationControllerStatus represents the current status of a replication controller.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "replicas": { - SchemaProps: spec.SchemaProps{ - Description: "Replicas is the most recently observed number of replicas. More info: https://kubernetes.io/docs/concepts/workloads/controllers/replicationcontroller#what-is-a-replicationcontroller", - Default: 0, - Type: []string{"integer"}, - Format: "int32", - }, - }, - "fullyLabeledReplicas": { - SchemaProps: spec.SchemaProps{ - Description: "The number of pods that have labels matching the labels of the pod template of the replication controller.", - Type: []string{"integer"}, - Format: "int32", - }, - }, - "readyReplicas": { - SchemaProps: spec.SchemaProps{ - Description: "The number of ready replicas for this replication controller.", - Type: []string{"integer"}, - Format: "int32", - }, - }, - "availableReplicas": { - SchemaProps: spec.SchemaProps{ - Description: "The number of available replicas (ready for at least minReadySeconds) for this replication controller.", - Type: []string{"integer"}, - Format: "int32", - }, - }, - "observedGeneration": { - SchemaProps: spec.SchemaProps{ - Description: "ObservedGeneration reflects the generation of the most recently observed replication controller.", - Type: []string{"integer"}, - Format: "int64", - }, - }, - "conditions": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-map-keys": []interface{}{ - "type", - }, - "x-kubernetes-list-type": "map", - "x-kubernetes-patch-merge-key": "type", - "x-kubernetes-patch-strategy": "merge", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "Represents the latest available observations of a replication controller's current state.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.ReplicationControllerCondition{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - }, - Required: []string{"replicas"}, - }, - }, - Dependencies: []string{ - v1.ReplicationControllerCondition{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_ResourceClaim(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "ResourceClaim references one entry in PodSpec.ResourceClaims.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "name": { - SchemaProps: spec.SchemaProps{ - Description: "Name must match the name of one entry in pod.spec.resourceClaims of the Pod where this field is used. It makes that resource available inside a container.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "request": { - SchemaProps: spec.SchemaProps{ - Description: "Request is the name chosen for a request in the referenced claim. If empty, everything from the claim is made available, otherwise only the result of this request.", - Type: []string{"string"}, - Format: "", - }, - }, - }, - Required: []string{"name"}, - }, - }, - } -} - -func schema_k8sio_api_core_v1_ResourceFieldSelector(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "ResourceFieldSelector represents container resources (cpu, memory) and their output format", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "containerName": { - SchemaProps: spec.SchemaProps{ - Description: "Container name: required for volumes, optional for env vars", - Type: []string{"string"}, - Format: "", - }, - }, - "resource": { - SchemaProps: spec.SchemaProps{ - Description: "Required: resource to select", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "divisor": { - SchemaProps: spec.SchemaProps{ - Description: "Specifies the output format of the exposed resources, defaults to \"1\"", - Ref: ref(resource.Quantity{}.OpenAPIModelName()), - }, - }, - }, - Required: []string{"resource"}, - }, - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-map-type": "atomic", - }, - }, - }, - Dependencies: []string{ - resource.Quantity{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_ResourceHealth(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "ResourceHealth represents the health of a resource. It has the latest device health information. This is a part of KEP https://kep.k8s.io/4680.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "resourceID": { - SchemaProps: spec.SchemaProps{ - Description: "ResourceID is the unique identifier of the resource. See the ResourceID type for more information.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "health": { - SchemaProps: spec.SchemaProps{ - Description: "Health of the resource. can be one of:\n - Healthy: operates as normal\n - Unhealthy: reported unhealthy. We consider this a temporary health issue\n since we do not have a mechanism today to distinguish\n temporary and permanent issues.\n - Unknown: The status cannot be determined.\n For example, Device Plugin got unregistered and hasn't been re-registered since.\n\nIn future we may want to introduce the PermanentlyUnhealthy Status.", - Type: []string{"string"}, - Format: "", - }, - }, - }, - Required: []string{"resourceID"}, - }, - }, - } -} - -func schema_k8sio_api_core_v1_ResourceQuota(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "ResourceQuota sets aggregate quota restrictions enforced per namespace", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Type: []string{"string"}, - Format: "", - }, - }, - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", - Type: []string{"string"}, - Format: "", - }, - }, - "metadata": { - SchemaProps: spec.SchemaProps{ - Description: "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata", - Default: map[string]interface{}{}, - Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), - }, - }, - "spec": { - SchemaProps: spec.SchemaProps{ - Description: "Spec defines the desired quota. https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status", - Default: map[string]interface{}{}, - Ref: ref(v1.ResourceQuotaSpec{}.OpenAPIModelName()), - }, - }, - "status": { - SchemaProps: spec.SchemaProps{ - Description: "Status defines the actual enforced quota and its current usage. https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status", - Default: map[string]interface{}{}, - Ref: ref(v1.ResourceQuotaStatus{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - Dependencies: []string{ - v1.ResourceQuotaSpec{}.OpenAPIModelName(), v1.ResourceQuotaStatus{}.OpenAPIModelName(), metav1.ObjectMeta{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_ResourceQuotaList(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "ResourceQuotaList is a list of ResourceQuota items.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Type: []string{"string"}, - Format: "", - }, - }, - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", - Type: []string{"string"}, - Format: "", - }, - }, - "metadata": { - SchemaProps: spec.SchemaProps{ - Description: "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Default: map[string]interface{}{}, - Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), - }, - }, - "items": { - SchemaProps: spec.SchemaProps{ - Description: "Items is a list of ResourceQuota objects. More info: https://kubernetes.io/docs/concepts/policy/resource-quotas/", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.ResourceQuota{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - }, - Required: []string{"items"}, - }, - }, - Dependencies: []string{ - v1.ResourceQuota{}.OpenAPIModelName(), metav1.ListMeta{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_ResourceQuotaSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "ResourceQuotaSpec defines the desired hard limits to enforce for Quota.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "hard": { - SchemaProps: spec.SchemaProps{ - Description: "hard is the set of desired hard limits for each named resource. More info: https://kubernetes.io/docs/concepts/policy/resource-quotas/", - Type: []string{"object"}, - AdditionalProperties: &spec.SchemaOrBool{ - Allows: true, - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Ref: ref(resource.Quantity{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "scopes": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "A collection of filters that must match each object tracked by a quota. If not specified, the quota matches all objects.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - Enum: []interface{}{"BestEffort", "CrossNamespacePodAffinity", "NotBestEffort", "NotTerminating", "PriorityClass", "Terminating", "VolumeAttributesClass"}, - }, - }, - }, - }, - }, - "scopeSelector": { - SchemaProps: spec.SchemaProps{ - Description: "scopeSelector is also a collection of filters like scopes that must match each object tracked by a quota but expressed using ScopeSelectorOperator in combination with possible values. For a resource to match, both scopes AND scopeSelector (if specified in spec), must be matched.", - Ref: ref(v1.ScopeSelector{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - Dependencies: []string{ - v1.ScopeSelector{}.OpenAPIModelName(), resource.Quantity{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_ResourceQuotaStatus(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "ResourceQuotaStatus defines the enforced hard limits and observed use.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "hard": { - SchemaProps: spec.SchemaProps{ - Description: "Hard is the set of enforced hard limits for each named resource. More info: https://kubernetes.io/docs/concepts/policy/resource-quotas/", - Type: []string{"object"}, - AdditionalProperties: &spec.SchemaOrBool{ - Allows: true, - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Ref: ref(resource.Quantity{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "used": { - SchemaProps: spec.SchemaProps{ - Description: "Used is the current observed total usage of the resource in the namespace.", - Type: []string{"object"}, - AdditionalProperties: &spec.SchemaOrBool{ - Allows: true, - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Ref: ref(resource.Quantity{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - }, - }, - }, - Dependencies: []string{ - resource.Quantity{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_ResourceRequirements(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "ResourceRequirements describes the compute resource requirements.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "limits": { - SchemaProps: spec.SchemaProps{ - Description: "Limits describes the maximum amount of compute resources allowed. More info: https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/", - Type: []string{"object"}, - AdditionalProperties: &spec.SchemaOrBool{ - Allows: true, - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Ref: ref(resource.Quantity{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "requests": { - SchemaProps: spec.SchemaProps{ - Description: "Requests describes the minimum amount of compute resources required. If Requests is omitted for a container, it defaults to Limits if that is explicitly specified, otherwise to an implementation-defined value. Requests cannot exceed Limits. More info: https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/", - Type: []string{"object"}, - AdditionalProperties: &spec.SchemaOrBool{ - Allows: true, - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Ref: ref(resource.Quantity{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "claims": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-map-keys": []interface{}{ - "name", - }, - "x-kubernetes-list-type": "map", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "Claims lists the names of resources, defined in spec.resourceClaims, that are used by this container.\n\nThis field depends on the DynamicResourceAllocation feature gate.\n\nThis field is immutable. It can only be set for containers.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.ResourceClaim{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - }, - }, - }, - Dependencies: []string{ - v1.ResourceClaim{}.OpenAPIModelName(), resource.Quantity{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_ResourceStatus(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "ResourceStatus represents the status of a single resource allocated to a Pod.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "name": { - SchemaProps: spec.SchemaProps{ - Description: "Name of the resource. Must be unique within the pod and in case of non-DRA resource, match one of the resources from the pod spec. For DRA resources, the value must be \"claim:/\". When this status is reported about a container, the \"claim_name\" and \"request\" must match one of the claims of this container.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "resources": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-map-keys": []interface{}{ - "resourceID", - }, - "x-kubernetes-list-type": "map", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "List of unique resources health. Each element in the list contains an unique resource ID and its health. At a minimum, for the lifetime of a Pod, resource ID must uniquely identify the resource allocated to the Pod on the Node. If other Pod on the same Node reports the status with the same resource ID, it must be the same resource they share. See ResourceID type definition for a specific format it has in various use cases.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.ResourceHealth{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - }, - Required: []string{"name"}, - }, - }, - Dependencies: []string{ - v1.ResourceHealth{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_SELinuxOptions(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "SELinuxOptions are the labels to be applied to the container", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "user": { - SchemaProps: spec.SchemaProps{ - Description: "User is a SELinux user label that applies to the container.", - Type: []string{"string"}, - Format: "", - }, - }, - "role": { - SchemaProps: spec.SchemaProps{ - Description: "Role is a SELinux role label that applies to the container.", - Type: []string{"string"}, - Format: "", - }, - }, - "type": { - SchemaProps: spec.SchemaProps{ - Description: "Type is a SELinux type label that applies to the container.", - Type: []string{"string"}, - Format: "", - }, - }, - "level": { - SchemaProps: spec.SchemaProps{ - Description: "Level is SELinux level label that applies to the container.", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - } -} - -func schema_k8sio_api_core_v1_ScaleIOPersistentVolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "ScaleIOPersistentVolumeSource represents a persistent ScaleIO volume", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "gateway": { - SchemaProps: spec.SchemaProps{ - Description: "gateway is the host address of the ScaleIO API Gateway.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "system": { - SchemaProps: spec.SchemaProps{ - Description: "system is the name of the storage system as configured in ScaleIO.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "secretRef": { - SchemaProps: spec.SchemaProps{ - Description: "secretRef references to the secret for ScaleIO user and other sensitive information. If this is not provided, Login operation will fail.", - Ref: ref(v1.SecretReference{}.OpenAPIModelName()), - }, - }, - "sslEnabled": { - SchemaProps: spec.SchemaProps{ - Description: "sslEnabled is the flag to enable/disable SSL communication with Gateway, default false", - Type: []string{"boolean"}, - Format: "", - }, - }, - "protectionDomain": { - SchemaProps: spec.SchemaProps{ - Description: "protectionDomain is the name of the ScaleIO Protection Domain for the configured storage.", - Type: []string{"string"}, - Format: "", - }, - }, - "storagePool": { - SchemaProps: spec.SchemaProps{ - Description: "storagePool is the ScaleIO Storage Pool associated with the protection domain.", - Type: []string{"string"}, - Format: "", - }, - }, - "storageMode": { - SchemaProps: spec.SchemaProps{ - Description: "storageMode indicates whether the storage for a volume should be ThickProvisioned or ThinProvisioned. Default is ThinProvisioned.", - Default: "ThinProvisioned", - Type: []string{"string"}, - Format: "", - }, - }, - "volumeName": { - SchemaProps: spec.SchemaProps{ - Description: "volumeName is the name of a volume already created in the ScaleIO system that is associated with this volume source.", - Type: []string{"string"}, - Format: "", - }, - }, - "fsType": { - SchemaProps: spec.SchemaProps{ - Description: "fsType is the filesystem type to mount. Must be a filesystem type supported by the host operating system. Ex. \"ext4\", \"xfs\", \"ntfs\". Default is \"xfs\"", - Default: "xfs", - Type: []string{"string"}, - Format: "", - }, - }, - "readOnly": { - SchemaProps: spec.SchemaProps{ - Description: "readOnly defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts.", - Type: []string{"boolean"}, - Format: "", - }, - }, - }, - Required: []string{"gateway", "system", "secretRef"}, - }, - }, - Dependencies: []string{ - v1.SecretReference{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_ScaleIOVolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "ScaleIOVolumeSource represents a persistent ScaleIO volume", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "gateway": { - SchemaProps: spec.SchemaProps{ - Description: "gateway is the host address of the ScaleIO API Gateway.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "system": { - SchemaProps: spec.SchemaProps{ - Description: "system is the name of the storage system as configured in ScaleIO.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "secretRef": { - SchemaProps: spec.SchemaProps{ - Description: "secretRef references to the secret for ScaleIO user and other sensitive information. If this is not provided, Login operation will fail.", - Ref: ref(v1.LocalObjectReference{}.OpenAPIModelName()), - }, - }, - "sslEnabled": { - SchemaProps: spec.SchemaProps{ - Description: "sslEnabled Flag enable/disable SSL communication with Gateway, default false", - Type: []string{"boolean"}, - Format: "", - }, - }, - "protectionDomain": { - SchemaProps: spec.SchemaProps{ - Description: "protectionDomain is the name of the ScaleIO Protection Domain for the configured storage.", - Type: []string{"string"}, - Format: "", - }, - }, - "storagePool": { - SchemaProps: spec.SchemaProps{ - Description: "storagePool is the ScaleIO Storage Pool associated with the protection domain.", - Type: []string{"string"}, - Format: "", - }, - }, - "storageMode": { - SchemaProps: spec.SchemaProps{ - Description: "storageMode indicates whether the storage for a volume should be ThickProvisioned or ThinProvisioned. Default is ThinProvisioned.", - Default: "ThinProvisioned", - Type: []string{"string"}, - Format: "", - }, - }, - "volumeName": { - SchemaProps: spec.SchemaProps{ - Description: "volumeName is the name of a volume already created in the ScaleIO system that is associated with this volume source.", - Type: []string{"string"}, - Format: "", - }, - }, - "fsType": { - SchemaProps: spec.SchemaProps{ - Description: "fsType is the filesystem type to mount. Must be a filesystem type supported by the host operating system. Ex. \"ext4\", \"xfs\", \"ntfs\". Default is \"xfs\".", - Default: "xfs", - Type: []string{"string"}, - Format: "", - }, - }, - "readOnly": { - SchemaProps: spec.SchemaProps{ - Description: "readOnly Defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts.", - Type: []string{"boolean"}, - Format: "", - }, - }, - }, - Required: []string{"gateway", "system", "secretRef"}, - }, - }, - Dependencies: []string{ - v1.LocalObjectReference{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_ScopeSelector(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "A scope selector represents the AND of the selectors represented by the scoped-resource selector requirements.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "matchExpressions": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "A list of scope selector requirements by scope of the resources.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.ScopedResourceSelectorRequirement{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - }, - }, - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-map-type": "atomic", - }, - }, - }, - Dependencies: []string{ - v1.ScopedResourceSelectorRequirement{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_ScopedResourceSelectorRequirement(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "A scoped-resource selector requirement is a selector that contains values, a scope name, and an operator that relates the scope name and values.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "scopeName": { - SchemaProps: spec.SchemaProps{ - Description: "The name of the scope that the selector applies to.\n\nPossible enum values:\n - `\"BestEffort\"` Match all pod objects that have best effort quality of service\n - `\"CrossNamespacePodAffinity\"` Match all pod objects that have cross-namespace pod (anti)affinity mentioned.\n - `\"NotBestEffort\"` Match all pod objects that do not have best effort quality of service\n - `\"NotTerminating\"` Match all pod objects where spec.activeDeadlineSeconds is nil\n - `\"PriorityClass\"` Match all pod objects that have priority class mentioned\n - `\"Terminating\"` Match all pod objects where spec.activeDeadlineSeconds >=0\n - `\"VolumeAttributesClass\"` Match all pvc objects that have volume attributes class mentioned.", - Default: "", - Type: []string{"string"}, - Format: "", - Enum: []interface{}{"BestEffort", "CrossNamespacePodAffinity", "NotBestEffort", "NotTerminating", "PriorityClass", "Terminating", "VolumeAttributesClass"}, - }, - }, - "operator": { - SchemaProps: spec.SchemaProps{ - Description: "Represents a scope's relationship to a set of values. Valid operators are In, NotIn, Exists, DoesNotExist.\n\nPossible enum values:\n - `\"DoesNotExist\"`\n - `\"Exists\"`\n - `\"In\"`\n - `\"NotIn\"`", - Default: "", - Type: []string{"string"}, - Format: "", - Enum: []interface{}{"DoesNotExist", "Exists", "In", "NotIn"}, - }, - }, - "values": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "An array of string values. If the operator is In or NotIn, the values array must be non-empty. If the operator is Exists or DoesNotExist, the values array must be empty. This array is replaced during a strategic merge patch.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - }, - Required: []string{"scopeName", "operator"}, - }, - }, - } -} - -func schema_k8sio_api_core_v1_SeccompProfile(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "SeccompProfile defines a pod/container's seccomp profile settings. Only one profile source may be set.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "type": { - SchemaProps: spec.SchemaProps{ - Description: "type indicates which kind of seccomp profile will be applied. Valid options are:\n\nLocalhost - a profile defined in a file on the node should be used. RuntimeDefault - the container runtime default profile should be used. Unconfined - no profile should be applied.\n\nPossible enum values:\n - `\"Localhost\"` indicates a profile defined in a file on the node should be used. The file's location relative to /seccomp.\n - `\"RuntimeDefault\"` represents the default container runtime seccomp profile.\n - `\"Unconfined\"` indicates no seccomp profile is applied (A.K.A. unconfined).", - Default: "", - Type: []string{"string"}, - Format: "", - Enum: []interface{}{"Localhost", "RuntimeDefault", "Unconfined"}, - }, - }, - "localhostProfile": { - SchemaProps: spec.SchemaProps{ - Description: "localhostProfile indicates a profile defined in a file on the node should be used. The profile must be preconfigured on the node to work. Must be a descending path, relative to the kubelet's configured seccomp profile location. Must be set if type is \"Localhost\". Must NOT be set for any other type.", - Type: []string{"string"}, - Format: "", - }, - }, - }, - Required: []string{"type"}, - }, - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-unions": []interface{}{ - map[string]interface{}{ - "discriminator": "type", - "fields-to-discriminateBy": map[string]interface{}{ - "localhostProfile": "LocalhostProfile", - }, - }, - }, - }, - }, - }, - } -} - -func schema_k8sio_api_core_v1_Secret(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "Secret holds secret data of a certain type. The total bytes of the values in the Data field must be less than MaxSecretSize bytes.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Type: []string{"string"}, - Format: "", - }, - }, - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", - Type: []string{"string"}, - Format: "", - }, - }, - "metadata": { - SchemaProps: spec.SchemaProps{ - Description: "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata", - Default: map[string]interface{}{}, - Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), - }, - }, - "immutable": { - SchemaProps: spec.SchemaProps{ - Description: "Immutable, if set to true, ensures that data stored in the Secret cannot be updated (only object metadata can be modified). If not set to true, the field can be modified at any time. Defaulted to nil.", - Type: []string{"boolean"}, - Format: "", - }, - }, - "data": { - SchemaProps: spec.SchemaProps{ - Description: "Data contains the secret data. Each key must consist of alphanumeric characters, '-', '_' or '.'. The serialized form of the secret data is a base64 encoded string, representing the arbitrary (possibly non-string) data value here. Described in https://tools.ietf.org/html/rfc4648#section-4", - Type: []string{"object"}, - AdditionalProperties: &spec.SchemaOrBool{ - Allows: true, - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Type: []string{"string"}, - Format: "byte", - }, - }, - }, - }, - }, - "stringData": { - SchemaProps: spec.SchemaProps{ - Description: "stringData allows specifying non-binary secret data in string form. It is provided as a write-only input field for convenience. All keys and values are merged into the data field on write, overwriting any existing values. The stringData field is never output when reading from the API.", - Type: []string{"object"}, - AdditionalProperties: &spec.SchemaOrBool{ - Allows: true, - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - "type": { - SchemaProps: spec.SchemaProps{ - Description: "Used to facilitate programmatic handling of secret data. More info: https://kubernetes.io/docs/concepts/configuration/secret/#secret-types", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - Dependencies: []string{ - metav1.ObjectMeta{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_SecretEnvSource(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "SecretEnvSource selects a Secret to populate the environment variables with.\n\nThe contents of the target Secret's Data field will represent the key-value pairs as environment variables.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "name": { - SchemaProps: spec.SchemaProps{ - Description: "Name of the referent. This field is effectively required, but due to backwards compatibility is allowed to be empty. Instances of this type with an empty value here are almost certainly wrong. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "optional": { - SchemaProps: spec.SchemaProps{ - Description: "Specify whether the Secret must be defined", - Type: []string{"boolean"}, - Format: "", - }, - }, - }, - }, - }, - } -} - -func schema_k8sio_api_core_v1_SecretKeySelector(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "SecretKeySelector selects a key of a Secret.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "name": { - SchemaProps: spec.SchemaProps{ - Description: "Name of the referent. This field is effectively required, but due to backwards compatibility is allowed to be empty. Instances of this type with an empty value here are almost certainly wrong. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "key": { - SchemaProps: spec.SchemaProps{ - Description: "The key of the secret to select from. Must be a valid secret key.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "optional": { - SchemaProps: spec.SchemaProps{ - Description: "Specify whether the Secret or its key must be defined", - Type: []string{"boolean"}, - Format: "", - }, - }, - }, - Required: []string{"key"}, - }, - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-map-type": "atomic", - }, - }, - }, - } -} - -func schema_k8sio_api_core_v1_SecretList(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "SecretList is a list of Secret.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Type: []string{"string"}, - Format: "", - }, - }, - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", - Type: []string{"string"}, - Format: "", - }, - }, - "metadata": { - SchemaProps: spec.SchemaProps{ - Description: "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Default: map[string]interface{}{}, - Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), - }, - }, - "items": { - SchemaProps: spec.SchemaProps{ - Description: "Items is a list of secret objects. More info: https://kubernetes.io/docs/concepts/configuration/secret", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.Secret{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - }, - Required: []string{"items"}, - }, - }, - Dependencies: []string{ - v1.Secret{}.OpenAPIModelName(), metav1.ListMeta{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_SecretProjection(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "Adapts a secret into a projected volume.\n\nThe contents of the target Secret's Data field will be presented in a projected volume as files using the keys in the Data field as the file names. Note that this is identical to a secret volume source without the default mode.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "name": { - SchemaProps: spec.SchemaProps{ - Description: "Name of the referent. This field is effectively required, but due to backwards compatibility is allowed to be empty. Instances of this type with an empty value here are almost certainly wrong. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "items": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "items if unspecified, each key-value pair in the Data field of the referenced Secret will be projected into the volume as a file whose name is the key and content is the value. If specified, the listed keys will be projected into the specified paths, and unlisted keys will not be present. If a key is specified which is not present in the Secret, the volume setup will error unless it is marked optional. Paths must be relative and may not contain the '..' path or start with '..'.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.KeyToPath{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "optional": { - SchemaProps: spec.SchemaProps{ - Description: "optional field specify whether the Secret or its key must be defined", - Type: []string{"boolean"}, - Format: "", - }, - }, - }, - }, - }, - Dependencies: []string{ - v1.KeyToPath{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_SecretReference(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "SecretReference represents a Secret Reference. It has enough information to retrieve secret in any namespace", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "name": { - SchemaProps: spec.SchemaProps{ - Description: "name is unique within a namespace to reference a secret resource.", - Type: []string{"string"}, - Format: "", - }, - }, - "namespace": { - SchemaProps: spec.SchemaProps{ - Description: "namespace defines the space within which the secret name must be unique.", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-map-type": "atomic", - }, - }, - }, - } -} - -func schema_k8sio_api_core_v1_SecretVolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "Adapts a Secret into a volume.\n\nThe contents of the target Secret's Data field will be presented in a volume as files using the keys in the Data field as the file names. Secret volumes support ownership management and SELinux relabeling.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "secretName": { - SchemaProps: spec.SchemaProps{ - Description: "secretName is the name of the secret in the pod's namespace to use. More info: https://kubernetes.io/docs/concepts/storage/volumes#secret", - Type: []string{"string"}, - Format: "", - }, - }, - "items": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "items If unspecified, each key-value pair in the Data field of the referenced Secret will be projected into the volume as a file whose name is the key and content is the value. If specified, the listed keys will be projected into the specified paths, and unlisted keys will not be present. If a key is specified which is not present in the Secret, the volume setup will error unless it is marked optional. Paths must be relative and may not contain the '..' path or start with '..'.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.KeyToPath{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "defaultMode": { - SchemaProps: spec.SchemaProps{ - Description: "defaultMode is Optional: mode bits used to set permissions on created files by default. Must be an octal value between 0000 and 0777 or a decimal value between 0 and 511. YAML accepts both octal and decimal values, JSON requires decimal values for mode bits. Defaults to 0644. Directories within the path are not affected by this setting. This might be in conflict with other options that affect the file mode, like fsGroup, and the result can be other mode bits set.", - Type: []string{"integer"}, - Format: "int32", - }, - }, - "optional": { - SchemaProps: spec.SchemaProps{ - Description: "optional field specify whether the Secret or its keys must be defined", - Type: []string{"boolean"}, - Format: "", - }, - }, - }, - }, - }, - Dependencies: []string{ - v1.KeyToPath{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_SecurityContext(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "SecurityContext holds security configuration that will be applied to a container. Some fields are present in both SecurityContext and PodSecurityContext. When both are set, the values in SecurityContext take precedence.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "capabilities": { - SchemaProps: spec.SchemaProps{ - Description: "The capabilities to add/drop when running containers. Defaults to the default set of capabilities granted by the container runtime. Note that this field cannot be set when spec.os.name is windows.", - Ref: ref(v1.Capabilities{}.OpenAPIModelName()), - }, - }, - "privileged": { - SchemaProps: spec.SchemaProps{ - Description: "Run container in privileged mode. Processes in privileged containers are essentially equivalent to root on the host. Defaults to false. Note that this field cannot be set when spec.os.name is windows.", - Type: []string{"boolean"}, - Format: "", - }, - }, - "seLinuxOptions": { - SchemaProps: spec.SchemaProps{ - Description: "The SELinux context to be applied to the container. If unspecified, the container runtime will allocate a random SELinux context for each container. May also be set in PodSecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence. Note that this field cannot be set when spec.os.name is windows.", - Ref: ref(v1.SELinuxOptions{}.OpenAPIModelName()), - }, - }, - "windowsOptions": { - SchemaProps: spec.SchemaProps{ - Description: "The Windows specific settings applied to all containers. If unspecified, the options from the PodSecurityContext will be used. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence. Note that this field cannot be set when spec.os.name is linux.", - Ref: ref(v1.WindowsSecurityContextOptions{}.OpenAPIModelName()), - }, - }, - "runAsUser": { - SchemaProps: spec.SchemaProps{ - Description: "The UID to run the entrypoint of the container process. Defaults to user specified in image metadata if unspecified. May also be set in PodSecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence. Note that this field cannot be set when spec.os.name is windows.", - Type: []string{"integer"}, - Format: "int64", - }, - }, - "runAsGroup": { - SchemaProps: spec.SchemaProps{ - Description: "The GID to run the entrypoint of the container process. Uses runtime default if unset. May also be set in PodSecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence. Note that this field cannot be set when spec.os.name is windows.", - Type: []string{"integer"}, - Format: "int64", - }, - }, - "runAsNonRoot": { - SchemaProps: spec.SchemaProps{ - Description: "Indicates that the container must run as a non-root user. If true, the Kubelet will validate the image at runtime to ensure that it does not run as UID 0 (root) and fail to start the container if it does. If unset or false, no such validation will be performed. May also be set in PodSecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence.", - Type: []string{"boolean"}, - Format: "", - }, - }, - "readOnlyRootFilesystem": { - SchemaProps: spec.SchemaProps{ - Description: "Whether this container has a read-only root filesystem. Default is false. Note that this field cannot be set when spec.os.name is windows.", - Type: []string{"boolean"}, - Format: "", - }, - }, - "allowPrivilegeEscalation": { - SchemaProps: spec.SchemaProps{ - Description: "AllowPrivilegeEscalation controls whether a process can gain more privileges than its parent process. This bool directly controls if the no_new_privs flag will be set on the container process. AllowPrivilegeEscalation is true always when the container is: 1) run as Privileged 2) has CAP_SYS_ADMIN Note that this field cannot be set when spec.os.name is windows.", - Type: []string{"boolean"}, - Format: "", - }, - }, - "procMount": { - SchemaProps: spec.SchemaProps{ - Description: "procMount denotes the type of proc mount to use for the containers. The default value is Default which uses the container runtime defaults for readonly paths and masked paths. This requires the ProcMountType feature flag to be enabled. Note that this field cannot be set when spec.os.name is windows.\n\nPossible enum values:\n - `\"Default\"` uses the container runtime defaults for readonly and masked paths for /proc. Most container runtimes mask certain paths in /proc to avoid accidental security exposure of special devices or information.\n - `\"Unmasked\"` bypasses the default masking behavior of the container runtime and ensures the newly created /proc the container stays in tact with no modifications.", - Type: []string{"string"}, - Format: "", - Enum: []interface{}{"Default", "Unmasked"}, - }, - }, - "seccompProfile": { - SchemaProps: spec.SchemaProps{ - Description: "The seccomp options to use by this container. If seccomp options are provided at both the pod & container level, the container options override the pod options. Note that this field cannot be set when spec.os.name is windows.", - Ref: ref(v1.SeccompProfile{}.OpenAPIModelName()), - }, - }, - "appArmorProfile": { - SchemaProps: spec.SchemaProps{ - Description: "appArmorProfile is the AppArmor options to use by this container. If set, this profile overrides the pod's appArmorProfile. Note that this field cannot be set when spec.os.name is windows.", - Ref: ref(v1.AppArmorProfile{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - Dependencies: []string{ - v1.AppArmorProfile{}.OpenAPIModelName(), v1.Capabilities{}.OpenAPIModelName(), v1.SELinuxOptions{}.OpenAPIModelName(), v1.SeccompProfile{}.OpenAPIModelName(), v1.WindowsSecurityContextOptions{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_SerializedReference(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "SerializedReference is a reference to serialized object.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Type: []string{"string"}, - Format: "", - }, - }, - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", - Type: []string{"string"}, - Format: "", - }, - }, - "reference": { - SchemaProps: spec.SchemaProps{ - Description: "The reference to an object in the system.", - Default: map[string]interface{}{}, - Ref: ref(v1.ObjectReference{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - Dependencies: []string{ - v1.ObjectReference{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_Service(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "Service is a named abstraction of software service (for example, mysql) consisting of local port (for example 3306) that the proxy listens on, and the selector that determines which pods will answer requests sent through the proxy.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Type: []string{"string"}, - Format: "", - }, - }, - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", - Type: []string{"string"}, - Format: "", - }, - }, - "metadata": { - SchemaProps: spec.SchemaProps{ - Description: "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata", - Default: map[string]interface{}{}, - Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), - }, - }, - "spec": { - SchemaProps: spec.SchemaProps{ - Description: "Spec defines the behavior of a service. https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status", - Default: map[string]interface{}{}, - Ref: ref(v1.ServiceSpec{}.OpenAPIModelName()), - }, - }, - "status": { - SchemaProps: spec.SchemaProps{ - Description: "Most recently observed status of the service. Populated by the system. Read-only. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status", - Default: map[string]interface{}{}, - Ref: ref(v1.ServiceStatus{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - Dependencies: []string{ - v1.ServiceSpec{}.OpenAPIModelName(), v1.ServiceStatus{}.OpenAPIModelName(), metav1.ObjectMeta{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_ServiceAccount(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "ServiceAccount binds together: * a name, understood by users, and perhaps by peripheral systems, for an identity * a principal that can be authenticated and authorized * a set of secrets", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Type: []string{"string"}, - Format: "", - }, - }, - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", - Type: []string{"string"}, - Format: "", - }, - }, - "metadata": { - SchemaProps: spec.SchemaProps{ - Description: "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata", - Default: map[string]interface{}{}, - Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), - }, - }, - "secrets": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-map-keys": []interface{}{ - "name", - }, - "x-kubernetes-list-type": "map", - "x-kubernetes-patch-merge-key": "name", - "x-kubernetes-patch-strategy": "merge", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "Secrets is a list of the secrets in the same namespace that pods running using this ServiceAccount are allowed to use. Pods are only limited to this list if this service account has a \"kubernetes.io/enforce-mountable-secrets\" annotation set to \"true\". The \"kubernetes.io/enforce-mountable-secrets\" annotation is deprecated since v1.32. Prefer separate namespaces to isolate access to mounted secrets. This field should not be used to find auto-generated service account token secrets for use outside of pods. Instead, tokens can be requested directly using the TokenRequest API, or service account token secrets can be manually created. More info: https://kubernetes.io/docs/concepts/configuration/secret", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.ObjectReference{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "imagePullSecrets": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "ImagePullSecrets is a list of references to secrets in the same namespace to use for pulling any images in pods that reference this ServiceAccount. ImagePullSecrets are distinct from Secrets because Secrets can be mounted in the pod, but ImagePullSecrets are only accessed by the kubelet. More info: https://kubernetes.io/docs/concepts/containers/images/#specifying-imagepullsecrets-on-a-pod", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.LocalObjectReference{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "automountServiceAccountToken": { - SchemaProps: spec.SchemaProps{ - Description: "AutomountServiceAccountToken indicates whether pods running as this service account should have an API token automatically mounted. Can be overridden at the pod level.", - Type: []string{"boolean"}, - Format: "", - }, - }, - }, - }, - }, - Dependencies: []string{ - v1.LocalObjectReference{}.OpenAPIModelName(), v1.ObjectReference{}.OpenAPIModelName(), metav1.ObjectMeta{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_ServiceAccountList(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "ServiceAccountList is a list of ServiceAccount objects", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Type: []string{"string"}, - Format: "", - }, - }, - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", - Type: []string{"string"}, - Format: "", - }, - }, - "metadata": { - SchemaProps: spec.SchemaProps{ - Description: "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Default: map[string]interface{}{}, - Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), - }, - }, - "items": { - SchemaProps: spec.SchemaProps{ - Description: "List of ServiceAccounts. More info: https://kubernetes.io/docs/tasks/configure-pod-container/configure-service-account/", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.ServiceAccount{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - }, - Required: []string{"items"}, - }, - }, - Dependencies: []string{ - v1.ServiceAccount{}.OpenAPIModelName(), metav1.ListMeta{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_ServiceAccountTokenProjection(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "ServiceAccountTokenProjection represents a projected service account token volume. This projection can be used to insert a service account token into the pods runtime filesystem for use against APIs (Kubernetes API Server or otherwise).", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "audience": { - SchemaProps: spec.SchemaProps{ - Description: "audience is the intended audience of the token. A recipient of a token must identify itself with an identifier specified in the audience of the token, and otherwise should reject the token. The audience defaults to the identifier of the apiserver.", - Type: []string{"string"}, - Format: "", - }, - }, - "expirationSeconds": { - SchemaProps: spec.SchemaProps{ - Description: "expirationSeconds is the requested duration of validity of the service account token. As the token approaches expiration, the kubelet volume plugin will proactively rotate the service account token. The kubelet will start trying to rotate the token if the token is older than 80 percent of its time to live or if the token is older than 24 hours.Defaults to 1 hour and must be at least 10 minutes.", - Type: []string{"integer"}, - Format: "int64", - }, - }, - "path": { - SchemaProps: spec.SchemaProps{ - Description: "path is the path relative to the mount point of the file to project the token into.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - Required: []string{"path"}, - }, - }, - } -} - -func schema_k8sio_api_core_v1_ServiceList(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "ServiceList holds a list of services.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Type: []string{"string"}, - Format: "", - }, - }, - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", - Type: []string{"string"}, - Format: "", - }, - }, - "metadata": { - SchemaProps: spec.SchemaProps{ - Description: "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Default: map[string]interface{}{}, - Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), - }, - }, - "items": { - SchemaProps: spec.SchemaProps{ - Description: "List of services", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.Service{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - }, - Required: []string{"items"}, - }, - }, - Dependencies: []string{ - v1.Service{}.OpenAPIModelName(), metav1.ListMeta{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_ServicePort(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "ServicePort contains information on service's port.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "name": { - SchemaProps: spec.SchemaProps{ - Description: "The name of this port within the service. This must be a DNS_LABEL. All ports within a ServiceSpec must have unique names. When considering the endpoints for a Service, this must match the 'name' field in the EndpointPort. Optional if only one ServicePort is defined on this service.", - Type: []string{"string"}, - Format: "", - }, - }, - "protocol": { - SchemaProps: spec.SchemaProps{ - Description: "The IP protocol for this port. Supports \"TCP\", \"UDP\", and \"SCTP\". Default is TCP.\n\nPossible enum values:\n - `\"SCTP\"` is the SCTP protocol.\n - `\"TCP\"` is the TCP protocol.\n - `\"UDP\"` is the UDP protocol.", - Default: "TCP", - Type: []string{"string"}, - Format: "", - Enum: []interface{}{"SCTP", "TCP", "UDP"}, - }, - }, - "appProtocol": { - SchemaProps: spec.SchemaProps{ - Description: "The application protocol for this port. This is used as a hint for implementations to offer richer behavior for protocols that they understand. This field follows standard Kubernetes label syntax. Valid values are either:\n\n* Un-prefixed protocol names - reserved for IANA standard service names (as per RFC-6335 and https://www.iana.org/assignments/service-names).\n\n* Kubernetes-defined prefixed names:\n * 'kubernetes.io/h2c' - HTTP/2 prior knowledge over cleartext as described in https://www.rfc-editor.org/rfc/rfc9113.html#name-starting-http-2-with-prior-\n * 'kubernetes.io/ws' - WebSocket over cleartext as described in https://www.rfc-editor.org/rfc/rfc6455\n * 'kubernetes.io/wss' - WebSocket over TLS as described in https://www.rfc-editor.org/rfc/rfc6455\n\n* Other protocols should use implementation-defined prefixed names such as mycompany.com/my-custom-protocol.", - Type: []string{"string"}, - Format: "", - }, - }, - "port": { - SchemaProps: spec.SchemaProps{ - Description: "The port that will be exposed by this service.", - Default: 0, - Type: []string{"integer"}, - Format: "int32", - }, - }, - "targetPort": { - SchemaProps: spec.SchemaProps{ - Description: "Number or name of the port to access on the pods targeted by the service. Number must be in the range 1 to 65535. Name must be an IANA_SVC_NAME. If this is a string, it will be looked up as a named port in the target Pod's container ports. If this is not specified, the value of the 'port' field is used (an identity map). This field is ignored for services with clusterIP=None, and should be omitted or set equal to the 'port' field. More info: https://kubernetes.io/docs/concepts/services-networking/service/#defining-a-service", - Ref: ref("k8s.io/apimachinery/pkg/util/intstr.IntOrString"), - }, - }, - "nodePort": { - SchemaProps: spec.SchemaProps{ - Description: "The port on each node on which this service is exposed when type is NodePort or LoadBalancer. Usually assigned by the system. If a value is specified, in-range, and not in use it will be used, otherwise the operation will fail. If not specified, a port will be allocated if this Service requires one. If this field is specified when creating a Service which does not need it, creation will fail. This field will be wiped when updating a Service to no longer need it (e.g. changing type from NodePort to ClusterIP). More info: https://kubernetes.io/docs/concepts/services-networking/service/#type-nodeport", - Type: []string{"integer"}, - Format: "int32", - }, - }, - }, - Required: []string{"port"}, - }, - }, - Dependencies: []string{ - "k8s.io/apimachinery/pkg/util/intstr.IntOrString"}, - } -} - -func schema_k8sio_api_core_v1_ServiceProxyOptions(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "ServiceProxyOptions is the query options to a Service's proxy call.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Type: []string{"string"}, - Format: "", - }, - }, - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", - Type: []string{"string"}, - Format: "", - }, - }, - "path": { - SchemaProps: spec.SchemaProps{ - Description: "Path is the part of URLs that include service endpoints, suffixes, and parameters to use for the current proxy request to service. For example, the whole request URL is http://localhost/api/v1/namespaces/kube-system/services/elasticsearch-logging/_search?q=user:kimchy. Path is _search?q=user:kimchy.", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - } -} - -func schema_k8sio_api_core_v1_ServiceSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "ServiceSpec describes the attributes that a user creates on a service.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "ports": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-map-keys": []interface{}{ - "port", - "protocol", - }, - "x-kubernetes-list-type": "map", - "x-kubernetes-patch-merge-key": "port", - "x-kubernetes-patch-strategy": "merge", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "The list of ports that are exposed by this service. More info: https://kubernetes.io/docs/concepts/services-networking/service/#virtual-ips-and-service-proxies", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.ServicePort{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "selector": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-map-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "Route service traffic to pods with label keys and values matching this selector. If empty or not present, the service is assumed to have an external process managing its endpoints, which Kubernetes will not modify. Only applies to types ClusterIP, NodePort, and LoadBalancer. Ignored if type is ExternalName. More info: https://kubernetes.io/docs/concepts/services-networking/service/", - Type: []string{"object"}, - AdditionalProperties: &spec.SchemaOrBool{ - Allows: true, - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - "clusterIP": { - SchemaProps: spec.SchemaProps{ - Description: "clusterIP is the IP address of the service and is usually assigned randomly. If an address is specified manually, is in-range (as per system configuration), and is not in use, it will be allocated to the service; otherwise creation of the service will fail. This field may not be changed through updates unless the type field is also being changed to ExternalName (which requires this field to be blank) or the type field is being changed from ExternalName (in which case this field may optionally be specified, as describe above). Valid values are \"None\", empty string (\"\"), or a valid IP address. Setting this to \"None\" makes a \"headless service\" (no virtual IP), which is useful when direct endpoint connections are preferred and proxying is not required. Only applies to types ClusterIP, NodePort, and LoadBalancer. If this field is specified when creating a Service of type ExternalName, creation will fail. This field will be wiped when updating a Service to type ExternalName. More info: https://kubernetes.io/docs/concepts/services-networking/service/#virtual-ips-and-service-proxies", - Type: []string{"string"}, - Format: "", - }, - }, - "clusterIPs": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "ClusterIPs is a list of IP addresses assigned to this service, and are usually assigned randomly. If an address is specified manually, is in-range (as per system configuration), and is not in use, it will be allocated to the service; otherwise creation of the service will fail. This field may not be changed through updates unless the type field is also being changed to ExternalName (which requires this field to be empty) or the type field is being changed from ExternalName (in which case this field may optionally be specified, as describe above). Valid values are \"None\", empty string (\"\"), or a valid IP address. Setting this to \"None\" makes a \"headless service\" (no virtual IP), which is useful when direct endpoint connections are preferred and proxying is not required. Only applies to types ClusterIP, NodePort, and LoadBalancer. If this field is specified when creating a Service of type ExternalName, creation will fail. This field will be wiped when updating a Service to type ExternalName. If this field is not specified, it will be initialized from the clusterIP field. If this field is specified, clients must ensure that clusterIPs[0] and clusterIP have the same value.\n\nThis field may hold a maximum of two entries (dual-stack IPs, in either order). These IPs must correspond to the values of the ipFamilies field. Both clusterIPs and ipFamilies are governed by the ipFamilyPolicy field. More info: https://kubernetes.io/docs/concepts/services-networking/service/#virtual-ips-and-service-proxies", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - "type": { - SchemaProps: spec.SchemaProps{ - Description: "type determines how the Service is exposed. Defaults to ClusterIP. Valid options are ExternalName, ClusterIP, NodePort, and LoadBalancer. \"ClusterIP\" allocates a cluster-internal IP address for load-balancing to endpoints. Endpoints are determined by the selector or if that is not specified, by manual construction of an Endpoints object or EndpointSlice objects. If clusterIP is \"None\", no virtual IP is allocated and the endpoints are published as a set of endpoints rather than a virtual IP. \"NodePort\" builds on ClusterIP and allocates a port on every node which routes to the same endpoints as the clusterIP. \"LoadBalancer\" builds on NodePort and creates an external load-balancer (if supported in the current cloud) which routes to the same endpoints as the clusterIP. \"ExternalName\" aliases this service to the specified externalName. Several other fields do not apply to ExternalName services. More info: https://kubernetes.io/docs/concepts/services-networking/service/#publishing-services-service-types\n\nPossible enum values:\n - `\"ClusterIP\"` means a service will only be accessible inside the cluster, via the cluster IP.\n - `\"ExternalName\"` means a service consists of only a reference to an external name that kubedns or equivalent will return as a CNAME record, with no exposing or proxying of any pods involved.\n - `\"LoadBalancer\"` means a service will be exposed via an external load balancer (if the cloud provider supports it), in addition to 'NodePort' type.\n - `\"NodePort\"` means a service will be exposed on one port of every node, in addition to 'ClusterIP' type.", - Type: []string{"string"}, - Format: "", - Enum: []interface{}{"ClusterIP", "ExternalName", "LoadBalancer", "NodePort"}, - }, - }, - "externalIPs": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "externalIPs is a list of IP addresses for which nodes in the cluster will also accept traffic for this service. These IPs are not managed by Kubernetes. The user is responsible for ensuring that traffic arrives at a node with this IP. A common example is external load-balancers that are not part of the Kubernetes system.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - "sessionAffinity": { - SchemaProps: spec.SchemaProps{ - Description: "Supports \"ClientIP\" and \"None\". Used to maintain session affinity. Enable client IP based session affinity. Must be ClientIP or None. Defaults to None. More info: https://kubernetes.io/docs/concepts/services-networking/service/#virtual-ips-and-service-proxies\n\nPossible enum values:\n - `\"ClientIP\"` is the Client IP based.\n - `\"None\"` - no session affinity.", - Type: []string{"string"}, - Format: "", - Enum: []interface{}{"ClientIP", "None"}, - }, - }, - "loadBalancerIP": { - SchemaProps: spec.SchemaProps{ - Description: "Only applies to Service Type: LoadBalancer. This feature depends on whether the underlying cloud-provider supports specifying the loadBalancerIP when a load balancer is created. This field will be ignored if the cloud-provider does not support the feature. Deprecated: This field was under-specified and its meaning varies across implementations. Using it is non-portable and it may not support dual-stack. Users are encouraged to use implementation-specific annotations when available.", - Type: []string{"string"}, - Format: "", - }, - }, - "loadBalancerSourceRanges": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "If specified and supported by the platform, this will restrict traffic through the cloud-provider load-balancer will be restricted to the specified client IPs. This field will be ignored if the cloud-provider does not support the feature.\" More info: https://kubernetes.io/docs/tasks/access-application-cluster/create-external-load-balancer/", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - "externalName": { - SchemaProps: spec.SchemaProps{ - Description: "externalName is the external reference that discovery mechanisms will return as an alias for this service (e.g. a DNS CNAME record). No proxying will be involved. Must be a lowercase RFC-1123 hostname (https://tools.ietf.org/html/rfc1123) and requires `type` to be \"ExternalName\".", - Type: []string{"string"}, - Format: "", - }, - }, - "externalTrafficPolicy": { - SchemaProps: spec.SchemaProps{ - Description: "externalTrafficPolicy describes how nodes distribute service traffic they receive on one of the Service's \"externally-facing\" addresses (NodePorts, ExternalIPs, and LoadBalancer IPs). If set to \"Local\", the proxy will configure the service in a way that assumes that external load balancers will take care of balancing the service traffic between nodes, and so each node will deliver traffic only to the node-local endpoints of the service, without masquerading the client source IP. (Traffic mistakenly sent to a node with no endpoints will be dropped.) The default value, \"Cluster\", uses the standard behavior of routing to all endpoints evenly (possibly modified by topology and other features). Note that traffic sent to an External IP or LoadBalancer IP from within the cluster will always get \"Cluster\" semantics, but clients sending to a NodePort from within the cluster may need to take traffic policy into account when picking a node.\n\nPossible enum values:\n - `\"Cluster\"` routes traffic to all endpoints.\n - `\"Local\"` preserves the source IP of the traffic by routing only to endpoints on the same node as the traffic was received on (dropping the traffic if there are no local endpoints).", - Type: []string{"string"}, - Format: "", - Enum: []interface{}{"Cluster", "Local"}, - }, - }, - "healthCheckNodePort": { - SchemaProps: spec.SchemaProps{ - Description: "healthCheckNodePort specifies the healthcheck nodePort for the service. This only applies when type is set to LoadBalancer and externalTrafficPolicy is set to Local. If a value is specified, is in-range, and is not in use, it will be used. If not specified, a value will be automatically allocated. External systems (e.g. load-balancers) can use this port to determine if a given node holds endpoints for this service or not. If this field is specified when creating a Service which does not need it, creation will fail. This field will be wiped when updating a Service to no longer need it (e.g. changing type). This field cannot be updated once set.", - Type: []string{"integer"}, - Format: "int32", - }, - }, - "publishNotReadyAddresses": { - SchemaProps: spec.SchemaProps{ - Description: "publishNotReadyAddresses indicates that any agent which deals with endpoints for this Service should disregard any indications of ready/not-ready. The primary use case for setting this field is for a StatefulSet's Headless Service to propagate SRV DNS records for its Pods for the purpose of peer discovery. The Kubernetes controllers that generate Endpoints and EndpointSlice resources for Services interpret this to mean that all endpoints are considered \"ready\" even if the Pods themselves are not. Agents which consume only Kubernetes generated endpoints through the Endpoints or EndpointSlice resources can safely assume this behavior.", - Type: []string{"boolean"}, - Format: "", - }, - }, - "sessionAffinityConfig": { - SchemaProps: spec.SchemaProps{ - Description: "sessionAffinityConfig contains the configurations of session affinity.", - Ref: ref(v1.SessionAffinityConfig{}.OpenAPIModelName()), - }, - }, - "ipFamilies": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "IPFamilies is a list of IP families (e.g. IPv4, IPv6) assigned to this service. This field is usually assigned automatically based on cluster configuration and the ipFamilyPolicy field. If this field is specified manually, the requested family is available in the cluster, and ipFamilyPolicy allows it, it will be used; otherwise creation of the service will fail. This field is conditionally mutable: it allows for adding or removing a secondary IP family, but it does not allow changing the primary IP family of the Service. Valid values are \"IPv4\" and \"IPv6\". This field only applies to Services of types ClusterIP, NodePort, and LoadBalancer, and does apply to \"headless\" services. This field will be wiped when updating a Service to type ExternalName.\n\nThis field may hold a maximum of two entries (dual-stack families, in either order). These families must correspond to the values of the clusterIPs field, if specified. Both clusterIPs and ipFamilies are governed by the ipFamilyPolicy field.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - Enum: []interface{}{"", "IPv4", "IPv6"}, - }, - }, - }, - }, - }, - "ipFamilyPolicy": { - SchemaProps: spec.SchemaProps{ - Description: "IPFamilyPolicy represents the dual-stack-ness requested or required by this Service. If there is no value provided, then this field will be set to SingleStack. Services can be \"SingleStack\" (a single IP family), \"PreferDualStack\" (two IP families on dual-stack configured clusters or a single IP family on single-stack clusters), or \"RequireDualStack\" (two IP families on dual-stack configured clusters, otherwise fail). The ipFamilies and clusterIPs fields depend on the value of this field. This field will be wiped when updating a service to type ExternalName.\n\nPossible enum values:\n - `\"PreferDualStack\"` indicates that this service prefers dual-stack when the cluster is configured for dual-stack. If the cluster is not configured for dual-stack the service will be assigned a single IPFamily. If the IPFamily is not set in service.spec.ipFamilies then the service will be assigned the default IPFamily configured on the cluster\n - `\"RequireDualStack\"` indicates that this service requires dual-stack. Using IPFamilyPolicyRequireDualStack on a single stack cluster will result in validation errors. The IPFamilies (and their order) assigned to this service is based on service.spec.ipFamilies. If service.spec.ipFamilies was not provided then it will be assigned according to how they are configured on the cluster. If service.spec.ipFamilies has only one entry then the alternative IPFamily will be added by apiserver\n - `\"SingleStack\"` indicates that this service is required to have a single IPFamily. The IPFamily assigned is based on the default IPFamily used by the cluster or as identified by service.spec.ipFamilies field", - Type: []string{"string"}, - Format: "", - Enum: []interface{}{"PreferDualStack", "RequireDualStack", "SingleStack"}, - }, - }, - "allocateLoadBalancerNodePorts": { - SchemaProps: spec.SchemaProps{ - Description: "allocateLoadBalancerNodePorts defines if NodePorts will be automatically allocated for services with type LoadBalancer. Default is \"true\". It may be set to \"false\" if the cluster load-balancer does not rely on NodePorts. If the caller requests specific NodePorts (by specifying a value), those requests will be respected, regardless of this field. This field may only be set for services with type LoadBalancer and will be cleared if the type is changed to any other type.", - Type: []string{"boolean"}, - Format: "", - }, - }, - "loadBalancerClass": { - SchemaProps: spec.SchemaProps{ - Description: "loadBalancerClass is the class of the load balancer implementation this Service belongs to. If specified, the value of this field must be a label-style identifier, with an optional prefix, e.g. \"internal-vip\" or \"example.com/internal-vip\". Unprefixed names are reserved for end-users. This field can only be set when the Service type is 'LoadBalancer'. If not set, the default load balancer implementation is used, today this is typically done through the cloud provider integration, but should apply for any default implementation. If set, it is assumed that a load balancer implementation is watching for Services with a matching class. Any default load balancer implementation (e.g. cloud providers) should ignore Services that set this field. This field can only be set when creating or updating a Service to type 'LoadBalancer'. Once set, it can not be changed. This field will be wiped when a service is updated to a non 'LoadBalancer' type.", - Type: []string{"string"}, - Format: "", - }, - }, - "internalTrafficPolicy": { - SchemaProps: spec.SchemaProps{ - Description: "InternalTrafficPolicy describes how nodes distribute service traffic they receive on the ClusterIP. If set to \"Local\", the proxy will assume that pods only want to talk to endpoints of the service on the same node as the pod, dropping the traffic if there are no local endpoints. The default value, \"Cluster\", uses the standard behavior of routing to all endpoints evenly (possibly modified by topology and other features).\n\nPossible enum values:\n - `\"Cluster\"` routes traffic to all endpoints.\n - `\"Local\"` routes traffic only to endpoints on the same node as the client pod (dropping the traffic if there are no local endpoints).", - Type: []string{"string"}, - Format: "", - Enum: []interface{}{"Cluster", "Local"}, - }, - }, - "trafficDistribution": { - SchemaProps: spec.SchemaProps{ - Description: "TrafficDistribution offers a way to express preferences for how traffic is distributed to Service endpoints. Implementations can use this field as a hint, but are not required to guarantee strict adherence. If the field is not set, the implementation will apply its default routing strategy. If set to \"PreferClose\", implementations should prioritize endpoints that are in the same zone.", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - Dependencies: []string{ - v1.ServicePort{}.OpenAPIModelName(), v1.SessionAffinityConfig{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_ServiceStatus(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "ServiceStatus represents the current status of a service.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "loadBalancer": { - SchemaProps: spec.SchemaProps{ - Description: "LoadBalancer contains the current status of the load-balancer, if one is present.", - Default: map[string]interface{}{}, - Ref: ref(v1.LoadBalancerStatus{}.OpenAPIModelName()), - }, - }, - "conditions": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-map-keys": []interface{}{ - "type", - }, - "x-kubernetes-list-type": "map", - "x-kubernetes-patch-merge-key": "type", - "x-kubernetes-patch-strategy": "merge", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "Current service state", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(metav1.Condition{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - }, - }, - }, - Dependencies: []string{ - v1.LoadBalancerStatus{}.OpenAPIModelName(), metav1.Condition{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_SessionAffinityConfig(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "SessionAffinityConfig represents the configurations of session affinity.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "clientIP": { - SchemaProps: spec.SchemaProps{ - Description: "clientIP contains the configurations of Client IP based session affinity.", - Ref: ref(v1.ClientIPConfig{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - Dependencies: []string{ - v1.ClientIPConfig{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_SleepAction(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "SleepAction describes a \"sleep\" action.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "seconds": { - SchemaProps: spec.SchemaProps{ - Description: "Seconds is the number of seconds to sleep.", - Default: 0, - Type: []string{"integer"}, - Format: "int64", - }, - }, - }, - Required: []string{"seconds"}, - }, - }, - } -} - -func schema_k8sio_api_core_v1_StorageOSPersistentVolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "Represents a StorageOS persistent volume resource.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "volumeName": { - SchemaProps: spec.SchemaProps{ - Description: "volumeName is the human-readable name of the StorageOS volume. Volume names are only unique within a namespace.", - Type: []string{"string"}, - Format: "", - }, - }, - "volumeNamespace": { - SchemaProps: spec.SchemaProps{ - Description: "volumeNamespace specifies the scope of the volume within StorageOS. If no namespace is specified then the Pod's namespace will be used. This allows the Kubernetes name scoping to be mirrored within StorageOS for tighter integration. Set VolumeName to any name to override the default behaviour. Set to \"default\" if you are not using namespaces within StorageOS. Namespaces that do not pre-exist within StorageOS will be created.", - Type: []string{"string"}, - Format: "", - }, - }, - "fsType": { - SchemaProps: spec.SchemaProps{ - Description: "fsType is the filesystem type to mount. Must be a filesystem type supported by the host operating system. Ex. \"ext4\", \"xfs\", \"ntfs\". Implicitly inferred to be \"ext4\" if unspecified.", - Type: []string{"string"}, - Format: "", - }, - }, - "readOnly": { - SchemaProps: spec.SchemaProps{ - Description: "readOnly defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts.", - Type: []string{"boolean"}, - Format: "", - }, - }, - "secretRef": { - SchemaProps: spec.SchemaProps{ - Description: "secretRef specifies the secret to use for obtaining the StorageOS API credentials. If not specified, default values will be attempted.", - Ref: ref(v1.ObjectReference{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - Dependencies: []string{ - v1.ObjectReference{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_StorageOSVolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "Represents a StorageOS persistent volume resource.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "volumeName": { - SchemaProps: spec.SchemaProps{ - Description: "volumeName is the human-readable name of the StorageOS volume. Volume names are only unique within a namespace.", - Type: []string{"string"}, - Format: "", - }, - }, - "volumeNamespace": { - SchemaProps: spec.SchemaProps{ - Description: "volumeNamespace specifies the scope of the volume within StorageOS. If no namespace is specified then the Pod's namespace will be used. This allows the Kubernetes name scoping to be mirrored within StorageOS for tighter integration. Set VolumeName to any name to override the default behaviour. Set to \"default\" if you are not using namespaces within StorageOS. Namespaces that do not pre-exist within StorageOS will be created.", - Type: []string{"string"}, - Format: "", - }, - }, - "fsType": { - SchemaProps: spec.SchemaProps{ - Description: "fsType is the filesystem type to mount. Must be a filesystem type supported by the host operating system. Ex. \"ext4\", \"xfs\", \"ntfs\". Implicitly inferred to be \"ext4\" if unspecified.", - Type: []string{"string"}, - Format: "", - }, - }, - "readOnly": { - SchemaProps: spec.SchemaProps{ - Description: "readOnly defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts.", - Type: []string{"boolean"}, - Format: "", - }, - }, - "secretRef": { - SchemaProps: spec.SchemaProps{ - Description: "secretRef specifies the secret to use for obtaining the StorageOS API credentials. If not specified, default values will be attempted.", - Ref: ref(v1.LocalObjectReference{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - Dependencies: []string{ - v1.LocalObjectReference{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_Sysctl(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "Sysctl defines a kernel parameter to be set", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "name": { - SchemaProps: spec.SchemaProps{ - Description: "Name of a property to set", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "value": { - SchemaProps: spec.SchemaProps{ - Description: "Value of a property to set", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - Required: []string{"name", "value"}, - }, - }, - } -} - -func schema_k8sio_api_core_v1_TCPSocketAction(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "TCPSocketAction describes an action based on opening a socket", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "port": { - SchemaProps: spec.SchemaProps{ - Description: "Number or name of the port to access on the container. Number must be in the range 1 to 65535. Name must be an IANA_SVC_NAME.", - Ref: ref("k8s.io/apimachinery/pkg/util/intstr.IntOrString"), - }, - }, - "host": { - SchemaProps: spec.SchemaProps{ - Description: "Optional: Host name to connect to, defaults to the pod IP.", - Type: []string{"string"}, - Format: "", - }, - }, - }, - Required: []string{"port"}, - }, - }, - Dependencies: []string{ - "k8s.io/apimachinery/pkg/util/intstr.IntOrString"}, - } -} - -func schema_k8sio_api_core_v1_Taint(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "The node this Taint is attached to has the \"effect\" on any pod that does not tolerate the Taint.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "key": { - SchemaProps: spec.SchemaProps{ - Description: "Required. The taint key to be applied to a node.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "value": { - SchemaProps: spec.SchemaProps{ - Description: "The taint value corresponding to the taint key.", - Type: []string{"string"}, - Format: "", - }, - }, - "effect": { - SchemaProps: spec.SchemaProps{ - Description: "Required. The effect of the taint on pods that do not tolerate the taint. Valid effects are NoSchedule, PreferNoSchedule and NoExecute.\n\nPossible enum values:\n - `\"NoExecute\"` Evict any already-running pods that do not tolerate the taint. Currently enforced by NodeController.\n - `\"NoSchedule\"` Do not allow new pods to schedule onto the node unless they tolerate the taint, but allow all pods submitted to Kubelet without going through the scheduler to start, and allow all already-running pods to continue running. Enforced by the scheduler.\n - `\"PreferNoSchedule\"` Like TaintEffectNoSchedule, but the scheduler tries not to schedule new pods onto the node, rather than prohibiting new pods from scheduling onto the node entirely. Enforced by the scheduler.", - Default: "", - Type: []string{"string"}, - Format: "", - Enum: []interface{}{"NoExecute", "NoSchedule", "PreferNoSchedule"}, - }, - }, - "timeAdded": { - SchemaProps: spec.SchemaProps{ - Description: "TimeAdded represents the time at which the taint was added.", - Ref: ref(metav1.Time{}.OpenAPIModelName()), - }, - }, - }, - Required: []string{"key", "effect"}, - }, - }, - Dependencies: []string{ - metav1.Time{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_Toleration(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "The pod this Toleration is attached to tolerates any taint that matches the triple using the matching operator .", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "key": { - SchemaProps: spec.SchemaProps{ - Description: "Key is the taint key that the toleration applies to. Empty means match all taint keys. If the key is empty, operator must be Exists; this combination means to match all values and all keys.", - Type: []string{"string"}, - Format: "", - }, - }, - "operator": { - SchemaProps: spec.SchemaProps{ - Description: "Operator represents a key's relationship to the value. Valid operators are Exists, Equal, Lt, and Gt. Defaults to Equal. Exists is equivalent to wildcard for value, so that a pod can tolerate all taints of a particular category. Lt and Gt perform numeric comparisons (requires feature gate TaintTolerationComparisonOperators).\n\nPossible enum values:\n - `\"Equal\"`\n - `\"Exists\"`\n - `\"Gt\"`\n - `\"Lt\"`", - Type: []string{"string"}, - Format: "", - Enum: []interface{}{"Equal", "Exists", "Gt", "Lt"}, - }, - }, - "value": { - SchemaProps: spec.SchemaProps{ - Description: "Value is the taint value the toleration matches to. If the operator is Exists, the value should be empty, otherwise just a regular string.", - Type: []string{"string"}, - Format: "", - }, - }, - "effect": { - SchemaProps: spec.SchemaProps{ - Description: "Effect indicates the taint effect to match. Empty means match all taint effects. When specified, allowed values are NoSchedule, PreferNoSchedule and NoExecute.\n\nPossible enum values:\n - `\"NoExecute\"` Evict any already-running pods that do not tolerate the taint. Currently enforced by NodeController.\n - `\"NoSchedule\"` Do not allow new pods to schedule onto the node unless they tolerate the taint, but allow all pods submitted to Kubelet without going through the scheduler to start, and allow all already-running pods to continue running. Enforced by the scheduler.\n - `\"PreferNoSchedule\"` Like TaintEffectNoSchedule, but the scheduler tries not to schedule new pods onto the node, rather than prohibiting new pods from scheduling onto the node entirely. Enforced by the scheduler.", - Type: []string{"string"}, - Format: "", - Enum: []interface{}{"NoExecute", "NoSchedule", "PreferNoSchedule"}, - }, - }, - "tolerationSeconds": { - SchemaProps: spec.SchemaProps{ - Description: "TolerationSeconds represents the period of time the toleration (which must be of effect NoExecute, otherwise this field is ignored) tolerates the taint. By default, it is not set, which means tolerate the taint forever (do not evict). Zero and negative values will be treated as 0 (evict immediately) by the system.", - Type: []string{"integer"}, - Format: "int64", - }, - }, - }, - }, - }, - } -} - -func schema_k8sio_api_core_v1_TopologySelectorLabelRequirement(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "A topology selector requirement is a selector that matches given label. This is an alpha feature and may change in the future.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "key": { - SchemaProps: spec.SchemaProps{ - Description: "The label key that the selector applies to.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "values": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "An array of string values. One value must match the label to be selected. Each entry in Values is ORed.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - }, - Required: []string{"key", "values"}, - }, - }, - } -} - -func schema_k8sio_api_core_v1_TopologySelectorTerm(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "A topology selector term represents the result of label queries. A null or empty topology selector term matches no objects. The requirements of them are ANDed. It provides a subset of functionality as NodeSelectorTerm. This is an alpha feature and may change in the future.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "matchLabelExpressions": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "A list of topology selector requirements by labels.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(v1.TopologySelectorLabelRequirement{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - }, - }, - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-map-type": "atomic", - }, - }, - }, - Dependencies: []string{ - v1.TopologySelectorLabelRequirement{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_TopologySpreadConstraint(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "TopologySpreadConstraint specifies how to spread matching pods among the given topology.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "maxSkew": { - SchemaProps: spec.SchemaProps{ - Description: "MaxSkew describes the degree to which pods may be unevenly distributed. When `whenUnsatisfiable=DoNotSchedule`, it is the maximum permitted difference between the number of matching pods in the target topology and the global minimum. The global minimum is the minimum number of matching pods in an eligible domain or zero if the number of eligible domains is less than MinDomains. For example, in a 3-zone cluster, MaxSkew is set to 1, and pods with the same labelSelector spread as 2/2/1: In this case, the global minimum is 1. | zone1 | zone2 | zone3 | | P P | P P | P | - if MaxSkew is 1, incoming pod can only be scheduled to zone3 to become 2/2/2; scheduling it onto zone1(zone2) would make the ActualSkew(3-1) on zone1(zone2) violate MaxSkew(1). - if MaxSkew is 2, incoming pod can be scheduled onto any zone. When `whenUnsatisfiable=ScheduleAnyway`, it is used to give higher precedence to topologies that satisfy it. It's a required field. Default value is 1 and 0 is not allowed.", - Default: 0, - Type: []string{"integer"}, - Format: "int32", - }, - }, - "topologyKey": { - SchemaProps: spec.SchemaProps{ - Description: "TopologyKey is the key of node labels. Nodes that have a label with this key and identical values are considered to be in the same topology. We consider each as a \"bucket\", and try to put balanced number of pods into each bucket. We define a domain as a particular instance of a topology. Also, we define an eligible domain as a domain whose nodes meet the requirements of nodeAffinityPolicy and nodeTaintsPolicy. e.g. If TopologyKey is \"kubernetes.io/hostname\", each Node is a domain of that topology. And, if TopologyKey is \"topology.kubernetes.io/zone\", each zone is a domain of that topology. It's a required field.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "whenUnsatisfiable": { - SchemaProps: spec.SchemaProps{ - Description: "WhenUnsatisfiable indicates how to deal with a pod if it doesn't satisfy the spread constraint. - DoNotSchedule (default) tells the scheduler not to schedule it. - ScheduleAnyway tells the scheduler to schedule the pod in any location,\n but giving higher precedence to topologies that would help reduce the\n skew.\nA constraint is considered \"Unsatisfiable\" for an incoming pod if and only if every possible node assignment for that pod would violate \"MaxSkew\" on some topology. For example, in a 3-zone cluster, MaxSkew is set to 1, and pods with the same labelSelector spread as 3/1/1: | zone1 | zone2 | zone3 | | P P P | P | P | If WhenUnsatisfiable is set to DoNotSchedule, incoming pod can only be scheduled to zone2(zone3) to become 3/2/1(3/1/2) as ActualSkew(2-1) on zone2(zone3) satisfies MaxSkew(1). In other words, the cluster can still be imbalanced, but scheduler won't make it *more* imbalanced. It's a required field.\n\nPossible enum values:\n - `\"DoNotSchedule\"` instructs the scheduler not to schedule the pod when constraints are not satisfied.\n - `\"ScheduleAnyway\"` instructs the scheduler to schedule the pod even if constraints are not satisfied.", - Default: "", - Type: []string{"string"}, - Format: "", - Enum: []interface{}{"DoNotSchedule", "ScheduleAnyway"}, - }, - }, - "labelSelector": { - SchemaProps: spec.SchemaProps{ - Description: "LabelSelector is used to find matching pods. Pods that match this label selector are counted to determine the number of pods in their corresponding topology domain.", - Ref: ref(metav1.LabelSelector{}.OpenAPIModelName()), - }, - }, - "minDomains": { - SchemaProps: spec.SchemaProps{ - Description: "MinDomains indicates a minimum number of eligible domains. When the number of eligible domains with matching topology keys is less than minDomains, Pod Topology Spread treats \"global minimum\" as 0, and then the calculation of Skew is performed. And when the number of eligible domains with matching topology keys equals or greater than minDomains, this value has no effect on scheduling. As a result, when the number of eligible domains is less than minDomains, scheduler won't schedule more than maxSkew Pods to those domains. If value is nil, the constraint behaves as if MinDomains is equal to 1. Valid values are integers greater than 0. When value is not nil, WhenUnsatisfiable must be DoNotSchedule.\n\nFor example, in a 3-zone cluster, MaxSkew is set to 2, MinDomains is set to 5 and pods with the same labelSelector spread as 2/2/2: | zone1 | zone2 | zone3 | | P P | P P | P P | The number of domains is less than 5(MinDomains), so \"global minimum\" is treated as 0. In this situation, new pod with the same labelSelector cannot be scheduled, because computed skew will be 3(3 - 0) if new Pod is scheduled to any of the three zones, it will violate MaxSkew.", - Type: []string{"integer"}, - Format: "int32", - }, - }, - "nodeAffinityPolicy": { - SchemaProps: spec.SchemaProps{ - Description: "NodeAffinityPolicy indicates how we will treat Pod's nodeAffinity/nodeSelector when calculating pod topology spread skew. Options are: - Honor: only nodes matching nodeAffinity/nodeSelector are included in the calculations. - Ignore: nodeAffinity/nodeSelector are ignored. All nodes are included in the calculations.\n\nIf this value is nil, the behavior is equivalent to the Honor policy.\n\nPossible enum values:\n - `\"Honor\"` means use this scheduling directive when calculating pod topology spread skew.\n - `\"Ignore\"` means ignore this scheduling directive when calculating pod topology spread skew.", - Type: []string{"string"}, - Format: "", - Enum: []interface{}{"Honor", "Ignore"}, - }, - }, - "nodeTaintsPolicy": { - SchemaProps: spec.SchemaProps{ - Description: "NodeTaintsPolicy indicates how we will treat node taints when calculating pod topology spread skew. Options are: - Honor: nodes without taints, along with tainted nodes for which the incoming pod has a toleration, are included. - Ignore: node taints are ignored. All nodes are included.\n\nIf this value is nil, the behavior is equivalent to the Ignore policy.\n\nPossible enum values:\n - `\"Honor\"` means use this scheduling directive when calculating pod topology spread skew.\n - `\"Ignore\"` means ignore this scheduling directive when calculating pod topology spread skew.", - Type: []string{"string"}, - Format: "", - Enum: []interface{}{"Honor", "Ignore"}, - }, - }, - "matchLabelKeys": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "MatchLabelKeys is a set of pod label keys to select the pods over which spreading will be calculated. The keys are used to lookup values from the incoming pod labels, those key-value labels are ANDed with labelSelector to select the group of existing pods over which spreading will be calculated for the incoming pod. The same key is forbidden to exist in both MatchLabelKeys and LabelSelector. MatchLabelKeys cannot be set when LabelSelector isn't set. Keys that don't exist in the incoming pod labels will be ignored. A null or empty list means only match against labelSelector.\n\nThis is a beta field and requires the MatchLabelKeysInPodTopologySpread feature gate to be enabled (enabled by default).", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - }, - Required: []string{"maxSkew", "topologyKey", "whenUnsatisfiable"}, - }, - }, - Dependencies: []string{ - metav1.LabelSelector{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_TypedLocalObjectReference(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "TypedLocalObjectReference contains enough information to let you locate the typed referenced object inside the same namespace.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "apiGroup": { - SchemaProps: spec.SchemaProps{ - Description: "APIGroup is the group for the resource being referenced. If APIGroup is not specified, the specified Kind must be in the core API group. For any other third-party types, APIGroup is required.", - Type: []string{"string"}, - Format: "", - }, - }, - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind is the type of resource being referenced", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "name": { - SchemaProps: spec.SchemaProps{ - Description: "Name is the name of resource being referenced", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - Required: []string{"kind", "name"}, - }, - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-map-type": "atomic", - }, - }, - }, - } -} - -func schema_k8sio_api_core_v1_TypedObjectReference(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "TypedObjectReference contains enough information to let you locate the typed referenced object", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "apiGroup": { - SchemaProps: spec.SchemaProps{ - Description: "APIGroup is the group for the resource being referenced. If APIGroup is not specified, the specified Kind must be in the core API group. For any other third-party types, APIGroup is required.", - Type: []string{"string"}, - Format: "", - }, - }, - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind is the type of resource being referenced", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "name": { - SchemaProps: spec.SchemaProps{ - Description: "Name is the name of resource being referenced", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "namespace": { - SchemaProps: spec.SchemaProps{ - Description: "Namespace is the namespace of resource being referenced Note that when a namespace is specified, a gateway.networking.k8s.io/ReferenceGrant object is required in the referent namespace to allow that namespace's owner to accept the reference. See the ReferenceGrant documentation for details. (Alpha) This field requires the CrossNamespaceVolumeDataSource feature gate to be enabled.", - Type: []string{"string"}, - Format: "", - }, - }, - }, - Required: []string{"kind", "name"}, - }, - }, - } -} - -func schema_k8sio_api_core_v1_Volume(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "Volume represents a named volume in a pod that may be accessed by any container in the pod.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "name": { - SchemaProps: spec.SchemaProps{ - Description: "name of the volume. Must be a DNS_LABEL and unique within the pod. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "hostPath": { - SchemaProps: spec.SchemaProps{ - Description: "hostPath represents a pre-existing file or directory on the host machine that is directly exposed to the container. This is generally used for system agents or other privileged things that are allowed to see the host machine. Most containers will NOT need this. More info: https://kubernetes.io/docs/concepts/storage/volumes#hostpath", - Ref: ref(v1.HostPathVolumeSource{}.OpenAPIModelName()), - }, - }, - "emptyDir": { - SchemaProps: spec.SchemaProps{ - Description: "emptyDir represents a temporary directory that shares a pod's lifetime. More info: https://kubernetes.io/docs/concepts/storage/volumes#emptydir", - Ref: ref(v1.EmptyDirVolumeSource{}.OpenAPIModelName()), - }, - }, - "gcePersistentDisk": { - SchemaProps: spec.SchemaProps{ - Description: "gcePersistentDisk represents a GCE Disk resource that is attached to a kubelet's host machine and then exposed to the pod. Deprecated: GCEPersistentDisk is deprecated. All operations for the in-tree gcePersistentDisk type are redirected to the pd.csi.storage.gke.io CSI driver. More info: https://kubernetes.io/docs/concepts/storage/volumes#gcepersistentdisk", - Ref: ref(v1.GCEPersistentDiskVolumeSource{}.OpenAPIModelName()), - }, - }, - "awsElasticBlockStore": { - SchemaProps: spec.SchemaProps{ - Description: "awsElasticBlockStore represents an AWS Disk resource that is attached to a kubelet's host machine and then exposed to the pod. Deprecated: AWSElasticBlockStore is deprecated. All operations for the in-tree awsElasticBlockStore type are redirected to the ebs.csi.aws.com CSI driver. More info: https://kubernetes.io/docs/concepts/storage/volumes#awselasticblockstore", - Ref: ref(v1.AWSElasticBlockStoreVolumeSource{}.OpenAPIModelName()), - }, - }, - "gitRepo": { - SchemaProps: spec.SchemaProps{ - Description: "gitRepo represents a git repository at a particular revision. Deprecated: GitRepo is deprecated. To provision a container with a git repo, mount an EmptyDir into an InitContainer that clones the repo using git, then mount the EmptyDir into the Pod's container.", - Ref: ref(v1.GitRepoVolumeSource{}.OpenAPIModelName()), - }, - }, - "secret": { - SchemaProps: spec.SchemaProps{ - Description: "secret represents a secret that should populate this volume. More info: https://kubernetes.io/docs/concepts/storage/volumes#secret", - Ref: ref(v1.SecretVolumeSource{}.OpenAPIModelName()), - }, - }, - "nfs": { - SchemaProps: spec.SchemaProps{ - Description: "nfs represents an NFS mount on the host that shares a pod's lifetime More info: https://kubernetes.io/docs/concepts/storage/volumes#nfs", - Ref: ref(v1.NFSVolumeSource{}.OpenAPIModelName()), - }, - }, - "iscsi": { - SchemaProps: spec.SchemaProps{ - Description: "iscsi represents an ISCSI Disk resource that is attached to a kubelet's host machine and then exposed to the pod. More info: https://kubernetes.io/docs/concepts/storage/volumes/#iscsi", - Ref: ref(v1.ISCSIVolumeSource{}.OpenAPIModelName()), - }, - }, - "glusterfs": { - SchemaProps: spec.SchemaProps{ - Description: "glusterfs represents a Glusterfs mount on the host that shares a pod's lifetime. Deprecated: Glusterfs is deprecated and the in-tree glusterfs type is no longer supported.", - Ref: ref(v1.GlusterfsVolumeSource{}.OpenAPIModelName()), - }, - }, - "persistentVolumeClaim": { - SchemaProps: spec.SchemaProps{ - Description: "persistentVolumeClaimVolumeSource represents a reference to a PersistentVolumeClaim in the same namespace. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#persistentvolumeclaims", - Ref: ref(v1.PersistentVolumeClaimVolumeSource{}.OpenAPIModelName()), - }, - }, - "rbd": { - SchemaProps: spec.SchemaProps{ - Description: "rbd represents a Rados Block Device mount on the host that shares a pod's lifetime. Deprecated: RBD is deprecated and the in-tree rbd type is no longer supported.", - Ref: ref(v1.RBDVolumeSource{}.OpenAPIModelName()), - }, - }, - "flexVolume": { - SchemaProps: spec.SchemaProps{ - Description: "flexVolume represents a generic volume resource that is provisioned/attached using an exec based plugin. Deprecated: FlexVolume is deprecated. Consider using a CSIDriver instead.", - Ref: ref(v1.FlexVolumeSource{}.OpenAPIModelName()), - }, - }, - "cinder": { - SchemaProps: spec.SchemaProps{ - Description: "cinder represents a cinder volume attached and mounted on kubelets host machine. Deprecated: Cinder is deprecated. All operations for the in-tree cinder type are redirected to the cinder.csi.openstack.org CSI driver. More info: https://examples.k8s.io/mysql-cinder-pd/README.md", - Ref: ref(v1.CinderVolumeSource{}.OpenAPIModelName()), - }, - }, - "cephfs": { - SchemaProps: spec.SchemaProps{ - Description: "cephFS represents a Ceph FS mount on the host that shares a pod's lifetime. Deprecated: CephFS is deprecated and the in-tree cephfs type is no longer supported.", - Ref: ref(v1.CephFSVolumeSource{}.OpenAPIModelName()), - }, - }, - "flocker": { - SchemaProps: spec.SchemaProps{ - Description: "flocker represents a Flocker volume attached to a kubelet's host machine. This depends on the Flocker control service being running. Deprecated: Flocker is deprecated and the in-tree flocker type is no longer supported.", - Ref: ref(v1.FlockerVolumeSource{}.OpenAPIModelName()), - }, - }, - "downwardAPI": { - SchemaProps: spec.SchemaProps{ - Description: "downwardAPI represents downward API about the pod that should populate this volume", - Ref: ref(v1.DownwardAPIVolumeSource{}.OpenAPIModelName()), - }, - }, - "fc": { - SchemaProps: spec.SchemaProps{ - Description: "fc represents a Fibre Channel resource that is attached to a kubelet's host machine and then exposed to the pod.", - Ref: ref(v1.FCVolumeSource{}.OpenAPIModelName()), - }, - }, - "azureFile": { - SchemaProps: spec.SchemaProps{ - Description: "azureFile represents an Azure File Service mount on the host and bind mount to the pod. Deprecated: AzureFile is deprecated. All operations for the in-tree azureFile type are redirected to the file.csi.azure.com CSI driver.", - Ref: ref(v1.AzureFileVolumeSource{}.OpenAPIModelName()), - }, - }, - "configMap": { - SchemaProps: spec.SchemaProps{ - Description: "configMap represents a configMap that should populate this volume", - Ref: ref(v1.ConfigMapVolumeSource{}.OpenAPIModelName()), - }, - }, - "vsphereVolume": { - SchemaProps: spec.SchemaProps{ - Description: "vsphereVolume represents a vSphere volume attached and mounted on kubelets host machine. Deprecated: VsphereVolume is deprecated. All operations for the in-tree vsphereVolume type are redirected to the csi.vsphere.vmware.com CSI driver.", - Ref: ref(v1.VsphereVirtualDiskVolumeSource{}.OpenAPIModelName()), - }, - }, - "quobyte": { - SchemaProps: spec.SchemaProps{ - Description: "quobyte represents a Quobyte mount on the host that shares a pod's lifetime. Deprecated: Quobyte is deprecated and the in-tree quobyte type is no longer supported.", - Ref: ref(v1.QuobyteVolumeSource{}.OpenAPIModelName()), - }, - }, - "azureDisk": { - SchemaProps: spec.SchemaProps{ - Description: "azureDisk represents an Azure Data Disk mount on the host and bind mount to the pod. Deprecated: AzureDisk is deprecated. All operations for the in-tree azureDisk type are redirected to the disk.csi.azure.com CSI driver.", - Ref: ref(v1.AzureDiskVolumeSource{}.OpenAPIModelName()), - }, - }, - "photonPersistentDisk": { - SchemaProps: spec.SchemaProps{ - Description: "photonPersistentDisk represents a PhotonController persistent disk attached and mounted on kubelets host machine. Deprecated: PhotonPersistentDisk is deprecated and the in-tree photonPersistentDisk type is no longer supported.", - Ref: ref(v1.PhotonPersistentDiskVolumeSource{}.OpenAPIModelName()), - }, - }, - "projected": { - SchemaProps: spec.SchemaProps{ - Description: "projected items for all in one resources secrets, configmaps, and downward API", - Ref: ref(v1.ProjectedVolumeSource{}.OpenAPIModelName()), - }, - }, - "portworxVolume": { - SchemaProps: spec.SchemaProps{ - Description: "portworxVolume represents a portworx volume attached and mounted on kubelets host machine. Deprecated: PortworxVolume is deprecated. All operations for the in-tree portworxVolume type are redirected to the pxd.portworx.com CSI driver when the CSIMigrationPortworx feature-gate is on.", - Ref: ref(v1.PortworxVolumeSource{}.OpenAPIModelName()), - }, - }, - "scaleIO": { - SchemaProps: spec.SchemaProps{ - Description: "scaleIO represents a ScaleIO persistent volume attached and mounted on Kubernetes nodes. Deprecated: ScaleIO is deprecated and the in-tree scaleIO type is no longer supported.", - Ref: ref(v1.ScaleIOVolumeSource{}.OpenAPIModelName()), - }, - }, - "storageos": { - SchemaProps: spec.SchemaProps{ - Description: "storageOS represents a StorageOS volume attached and mounted on Kubernetes nodes. Deprecated: StorageOS is deprecated and the in-tree storageos type is no longer supported.", - Ref: ref(v1.StorageOSVolumeSource{}.OpenAPIModelName()), - }, - }, - "csi": { - SchemaProps: spec.SchemaProps{ - Description: "csi (Container Storage Interface) represents ephemeral storage that is handled by certain external CSI drivers.", - Ref: ref(v1.CSIVolumeSource{}.OpenAPIModelName()), - }, - }, - "ephemeral": { - SchemaProps: spec.SchemaProps{ - Description: "ephemeral represents a volume that is handled by a cluster storage driver. The volume's lifecycle is tied to the pod that defines it - it will be created before the pod starts, and deleted when the pod is removed.\n\nUse this if: a) the volume is only needed while the pod runs, b) features of normal volumes like restoring from snapshot or capacity\n tracking are needed,\nc) the storage driver is specified through a storage class, and d) the storage driver supports dynamic volume provisioning through\n a PersistentVolumeClaim (see EphemeralVolumeSource for more\n information on the connection between this volume type\n and PersistentVolumeClaim).\n\nUse PersistentVolumeClaim or one of the vendor-specific APIs for volumes that persist for longer than the lifecycle of an individual pod.\n\nUse CSI for light-weight local ephemeral volumes if the CSI driver is meant to be used that way - see the documentation of the driver for more information.\n\nA pod can use both types of ephemeral volumes and persistent volumes at the same time.", - Ref: ref(v1.EphemeralVolumeSource{}.OpenAPIModelName()), - }, - }, - "image": { - SchemaProps: spec.SchemaProps{ - Description: "image represents an OCI object (a container image or artifact) pulled and mounted on the kubelet's host machine. The volume is resolved at pod startup depending on which PullPolicy value is provided:\n\n- Always: the kubelet always attempts to pull the reference. Container creation will fail If the pull fails. - Never: the kubelet never pulls the reference and only uses a local image or artifact. Container creation will fail if the reference isn't present. - IfNotPresent: the kubelet pulls if the reference isn't already present on disk. Container creation will fail if the reference isn't present and the pull fails.\n\nThe volume gets re-resolved if the pod gets deleted and recreated, which means that new remote content will become available on pod recreation. A failure to resolve or pull the image during pod startup will block containers from starting and may add significant latency. Failures will be retried using normal volume backoff and will be reported on the pod reason and message. The types of objects that may be mounted by this volume are defined by the container runtime implementation on a host machine and at minimum must include all valid types supported by the container image field. The OCI object gets mounted in a single directory (spec.containers[*].volumeMounts.mountPath) by merging the manifest layers in the same way as for container images. The volume will be mounted read-only (ro) and non-executable files (noexec). Sub path mounts for containers are not supported (spec.containers[*].volumeMounts.subpath) before 1.33. The field spec.securityContext.fsGroupChangePolicy has no effect on this volume type.", - Ref: ref(v1.ImageVolumeSource{}.OpenAPIModelName()), - }, - }, - }, - Required: []string{"name"}, - }, - }, - Dependencies: []string{ - v1.AWSElasticBlockStoreVolumeSource{}.OpenAPIModelName(), v1.AzureDiskVolumeSource{}.OpenAPIModelName(), v1.AzureFileVolumeSource{}.OpenAPIModelName(), v1.CSIVolumeSource{}.OpenAPIModelName(), v1.CephFSVolumeSource{}.OpenAPIModelName(), v1.CinderVolumeSource{}.OpenAPIModelName(), v1.ConfigMapVolumeSource{}.OpenAPIModelName(), v1.DownwardAPIVolumeSource{}.OpenAPIModelName(), v1.EmptyDirVolumeSource{}.OpenAPIModelName(), v1.EphemeralVolumeSource{}.OpenAPIModelName(), v1.FCVolumeSource{}.OpenAPIModelName(), v1.FlexVolumeSource{}.OpenAPIModelName(), v1.FlockerVolumeSource{}.OpenAPIModelName(), v1.GCEPersistentDiskVolumeSource{}.OpenAPIModelName(), v1.GitRepoVolumeSource{}.OpenAPIModelName(), v1.GlusterfsVolumeSource{}.OpenAPIModelName(), v1.HostPathVolumeSource{}.OpenAPIModelName(), v1.ISCSIVolumeSource{}.OpenAPIModelName(), v1.ImageVolumeSource{}.OpenAPIModelName(), v1.NFSVolumeSource{}.OpenAPIModelName(), v1.PersistentVolumeClaimVolumeSource{}.OpenAPIModelName(), v1.PhotonPersistentDiskVolumeSource{}.OpenAPIModelName(), v1.PortworxVolumeSource{}.OpenAPIModelName(), v1.ProjectedVolumeSource{}.OpenAPIModelName(), v1.QuobyteVolumeSource{}.OpenAPIModelName(), v1.RBDVolumeSource{}.OpenAPIModelName(), v1.ScaleIOVolumeSource{}.OpenAPIModelName(), v1.SecretVolumeSource{}.OpenAPIModelName(), v1.StorageOSVolumeSource{}.OpenAPIModelName(), v1.VsphereVirtualDiskVolumeSource{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_VolumeDevice(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "volumeDevice describes a mapping of a raw block device within a container.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "name": { - SchemaProps: spec.SchemaProps{ - Description: "name must match the name of a persistentVolumeClaim in the pod", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "devicePath": { - SchemaProps: spec.SchemaProps{ - Description: "devicePath is the path inside of the container that the device will be mapped to.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - Required: []string{"name", "devicePath"}, - }, - }, - } -} - -func schema_k8sio_api_core_v1_VolumeMount(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "VolumeMount describes a mounting of a Volume within a container.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "name": { - SchemaProps: spec.SchemaProps{ - Description: "This must match the Name of a Volume.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "readOnly": { - SchemaProps: spec.SchemaProps{ - Description: "Mounted read-only if true, read-write otherwise (false or unspecified). Defaults to false.", - Type: []string{"boolean"}, - Format: "", - }, - }, - "recursiveReadOnly": { - SchemaProps: spec.SchemaProps{ - Description: "RecursiveReadOnly specifies whether read-only mounts should be handled recursively.\n\nIf ReadOnly is false, this field has no meaning and must be unspecified.\n\nIf ReadOnly is true, and this field is set to Disabled, the mount is not made recursively read-only. If this field is set to IfPossible, the mount is made recursively read-only, if it is supported by the container runtime. If this field is set to Enabled, the mount is made recursively read-only if it is supported by the container runtime, otherwise the pod will not be started and an error will be generated to indicate the reason.\n\nIf this field is set to IfPossible or Enabled, MountPropagation must be set to None (or be unspecified, which defaults to None).\n\nIf this field is not specified, it is treated as an equivalent of Disabled.", - Type: []string{"string"}, - Format: "", - }, - }, - "mountPath": { - SchemaProps: spec.SchemaProps{ - Description: "Path within the container at which the volume should be mounted. Must not contain ':'.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "subPath": { - SchemaProps: spec.SchemaProps{ - Description: "Path within the volume from which the container's volume should be mounted. Defaults to \"\" (volume's root).", - Type: []string{"string"}, - Format: "", - }, - }, - "mountPropagation": { - SchemaProps: spec.SchemaProps{ - Description: "mountPropagation determines how mounts are propagated from the host to container and the other way around. When not set, MountPropagationNone is used. This field is beta in 1.10. When RecursiveReadOnly is set to IfPossible or to Enabled, MountPropagation must be None or unspecified (which defaults to None).\n\nPossible enum values:\n - `\"Bidirectional\"` means that the volume in a container will receive new mounts from the host or other containers, and its own mounts will be propagated from the container to the host or other containers. Note that this mode is recursively applied to all mounts in the volume (\"rshared\" in Linux terminology).\n - `\"HostToContainer\"` means that the volume in a container will receive new mounts from the host or other containers, but filesystems mounted inside the container won't be propagated to the host or other containers. Note that this mode is recursively applied to all mounts in the volume (\"rslave\" in Linux terminology).\n - `\"None\"` means that the volume in a container will not receive new mounts from the host or other containers, and filesystems mounted inside the container won't be propagated to the host or other containers. Note that this mode corresponds to \"private\" in Linux terminology.", - Type: []string{"string"}, - Format: "", - Enum: []interface{}{"Bidirectional", "HostToContainer", "None"}, - }, - }, - "subPathExpr": { - SchemaProps: spec.SchemaProps{ - Description: "Expanded path within the volume from which the container's volume should be mounted. Behaves similarly to SubPath but environment variable references $(VAR_NAME) are expanded using the container's environment. Defaults to \"\" (volume's root). SubPathExpr and SubPath are mutually exclusive.", - Type: []string{"string"}, - Format: "", - }, - }, - }, - Required: []string{"name", "mountPath"}, - }, - }, - } -} - -func schema_k8sio_api_core_v1_VolumeMountStatus(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "VolumeMountStatus shows status of volume mounts.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "name": { - SchemaProps: spec.SchemaProps{ - Description: "Name corresponds to the name of the original VolumeMount.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "mountPath": { - SchemaProps: spec.SchemaProps{ - Description: "MountPath corresponds to the original VolumeMount.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "readOnly": { - SchemaProps: spec.SchemaProps{ - Description: "ReadOnly corresponds to the original VolumeMount.", - Type: []string{"boolean"}, - Format: "", - }, - }, - "recursiveReadOnly": { - SchemaProps: spec.SchemaProps{ - Description: "RecursiveReadOnly must be set to Disabled, Enabled, or unspecified (for non-readonly mounts). An IfPossible value in the original VolumeMount must be translated to Disabled or Enabled, depending on the mount result.", - Type: []string{"string"}, - Format: "", - }, - }, - }, - Required: []string{"name", "mountPath"}, - }, - }, - } -} - -func schema_k8sio_api_core_v1_VolumeNodeAffinity(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "VolumeNodeAffinity defines constraints that limit what nodes this volume can be accessed from.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "required": { - SchemaProps: spec.SchemaProps{ - Description: "required specifies hard node constraints that must be met.", - Ref: ref(v1.NodeSelector{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - Dependencies: []string{ - v1.NodeSelector{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_VolumeProjection(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "Projection that may be projected along with other supported volume types. Exactly one of these fields must be set.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "secret": { - SchemaProps: spec.SchemaProps{ - Description: "secret information about the secret data to project", - Ref: ref(v1.SecretProjection{}.OpenAPIModelName()), - }, - }, - "downwardAPI": { - SchemaProps: spec.SchemaProps{ - Description: "downwardAPI information about the downwardAPI data to project", - Ref: ref(v1.DownwardAPIProjection{}.OpenAPIModelName()), - }, - }, - "configMap": { - SchemaProps: spec.SchemaProps{ - Description: "configMap information about the configMap data to project", - Ref: ref(v1.ConfigMapProjection{}.OpenAPIModelName()), - }, - }, - "serviceAccountToken": { - SchemaProps: spec.SchemaProps{ - Description: "serviceAccountToken is information about the serviceAccountToken data to project", - Ref: ref(v1.ServiceAccountTokenProjection{}.OpenAPIModelName()), - }, - }, - "clusterTrustBundle": { - SchemaProps: spec.SchemaProps{ - Description: "ClusterTrustBundle allows a pod to access the `.spec.trustBundle` field of ClusterTrustBundle objects in an auto-updating file.\n\nAlpha, gated by the ClusterTrustBundleProjection feature gate.\n\nClusterTrustBundle objects can either be selected by name, or by the combination of signer name and a label selector.\n\nKubelet performs aggressive normalization of the PEM contents written into the pod filesystem. Esoteric PEM features such as inter-block comments and block headers are stripped. Certificates are deduplicated. The ordering of certificates within the file is arbitrary, and Kubelet may change the order over time.", - Ref: ref(v1.ClusterTrustBundleProjection{}.OpenAPIModelName()), - }, - }, - "podCertificate": { - SchemaProps: spec.SchemaProps{ - Description: "Projects an auto-rotating credential bundle (private key and certificate chain) that the pod can use either as a TLS client or server.\n\nKubelet generates a private key and uses it to send a PodCertificateRequest to the named signer. Once the signer approves the request and issues a certificate chain, Kubelet writes the key and certificate chain to the pod filesystem. The pod does not start until certificates have been issued for each podCertificate projected volume source in its spec.\n\nKubelet will begin trying to rotate the certificate at the time indicated by the signer using the PodCertificateRequest.Status.BeginRefreshAt timestamp.\n\nKubelet can write a single file, indicated by the credentialBundlePath field, or separate files, indicated by the keyPath and certificateChainPath fields.\n\nThe credential bundle is a single file in PEM format. The first PEM entry is the private key (in PKCS#8 format), and the remaining PEM entries are the certificate chain issued by the signer (typically, signers will return their certificate chain in leaf-to-root order).\n\nPrefer using the credential bundle format, since your application code can read it atomically. If you use keyPath and certificateChainPath, your application must make two separate file reads. If these coincide with a certificate rotation, it is possible that the private key and leaf certificate you read may not correspond to each other. Your application will need to check for this condition, and re-read until they are consistent.\n\nThe named signer controls chooses the format of the certificate it issues; consult the signer implementation's documentation to learn how to use the certificates it issues.", - Ref: ref(v1.PodCertificateProjection{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - Dependencies: []string{ - v1.ClusterTrustBundleProjection{}.OpenAPIModelName(), v1.ConfigMapProjection{}.OpenAPIModelName(), v1.DownwardAPIProjection{}.OpenAPIModelName(), v1.PodCertificateProjection{}.OpenAPIModelName(), v1.SecretProjection{}.OpenAPIModelName(), v1.ServiceAccountTokenProjection{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_VolumeResourceRequirements(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "VolumeResourceRequirements describes the storage resource requirements for a volume.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "limits": { - SchemaProps: spec.SchemaProps{ - Description: "Limits describes the maximum amount of compute resources allowed. More info: https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/", - Type: []string{"object"}, - AdditionalProperties: &spec.SchemaOrBool{ - Allows: true, - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Ref: ref(resource.Quantity{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "requests": { - SchemaProps: spec.SchemaProps{ - Description: "Requests describes the minimum amount of compute resources required. If Requests is omitted for a container, it defaults to Limits if that is explicitly specified, otherwise to an implementation-defined value. Requests cannot exceed Limits. More info: https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/", - Type: []string{"object"}, - AdditionalProperties: &spec.SchemaOrBool{ - Allows: true, - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Ref: ref(resource.Quantity{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - }, - }, - }, - Dependencies: []string{ - resource.Quantity{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_VolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "Represents the source of a volume to mount. Only one of its members may be specified.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "hostPath": { - SchemaProps: spec.SchemaProps{ - Description: "hostPath represents a pre-existing file or directory on the host machine that is directly exposed to the container. This is generally used for system agents or other privileged things that are allowed to see the host machine. Most containers will NOT need this. More info: https://kubernetes.io/docs/concepts/storage/volumes#hostpath", - Ref: ref(v1.HostPathVolumeSource{}.OpenAPIModelName()), - }, - }, - "emptyDir": { - SchemaProps: spec.SchemaProps{ - Description: "emptyDir represents a temporary directory that shares a pod's lifetime. More info: https://kubernetes.io/docs/concepts/storage/volumes#emptydir", - Ref: ref(v1.EmptyDirVolumeSource{}.OpenAPIModelName()), - }, - }, - "gcePersistentDisk": { - SchemaProps: spec.SchemaProps{ - Description: "gcePersistentDisk represents a GCE Disk resource that is attached to a kubelet's host machine and then exposed to the pod. Deprecated: GCEPersistentDisk is deprecated. All operations for the in-tree gcePersistentDisk type are redirected to the pd.csi.storage.gke.io CSI driver. More info: https://kubernetes.io/docs/concepts/storage/volumes#gcepersistentdisk", - Ref: ref(v1.GCEPersistentDiskVolumeSource{}.OpenAPIModelName()), - }, - }, - "awsElasticBlockStore": { - SchemaProps: spec.SchemaProps{ - Description: "awsElasticBlockStore represents an AWS Disk resource that is attached to a kubelet's host machine and then exposed to the pod. Deprecated: AWSElasticBlockStore is deprecated. All operations for the in-tree awsElasticBlockStore type are redirected to the ebs.csi.aws.com CSI driver. More info: https://kubernetes.io/docs/concepts/storage/volumes#awselasticblockstore", - Ref: ref(v1.AWSElasticBlockStoreVolumeSource{}.OpenAPIModelName()), - }, - }, - "gitRepo": { - SchemaProps: spec.SchemaProps{ - Description: "gitRepo represents a git repository at a particular revision. Deprecated: GitRepo is deprecated. To provision a container with a git repo, mount an EmptyDir into an InitContainer that clones the repo using git, then mount the EmptyDir into the Pod's container.", - Ref: ref(v1.GitRepoVolumeSource{}.OpenAPIModelName()), - }, - }, - "secret": { - SchemaProps: spec.SchemaProps{ - Description: "secret represents a secret that should populate this volume. More info: https://kubernetes.io/docs/concepts/storage/volumes#secret", - Ref: ref(v1.SecretVolumeSource{}.OpenAPIModelName()), - }, - }, - "nfs": { - SchemaProps: spec.SchemaProps{ - Description: "nfs represents an NFS mount on the host that shares a pod's lifetime More info: https://kubernetes.io/docs/concepts/storage/volumes#nfs", - Ref: ref(v1.NFSVolumeSource{}.OpenAPIModelName()), - }, - }, - "iscsi": { - SchemaProps: spec.SchemaProps{ - Description: "iscsi represents an ISCSI Disk resource that is attached to a kubelet's host machine and then exposed to the pod. More info: https://kubernetes.io/docs/concepts/storage/volumes/#iscsi", - Ref: ref(v1.ISCSIVolumeSource{}.OpenAPIModelName()), - }, - }, - "glusterfs": { - SchemaProps: spec.SchemaProps{ - Description: "glusterfs represents a Glusterfs mount on the host that shares a pod's lifetime. Deprecated: Glusterfs is deprecated and the in-tree glusterfs type is no longer supported.", - Ref: ref(v1.GlusterfsVolumeSource{}.OpenAPIModelName()), - }, - }, - "persistentVolumeClaim": { - SchemaProps: spec.SchemaProps{ - Description: "persistentVolumeClaimVolumeSource represents a reference to a PersistentVolumeClaim in the same namespace. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#persistentvolumeclaims", - Ref: ref(v1.PersistentVolumeClaimVolumeSource{}.OpenAPIModelName()), - }, - }, - "rbd": { - SchemaProps: spec.SchemaProps{ - Description: "rbd represents a Rados Block Device mount on the host that shares a pod's lifetime. Deprecated: RBD is deprecated and the in-tree rbd type is no longer supported.", - Ref: ref(v1.RBDVolumeSource{}.OpenAPIModelName()), - }, - }, - "flexVolume": { - SchemaProps: spec.SchemaProps{ - Description: "flexVolume represents a generic volume resource that is provisioned/attached using an exec based plugin. Deprecated: FlexVolume is deprecated. Consider using a CSIDriver instead.", - Ref: ref(v1.FlexVolumeSource{}.OpenAPIModelName()), - }, - }, - "cinder": { - SchemaProps: spec.SchemaProps{ - Description: "cinder represents a cinder volume attached and mounted on kubelets host machine. Deprecated: Cinder is deprecated. All operations for the in-tree cinder type are redirected to the cinder.csi.openstack.org CSI driver. More info: https://examples.k8s.io/mysql-cinder-pd/README.md", - Ref: ref(v1.CinderVolumeSource{}.OpenAPIModelName()), - }, - }, - "cephfs": { - SchemaProps: spec.SchemaProps{ - Description: "cephFS represents a Ceph FS mount on the host that shares a pod's lifetime. Deprecated: CephFS is deprecated and the in-tree cephfs type is no longer supported.", - Ref: ref(v1.CephFSVolumeSource{}.OpenAPIModelName()), - }, - }, - "flocker": { - SchemaProps: spec.SchemaProps{ - Description: "flocker represents a Flocker volume attached to a kubelet's host machine. This depends on the Flocker control service being running. Deprecated: Flocker is deprecated and the in-tree flocker type is no longer supported.", - Ref: ref(v1.FlockerVolumeSource{}.OpenAPIModelName()), - }, - }, - "downwardAPI": { - SchemaProps: spec.SchemaProps{ - Description: "downwardAPI represents downward API about the pod that should populate this volume", - Ref: ref(v1.DownwardAPIVolumeSource{}.OpenAPIModelName()), - }, - }, - "fc": { - SchemaProps: spec.SchemaProps{ - Description: "fc represents a Fibre Channel resource that is attached to a kubelet's host machine and then exposed to the pod.", - Ref: ref(v1.FCVolumeSource{}.OpenAPIModelName()), - }, - }, - "azureFile": { - SchemaProps: spec.SchemaProps{ - Description: "azureFile represents an Azure File Service mount on the host and bind mount to the pod. Deprecated: AzureFile is deprecated. All operations for the in-tree azureFile type are redirected to the file.csi.azure.com CSI driver.", - Ref: ref(v1.AzureFileVolumeSource{}.OpenAPIModelName()), - }, - }, - "configMap": { - SchemaProps: spec.SchemaProps{ - Description: "configMap represents a configMap that should populate this volume", - Ref: ref(v1.ConfigMapVolumeSource{}.OpenAPIModelName()), - }, - }, - "vsphereVolume": { - SchemaProps: spec.SchemaProps{ - Description: "vsphereVolume represents a vSphere volume attached and mounted on kubelets host machine. Deprecated: VsphereVolume is deprecated. All operations for the in-tree vsphereVolume type are redirected to the csi.vsphere.vmware.com CSI driver.", - Ref: ref(v1.VsphereVirtualDiskVolumeSource{}.OpenAPIModelName()), - }, - }, - "quobyte": { - SchemaProps: spec.SchemaProps{ - Description: "quobyte represents a Quobyte mount on the host that shares a pod's lifetime. Deprecated: Quobyte is deprecated and the in-tree quobyte type is no longer supported.", - Ref: ref(v1.QuobyteVolumeSource{}.OpenAPIModelName()), - }, - }, - "azureDisk": { - SchemaProps: spec.SchemaProps{ - Description: "azureDisk represents an Azure Data Disk mount on the host and bind mount to the pod. Deprecated: AzureDisk is deprecated. All operations for the in-tree azureDisk type are redirected to the disk.csi.azure.com CSI driver.", - Ref: ref(v1.AzureDiskVolumeSource{}.OpenAPIModelName()), - }, - }, - "photonPersistentDisk": { - SchemaProps: spec.SchemaProps{ - Description: "photonPersistentDisk represents a PhotonController persistent disk attached and mounted on kubelets host machine. Deprecated: PhotonPersistentDisk is deprecated and the in-tree photonPersistentDisk type is no longer supported.", - Ref: ref(v1.PhotonPersistentDiskVolumeSource{}.OpenAPIModelName()), - }, - }, - "projected": { - SchemaProps: spec.SchemaProps{ - Description: "projected items for all in one resources secrets, configmaps, and downward API", - Ref: ref(v1.ProjectedVolumeSource{}.OpenAPIModelName()), - }, - }, - "portworxVolume": { - SchemaProps: spec.SchemaProps{ - Description: "portworxVolume represents a portworx volume attached and mounted on kubelets host machine. Deprecated: PortworxVolume is deprecated. All operations for the in-tree portworxVolume type are redirected to the pxd.portworx.com CSI driver when the CSIMigrationPortworx feature-gate is on.", - Ref: ref(v1.PortworxVolumeSource{}.OpenAPIModelName()), - }, - }, - "scaleIO": { - SchemaProps: spec.SchemaProps{ - Description: "scaleIO represents a ScaleIO persistent volume attached and mounted on Kubernetes nodes. Deprecated: ScaleIO is deprecated and the in-tree scaleIO type is no longer supported.", - Ref: ref(v1.ScaleIOVolumeSource{}.OpenAPIModelName()), - }, - }, - "storageos": { - SchemaProps: spec.SchemaProps{ - Description: "storageOS represents a StorageOS volume attached and mounted on Kubernetes nodes. Deprecated: StorageOS is deprecated and the in-tree storageos type is no longer supported.", - Ref: ref(v1.StorageOSVolumeSource{}.OpenAPIModelName()), - }, - }, - "csi": { - SchemaProps: spec.SchemaProps{ - Description: "csi (Container Storage Interface) represents ephemeral storage that is handled by certain external CSI drivers.", - Ref: ref(v1.CSIVolumeSource{}.OpenAPIModelName()), - }, - }, - "ephemeral": { - SchemaProps: spec.SchemaProps{ - Description: "ephemeral represents a volume that is handled by a cluster storage driver. The volume's lifecycle is tied to the pod that defines it - it will be created before the pod starts, and deleted when the pod is removed.\n\nUse this if: a) the volume is only needed while the pod runs, b) features of normal volumes like restoring from snapshot or capacity\n tracking are needed,\nc) the storage driver is specified through a storage class, and d) the storage driver supports dynamic volume provisioning through\n a PersistentVolumeClaim (see EphemeralVolumeSource for more\n information on the connection between this volume type\n and PersistentVolumeClaim).\n\nUse PersistentVolumeClaim or one of the vendor-specific APIs for volumes that persist for longer than the lifecycle of an individual pod.\n\nUse CSI for light-weight local ephemeral volumes if the CSI driver is meant to be used that way - see the documentation of the driver for more information.\n\nA pod can use both types of ephemeral volumes and persistent volumes at the same time.", - Ref: ref(v1.EphemeralVolumeSource{}.OpenAPIModelName()), - }, - }, - "image": { - SchemaProps: spec.SchemaProps{ - Description: "image represents an OCI object (a container image or artifact) pulled and mounted on the kubelet's host machine. The volume is resolved at pod startup depending on which PullPolicy value is provided:\n\n- Always: the kubelet always attempts to pull the reference. Container creation will fail If the pull fails. - Never: the kubelet never pulls the reference and only uses a local image or artifact. Container creation will fail if the reference isn't present. - IfNotPresent: the kubelet pulls if the reference isn't already present on disk. Container creation will fail if the reference isn't present and the pull fails.\n\nThe volume gets re-resolved if the pod gets deleted and recreated, which means that new remote content will become available on pod recreation. A failure to resolve or pull the image during pod startup will block containers from starting and may add significant latency. Failures will be retried using normal volume backoff and will be reported on the pod reason and message. The types of objects that may be mounted by this volume are defined by the container runtime implementation on a host machine and at minimum must include all valid types supported by the container image field. The OCI object gets mounted in a single directory (spec.containers[*].volumeMounts.mountPath) by merging the manifest layers in the same way as for container images. The volume will be mounted read-only (ro) and non-executable files (noexec). Sub path mounts for containers are not supported (spec.containers[*].volumeMounts.subpath) before 1.33. The field spec.securityContext.fsGroupChangePolicy has no effect on this volume type.", - Ref: ref(v1.ImageVolumeSource{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - Dependencies: []string{ - v1.AWSElasticBlockStoreVolumeSource{}.OpenAPIModelName(), v1.AzureDiskVolumeSource{}.OpenAPIModelName(), v1.AzureFileVolumeSource{}.OpenAPIModelName(), v1.CSIVolumeSource{}.OpenAPIModelName(), v1.CephFSVolumeSource{}.OpenAPIModelName(), v1.CinderVolumeSource{}.OpenAPIModelName(), v1.ConfigMapVolumeSource{}.OpenAPIModelName(), v1.DownwardAPIVolumeSource{}.OpenAPIModelName(), v1.EmptyDirVolumeSource{}.OpenAPIModelName(), v1.EphemeralVolumeSource{}.OpenAPIModelName(), v1.FCVolumeSource{}.OpenAPIModelName(), v1.FlexVolumeSource{}.OpenAPIModelName(), v1.FlockerVolumeSource{}.OpenAPIModelName(), v1.GCEPersistentDiskVolumeSource{}.OpenAPIModelName(), v1.GitRepoVolumeSource{}.OpenAPIModelName(), v1.GlusterfsVolumeSource{}.OpenAPIModelName(), v1.HostPathVolumeSource{}.OpenAPIModelName(), v1.ISCSIVolumeSource{}.OpenAPIModelName(), v1.ImageVolumeSource{}.OpenAPIModelName(), v1.NFSVolumeSource{}.OpenAPIModelName(), v1.PersistentVolumeClaimVolumeSource{}.OpenAPIModelName(), v1.PhotonPersistentDiskVolumeSource{}.OpenAPIModelName(), v1.PortworxVolumeSource{}.OpenAPIModelName(), v1.ProjectedVolumeSource{}.OpenAPIModelName(), v1.QuobyteVolumeSource{}.OpenAPIModelName(), v1.RBDVolumeSource{}.OpenAPIModelName(), v1.ScaleIOVolumeSource{}.OpenAPIModelName(), v1.SecretVolumeSource{}.OpenAPIModelName(), v1.StorageOSVolumeSource{}.OpenAPIModelName(), v1.VsphereVirtualDiskVolumeSource{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_VsphereVirtualDiskVolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "Represents a vSphere volume resource.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "volumePath": { - SchemaProps: spec.SchemaProps{ - Description: "volumePath is the path that identifies vSphere volume vmdk", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "fsType": { - SchemaProps: spec.SchemaProps{ - Description: "fsType is filesystem type to mount. Must be a filesystem type supported by the host operating system. Ex. \"ext4\", \"xfs\", \"ntfs\". Implicitly inferred to be \"ext4\" if unspecified.", - Type: []string{"string"}, - Format: "", - }, - }, - "storagePolicyName": { - SchemaProps: spec.SchemaProps{ - Description: "storagePolicyName is the storage Policy Based Management (SPBM) profile name.", - Type: []string{"string"}, - Format: "", - }, - }, - "storagePolicyID": { - SchemaProps: spec.SchemaProps{ - Description: "storagePolicyID is the storage Policy Based Management (SPBM) profile ID associated with the StoragePolicyName.", - Type: []string{"string"}, - Format: "", - }, - }, - }, - Required: []string{"volumePath"}, - }, - }, - } -} - -func schema_k8sio_api_core_v1_WeightedPodAffinityTerm(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "The weights of all of the matched WeightedPodAffinityTerm fields are added per-node to find the most preferred node(s)", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "weight": { - SchemaProps: spec.SchemaProps{ - Description: "weight associated with matching the corresponding podAffinityTerm, in the range 1-100.", - Default: 0, - Type: []string{"integer"}, - Format: "int32", - }, - }, - "podAffinityTerm": { - SchemaProps: spec.SchemaProps{ - Description: "Required. A pod affinity term, associated with the corresponding weight.", - Default: map[string]interface{}{}, - Ref: ref(v1.PodAffinityTerm{}.OpenAPIModelName()), - }, - }, - }, - Required: []string{"weight", "podAffinityTerm"}, - }, - }, - Dependencies: []string{ - v1.PodAffinityTerm{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_api_core_v1_WindowsSecurityContextOptions(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "WindowsSecurityContextOptions contain Windows-specific options and credentials.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "gmsaCredentialSpecName": { - SchemaProps: spec.SchemaProps{ - Description: "GMSACredentialSpecName is the name of the GMSA credential spec to use.", - Type: []string{"string"}, - Format: "", - }, - }, - "gmsaCredentialSpec": { - SchemaProps: spec.SchemaProps{ - Description: "GMSACredentialSpec is where the GMSA admission webhook (https://github.com/kubernetes-sigs/windows-gmsa) inlines the contents of the GMSA credential spec named by the GMSACredentialSpecName field.", - Type: []string{"string"}, - Format: "", - }, - }, - "runAsUserName": { - SchemaProps: spec.SchemaProps{ - Description: "The UserName in Windows to run the entrypoint of the container process. Defaults to the user specified in image metadata if unspecified. May also be set in PodSecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence.", - Type: []string{"string"}, - Format: "", - }, - }, - "hostProcess": { - SchemaProps: spec.SchemaProps{ - Description: "HostProcess determines if a container should be run as a 'Host Process' container. All of a Pod's containers must have the same effective HostProcess value (it is not allowed to have a mix of HostProcess containers and non-HostProcess containers). In addition, if HostProcess is true then HostNetwork must also be set to true.", - Type: []string{"boolean"}, - Format: "", - }, - }, - }, - }, - }, - } -} - -func schema_k8sio_api_core_v1_WorkloadReference(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "WorkloadReference identifies the Workload object and PodGroup membership that a Pod belongs to. The scheduler uses this information to apply workload-aware scheduling semantics.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "name": { - SchemaProps: spec.SchemaProps{ - Description: "Name defines the name of the Workload object this Pod belongs to. Workload must be in the same namespace as the Pod. If it doesn't match any existing Workload, the Pod will remain unschedulable until a Workload object is created and observed by the kube-scheduler. It must be a DNS subdomain.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "podGroup": { - SchemaProps: spec.SchemaProps{ - Description: "PodGroup is the name of the PodGroup within the Workload that this Pod belongs to. If it doesn't match any existing PodGroup within the Workload, the Pod will remain unschedulable until the Workload object is recreated and observed by the kube-scheduler. It must be a DNS label.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "podGroupReplicaKey": { - SchemaProps: spec.SchemaProps{ - Description: "PodGroupReplicaKey specifies the replica key of the PodGroup to which this Pod belongs. It is used to distinguish pods belonging to different replicas of the same pod group. The pod group policy is applied separately to each replica. When set, it must be a DNS label.", - Type: []string{"string"}, - Format: "", - }, - }, - }, - Required: []string{"name", "podGroup"}, - }, - }, - } -} - -func schema_apimachinery_pkg_api_resource_Quantity(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.EmbedOpenAPIDefinitionIntoV2Extension(common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "Quantity is a fixed-point representation of a number. It provides convenient marshaling/unmarshaling in JSON and YAML, in addition to String() and AsInt64() accessors.\n\nThe serialization format is:\n\n``` ::= \n\n\t(Note that may be empty, from the \"\" case in .)\n\n ::= 0 | 1 | ... | 9 ::= | ::= | . | . | . ::= \"+\" | \"-\" ::= | ::= | | ::= Ki | Mi | Gi | Ti | Pi | Ei\n\n\t(International System of units; See: http://physics.nist.gov/cuu/Units/binary.html)\n\n ::= m | \"\" | k | M | G | T | P | E\n\n\t(Note that 1024 = 1Ki but 1000 = 1k; I didn't choose the capitalization.)\n\n ::= \"e\" | \"E\" ```\n\nNo matter which of the three exponent forms is used, no quantity may represent a number greater than 2^63-1 in magnitude, nor may it have more than 3 decimal places. Numbers larger or more precise will be capped or rounded up. (E.g.: 0.1m will rounded up to 1m.) This may be extended in the future if we require larger or smaller quantities.\n\nWhen a Quantity is parsed from a string, it will remember the type of suffix it had, and will use the same type again when it is serialized.\n\nBefore serializing, Quantity will be put in \"canonical form\". This means that Exponent/suffix will be adjusted up or down (with a corresponding increase or decrease in Mantissa) such that:\n\n- No precision is lost - No fractional digits will be emitted - The exponent (or suffix) is as large as possible.\n\nThe sign will be omitted unless the number is negative.\n\nExamples:\n\n- 1.5 will be serialized as \"1500m\" - 1.5Gi will be serialized as \"1536Mi\"\n\nNote that the quantity will NEVER be internally represented by a floating point number. That is the whole point of this exercise.\n\nNon-canonical values will still parse as long as they are well formed, but will be re-emitted in their canonical form. (So always use canonical form, or don't diff.)\n\nThis format is intended to make it difficult to use these numbers without writing some sort of special handling code in the hopes that that will cause implementors to also use a fixed point implementation.", - OneOf: common.GenerateOpenAPIV3OneOfSchema(resource.Quantity{}.OpenAPIV3OneOfTypes()), - Format: resource.Quantity{}.OpenAPISchemaFormat(), - }, - }, - }, common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "Quantity is a fixed-point representation of a number. It provides convenient marshaling/unmarshaling in JSON and YAML, in addition to String() and AsInt64() accessors.\n\nThe serialization format is:\n\n``` ::= \n\n\t(Note that may be empty, from the \"\" case in .)\n\n ::= 0 | 1 | ... | 9 ::= | ::= | . | . | . ::= \"+\" | \"-\" ::= | ::= | | ::= Ki | Mi | Gi | Ti | Pi | Ei\n\n\t(International System of units; See: http://physics.nist.gov/cuu/Units/binary.html)\n\n ::= m | \"\" | k | M | G | T | P | E\n\n\t(Note that 1024 = 1Ki but 1000 = 1k; I didn't choose the capitalization.)\n\n ::= \"e\" | \"E\" ```\n\nNo matter which of the three exponent forms is used, no quantity may represent a number greater than 2^63-1 in magnitude, nor may it have more than 3 decimal places. Numbers larger or more precise will be capped or rounded up. (E.g.: 0.1m will rounded up to 1m.) This may be extended in the future if we require larger or smaller quantities.\n\nWhen a Quantity is parsed from a string, it will remember the type of suffix it had, and will use the same type again when it is serialized.\n\nBefore serializing, Quantity will be put in \"canonical form\". This means that Exponent/suffix will be adjusted up or down (with a corresponding increase or decrease in Mantissa) such that:\n\n- No precision is lost - No fractional digits will be emitted - The exponent (or suffix) is as large as possible.\n\nThe sign will be omitted unless the number is negative.\n\nExamples:\n\n- 1.5 will be serialized as \"1500m\" - 1.5Gi will be serialized as \"1536Mi\"\n\nNote that the quantity will NEVER be internally represented by a floating point number. That is the whole point of this exercise.\n\nNon-canonical values will still parse as long as they are well formed, but will be re-emitted in their canonical form. (So always use canonical form, or don't diff.)\n\nThis format is intended to make it difficult to use these numbers without writing some sort of special handling code in the hopes that that will cause implementors to also use a fixed point implementation.", - Type: resource.Quantity{}.OpenAPISchemaType(), - Format: resource.Quantity{}.OpenAPISchemaFormat(), - }, - }, - }) -} - -func schema_apimachinery_pkg_api_resource_int64Amount(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "int64Amount represents a fixed precision numerator and arbitrary scale exponent. It is faster than operations on inf.Dec for values that can be represented as int64.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "value": { - SchemaProps: spec.SchemaProps{ - Default: 0, - Type: []string{"integer"}, - Format: "int64", - }, - }, - "scale": { - SchemaProps: spec.SchemaProps{ - Default: 0, - Type: []string{"integer"}, - Format: "int32", - }, - }, - }, - Required: []string{"value", "scale"}, - }, - }, - } -} - -func schema_pkg_apis_meta_v1_APIGroup(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "APIGroup contains the name, the supported versions, and the preferred version of a group.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Type: []string{"string"}, - Format: "", - }, - }, - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", - Type: []string{"string"}, - Format: "", - }, - }, - "name": { - SchemaProps: spec.SchemaProps{ - Description: "name is the name of the group.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "versions": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "versions are the versions supported in this group.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(metav1.GroupVersionForDiscovery{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "preferredVersion": { - SchemaProps: spec.SchemaProps{ - Description: "preferredVersion is the version preferred by the API server, which probably is the storage version.", - Default: map[string]interface{}{}, - Ref: ref(metav1.GroupVersionForDiscovery{}.OpenAPIModelName()), - }, - }, - "serverAddressByClientCIDRs": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "a map of client CIDR to server address that is serving this group. This is to help clients reach servers in the most network-efficient way possible. Clients can use the appropriate server address as per the CIDR that they match. In case of multiple matches, clients should use the longest matching CIDR. The server returns only those CIDRs that it thinks that the client can match. For example: the master will return an internal IP CIDR only, if the client reaches the server using an internal IP. Server looks at X-Forwarded-For header or X-Real-Ip header or request.RemoteAddr (in that order) to get the client IP.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(metav1.ServerAddressByClientCIDR{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - }, - Required: []string{"name", "versions"}, - }, - }, - Dependencies: []string{ - metav1.GroupVersionForDiscovery{}.OpenAPIModelName(), metav1.ServerAddressByClientCIDR{}.OpenAPIModelName()}, - } -} - -func schema_pkg_apis_meta_v1_APIGroupList(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "APIGroupList is a list of APIGroup, to allow clients to discover the API at /apis.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Type: []string{"string"}, - Format: "", - }, - }, - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", - Type: []string{"string"}, - Format: "", - }, - }, - "groups": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "groups is a list of APIGroup.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(metav1.APIGroup{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - }, - Required: []string{"groups"}, - }, - }, - Dependencies: []string{ - metav1.APIGroup{}.OpenAPIModelName()}, - } -} - -func schema_pkg_apis_meta_v1_APIResource(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "APIResource specifies the name of a resource and whether it is namespaced.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "name": { - SchemaProps: spec.SchemaProps{ - Description: "name is the plural name of the resource.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "singularName": { - SchemaProps: spec.SchemaProps{ - Description: "singularName is the singular name of the resource. This allows clients to handle plural and singular opaquely. The singularName is more correct for reporting status on a single item and both singular and plural are allowed from the kubectl CLI interface.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "namespaced": { - SchemaProps: spec.SchemaProps{ - Description: "namespaced indicates if a resource is namespaced or not.", - Default: false, - Type: []string{"boolean"}, - Format: "", - }, - }, - "group": { - SchemaProps: spec.SchemaProps{ - Description: "group is the preferred group of the resource. Empty implies the group of the containing resource list. For subresources, this may have a different value, for example: Scale\".", - Type: []string{"string"}, - Format: "", - }, - }, - "version": { - SchemaProps: spec.SchemaProps{ - Description: "version is the preferred version of the resource. Empty implies the version of the containing resource list For subresources, this may have a different value, for example: v1 (while inside a v1beta1 version of the core resource's group)\".", - Type: []string{"string"}, - Format: "", - }, - }, - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "kind is the kind for the resource (e.g. 'Foo' is the kind for a resource 'foo')", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "verbs": { - SchemaProps: spec.SchemaProps{ - Description: "verbs is a list of supported kube verbs (this includes get, list, watch, create, update, patch, delete, deletecollection, and proxy)", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - "shortNames": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "shortNames is a list of suggested short names of the resource.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - "categories": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "categories is a list of the grouped resources this resource belongs to (e.g. 'all')", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - "storageVersionHash": { - SchemaProps: spec.SchemaProps{ - Description: "The hash value of the storage version, the version this resource is converted to when written to the data store. Value must be treated as opaque by clients. Only equality comparison on the value is valid. This is an alpha feature and may change or be removed in the future. The field is populated by the apiserver only if the StorageVersionHash feature gate is enabled. This field will remain optional even if it graduates.", - Type: []string{"string"}, - Format: "", - }, - }, - }, - Required: []string{"name", "singularName", "namespaced", "kind", "verbs"}, - }, - }, - } -} - -func schema_pkg_apis_meta_v1_APIResourceList(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "APIResourceList is a list of APIResource, it is used to expose the name of the resources supported in a specific group and version, and if the resource is namespaced.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Type: []string{"string"}, - Format: "", - }, - }, - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", - Type: []string{"string"}, - Format: "", - }, - }, - "groupVersion": { - SchemaProps: spec.SchemaProps{ - Description: "groupVersion is the group and version this APIResourceList is for.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "resources": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "resources contains the name of the resources and if they are namespaced.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(metav1.APIResource{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - }, - Required: []string{"groupVersion", "resources"}, - }, - }, - Dependencies: []string{ - metav1.APIResource{}.OpenAPIModelName()}, - } -} - -func schema_pkg_apis_meta_v1_APIVersions(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "APIVersions lists the versions that are available, to allow clients to discover the API at /api, which is the root path of the legacy v1 API.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Type: []string{"string"}, - Format: "", - }, - }, - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", - Type: []string{"string"}, - Format: "", - }, - }, - "versions": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "versions are the api versions that are available.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - "serverAddressByClientCIDRs": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "a map of client CIDR to server address that is serving this group. This is to help clients reach servers in the most network-efficient way possible. Clients can use the appropriate server address as per the CIDR that they match. In case of multiple matches, clients should use the longest matching CIDR. The server returns only those CIDRs that it thinks that the client can match. For example: the master will return an internal IP CIDR only, if the client reaches the server using an internal IP. Server looks at X-Forwarded-For header or X-Real-Ip header or request.RemoteAddr (in that order) to get the client IP.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(metav1.ServerAddressByClientCIDR{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - }, - Required: []string{"versions", "serverAddressByClientCIDRs"}, - }, - }, - Dependencies: []string{ - metav1.ServerAddressByClientCIDR{}.OpenAPIModelName()}, - } -} - -func schema_pkg_apis_meta_v1_ApplyOptions(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "ApplyOptions may be provided when applying an API object. FieldManager is required for apply requests. ApplyOptions is equivalent to PatchOptions. It is provided as a convenience with documentation that speaks specifically to how the options fields relate to apply.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Type: []string{"string"}, - Format: "", - }, - }, - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", - Type: []string{"string"}, - Format: "", - }, - }, - "dryRun": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - "force": { - SchemaProps: spec.SchemaProps{ - Description: "Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people.", - Default: false, - Type: []string{"boolean"}, - Format: "", - }, - }, - "fieldManager": { - SchemaProps: spec.SchemaProps{ - Description: "fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - Required: []string{"force", "fieldManager"}, - }, - }, - } -} - -func schema_pkg_apis_meta_v1_Condition(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "Condition contains details for one aspect of the current state of this API Resource.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "type": { - SchemaProps: spec.SchemaProps{ - Description: "type of condition in CamelCase or in foo.example.com/CamelCase.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "status": { - SchemaProps: spec.SchemaProps{ - Description: "status of the condition, one of True, False, Unknown.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "observedGeneration": { - SchemaProps: spec.SchemaProps{ - Description: "observedGeneration represents the .metadata.generation that the condition was set based upon. For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date with respect to the current state of the instance.", - Type: []string{"integer"}, - Format: "int64", - }, - }, - "lastTransitionTime": { - SchemaProps: spec.SchemaProps{ - Description: "lastTransitionTime is the last time the condition transitioned from one status to another. This should be when the underlying condition changed. If that is not known, then using the time when the API field changed is acceptable.", - Ref: ref(metav1.Time{}.OpenAPIModelName()), - }, - }, - "reason": { - SchemaProps: spec.SchemaProps{ - Description: "reason contains a programmatic identifier indicating the reason for the condition's last transition. Producers of specific condition types may define expected values and meanings for this field, and whether the values are considered a guaranteed API. The value should be a CamelCase string. This field may not be empty.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "message": { - SchemaProps: spec.SchemaProps{ - Description: "message is a human readable message indicating details about the transition. This may be an empty string.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - Required: []string{"type", "status", "lastTransitionTime", "reason", "message"}, - }, - }, - Dependencies: []string{ - metav1.Time{}.OpenAPIModelName()}, - } -} - -func schema_pkg_apis_meta_v1_CreateOptions(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "CreateOptions may be provided when creating an API object.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Type: []string{"string"}, - Format: "", - }, - }, - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", - Type: []string{"string"}, - Format: "", - }, - }, - "dryRun": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - "fieldManager": { - SchemaProps: spec.SchemaProps{ - Description: "fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.", - Type: []string{"string"}, - Format: "", - }, - }, - "fieldValidation": { - SchemaProps: spec.SchemaProps{ - Description: "fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - } -} - -func schema_pkg_apis_meta_v1_DeleteOptions(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "DeleteOptions may be provided when deleting an API object.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Type: []string{"string"}, - Format: "", - }, - }, - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", - Type: []string{"string"}, - Format: "", - }, - }, - "gracePeriodSeconds": { - SchemaProps: spec.SchemaProps{ - Description: "The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.", - Type: []string{"integer"}, - Format: "int64", - }, - }, - "preconditions": { - SchemaProps: spec.SchemaProps{ - Description: "Must be fulfilled before a deletion is carried out. If not possible, a 409 Conflict status will be returned.", - Ref: ref(metav1.Preconditions{}.OpenAPIModelName()), - }, - }, - "orphanDependents": { - SchemaProps: spec.SchemaProps{ - Description: "Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.", - Type: []string{"boolean"}, - Format: "", - }, - }, - "propagationPolicy": { - SchemaProps: spec.SchemaProps{ - Description: "Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.", - Type: []string{"string"}, - Format: "", - }, - }, - "dryRun": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - "ignoreStoreReadErrorWithClusterBreakingPotential": { - SchemaProps: spec.SchemaProps{ - Description: "if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it", - Type: []string{"boolean"}, - Format: "", - }, - }, - }, - }, - }, - Dependencies: []string{ - metav1.Preconditions{}.OpenAPIModelName()}, - } -} - -func schema_pkg_apis_meta_v1_Duration(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "Duration is a wrapper around time.Duration which supports correct marshaling to YAML and JSON. In particular, it marshals into strings, which can be used as map keys in json.", - Type: metav1.Duration{}.OpenAPISchemaType(), - Format: metav1.Duration{}.OpenAPISchemaFormat(), - }, - }, - } -} - -func schema_pkg_apis_meta_v1_FieldSelectorRequirement(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "FieldSelectorRequirement is a selector that contains values, a key, and an operator that relates the key and values.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "key": { - SchemaProps: spec.SchemaProps{ - Description: "key is the field selector key that the requirement applies to.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "operator": { - SchemaProps: spec.SchemaProps{ - Description: "operator represents a key's relationship to a set of values. Valid operators are In, NotIn, Exists, DoesNotExist. The list of operators may grow in the future.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "values": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "values is an array of string values. If the operator is In or NotIn, the values array must be non-empty. If the operator is Exists or DoesNotExist, the values array must be empty.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - }, - Required: []string{"key", "operator"}, - }, - }, - } -} - -func schema_pkg_apis_meta_v1_FieldsV1(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "FieldsV1 stores a set of fields in a data structure like a Trie, in JSON format.\n\nEach key is either a '.' representing the field itself, and will always map to an empty set, or a string representing a sub-field or item. The string will follow one of these four formats: 'f:', where is the name of a field in a struct, or key in a map 'v:', where is the exact json formatted value of a list item 'i:', where is position of a item in a list 'k:', where is a map of a list item's key fields to their unique values If a key maps to an empty Fields value, the field that key represents is part of the set.\n\nThe exact format is defined in sigs.k8s.io/structured-merge-diff", - Type: []string{"object"}, - }, - }, - } -} - -func schema_pkg_apis_meta_v1_GetOptions(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "GetOptions is the standard query options to the standard REST get call.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Type: []string{"string"}, - Format: "", - }, - }, - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", - Type: []string{"string"}, - Format: "", - }, - }, - "resourceVersion": { - SchemaProps: spec.SchemaProps{ - Description: "resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details.\n\nDefaults to unset", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - } -} - -func schema_pkg_apis_meta_v1_GroupKind(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "GroupKind specifies a Group and a Kind, but does not force a version. This is useful for identifying concepts during lookup stages without having partially valid types", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "group": { - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "kind": { - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - Required: []string{"group", "kind"}, - }, - }, - } -} - -func schema_pkg_apis_meta_v1_GroupResource(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "GroupResource specifies a Group and a Resource, but does not force a version. This is useful for identifying concepts during lookup stages without having partially valid types", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "group": { - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "resource": { - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - Required: []string{"group", "resource"}, - }, - }, - } -} - -func schema_pkg_apis_meta_v1_GroupVersion(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "GroupVersion contains the \"group\" and the \"version\", which uniquely identifies the API.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "group": { - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "version": { - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - Required: []string{"group", "version"}, - }, - }, - } -} - -func schema_pkg_apis_meta_v1_GroupVersionForDiscovery(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "GroupVersion contains the \"group/version\" and \"version\" string of a version. It is made a struct to keep extensibility.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "groupVersion": { - SchemaProps: spec.SchemaProps{ - Description: "groupVersion specifies the API group and version in the form \"group/version\"", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "version": { - SchemaProps: spec.SchemaProps{ - Description: "version specifies the version in the form of \"version\". This is to save the clients the trouble of splitting the GroupVersion.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - Required: []string{"groupVersion", "version"}, - }, - }, - } -} - -func schema_pkg_apis_meta_v1_GroupVersionKind(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "GroupVersionKind unambiguously identifies a kind. It doesn't anonymously include GroupVersion to avoid automatic coercion. It doesn't use a GroupVersion to avoid custom marshalling", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "group": { - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "version": { - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "kind": { - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - Required: []string{"group", "version", "kind"}, - }, - }, - } -} - -func schema_pkg_apis_meta_v1_GroupVersionResource(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "GroupVersionResource unambiguously identifies a resource. It doesn't anonymously include GroupVersion to avoid automatic coercion. It doesn't use a GroupVersion to avoid custom marshalling", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "group": { - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "version": { - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "resource": { - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - Required: []string{"group", "version", "resource"}, - }, - }, - } -} - -func schema_pkg_apis_meta_v1_InternalEvent(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "InternalEvent makes watch.Event versioned", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "Type": { - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "Object": { - SchemaProps: spec.SchemaProps{ - Description: "Object is:\n * If Type is Added or Modified: the new state of the object.\n * If Type is Deleted: the state of the object immediately before deletion.\n * If Type is Bookmark: the object (instance of a type being watched) where\n only ResourceVersion field is set. On successful restart of watch from a\n bookmark resourceVersion, client is guaranteed to not get repeat event\n nor miss any events.\n * If Type is Error: *api.Status is recommended; other types may make sense\n depending on context.", - }, - }, - }, - Required: []string{"Type", "Object"}, - }, - }, - } -} - -func schema_pkg_apis_meta_v1_LabelSelector(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "A label selector is a label query over a set of resources. The result of matchLabels and matchExpressions are ANDed. An empty label selector matches all objects. A null label selector matches no objects.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "matchLabels": { - SchemaProps: spec.SchemaProps{ - Description: "matchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels map is equivalent to an element of matchExpressions, whose key field is \"key\", the operator is \"In\", and the values array contains only \"value\". The requirements are ANDed.", - Type: []string{"object"}, - AdditionalProperties: &spec.SchemaOrBool{ - Allows: true, - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - "matchExpressions": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "matchExpressions is a list of label selector requirements. The requirements are ANDed.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(metav1.LabelSelectorRequirement{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - }, - }, - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-map-type": "atomic", - }, - }, - }, - Dependencies: []string{ - metav1.LabelSelectorRequirement{}.OpenAPIModelName()}, - } -} - -func schema_pkg_apis_meta_v1_LabelSelectorRequirement(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "A label selector requirement is a selector that contains values, a key, and an operator that relates the key and values.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "key": { - SchemaProps: spec.SchemaProps{ - Description: "key is the label key that the selector applies to.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "operator": { - SchemaProps: spec.SchemaProps{ - Description: "operator represents a key's relationship to a set of values. Valid operators are In, NotIn, Exists and DoesNotExist.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "values": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "values is an array of string values. If the operator is In or NotIn, the values array must be non-empty. If the operator is Exists or DoesNotExist, the values array must be empty. This array is replaced during a strategic merge patch.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - }, - Required: []string{"key", "operator"}, - }, - }, - } -} - -func schema_pkg_apis_meta_v1_List(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "List holds a list of objects, which may not be known by the server.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Type: []string{"string"}, - Format: "", - }, - }, - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", - Type: []string{"string"}, - Format: "", - }, - }, - "metadata": { - SchemaProps: spec.SchemaProps{ - Description: "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Default: map[string]interface{}{}, - Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), - }, - }, - "items": { - SchemaProps: spec.SchemaProps{ - Description: "List of objects", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Ref: ref(runtime.RawExtension{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - }, - Required: []string{"items"}, - }, - }, - Dependencies: []string{ - metav1.ListMeta{}.OpenAPIModelName(), runtime.RawExtension{}.OpenAPIModelName()}, - } -} - -func schema_pkg_apis_meta_v1_ListMeta(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "ListMeta describes metadata that synthetic resources must have, including lists and various status objects. A resource may have only one of {ObjectMeta, ListMeta}.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "selfLink": { - SchemaProps: spec.SchemaProps{ - Description: "Deprecated: selfLink is a legacy read-only field that is no longer populated by the system.", - Type: []string{"string"}, - Format: "", - }, - }, - "resourceVersion": { - SchemaProps: spec.SchemaProps{ - Description: "String that identifies the server's internal version of this object that can be used by clients to determine when objects have changed. Value must be treated as opaque by clients and passed unmodified back to the server. Populated by the system. Read-only. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#concurrency-control-and-consistency", - Type: []string{"string"}, - Format: "", - }, - }, - "continue": { - SchemaProps: spec.SchemaProps{ - Description: "continue may be set if the user set a limit on the number of items returned, and indicates that the server has more data available. The value is opaque and may be used to issue another request to the endpoint that served this list to retrieve the next set of available objects. Continuing a consistent list may not be possible if the server configuration has changed or more than a few minutes have passed. The resourceVersion field returned when using this continue value will be identical to the value in the first response, unless you have received this token from an error message.", - Type: []string{"string"}, - Format: "", - }, - }, - "remainingItemCount": { - SchemaProps: spec.SchemaProps{ - Description: "remainingItemCount is the number of subsequent items in the list which are not included in this list response. If the list request contained label or field selectors, then the number of remaining items is unknown and the field will be left unset and omitted during serialization. If the list is complete (either because it is not chunking or because this is the last chunk), then there are no more remaining items and this field will be left unset and omitted during serialization. Servers older than v1.15 do not set this field. The intended use of the remainingItemCount is *estimating* the size of a collection. Clients should not rely on the remainingItemCount to be set or to be exact.", - Type: []string{"integer"}, - Format: "int64", - }, - }, - }, - }, - }, - } -} - -func schema_pkg_apis_meta_v1_ListOptions(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "ListOptions is the query options to a standard REST list call.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Type: []string{"string"}, - Format: "", - }, - }, - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", - Type: []string{"string"}, - Format: "", - }, - }, - "labelSelector": { - SchemaProps: spec.SchemaProps{ - Description: "A selector to restrict the list of returned objects by their labels. Defaults to everything.", - Type: []string{"string"}, - Format: "", - }, - }, - "fieldSelector": { - SchemaProps: spec.SchemaProps{ - Description: "A selector to restrict the list of returned objects by their fields. Defaults to everything.", - Type: []string{"string"}, - Format: "", - }, - }, - "watch": { - SchemaProps: spec.SchemaProps{ - Description: "Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.", - Type: []string{"boolean"}, - Format: "", - }, - }, - "allowWatchBookmarks": { - SchemaProps: spec.SchemaProps{ - Description: "allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.", - Type: []string{"boolean"}, - Format: "", - }, - }, - "resourceVersion": { - SchemaProps: spec.SchemaProps{ - Description: "resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details.\n\nDefaults to unset", - Type: []string{"string"}, - Format: "", - }, - }, - "resourceVersionMatch": { - SchemaProps: spec.SchemaProps{ - Description: "resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details.\n\nDefaults to unset", - Type: []string{"string"}, - Format: "", - }, - }, - "timeoutSeconds": { - SchemaProps: spec.SchemaProps{ - Description: "Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.", - Type: []string{"integer"}, - Format: "int64", - }, - }, - "limit": { - SchemaProps: spec.SchemaProps{ - Description: "limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true.\n\nThe server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.", - Type: []string{"integer"}, - Format: "int64", - }, - }, - "continue": { - SchemaProps: spec.SchemaProps{ - Description: "The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\".\n\nThis field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.", - Type: []string{"string"}, - Format: "", - }, - }, - "sendInitialEvents": { - SchemaProps: spec.SchemaProps{ - Description: "`sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched.\n\nWhen `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan\n is interpreted as \"data at least as new as the provided `resourceVersion`\"\n and the bookmark event is send when the state is synced\n to a `resourceVersion` at least as fresh as the one provided by the ListOptions.\n If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the\n bookmark event is send when the state is synced at least to the moment\n when request started being processed.\n- `resourceVersionMatch` set to any other value or unset\n Invalid error is returned.\n\nDefaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.", - Type: []string{"boolean"}, - Format: "", - }, - }, - }, - }, - }, - } -} - -func schema_pkg_apis_meta_v1_ManagedFieldsEntry(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "ManagedFieldsEntry is a workflow-id, a FieldSet and the group version of the resource that the fieldset applies to.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "manager": { - SchemaProps: spec.SchemaProps{ - Description: "Manager is an identifier of the workflow managing these fields.", - Type: []string{"string"}, - Format: "", - }, - }, - "operation": { - SchemaProps: spec.SchemaProps{ - Description: "Operation is the type of operation which lead to this ManagedFieldsEntry being created. The only valid values for this field are 'Apply' and 'Update'.", - Type: []string{"string"}, - Format: "", - }, - }, - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "APIVersion defines the version of this resource that this field set applies to. The format is \"group/version\" just like the top-level APIVersion field. It is necessary to track the version of a field set because it cannot be automatically converted.", - Type: []string{"string"}, - Format: "", - }, - }, - "time": { - SchemaProps: spec.SchemaProps{ - Description: "Time is the timestamp of when the ManagedFields entry was added. The timestamp will also be updated if a field is added, the manager changes any of the owned fields value or removes a field. The timestamp does not update when a field is removed from the entry because another manager took it over.", - Ref: ref(metav1.Time{}.OpenAPIModelName()), - }, - }, - "fieldsType": { - SchemaProps: spec.SchemaProps{ - Description: "FieldsType is the discriminator for the different fields format and version. There is currently only one possible value: \"FieldsV1\"", - Type: []string{"string"}, - Format: "", - }, - }, - "fieldsV1": { - SchemaProps: spec.SchemaProps{ - Description: "FieldsV1 holds the first JSON version format as described in the \"FieldsV1\" type.", - Ref: ref(metav1.FieldsV1{}.OpenAPIModelName()), - }, - }, - "subresource": { - SchemaProps: spec.SchemaProps{ - Description: "Subresource is the name of the subresource used to update that object, or empty string if the object was updated through the main resource. The value of this field is used to distinguish between managers, even if they share the same name. For example, a status update will be distinct from a regular update using the same manager name. Note that the APIVersion field is not related to the Subresource field and it always corresponds to the version of the main resource.", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - Dependencies: []string{ - metav1.FieldsV1{}.OpenAPIModelName(), metav1.Time{}.OpenAPIModelName()}, - } -} - -func schema_pkg_apis_meta_v1_MicroTime(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "MicroTime is version of Time with microsecond level precision.", - Type: metav1.MicroTime{}.OpenAPISchemaType(), - Format: metav1.MicroTime{}.OpenAPISchemaFormat(), - }, - }, - } -} - -func schema_pkg_apis_meta_v1_ObjectMeta(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "ObjectMeta is metadata that all persisted resources must have, which includes all objects users must create.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "name": { - SchemaProps: spec.SchemaProps{ - Description: "Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names#names", - Type: []string{"string"}, - Format: "", - }, - }, - "generateName": { - SchemaProps: spec.SchemaProps{ - Description: "GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server.\n\nIf this field is specified and the generated name exists, the server will return a 409.\n\nApplied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#idempotency", - Type: []string{"string"}, - Format: "", - }, - }, - "namespace": { - SchemaProps: spec.SchemaProps{ - Description: "Namespace defines the space within which each name must be unique. An empty namespace is equivalent to the \"default\" namespace, but \"default\" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty.\n\nMust be a DNS_LABEL. Cannot be updated. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/namespaces", - Type: []string{"string"}, - Format: "", - }, - }, - "selfLink": { - SchemaProps: spec.SchemaProps{ - Description: "Deprecated: selfLink is a legacy read-only field that is no longer populated by the system.", - Type: []string{"string"}, - Format: "", - }, - }, - "uid": { - SchemaProps: spec.SchemaProps{ - Description: "UID is the unique in time and space value for this object. It is typically generated by the server on successful creation of a resource and is not allowed to change on PUT operations.\n\nPopulated by the system. Read-only. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names#uids", - Type: []string{"string"}, - Format: "", - }, - }, - "resourceVersion": { - SchemaProps: spec.SchemaProps{ - Description: "An opaque value that represents the internal version of this object that can be used by clients to determine when objects have changed. May be used for optimistic concurrency, change detection, and the watch operation on a resource or set of resources. Clients must treat these values as opaque and passed unmodified back to the server. They may only be valid for a particular resource or set of resources.\n\nPopulated by the system. Read-only. Value must be treated as opaque by clients and . More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#concurrency-control-and-consistency", - Type: []string{"string"}, - Format: "", - }, - }, - "generation": { - SchemaProps: spec.SchemaProps{ - Description: "A sequence number representing a specific generation of the desired state. Populated by the system. Read-only.", - Type: []string{"integer"}, - Format: "int64", - }, - }, - "creationTimestamp": { - SchemaProps: spec.SchemaProps{ - Description: "CreationTimestamp is a timestamp representing the server time when this object was created. It is not guaranteed to be set in happens-before order across separate operations. Clients may not set this value. It is represented in RFC3339 form and is in UTC.\n\nPopulated by the system. Read-only. Null for lists. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata", - Ref: ref(metav1.Time{}.OpenAPIModelName()), - }, - }, - "deletionTimestamp": { - SchemaProps: spec.SchemaProps{ - Description: "DeletionTimestamp is RFC 3339 date and time at which this resource will be deleted. This field is set by the server when a graceful deletion is requested by the user, and is not directly settable by a client. The resource is expected to be deleted (no longer visible from resource lists, and not reachable by name) after the time in this field, once the finalizers list is empty. As long as the finalizers list contains items, deletion is blocked. Once the deletionTimestamp is set, this value may not be unset or be set further into the future, although it may be shortened or the resource may be deleted prior to this time. For example, a user may request that a pod is deleted in 30 seconds. The Kubelet will react by sending a graceful termination signal to the containers in the pod. After that 30 seconds, the Kubelet will send a hard termination signal (SIGKILL) to the container and after cleanup, remove the pod from the API. In the presence of network partitions, this object may still exist after this timestamp, until an administrator or automated process can determine the resource is fully terminated. If not set, graceful deletion of the object has not been requested.\n\nPopulated by the system when a graceful deletion is requested. Read-only. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata", - Ref: ref(metav1.Time{}.OpenAPIModelName()), - }, - }, - "deletionGracePeriodSeconds": { - SchemaProps: spec.SchemaProps{ - Description: "Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only.", - Type: []string{"integer"}, - Format: "int64", - }, - }, - "labels": { - SchemaProps: spec.SchemaProps{ - Description: "Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/labels", - Type: []string{"object"}, - AdditionalProperties: &spec.SchemaOrBool{ - Allows: true, - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - "annotations": { - SchemaProps: spec.SchemaProps{ - Description: "Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/annotations", - Type: []string{"object"}, - AdditionalProperties: &spec.SchemaOrBool{ - Allows: true, - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - "ownerReferences": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-map-keys": []interface{}{ - "uid", - }, - "x-kubernetes-list-type": "map", - "x-kubernetes-patch-merge-key": "uid", - "x-kubernetes-patch-strategy": "merge", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "List of objects depended by this object. If ALL objects in the list have been deleted, this object will be garbage collected. If this object is managed by a controller, then an entry in this list will point to this controller, with the controller field set to true. There cannot be more than one managing controller.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(metav1.OwnerReference{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "finalizers": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "set", - "x-kubernetes-patch-strategy": "merge", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. Finalizers may be processed and removed in any order. Order is NOT enforced because it introduces significant risk of stuck finalizers. finalizers is a shared field, any actor with permission can reorder it. If the finalizer list is processed in order, then this can lead to a situation in which the component responsible for the first finalizer in the list is waiting for a signal (field value, external system, or other) produced by a component responsible for a finalizer later in the list, resulting in a deadlock. Without enforced ordering finalizers are free to order amongst themselves and are not vulnerable to ordering changes in the list.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - "managedFields": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "ManagedFields maps workflow-id and version to the set of fields that are managed by that workflow. This is mostly for internal housekeeping, and users typically shouldn't need to set or understand this field. A workflow can be the user's name, a controller's name, or the name of a specific apply path like \"ci-cd\". The set of fields is always in the version that the workflow used when modifying the object.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(metav1.ManagedFieldsEntry{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - }, - }, - }, - Dependencies: []string{ - metav1.ManagedFieldsEntry{}.OpenAPIModelName(), metav1.OwnerReference{}.OpenAPIModelName(), metav1.Time{}.OpenAPIModelName()}, - } -} - -func schema_pkg_apis_meta_v1_OwnerReference(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "OwnerReference contains enough information to let you identify an owning object. An owning object must be in the same namespace as the dependent, or be cluster-scoped, so there is no namespace field.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "API version of the referent.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind of the referent. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "name": { - SchemaProps: spec.SchemaProps{ - Description: "Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names#names", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "uid": { - SchemaProps: spec.SchemaProps{ - Description: "UID of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names#uids", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "controller": { - SchemaProps: spec.SchemaProps{ - Description: "If true, this reference points to the managing controller.", - Type: []string{"boolean"}, - Format: "", - }, - }, - "blockOwnerDeletion": { - SchemaProps: spec.SchemaProps{ - Description: "If true, AND if the owner has the \"foregroundDeletion\" finalizer, then the owner cannot be deleted from the key-value store until this reference is removed. See https://kubernetes.io/docs/concepts/architecture/garbage-collection/#foreground-deletion for how the garbage collector interacts with this field and enforces the foreground deletion. Defaults to false. To set this field, a user needs \"delete\" permission of the owner, otherwise 422 (Unprocessable Entity) will be returned.", - Type: []string{"boolean"}, - Format: "", - }, - }, - }, - Required: []string{"apiVersion", "kind", "name", "uid"}, - }, - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-map-type": "atomic", - }, - }, - }, - } -} - -func schema_pkg_apis_meta_v1_PartialObjectMetadata(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "PartialObjectMetadata is a generic representation of any object with ObjectMeta. It allows clients to get access to a particular ObjectMeta schema without knowing the details of the version.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Type: []string{"string"}, - Format: "", - }, - }, - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", - Type: []string{"string"}, - Format: "", - }, - }, - "metadata": { - SchemaProps: spec.SchemaProps{ - Description: "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata", - Default: map[string]interface{}{}, - Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - Dependencies: []string{ - metav1.ObjectMeta{}.OpenAPIModelName()}, - } -} - -func schema_pkg_apis_meta_v1_PartialObjectMetadataList(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "PartialObjectMetadataList contains a list of objects containing only their metadata", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Type: []string{"string"}, - Format: "", - }, - }, - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", - Type: []string{"string"}, - Format: "", - }, - }, - "metadata": { - SchemaProps: spec.SchemaProps{ - Description: "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Default: map[string]interface{}{}, - Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), - }, - }, - "items": { - SchemaProps: spec.SchemaProps{ - Description: "items contains each of the included items.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(metav1.PartialObjectMetadata{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - }, - Required: []string{"items"}, - }, - }, - Dependencies: []string{ - metav1.ListMeta{}.OpenAPIModelName(), metav1.PartialObjectMetadata{}.OpenAPIModelName()}, - } -} - -func schema_pkg_apis_meta_v1_Patch(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "Patch is provided to give a concrete name and type to the Kubernetes PATCH request body.", - Type: []string{"object"}, - }, - }, - } -} - -func schema_pkg_apis_meta_v1_PatchOptions(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "PatchOptions may be provided when patching an API object. PatchOptions is meant to be a superset of UpdateOptions.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Type: []string{"string"}, - Format: "", - }, - }, - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", - Type: []string{"string"}, - Format: "", - }, - }, - "dryRun": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - "force": { - SchemaProps: spec.SchemaProps{ - Description: "Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.", - Type: []string{"boolean"}, - Format: "", - }, - }, - "fieldManager": { - SchemaProps: spec.SchemaProps{ - Description: "fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).", - Type: []string{"string"}, - Format: "", - }, - }, - "fieldValidation": { - SchemaProps: spec.SchemaProps{ - Description: "fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - } -} - -func schema_pkg_apis_meta_v1_Preconditions(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "Preconditions must be fulfilled before an operation (update, delete, etc.) is carried out.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "uid": { - SchemaProps: spec.SchemaProps{ - Description: "Specifies the target UID.", - Type: []string{"string"}, - Format: "", - }, - }, - "resourceVersion": { - SchemaProps: spec.SchemaProps{ - Description: "Specifies the target ResourceVersion", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - } -} - -func schema_pkg_apis_meta_v1_RootPaths(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "RootPaths lists the paths available at root. For example: \"/healthz\", \"/apis\".", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "paths": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "paths are the paths available at root.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - }, - Required: []string{"paths"}, - }, - }, - } -} - -func schema_pkg_apis_meta_v1_ServerAddressByClientCIDR(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "ServerAddressByClientCIDR helps the client to determine the server address that they should use, depending on the clientCIDR that they match.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "clientCIDR": { - SchemaProps: spec.SchemaProps{ - Description: "The CIDR with which clients can match their IP to figure out the server address that they should use.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "serverAddress": { - SchemaProps: spec.SchemaProps{ - Description: "Address of this server, suitable for a client that matches the above CIDR. This can be a hostname, hostname:port, IP or IP:port.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - Required: []string{"clientCIDR", "serverAddress"}, - }, - }, - } -} - -func schema_pkg_apis_meta_v1_Status(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "Status is a return value for calls that don't return other objects.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Type: []string{"string"}, - Format: "", - }, - }, - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", - Type: []string{"string"}, - Format: "", - }, - }, - "metadata": { - SchemaProps: spec.SchemaProps{ - Description: "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Default: map[string]interface{}{}, - Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), - }, - }, - "status": { - SchemaProps: spec.SchemaProps{ - Description: "Status of the operation. One of: \"Success\" or \"Failure\". More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status", - Type: []string{"string"}, - Format: "", - }, - }, - "message": { - SchemaProps: spec.SchemaProps{ - Description: "A human-readable description of the status of this operation.", - Type: []string{"string"}, - Format: "", - }, - }, - "reason": { - SchemaProps: spec.SchemaProps{ - Description: "A machine-readable description of why this operation is in the \"Failure\" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it.", - Type: []string{"string"}, - Format: "", - }, - }, - "details": { - SchemaProps: spec.SchemaProps{ - Description: "Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type.", - Ref: ref(metav1.StatusDetails{}.OpenAPIModelName()), - }, - }, - "code": { - SchemaProps: spec.SchemaProps{ - Description: "Suggested HTTP return code for this status, 0 if not set.", - Type: []string{"integer"}, - Format: "int32", - }, - }, - }, - }, - }, - Dependencies: []string{ - metav1.ListMeta{}.OpenAPIModelName(), metav1.StatusDetails{}.OpenAPIModelName()}, - } -} - -func schema_pkg_apis_meta_v1_StatusCause(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "StatusCause provides more information about an api.Status failure, including cases when multiple errors are encountered.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "reason": { - SchemaProps: spec.SchemaProps{ - Description: "A machine-readable description of the cause of the error. If this value is empty there is no information available.", - Type: []string{"string"}, - Format: "", - }, - }, - "message": { - SchemaProps: spec.SchemaProps{ - Description: "A human-readable description of the cause of the error. This field may be presented as-is to a reader.", - Type: []string{"string"}, - Format: "", - }, - }, - "field": { - SchemaProps: spec.SchemaProps{ - Description: "The field of the resource that has caused this error, as named by its JSON serialization. May include dot and postfix notation for nested attributes. Arrays are zero-indexed. Fields may appear more than once in an array of causes due to fields having multiple errors. Optional.\n\nExamples:\n \"name\" - the field \"name\" on the current resource\n \"items[0].name\" - the field \"name\" on the first array entry in \"items\"", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - } -} - -func schema_pkg_apis_meta_v1_StatusDetails(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "StatusDetails is a set of additional properties that MAY be set by the server to provide additional information about a response. The Reason field of a Status object defines what attributes will be set. Clients must ignore fields that do not match the defined type of each attribute, and should assume that any attribute may be empty, invalid, or under defined.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "name": { - SchemaProps: spec.SchemaProps{ - Description: "The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described).", - Type: []string{"string"}, - Format: "", - }, - }, - "group": { - SchemaProps: spec.SchemaProps{ - Description: "The group attribute of the resource associated with the status StatusReason.", - Type: []string{"string"}, - Format: "", - }, - }, - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "The kind attribute of the resource associated with the status StatusReason. On some operations may differ from the requested resource Kind. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Type: []string{"string"}, - Format: "", - }, - }, - "uid": { - SchemaProps: spec.SchemaProps{ - Description: "UID of the resource. (when there is a single resource which can be described). More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names#uids", - Type: []string{"string"}, - Format: "", - }, - }, - "causes": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(metav1.StatusCause{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "retryAfterSeconds": { - SchemaProps: spec.SchemaProps{ - Description: "If specified, the time in seconds before the operation should be retried. Some errors may indicate the client must take an alternate action - for those errors this field may indicate how long to wait before taking the alternate action.", - Type: []string{"integer"}, - Format: "int32", - }, - }, - }, - }, - }, - Dependencies: []string{ - metav1.StatusCause{}.OpenAPIModelName()}, - } -} - -func schema_pkg_apis_meta_v1_Table(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "Table is a tabular representation of a set of API resources. The server transforms the object into a set of preferred columns for quickly reviewing the objects.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Type: []string{"string"}, - Format: "", - }, - }, - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", - Type: []string{"string"}, - Format: "", - }, - }, - "metadata": { - SchemaProps: spec.SchemaProps{ - Description: "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Default: map[string]interface{}{}, - Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), - }, - }, - "columnDefinitions": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "columnDefinitions describes each column in the returned items array. The number of cells per row will always match the number of column definitions.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(metav1.TableColumnDefinition{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "rows": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "rows is the list of items in the table.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(metav1.TableRow{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - }, - Required: []string{"columnDefinitions", "rows"}, - }, - }, - Dependencies: []string{ - metav1.ListMeta{}.OpenAPIModelName(), metav1.TableColumnDefinition{}.OpenAPIModelName(), metav1.TableRow{}.OpenAPIModelName()}, - } -} - -func schema_pkg_apis_meta_v1_TableColumnDefinition(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "TableColumnDefinition contains information about a column returned in the Table.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "name": { - SchemaProps: spec.SchemaProps{ - Description: "name is a human readable name for the column.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "type": { - SchemaProps: spec.SchemaProps{ - Description: "type is an OpenAPI type definition for this column, such as number, integer, string, or array. See https://github.com/OAI/OpenAPI-Specification/blob/master/versions/2.0.md#data-types for more.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "format": { - SchemaProps: spec.SchemaProps{ - Description: "format is an optional OpenAPI type modifier for this column. A format modifies the type and imposes additional rules, like date or time formatting for a string. The 'name' format is applied to the primary identifier column which has type 'string' to assist in clients identifying column is the resource name. See https://github.com/OAI/OpenAPI-Specification/blob/master/versions/2.0.md#data-types for more.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "description": { - SchemaProps: spec.SchemaProps{ - Description: "description is a human readable description of this column.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "priority": { - SchemaProps: spec.SchemaProps{ - Description: "priority is an integer defining the relative importance of this column compared to others. Lower numbers are considered higher priority. Columns that may be omitted in limited space scenarios should be given a higher priority.", - Default: 0, - Type: []string{"integer"}, - Format: "int32", - }, - }, - }, - Required: []string{"name", "type", "format", "description", "priority"}, - }, - }, - } -} - -func schema_pkg_apis_meta_v1_TableOptions(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "TableOptions are used when a Table is requested by the caller.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Type: []string{"string"}, - Format: "", - }, - }, - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", - Type: []string{"string"}, - Format: "", - }, - }, - "includeObject": { - SchemaProps: spec.SchemaProps{ - Description: "includeObject decides whether to include each object along with its columnar information. Specifying \"None\" will return no object, specifying \"Object\" will return the full object contents, and specifying \"Metadata\" (the default) will return the object's metadata in the PartialObjectMetadata kind in version v1beta1 of the meta.k8s.io API group.", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - } -} - -func schema_pkg_apis_meta_v1_TableRow(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "TableRow is an individual row in a table.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "cells": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "cells will be as wide as the column definitions array and may contain strings, numbers (float64 or int64), booleans, simple maps, lists, or null. See the type field of the column definition for a more detailed description.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Type: []string{"object"}, - Format: "", - }, - }, - }, - }, - }, - "conditions": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "conditions describe additional status of a row that are relevant for a human user. These conditions apply to the row, not to the object, and will be specific to table output. The only defined condition type is 'Completed', for a row that indicates a resource that has run to completion and can be given less visual priority.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(metav1.TableRowCondition{}.OpenAPIModelName()), - }, - }, - }, - }, - }, - "object": { - SchemaProps: spec.SchemaProps{ - Description: "This field contains the requested additional information about each object based on the includeObject policy when requesting the Table. If \"None\", this field is empty, if \"Object\" this will be the default serialization of the object for the current API version, and if \"Metadata\" (the default) will contain the object metadata. Check the returned kind and apiVersion of the object before parsing. The media type of the object will always match the enclosing list - if this as a JSON table, these will be JSON encoded objects.", - Ref: ref(runtime.RawExtension{}.OpenAPIModelName()), - }, - }, - }, - Required: []string{"cells"}, - }, - }, - Dependencies: []string{ - metav1.TableRowCondition{}.OpenAPIModelName(), runtime.RawExtension{}.OpenAPIModelName()}, - } -} - -func schema_pkg_apis_meta_v1_TableRowCondition(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "TableRowCondition allows a row to be marked with additional information.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "type": { - SchemaProps: spec.SchemaProps{ - Description: "Type of row condition. The only defined value is 'Completed' indicating that the object this row represents has reached a completed state and may be given less visual priority than other rows. Clients are not required to honor any conditions but should be consistent where possible about handling the conditions.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "status": { - SchemaProps: spec.SchemaProps{ - Description: "Status of the condition, one of True, False, Unknown.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "reason": { - SchemaProps: spec.SchemaProps{ - Description: "(brief) machine readable reason for the condition's last transition.", - Type: []string{"string"}, - Format: "", - }, - }, - "message": { - SchemaProps: spec.SchemaProps{ - Description: "Human readable message indicating details about last transition.", - Type: []string{"string"}, - Format: "", - }, - }, - }, - Required: []string{"type", "status"}, - }, - }, - } -} - -func schema_pkg_apis_meta_v1_Time(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "Time is a wrapper around time.Time which supports correct marshaling to YAML and JSON. Wrappers are provided for many of the factory methods that the time package offers.", - Type: metav1.Time{}.OpenAPISchemaType(), - Format: metav1.Time{}.OpenAPISchemaFormat(), - }, - }, - } -} - -func schema_pkg_apis_meta_v1_Timestamp(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "Timestamp is a struct that is equivalent to Time, but intended for protobuf marshalling/unmarshalling. It is generated into a serialization that matches Time. Do not use in Go structs.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "seconds": { - SchemaProps: spec.SchemaProps{ - Description: "Represents seconds of UTC time since Unix epoch 1970-01-01T00:00:00Z. Must be from 0001-01-01T00:00:00Z to 9999-12-31T23:59:59Z inclusive.", - Default: 0, - Type: []string{"integer"}, - Format: "int64", - }, - }, - "nanos": { - SchemaProps: spec.SchemaProps{ - Description: "Non-negative fractions of a second at nanosecond resolution. Negative second values with fractions must still have non-negative nanos values that count forward in time. Must be from 0 to 999,999,999 inclusive. This field may be limited in precision depending on context.", - Default: 0, - Type: []string{"integer"}, - Format: "int32", - }, - }, - }, - Required: []string{"seconds", "nanos"}, - }, - }, - } -} - -func schema_pkg_apis_meta_v1_TypeMeta(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "TypeMeta describes an individual object in an API response or request with strings representing the type of the object and its API schema version. Structures that are versioned or persisted should inline TypeMeta.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Type: []string{"string"}, - Format: "", - }, - }, - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - } -} - -func schema_pkg_apis_meta_v1_UpdateOptions(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "UpdateOptions may be provided when updating an API object. All fields in UpdateOptions should also be present in PatchOptions.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Type: []string{"string"}, - Format: "", - }, - }, - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", - Type: []string{"string"}, - Format: "", - }, - }, - "dryRun": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - "fieldManager": { - SchemaProps: spec.SchemaProps{ - Description: "fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.", - Type: []string{"string"}, - Format: "", - }, - }, - "fieldValidation": { - SchemaProps: spec.SchemaProps{ - Description: "fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.", - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - } -} - -func schema_pkg_apis_meta_v1_WatchEvent(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "Event represents a single event to a watched resource.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "type": { - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "object": { - SchemaProps: spec.SchemaProps{ - Description: "Object is:\n * If Type is Added or Modified: the new state of the object.\n * If Type is Deleted: the state of the object immediately before deletion.\n * If Type is Error: *Status is recommended; other types may make sense\n depending on context.", - Ref: ref(runtime.RawExtension{}.OpenAPIModelName()), - }, - }, - }, - Required: []string{"type", "object"}, - }, - }, - Dependencies: []string{ - runtime.RawExtension{}.OpenAPIModelName()}, - } -} - -func schema_k8sio_apimachinery_pkg_runtime_RawExtension(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "RawExtension is used to hold extensions in external versions.\n\nTo use this, make a field which has RawExtension as its type in your external, versioned struct, and Object in your internal struct. You also need to register your various plugin types.\n\n// Internal package:\n\n\ttype MyAPIObject struct {\n\t\truntime.TypeMeta `json:\",inline\"`\n\t\tMyPlugin runtime.Object `json:\"myPlugin\"`\n\t}\n\n\ttype PluginA struct {\n\t\tAOption string `json:\"aOption\"`\n\t}\n\n// External package:\n\n\ttype MyAPIObject struct {\n\t\truntime.TypeMeta `json:\",inline\"`\n\t\tMyPlugin runtime.RawExtension `json:\"myPlugin\"`\n\t}\n\n\ttype PluginA struct {\n\t\tAOption string `json:\"aOption\"`\n\t}\n\n// On the wire, the JSON will look something like this:\n\n\t{\n\t\t\"kind\":\"MyAPIObject\",\n\t\t\"apiVersion\":\"v1\",\n\t\t\"myPlugin\": {\n\t\t\t\"kind\":\"PluginA\",\n\t\t\t\"aOption\":\"foo\",\n\t\t},\n\t}\n\nSo what happens? Decode first uses json or yaml to unmarshal the serialized data into your external MyAPIObject. That causes the raw JSON to be stored, but not unpacked. The next step is to copy (using pkg/conversion) into the internal struct. The runtime package's DefaultScheme has conversion functions installed which will unpack the JSON stored in RawExtension, turning it into the correct object type, and storing it in the Object. (TODO: In the case where the object is of an unknown type, a runtime.Unknown object will be created and stored.)", - Type: []string{"object"}, - }, - }, - } -} - -func schema_k8sio_apimachinery_pkg_runtime_TypeMeta(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "TypeMeta is shared by all top level objects. The proper way to use it is to inline it in your type, like this:\n\n\ttype MyAwesomeAPIObject struct {\n\t runtime.TypeMeta `json:\",inline\"`\n\t ... // other fields\n\t}\n\nfunc (obj *MyAwesomeAPIObject) SetGroupVersionKind(gvk *metav1.GroupVersionKind) { metav1.UpdateTypeMeta(obj,gvk) }; GroupVersionKind() *GroupVersionKind\n\nTypeMeta is provided here for convenience. You may use it directly from this package or define your own with the same fields.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Type: []string{"string"}, - Format: "", - }, - }, - "kind": { - SchemaProps: spec.SchemaProps{ - Type: []string{"string"}, - Format: "", - }, - }, - }, - }, - }, - } -} - -func schema_k8sio_apimachinery_pkg_runtime_Unknown(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "Unknown allows api objects with unknown types to be passed-through. This can be used to deal with the API objects from a plug-in. Unknown objects still have functioning TypeMeta features-- kind, version, etc. metadata and field mutatation.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Type: []string{"string"}, - Format: "", - }, - }, - "kind": { - SchemaProps: spec.SchemaProps{ - Type: []string{"string"}, - Format: "", - }, - }, - "ContentEncoding": { - SchemaProps: spec.SchemaProps{ - Description: "ContentEncoding is encoding used to encode 'Raw' data. Unspecified means no encoding.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "ContentType": { - SchemaProps: spec.SchemaProps{ - Description: "ContentType is serialization method used to serialize 'Raw'. Unspecified means ContentTypeJSON.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - Required: []string{"ContentEncoding", "ContentType"}, - }, - }, - } -} - -func schema_k8sio_apimachinery_pkg_version_Info(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "Info contains versioning information. how we'll want to distribute that information.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "major": { - SchemaProps: spec.SchemaProps{ - Description: "Major is the major version of the binary version", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "minor": { - SchemaProps: spec.SchemaProps{ - Description: "Minor is the minor version of the binary version", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "emulationMajor": { - SchemaProps: spec.SchemaProps{ - Description: "EmulationMajor is the major version of the emulation version", - Type: []string{"string"}, - Format: "", - }, - }, - "emulationMinor": { - SchemaProps: spec.SchemaProps{ - Description: "EmulationMinor is the minor version of the emulation version", - Type: []string{"string"}, - Format: "", - }, - }, - "minCompatibilityMajor": { - SchemaProps: spec.SchemaProps{ - Description: "MinCompatibilityMajor is the major version of the minimum compatibility version", - Type: []string{"string"}, - Format: "", - }, - }, - "minCompatibilityMinor": { - SchemaProps: spec.SchemaProps{ - Description: "MinCompatibilityMinor is the minor version of the minimum compatibility version", - Type: []string{"string"}, - Format: "", - }, - }, - "gitVersion": { - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "gitCommit": { - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "gitTreeState": { - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "buildDate": { - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "goVersion": { - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "compiler": { - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "platform": { - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - Required: []string{"major", "minor", "gitVersion", "gitCommit", "gitTreeState", "buildDate", "goVersion", "compiler", "platform"}, - }, - }, + "k8s.io/apimachinery/pkg/apis/meta/v1.Time"}, } } diff --git a/tools/apiserver-runtime-gen/main.go b/tools/apiserver-runtime-gen/main.go index 50beb8d6..46b0460d 100644 --- a/tools/apiserver-runtime-gen/main.go +++ b/tools/apiserver-runtime-gen/main.go @@ -65,7 +65,7 @@ func runE(cmd *cobra.Command, args []string) error { for _, gen := range generators { // nolint:gosec if gen == "openapi-gen" { - err := run(exec.Command("go", "install", "k8s.io/kube-openapi/cmd/openapi-gen@latest")) + err := run(exec.Command("go", "install", "k8s.io/kube-openapi/cmd/openapi-gen")) if err != nil { return err } @@ -164,7 +164,7 @@ func doGen() error { "k8s.io/apimachinery/pkg/version", } cmdArgs = append(cmdArgs, typeVersions...) - err := run(getCmdSimple("bin/openapi-gen", cmdArgs...)) + err := run(getCmdSimple("openapi-gen", cmdArgs...)) if err != nil { return err From 45e18e5ec8f60a272be2c8edf2d979b09887345c Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Wed, 18 Feb 2026 17:29:08 +0100 Subject: [PATCH 020/135] updated api tags/generation --- PROTO.md | 7 +- apis/config/config_types.go | 1 - apis/config/configblame_types.go | 1 - apis/config/configset_types.go | 1 - apis/config/deviation_types.go | 1 - apis/config/running_config_types.go | 1 - apis/config/sensitive_config_types.go | 1 - apis/config/v1alpha1/config_types.go | 3 +- apis/config/v1alpha1/configset_types.go | 2 + apis/config/v1alpha1/deviation_types.go | 5 +- apis/config/v1alpha1/generated.pb.go | 20 +- .../config/v1alpha1/sensitive_config_types.go | 1 + .../v1alpha1/zz_generated.conversion.go | 24 +- apis/config/v1alpha1/zz_generated.deepcopy.go | 4 +- apis/inv/v1alpha1/discoveryrule_types.go | 5 + .../v1alpha1/discoveryvendorprofile_types.go | 1 + apis/inv/v1alpha1/generated.pb.go | 24 +- apis/inv/v1alpha1/repository.go | 6 +- apis/inv/v1alpha1/rollout_types.go | 1 + apis/inv/v1alpha1/schema_types.go | 6 + apis/inv/v1alpha1/subscription_types.go | 3 + apis/inv/v1alpha1/target_types.go | 5 +- apis/inv/v1alpha1/targetsyncprofile_types.go | 2 + pkg/discovery/discoveryrule/discover_gnmi.go | 10 +- .../discover_gnmi_discovery_test.go | 26 +- pkg/discovery/discoveryrule/discover_none.go | 2 +- pkg/discovery/discoveryrule/target.go | 11 +- .../config/v1alpha1/configdeviation.go | 12 +- .../inv/v1alpha1/discoveryinfo.go | 12 +- .../applyconfiguration/inv/v1alpha1/proxy.go | 2 +- .../inv/v1alpha1/repository.go | 12 +- .../inv/v1alpha1/rolloutspec.go | 8 +- .../inv/v1alpha1/schemaspecrepository.go | 8 +- .../inv/v1alpha1/workspacespec.go | 8 +- pkg/generated/openapi/zz_generated.openapi.go | 20010 +++++++++++++++- pkg/reconcilers/target/reconciler.go | 3 +- pkg/schema/gitdownloader.go | 2 +- pkg/schema/loader.go | 8 +- pkg/sdc/target/manager/deviation_watcher.go | 64 +- pkg/sdc/target/manager/runtime.go | 1 - pkg/workspace/loader.go | 2 +- pkg/workspace/reader.go | 2 +- 42 files changed, 20101 insertions(+), 227 deletions(-) diff --git a/PROTO.md b/PROTO.md index 123cbd88..43b7d859 100644 --- a/PROTO.md +++ b/PROTO.md @@ -1,3 +1,8 @@ protoc -I . -I ./vendor --gogo_opt=paths=source_relative --gogo_out=. apis/condition/v1alpha1/generated.proto -protoc -I . -I ./vendor -I ./apis/condition/v1alpha1 --gogo_opt=paths=source_relative --gogo_out=. apis/config/v1alpha1/generated.proto \ No newline at end of file +protoc -I . -I ./vendor -I ./apis/condition/v1alpha1 --gogo_opt=paths=source_relative --gogo_out=. apis/config/v1alpha1/generated.proto + + +go run ./tools/apiserver-runtime-gen \ + -g applyconfiguration-gen \ + --module github.com/sdcio/config-server \ No newline at end of file diff --git a/apis/config/config_types.go b/apis/config/config_types.go index 047e1504..db2a6855 100644 --- a/apis/config/config_types.go +++ b/apis/config/config_types.go @@ -67,7 +67,6 @@ type ConfigStatusLastKnownGoodSchema struct { Version string `json:"version,omitempty" protobuf:"bytes,3,opt,name=version"` } -// +genclient // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object // +kubebuilder:object:root=true // +kubebuilder:storageversion diff --git a/apis/config/configblame_types.go b/apis/config/configblame_types.go index 81c6b591..2c5d080c 100644 --- a/apis/config/configblame_types.go +++ b/apis/config/configblame_types.go @@ -33,7 +33,6 @@ type ConfigBlameStatus struct { Value runtime.RawExtension `json:"value" protobuf:"bytes,2,opt,name=value"` } -// +genclient // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object // +kubebuilder:object:root=true // +kubebuilder:storageversion diff --git a/apis/config/configset_types.go b/apis/config/configset_types.go index d1e5751b..1235010d 100644 --- a/apis/config/configset_types.go +++ b/apis/config/configset_types.go @@ -61,7 +61,6 @@ type TargetStatus struct { condition.Condition `json:",inline" protobuf:"bytes,3,opt,name=condition"` } -// +genclient // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object // +kubebuilder:object:root=true // +kubebuilder:storageversion diff --git a/apis/config/deviation_types.go b/apis/config/deviation_types.go index 69cbfdde..3dee158f 100644 --- a/apis/config/deviation_types.go +++ b/apis/config/deviation_types.go @@ -67,7 +67,6 @@ type DeviationStatus struct { condition.ConditionedStatus `json:",inline" protobuf:"bytes,1,opt,name=conditionedStatus"` } -// +genclient // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object // +kubebuilder:object:root=true // +kubebuilder:storageversion diff --git a/apis/config/running_config_types.go b/apis/config/running_config_types.go index 56042eb7..7f02947c 100644 --- a/apis/config/running_config_types.go +++ b/apis/config/running_config_types.go @@ -33,7 +33,6 @@ type RunningConfigStatus struct { Value runtime.RawExtension `json:"value" protobuf:"bytes,2,opt,name=value"` } -// +genclient // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object // +kubebuilder:object:root=true // +kubebuilder:storageversion diff --git a/apis/config/sensitive_config_types.go b/apis/config/sensitive_config_types.go index 4a6c4a50..78cf316f 100644 --- a/apis/config/sensitive_config_types.go +++ b/apis/config/sensitive_config_types.go @@ -57,7 +57,6 @@ type SensitiveConfigStatus struct { DeviationGeneration *int64 `json:"deviationGeneration,omitempty" protobuf:"bytes,4,opt,name=deviationGeneration"` } -// +genclient // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object // +kubebuilder:object:root=true // +kubebuilder:storageversion diff --git a/apis/config/v1alpha1/config_types.go b/apis/config/v1alpha1/config_types.go index 04ec27f2..7d96f790 100644 --- a/apis/config/v1alpha1/config_types.go +++ b/apis/config/v1alpha1/config_types.go @@ -34,7 +34,8 @@ type ConfigSpec struct { // Revertive defines if this CR is enabled for revertive or non revertve operation Revertive *bool `json:"revertive,omitempty" protobuf:"varint,3,opt,name=revertive"` // Config defines the configuration to be applied to a target device - //+kubebuilder:pruning:PreserveUnknownFields + // +kubebuilder:pruning:PreserveUnknownFields + // +listType=atomic Config []ConfigBlob `json:"config" protobuf:"bytes,4,rep,name=config"` } diff --git a/apis/config/v1alpha1/configset_types.go b/apis/config/v1alpha1/configset_types.go index ad94968d..836a7020 100644 --- a/apis/config/v1alpha1/configset_types.go +++ b/apis/config/v1alpha1/configset_types.go @@ -36,6 +36,7 @@ type ConfigSetSpec struct { Revertive *bool `json:"revertive,omitempty" protobuf:"varint,4,opt,name=revertive"` // Config defines the configuration to be applied to a target device //+kubebuilder:pruning:PreserveUnknownFields + // +listType=atomic Config []ConfigBlob `json:"config" protobuf:"bytes,5,rep,name=config"` } @@ -50,6 +51,7 @@ type ConfigSetStatus struct { // if the condition is true the other attributes in the status are meaningful condv1alpha1.ConditionedStatus `json:",inline" protobuf:"bytes,1,opt,name=conditionedStatus"` // Targets defines the status of the configSet resource on the respective target + // +listType=atomic Targets []TargetStatus `json:"targets,omitempty" protobuf:"bytes,2,rep,name=targets"` } diff --git a/apis/config/v1alpha1/deviation_types.go b/apis/config/v1alpha1/deviation_types.go index cf30a468..9b604000 100644 --- a/apis/config/v1alpha1/deviation_types.go +++ b/apis/config/v1alpha1/deviation_types.go @@ -27,6 +27,7 @@ import ( type DeviationSpec struct { DeviationType *DeviationType `json:"deviationType,omitempty" protobuf:"bytes,1,opt,name=deviationType"` // Deviations identify the configuration deviation based on the last applied config CR + // +listType=atomic Deviations []ConfigDeviation `json:"deviations,omitempty" protobuf:"bytes,2,rep,name=deviations"` } @@ -53,9 +54,9 @@ type ConfigDeviation struct { Path string `json:"path,omitempty" protobuf:"bytes,1,opt,name=path"` // DesiredValue is the desired value of the config belonging to the path DesiredValue *string `json:"desiredValue,omitempty" protobuf:"bytes,2,opt,name=desiredValue"` - // CurrentValue defines the current value of the config belonging to the path + // ActualValue defines the current value of the config belonging to the path // that is currently configured on the target - CurrentValue *string `json:"actualValue,omitempty" protobuf:"bytes,3,opt,name=actualValue"` + ActualValue *string `json:"actualValue,omitempty" protobuf:"bytes,3,opt,name=actualValue"` // Reason defines the reason of the deviation Reason string `json:"reason,omitempty" protobuf:"bytes,4,opt,name=reason"` } diff --git a/apis/config/v1alpha1/generated.pb.go b/apis/config/v1alpha1/generated.pb.go index 131ffd7d..347ec2ce 100644 --- a/apis/config/v1alpha1/generated.pb.go +++ b/apis/config/v1alpha1/generated.pb.go @@ -42,8 +42,8 @@ var _ = math.Inf // A compilation error at this line likely means your copy of the // proto package needs to be updated. const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package -func (m *Config) Reset() { *m = Config{} } -func (*Config) ProtoMessage() {} +func (m *Config) Reset() { *m = Config{} } +func (*Config) ProtoMessage() {} func (*Config) Descriptor() ([]byte, []int) { return fileDescriptor_609f4c56ac31047c, []int{2} } @@ -1178,10 +1178,10 @@ func (m *ConfigDeviation) MarshalToSizedBuffer(dAtA []byte) (int, error) { i = encodeVarintGenerated(dAtA, i, uint64(len(m.Reason))) i-- dAtA[i] = 0x22 - if m.CurrentValue != nil { - i -= len(*m.CurrentValue) - copy(dAtA[i:], *m.CurrentValue) - i = encodeVarintGenerated(dAtA, i, uint64(len(*m.CurrentValue))) + if m.ActualValue != nil { + i -= len(*m.ActualValue) + copy(dAtA[i:], *m.ActualValue) + i = encodeVarintGenerated(dAtA, i, uint64(len(*m.ActualValue))) i-- dAtA[i] = 0x1a } @@ -2165,8 +2165,8 @@ func (m *ConfigDeviation) Size() (n int) { l = len(*m.DesiredValue) n += 1 + l + sovGenerated(uint64(l)) } - if m.CurrentValue != nil { - l = len(*m.CurrentValue) + if m.ActualValue != nil { + l = len(*m.ActualValue) n += 1 + l + sovGenerated(uint64(l)) } l = len(m.Reason) @@ -2559,7 +2559,7 @@ func (this *ConfigDeviation) String() string { s := strings.Join([]string{`&ConfigDeviation{`, `Path:` + fmt.Sprintf("%v", this.Path) + `,`, `DesiredValue:` + valueToStringGenerated(this.DesiredValue) + `,`, - `CurrentValue:` + valueToStringGenerated(this.CurrentValue) + `,`, + `CurrentValue:` + valueToStringGenerated(this.ActualValue) + `,`, `Reason:` + fmt.Sprintf("%v", this.Reason) + `,`, `}`, }, "") @@ -3615,7 +3615,7 @@ func (m *ConfigDeviation) Unmarshal(dAtA []byte) error { return io.ErrUnexpectedEOF } s := string(dAtA[iNdEx:postIndex]) - m.CurrentValue = &s + m.ActualValue = &s iNdEx = postIndex case 4: if wireType != 2 { diff --git a/apis/config/v1alpha1/sensitive_config_types.go b/apis/config/v1alpha1/sensitive_config_types.go index bb824766..44bd1e6c 100644 --- a/apis/config/v1alpha1/sensitive_config_types.go +++ b/apis/config/v1alpha1/sensitive_config_types.go @@ -34,6 +34,7 @@ type SensitiveConfigSpec struct { // Revertive defines if this CR is enabled for revertive or non revertve operation Revertive *bool `json:"revertive,omitempty" protobuf:"varint,3,opt,name=revertive"` // SensitiveConfig defines the SensitiveConfiguration to be applied to a target device + // +listType=atomic Config []SensitiveConfigData `json:"config" protobuf:"bytes,4,rep,name=config"` } diff --git a/apis/config/v1alpha1/zz_generated.conversion.go b/apis/config/v1alpha1/zz_generated.conversion.go index 62f3daf4..aa359115 100644 --- a/apis/config/v1alpha1/zz_generated.conversion.go +++ b/apis/config/v1alpha1/zz_generated.conversion.go @@ -98,16 +98,6 @@ func RegisterConversions(s *runtime.Scheme) error { }); err != nil { return err } - if err := s.AddGeneratedConversionFunc((*ConfigDeviation)(nil), (*config.ConfigDeviation)(nil), func(a, b interface{}, scope conversion.Scope) error { - return Convert_v1alpha1_ConfigDeviation_To_config_ConfigDeviation(a.(*ConfigDeviation), b.(*config.ConfigDeviation), scope) - }); err != nil { - return err - } - if err := s.AddGeneratedConversionFunc((*config.ConfigDeviation)(nil), (*ConfigDeviation)(nil), func(a, b interface{}, scope conversion.Scope) error { - return Convert_config_ConfigDeviation_To_v1alpha1_ConfigDeviation(a.(*config.ConfigDeviation), b.(*ConfigDeviation), scope) - }); err != nil { - return err - } if err := s.AddGeneratedConversionFunc((*ConfigList)(nil), (*config.ConfigList)(nil), func(a, b interface{}, scope conversion.Scope) error { return Convert_v1alpha1_ConfigList_To_config_ConfigList(a.(*ConfigList), b.(*config.ConfigList), scope) }); err != nil { @@ -520,29 +510,19 @@ func Convert_config_ConfigBlob_To_v1alpha1_ConfigBlob(in *config.ConfigBlob, out func autoConvert_v1alpha1_ConfigDeviation_To_config_ConfigDeviation(in *ConfigDeviation, out *config.ConfigDeviation, s conversion.Scope) error { out.Path = in.Path out.DesiredValue = (*string)(unsafe.Pointer(in.DesiredValue)) - out.CurrentValue = (*string)(unsafe.Pointer(in.CurrentValue)) + // WARNING: in.ActualValue requires manual conversion: does not exist in peer-type out.Reason = in.Reason return nil } -// Convert_v1alpha1_ConfigDeviation_To_config_ConfigDeviation is an autogenerated conversion function. -func Convert_v1alpha1_ConfigDeviation_To_config_ConfigDeviation(in *ConfigDeviation, out *config.ConfigDeviation, s conversion.Scope) error { - return autoConvert_v1alpha1_ConfigDeviation_To_config_ConfigDeviation(in, out, s) -} - func autoConvert_config_ConfigDeviation_To_v1alpha1_ConfigDeviation(in *config.ConfigDeviation, out *ConfigDeviation, s conversion.Scope) error { out.Path = in.Path out.DesiredValue = (*string)(unsafe.Pointer(in.DesiredValue)) - out.CurrentValue = (*string)(unsafe.Pointer(in.CurrentValue)) + // WARNING: in.CurrentValue requires manual conversion: does not exist in peer-type out.Reason = in.Reason return nil } -// Convert_config_ConfigDeviation_To_v1alpha1_ConfigDeviation is an autogenerated conversion function. -func Convert_config_ConfigDeviation_To_v1alpha1_ConfigDeviation(in *config.ConfigDeviation, out *ConfigDeviation, s conversion.Scope) error { - return autoConvert_config_ConfigDeviation_To_v1alpha1_ConfigDeviation(in, out, s) -} - func autoConvert_v1alpha1_ConfigList_To_config_ConfigList(in *ConfigList, out *config.ConfigList, s conversion.Scope) error { out.ListMeta = in.ListMeta if in.Items != nil { diff --git a/apis/config/v1alpha1/zz_generated.deepcopy.go b/apis/config/v1alpha1/zz_generated.deepcopy.go index 45ce882a..dca45f42 100644 --- a/apis/config/v1alpha1/zz_generated.deepcopy.go +++ b/apis/config/v1alpha1/zz_generated.deepcopy.go @@ -172,8 +172,8 @@ func (in *ConfigDeviation) DeepCopyInto(out *ConfigDeviation) { *out = new(string) **out = **in } - if in.CurrentValue != nil { - in, out := &in.CurrentValue, &out.CurrentValue + if in.ActualValue != nil { + in, out := &in.ActualValue, &out.ActualValue *out = new(string) **out = **in } diff --git a/apis/inv/v1alpha1/discoveryrule_types.go b/apis/inv/v1alpha1/discoveryrule_types.go index e0a30065..c4ddb45b 100644 --- a/apis/inv/v1alpha1/discoveryrule_types.go +++ b/apis/inv/v1alpha1/discoveryrule_types.go @@ -37,8 +37,10 @@ const ( // DiscoveryRuleSpec defines the desired state of DiscoveryRule type DiscoveryRuleSpec struct { // IP Prefixes for which this discovery rule applies + // +listType=atomic Prefixes []DiscoveryRulePrefix `json:"prefixes,omitempty" yaml:"prefixes,omitempty" protobuf:"bytes,1,rep,name=prefixes"` // IP Prefixes for which this discovery rule applies + // +listType=atomic Addresses []DiscoveryRuleAddress `json:"addresses,omitempty" yaml:"addresses,omitempty" protobuf:"bytes,2,rep,name=addresses"` // PodSelector defines the pod selector for which this discovery rule applies PodSelector *metav1.LabelSelector `json:"podSelector,omitempty" yaml:"podSelector,omitempty" protobuf:"bytes,3,opt,name=podSelector"` @@ -59,6 +61,7 @@ type DiscoveryParameters struct { DiscoveryProfile *DiscoveryProfile `json:"discoveryProfile,omitempty" yaml:"discoveryProfile,omitempty" protobuf:"bytes,2,opt,name=discoveryProfile"` // TargetConnectionProfiles define the profile the discovery controller uses to create targets // once discovered + // +listType=atomic TargetConnectionProfiles []TargetProfile `json:"targetConnectionProfiles" yaml:"targetConnectionProfiles" protobuf:"bytes,3,rep,name=targetConnectionProfiles"` // TargetTemplate defines the template the discovery controller uses to create the targets as a result of the discovery TargetTemplate *TargetTemplate `json:"targetTemplate,omitempty" yaml:"targetTemplate,omitempty" protobuf:"bytes,4,opt,name=targetTemplate"` @@ -72,6 +75,7 @@ type DiscoveryRulePrefix struct { // Prefix of the target/target(s) Prefix string `json:"prefix" yaml:"prefix" protobuf:"bytes,1,opt,name=prefix"` // IP Prefixes to be excluded + // +listType=atomic Excludes []string `json:"excludes,omitempty" yaml:"excludes,omitempty" protobuf:"bytes,2,rep,name=excludes"` } @@ -89,6 +93,7 @@ type DiscoveryProfile struct { TLSSecret *string `json:"tlsSecret,omitempty" yaml:"tlsSecret,omitempty" protobuf:"bytes,2,opt,name=tlsSecret"` // ConnectionProfiles define the list of profiles the discovery controller uses to discover the target. // The order in which they are specified is the order in which discovery is executed. + // +listType=atomic ConnectionProfiles []string `json:"connectionProfiles" yaml:"connectionProfiles" protobuf:"bytes,3,rep,name=connectionProfiles"` } diff --git a/apis/inv/v1alpha1/discoveryvendorprofile_types.go b/apis/inv/v1alpha1/discoveryvendorprofile_types.go index a8cdaad2..aa392df7 100644 --- a/apis/inv/v1alpha1/discoveryvendorprofile_types.go +++ b/apis/inv/v1alpha1/discoveryvendorprofile_types.go @@ -32,6 +32,7 @@ type GnmiDiscoveryVendorProfileParameters struct { Organization string `json:"organization" protobuf:"bytes,1,opt,name=organization"` ModelMatch *string `json:"modelMatch,omitempty" protobuf:"bytes,2,opt,name=modelMatch"` //Paths DiscoveryPaths `json:"paths" protobuf:"bytes,3,opt,name=paths"` + // +listType=atomic Paths []DiscoveryPathDefinition `json:"paths" protobuf:"bytes,3,rep,name=paths"` // +kubebuilder:validation:XValidation:rule="self == oldSelf",message="encoding is immutable" // +kubebuilder:validation:Enum=UNKNOWN;JSON;JSON_IETF;PROTO;ASCII; diff --git a/apis/inv/v1alpha1/generated.pb.go b/apis/inv/v1alpha1/generated.pb.go index 04c3b85a..92d1da1b 100644 --- a/apis/inv/v1alpha1/generated.pb.go +++ b/apis/inv/v1alpha1/generated.pb.go @@ -1878,9 +1878,9 @@ func (m *DiscoveryInfo) MarshalToSizedBuffer(dAtA []byte) (int, error) { i = encodeVarintGenerated(dAtA, i, uint64(len(m.Platform))) i-- dAtA[i] = 0x2a - i -= len(m.HostName) - copy(dAtA[i:], m.HostName) - i = encodeVarintGenerated(dAtA, i, uint64(len(m.HostName))) + i -= len(m.Hostname) + copy(dAtA[i:], m.Hostname) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Hostname))) i-- dAtA[i] = 0x22 i -= len(m.Version) @@ -2652,9 +2652,9 @@ func (m *Repository) MarshalToSizedBuffer(dAtA []byte) (int, error) { i = encodeVarintGenerated(dAtA, i, uint64(len(m.Credentials))) i-- dAtA[i] = 0x12 - i -= len(m.RepositoryURL) - copy(dAtA[i:], m.RepositoryURL) - i = encodeVarintGenerated(dAtA, i, uint64(len(m.RepositoryURL))) + i -= len(m.RepoURL) + copy(dAtA[i:], m.RepoURL) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.RepoURL))) i-- dAtA[i] = 0xa return len(dAtA) - i, nil @@ -4620,7 +4620,7 @@ func (m *DiscoveryInfo) Size() (n int) { n += 1 + l + sovGenerated(uint64(l)) l = len(m.Version) n += 1 + l + sovGenerated(uint64(l)) - l = len(m.HostName) + l = len(m.Hostname) n += 1 + l + sovGenerated(uint64(l)) l = len(m.Platform) n += 1 + l + sovGenerated(uint64(l)) @@ -4907,7 +4907,7 @@ func (m *Repository) Size() (n int) { } var l int _ = l - l = len(m.RepositoryURL) + l = len(m.RepoURL) n += 1 + l + sovGenerated(uint64(l)) l = len(m.Credentials) n += 1 + l + sovGenerated(uint64(l)) @@ -5638,7 +5638,7 @@ func (this *DiscoveryInfo) String() string { `Protocol:` + fmt.Sprintf("%v", this.Protocol) + `,`, `Provider:` + fmt.Sprintf("%v", this.Provider) + `,`, `Version:` + fmt.Sprintf("%v", this.Version) + `,`, - `HostName:` + fmt.Sprintf("%v", this.HostName) + `,`, + `HostName:` + fmt.Sprintf("%v", this.Hostname) + `,`, `Platform:` + fmt.Sprintf("%v", this.Platform) + `,`, `MacAddress:` + fmt.Sprintf("%v", this.MacAddress) + `,`, `SerialNumber:` + fmt.Sprintf("%v", this.SerialNumber) + `,`, @@ -5850,7 +5850,7 @@ func (this *Repository) String() string { return "nil" } s := strings.Join([]string{`&Repository{`, - `RepositoryURL:` + fmt.Sprintf("%v", this.RepositoryURL) + `,`, + `RepositoryURL:` + fmt.Sprintf("%v", this.RepoURL) + `,`, `Credentials:` + fmt.Sprintf("%v", this.Credentials) + `,`, `Proxy:` + strings.Replace(this.Proxy.String(), "Proxy", "Proxy", 1) + `,`, `Kind:` + fmt.Sprintf("%v", this.Kind) + `,`, @@ -6576,7 +6576,7 @@ func (m *DiscoveryInfo) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.HostName = string(dAtA[iNdEx:postIndex]) + m.Hostname = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 5: if wireType != 2 { @@ -8858,7 +8858,7 @@ func (m *Repository) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.RepositoryURL = string(dAtA[iNdEx:postIndex]) + m.RepoURL = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { diff --git a/apis/inv/v1alpha1/repository.go b/apis/inv/v1alpha1/repository.go index ee84c9bf..1da6008e 100644 --- a/apis/inv/v1alpha1/repository.go +++ b/apis/inv/v1alpha1/repository.go @@ -17,8 +17,8 @@ limitations under the License. package v1alpha1 type Repository struct { - // RepositoryURL specifies the base URL for a given repository - RepositoryURL string `json:"repoURL" protobuf:"bytes,1,opt,name=repoURL"` + // RepoURL specifies the base URL for a given repository + RepoURL string `json:"repoURL" protobuf:"bytes,1,opt,name=repoURL"` // Credentials defines the name of the secret that holds the credentials to connect to the repo Credentials string `json:"credentials,omitempty" protobuf:"bytes,2,opt,name=credentials"` // Proxy defines the HTTP/HTTPS proxy to be used to connect to the repo. @@ -34,7 +34,7 @@ type Repository struct { type Proxy struct { // URL specifies the base URL of the HTTP/HTTPS proxy server. - URL string `json:"URL" protobuf:"bytes,1,opt,name=URL"` + URL string `json:"url" protobuf:"bytes,1,opt,name=url"` // Credentials defines the name of the secret that holds the credentials to connect to the proxy server Credentials string `json:"credentials" protobuf:"bytes,2,opt,name=credentials"` } diff --git a/apis/inv/v1alpha1/rollout_types.go b/apis/inv/v1alpha1/rollout_types.go index 7d2516f0..b22b7ab1 100644 --- a/apis/inv/v1alpha1/rollout_types.go +++ b/apis/inv/v1alpha1/rollout_types.go @@ -43,6 +43,7 @@ type RolloutStatus struct { // ConditionedStatus provides the status of the Rollout using conditions condv1alpha1.ConditionedStatus `json:",inline" protobuf:"bytes,1,opt,name=conditionedStatus"` // Targets defines the status of the rollout on the respective target + // +listType=atomic Targets []RolloutTargetStatus `json:"targets,omitempty" protobuf:"bytes,2,rep,name=targets"` } diff --git a/apis/inv/v1alpha1/schema_types.go b/apis/inv/v1alpha1/schema_types.go index fe49e20c..9587aa26 100644 --- a/apis/inv/v1alpha1/schema_types.go +++ b/apis/inv/v1alpha1/schema_types.go @@ -43,6 +43,7 @@ type SchemaSpec struct { // +kubebuilder:validation:MinItems:=1 // +kubebuilder:validation:MaxItems:=10 // Repositories define the repositories used for building the provider schema + // +listType=atomic Repositories []*SchemaSpecRepository `json:"repositories" protobuf:"bytes,3,rep,name=repositories"` } @@ -51,6 +52,7 @@ type SchemaSpecRepository struct { // +kubebuilder:validation:MaxItems=10 // Dirs defines the list of directories that identified the provider schema in src/dst pairs // relative within the repository + // +listType=atomic Dirs []SrcDstPath `json:"dirs,omitempty" yaml:"dirs,omitempty" protobuf:"bytes,6,rep,name=dirs"` // Schema provides the details of which files must be used for the models and which files/directories // cana be excludes @@ -69,12 +71,15 @@ type SrcDstPath struct { type SchemaSpecSchema struct { // +kubebuilder:validation:MaxItems=64 // Models defines the list of files/directories to be used as a model + // +listType=atomic Models []string `json:"models,omitempty" yaml:"models,omitempty" protobuf:"bytes,1,rep,name=models"` // +kubebuilder:validation:MaxItems=64 // Excludes defines the list of files/directories to be excluded + // +listType=atomic Includes []string `json:"includes,omitempty" yaml:"includes,omitempty" protobuf:"bytes,2,rep,name=includes"` // +kubebuilder:validation:MaxItems=64 // Excludes defines the list of files/directories to be excluded + // +listType=atomic Excludes []string `json:"excludes,omitempty" yaml:"excludes,omitempty" protobuf:"bytes,3,rep,name=excludes"` } @@ -83,6 +88,7 @@ type SchemaStatus struct { // ConditionedStatus provides the status of the Schema using conditions condv1alpha1.ConditionedStatus `json:",inline" yaml:",inline" protobuf:"bytes,1,opt,name=conditionedStatus"` // SchemaRepositoryStatus provides the array of repositories + // +listType=atomic Repositories []SchemaRepositoryStatus `json:"repositories,omitempty" protobuf:"bytes,2,rep,name=repositories"` } diff --git a/apis/inv/v1alpha1/subscription_types.go b/apis/inv/v1alpha1/subscription_types.go index 2757b4ca..28b2afca 100644 --- a/apis/inv/v1alpha1/subscription_types.go +++ b/apis/inv/v1alpha1/subscription_types.go @@ -44,6 +44,7 @@ type SubscriptionSpec struct { Encoding *Encoding `json:"encoding,omitempty" protobuf:"bytes,4,opt,name=encoding,casttype=Encoding"` // +kubebuilder:validation:MaxItems=128 // +kubebuilder:validation:Optional + // +listType=atomic Subscriptions []SubscriptionParameters `json:"subscriptions" protobuf:"bytes,5,rep,name=subscriptions"` } @@ -74,6 +75,7 @@ type SubscriptionParameters struct { // +kubebuilder:validation:Enum="1s";"15s";"30s";"60s"; Interval *metav1.Duration `json:"interval,omitempty" protobuf:"bytes,6,opt,name=interval"` // +kubebuilder:validation:MaxItems=128 + // +listType=atomic Paths []string `json:"paths" protobuf:"bytes,7,rep,name=paths"` // TODO Outputs define the outputs to which this information should go -> reight now we only support prometheus locally // this looks up another CR where they are defined with their respective secrets, etc @@ -84,6 +86,7 @@ type SubscriptionStatus struct { // ConditionedStatus provides the status of the Schema using conditions condv1alpha1.ConditionedStatus `json:",inline" protobuf:"bytes,1,opt,name=conditionedStatus"` // Targets defines the list of targets this resource applies to + // +listType=atomic Targets []string `json:"targets,omitempty" protobuf:"bytes,2,rep,name=targets"` } diff --git a/apis/inv/v1alpha1/target_types.go b/apis/inv/v1alpha1/target_types.go index 57630619..e5207cf8 100644 --- a/apis/inv/v1alpha1/target_types.go +++ b/apis/inv/v1alpha1/target_types.go @@ -51,8 +51,8 @@ type DiscoveryInfo struct { Provider string `json:"provider,omitempty" protobuf:"bytes,2,opt,name=provider"` // Version associated with the target Version string `json:"version,omitempty" protobuf:"bytes,3,opt,name=version"` - // HostName associated with the target - HostName string `json:"hostname,omitempty" protobuf:"bytes,4,opt,name=hostname"` + // Hostname associated with the target + Hostname string `json:"hostname,omitempty" protobuf:"bytes,4,opt,name=hostname"` // Platform associated with the target Platform string `json:"platform,omitempty" protobuf:"bytes,5,opt,name=platform"` // MacAddress associated with the target @@ -60,6 +60,7 @@ type DiscoveryInfo struct { // SerialNumber associated with the target SerialNumber string `json:"serialNumber,omitempty" protobuf:"bytes,7,opt,name=serialNumber"` // Supported Encodings of the target + // +listType=atomic SupportedEncodings []string `json:"supportedEncodings,omitempty" protobuf:"bytes,8,rep,name=supportedEncodings"` // Last discovery time //LastSeen metav1.Time `json:"lastSeen,omitempty"` diff --git a/apis/inv/v1alpha1/targetsyncprofile_types.go b/apis/inv/v1alpha1/targetsyncprofile_types.go index 429d5095..7ce79d71 100644 --- a/apis/inv/v1alpha1/targetsyncprofile_types.go +++ b/apis/inv/v1alpha1/targetsyncprofile_types.go @@ -48,6 +48,7 @@ type TargetSyncProfileSpec struct { // +kubebuilder:validation:MaxItems=10 // +kubebuilder:validation:Optional // +kubebuilder:validation:XValidation:rule="oldSelf.all(x, x in self)",message="sync may only be added" + // +listType=atomic Sync []TargetSyncProfileSync `json:"sync" yaml:"sync" protobuf:"bytes,4,rep,name=sync"` } @@ -61,6 +62,7 @@ type TargetSyncProfileSync struct { // Port defines the port on which the scan runs Port uint32 `json:"port" yaml:"port" protobuf:"varint,3,opt,name=port"` // +kubebuilder:validation:MaxItems=10 + // +listType=atomic Paths []string `json:"paths" yaml:"paths" protobuf:"bytes,4,rep,name=paths"` // +kubebuilder:validation:Enum=unknown;onChange;sample;once;get; // +kubebuilder:default:="get" diff --git a/pkg/discovery/discoveryrule/discover_gnmi.go b/pkg/discovery/discoveryrule/discover_gnmi.go index 5195a9dc..8e3328cd 100644 --- a/pkg/discovery/discoveryrule/discover_gnmi.go +++ b/pkg/discovery/discoveryrule/discover_gnmi.go @@ -61,10 +61,10 @@ func (r *dr) discoverWithGNMI(ctx context.Context, h *hostInfo, connProfile *inv return err } defer func() { - if err := t.Close(); err != nil { - log.Error("closing gNMI target", "err", err) - } - }() + if err := t.Close(); err != nil { + log.Error("closing gNMI target", "err", err) + } + }() capRsp, err := t.Capabilities(ctx) if err != nil { return err @@ -218,7 +218,7 @@ func (r *Discoverer) parseDiscoveryInformation( "platform": &di.Platform, "serialNumber": &di.SerialNumber, "macAddress": &di.MacAddress, - "hostname": &di.HostName, + "hostname": &di.Hostname, } // Process gNMI notifications diff --git a/pkg/discovery/discoveryrule/discover_gnmi_discovery_test.go b/pkg/discovery/discoveryrule/discover_gnmi_discovery_test.go index f5a3f3c3..dba54ad4 100644 --- a/pkg/discovery/discoveryrule/discover_gnmi_discovery_test.go +++ b/pkg/discovery/discoveryrule/discover_gnmi_discovery_test.go @@ -41,7 +41,7 @@ func TestParseDiscoveryInformation(t *testing.T) { Protocol: "gnmi", Provider: "srl.nokia.sdcio.dev", Version: "24.3.2", - HostName: "edge02", + Hostname: "edge02", Platform: "7220 IXR-D2", MacAddress: "1A:05:04:FF:00:00", SerialNumber: "Sim Serial No.", @@ -56,7 +56,7 @@ func TestParseDiscoveryInformation(t *testing.T) { Protocol: "gnmi", Provider: "eos.arista.sdcio.dev", Version: "4.33.1F", - HostName: "edge02", + Hostname: "edge02", Platform: "cEOSLab", MacAddress: "00:1c:73:6f:e4:7c", SerialNumber: "864D1228500892CEF934F5C6DF8784B2", @@ -71,7 +71,7 @@ func TestParseDiscoveryInformation(t *testing.T) { Protocol: "gnmi", Provider: "iosxr.cisco.sdcio.dev", Version: "24.4.1.26I", - HostName: "edge02", + Hostname: "edge02", Platform: "Cisco IOS-XRv 9000 Centralized Virtual Router", MacAddress: "02:42:0a:0a:14:65", SerialNumber: "VSN-NPP2G7K", @@ -123,8 +123,8 @@ func TestParseDiscoveryInformation(t *testing.T) { if di.Version != tc.expectedResult.Version { t.Errorf("Version mismatch: expected %s, got %s", tc.expectedResult.Version, di.Version) } - if di.HostName != tc.expectedResult.HostName { - t.Errorf("HostName mismatch: expected %s, got %s", tc.expectedResult.HostName, di.HostName) + if di.Hostname != tc.expectedResult.Hostname { + t.Errorf("HostName mismatch: expected %s, got %s", tc.expectedResult.Hostname, di.Hostname) } if di.Platform != tc.expectedResult.Platform { t.Errorf("Platform mismatch: expected %s, got %s", tc.expectedResult.Platform, di.Platform) @@ -310,7 +310,7 @@ func getCiscoResponse() *gnmi.GetResponse { {Name: "system"}, {Name: "state"}, {Name: "software-version"}, - }}, + }}, Val: &gnmi.TypedValue{ Value: &gnmi.TypedValue_StringVal{StringVal: "24.4.1.26I"}, }, @@ -320,13 +320,13 @@ func getCiscoResponse() *gnmi.GetResponse { { Update: []*gnmi.Update{ { - Path: &gnmi.Path{Origin: "openconfig-platform", + Path: &gnmi.Path{Origin: "openconfig-platform", Elem: []*gnmi.PathElem{ {Name: "components"}, {Name: "component", Key: map[string]string{"name": "Rack 0"}}, {Name: "state"}, {Name: "part-no"}, - }}, + }}, Val: &gnmi.TypedValue{ Value: &gnmi.TypedValue_StringVal{StringVal: "Cisco IOS-XRv 9000 Centralized Virtual Router"}, }, @@ -336,12 +336,12 @@ func getCiscoResponse() *gnmi.GetResponse { { Update: []*gnmi.Update{ { - Path: &gnmi.Path{Origin: "openconfig-system", + Path: &gnmi.Path{Origin: "openconfig-system", Elem: []*gnmi.PathElem{ {Name: "system"}, {Name: "state"}, {Name: "hostname"}, - }}, + }}, Val: &gnmi.TypedValue{ Value: &gnmi.TypedValue_StringVal{StringVal: "edge02"}, }, @@ -357,7 +357,7 @@ func getCiscoResponse() *gnmi.GetResponse { {Name: "component", Key: map[string]string{"name": "Rack 0"}}, {Name: "state"}, {Name: "serial-no"}, - }}, + }}, Val: &gnmi.TypedValue{ Value: &gnmi.TypedValue_StringVal{StringVal: "VSN-NPP2G7K"}, }, @@ -367,14 +367,14 @@ func getCiscoResponse() *gnmi.GetResponse { { Update: []*gnmi.Update{ { - Path: &gnmi.Path{Origin: "openconfig-interfaces", + Path: &gnmi.Path{Origin: "openconfig-interfaces", Elem: []*gnmi.PathElem{ {Name: "interfaces"}, {Name: "interface", Key: map[string]string{"name": "MgmtEth0/RP0/CPU0/0"}}, {Name: "openconfig-if-ethernet:ethernet"}, {Name: "state"}, {Name: "mac-address"}, - }}, + }}, Val: &gnmi.TypedValue{ Value: &gnmi.TypedValue_StringVal{StringVal: "02:42:0a:0a:14:65"}, }, diff --git a/pkg/discovery/discoveryrule/discover_none.go b/pkg/discovery/discoveryrule/discover_none.go index 3e4334f9..aab0a27a 100644 --- a/pkg/discovery/discoveryrule/discover_none.go +++ b/pkg/discovery/discoveryrule/discover_none.go @@ -36,7 +36,7 @@ func (r *dr) discoverWithNone(ctx context.Context, h *hostInfo, connProfile *inv Protocol: "static", Provider: provider, Version: version, - HostName: h.hostName, + Hostname: h.hostName, //LastSeen: metav1.Now(), } return r.createTarget(ctx, provider, h.Address, di) diff --git a/pkg/discovery/discoveryrule/target.go b/pkg/discovery/discoveryrule/target.go index 46477234..54c35b85 100644 --- a/pkg/discovery/discoveryrule/target.go +++ b/pkg/discovery/discoveryrule/target.go @@ -42,7 +42,7 @@ const ( func (r *dr) createTarget(ctx context.Context, provider, address string, di *invv1alpha1.DiscoveryInfo) error { log := log.FromContext(ctx) - if err := r.children.Create(ctx, storebackend.ToKey(getTargetName(di.HostName)), ""); err != nil { + if err := r.children.Create(ctx, storebackend.ToKey(getTargetName(di.Hostname)), ""); err != nil { return err } @@ -68,11 +68,10 @@ func (r *dr) createTarget(ctx context.Context, provider, address string, di *inv return err } - if err := r.applyTargetDeviationCR(ctx, target); err != nil { return err } - + return nil } @@ -98,7 +97,7 @@ func (r *dr) newTarget(_ context.Context, providerName, address string, di *invv return invv1alpha1.BuildTarget( metav1.ObjectMeta{ - Name: getTargetName(di.HostName), + Name: getTargetName(di.Hostname), Namespace: r.cfg.CR.GetNamespace(), Labels: labels, Annotations: anno, @@ -197,8 +196,8 @@ func discoveryInfoToApply(di *invv1alpha1.DiscoveryInfo) *invv1alpha1apply.Disco if di.Version != "" { a.WithVersion(di.Version) } - if di.HostName != "" { - a.WithHostName(di.HostName) + if di.Hostname != "" { + a.WithHostname(di.Hostname) } if di.Platform != "" { a.WithPlatform(di.Platform) diff --git a/pkg/generated/applyconfiguration/config/v1alpha1/configdeviation.go b/pkg/generated/applyconfiguration/config/v1alpha1/configdeviation.go index 5ce88117..8484de79 100644 --- a/pkg/generated/applyconfiguration/config/v1alpha1/configdeviation.go +++ b/pkg/generated/applyconfiguration/config/v1alpha1/configdeviation.go @@ -24,9 +24,9 @@ type ConfigDeviationApplyConfiguration struct { Path *string `json:"path,omitempty"` // DesiredValue is the desired value of the config belonging to the path DesiredValue *string `json:"desiredValue,omitempty"` - // CurrentValue defines the current value of the config belonging to the path + // ActualValue defines the current value of the config belonging to the path // that is currently configured on the target - CurrentValue *string `json:"actualValue,omitempty"` + ActualValue *string `json:"actualValue,omitempty"` // Reason defines the reason of the deviation Reason *string `json:"reason,omitempty"` } @@ -53,11 +53,11 @@ func (b *ConfigDeviationApplyConfiguration) WithDesiredValue(value string) *Conf return b } -// WithCurrentValue sets the CurrentValue field in the declarative configuration to the given value +// WithActualValue sets the ActualValue field in the declarative configuration to the given value // and returns the receiver, so that objects can be built by chaining "With" function invocations. -// If called multiple times, the CurrentValue field is set to the value of the last call. -func (b *ConfigDeviationApplyConfiguration) WithCurrentValue(value string) *ConfigDeviationApplyConfiguration { - b.CurrentValue = &value +// If called multiple times, the ActualValue field is set to the value of the last call. +func (b *ConfigDeviationApplyConfiguration) WithActualValue(value string) *ConfigDeviationApplyConfiguration { + b.ActualValue = &value return b } diff --git a/pkg/generated/applyconfiguration/inv/v1alpha1/discoveryinfo.go b/pkg/generated/applyconfiguration/inv/v1alpha1/discoveryinfo.go index 17a36637..7096908d 100644 --- a/pkg/generated/applyconfiguration/inv/v1alpha1/discoveryinfo.go +++ b/pkg/generated/applyconfiguration/inv/v1alpha1/discoveryinfo.go @@ -26,8 +26,8 @@ type DiscoveryInfoApplyConfiguration struct { Provider *string `json:"provider,omitempty"` // Version associated with the target Version *string `json:"version,omitempty"` - // HostName associated with the target - HostName *string `json:"hostname,omitempty"` + // Hostname associated with the target + Hostname *string `json:"hostname,omitempty"` // Platform associated with the target Platform *string `json:"platform,omitempty"` // MacAddress associated with the target @@ -68,11 +68,11 @@ func (b *DiscoveryInfoApplyConfiguration) WithVersion(value string) *DiscoveryIn return b } -// WithHostName sets the HostName field in the declarative configuration to the given value +// WithHostname sets the Hostname field in the declarative configuration to the given value // and returns the receiver, so that objects can be built by chaining "With" function invocations. -// If called multiple times, the HostName field is set to the value of the last call. -func (b *DiscoveryInfoApplyConfiguration) WithHostName(value string) *DiscoveryInfoApplyConfiguration { - b.HostName = &value +// If called multiple times, the Hostname field is set to the value of the last call. +func (b *DiscoveryInfoApplyConfiguration) WithHostname(value string) *DiscoveryInfoApplyConfiguration { + b.Hostname = &value return b } diff --git a/pkg/generated/applyconfiguration/inv/v1alpha1/proxy.go b/pkg/generated/applyconfiguration/inv/v1alpha1/proxy.go index 73a61b64..d7dda4aa 100644 --- a/pkg/generated/applyconfiguration/inv/v1alpha1/proxy.go +++ b/pkg/generated/applyconfiguration/inv/v1alpha1/proxy.go @@ -21,7 +21,7 @@ package v1alpha1 // with apply. type ProxyApplyConfiguration struct { // URL specifies the base URL of the HTTP/HTTPS proxy server. - URL *string `json:"URL,omitempty"` + URL *string `json:"url,omitempty"` // Credentials defines the name of the secret that holds the credentials to connect to the proxy server Credentials *string `json:"credentials,omitempty"` } diff --git a/pkg/generated/applyconfiguration/inv/v1alpha1/repository.go b/pkg/generated/applyconfiguration/inv/v1alpha1/repository.go index 73204afb..e793d636 100644 --- a/pkg/generated/applyconfiguration/inv/v1alpha1/repository.go +++ b/pkg/generated/applyconfiguration/inv/v1alpha1/repository.go @@ -24,8 +24,8 @@ import ( // RepositoryApplyConfiguration represents a declarative configuration of the Repository type for use // with apply. type RepositoryApplyConfiguration struct { - // RepositoryURL specifies the base URL for a given repository - RepositoryURL *string `json:"repoURL,omitempty"` + // RepoURL specifies the base URL for a given repository + RepoURL *string `json:"repoURL,omitempty"` // Credentials defines the name of the secret that holds the credentials to connect to the repo Credentials *string `json:"credentials,omitempty"` // Proxy defines the HTTP/HTTPS proxy to be used to connect to the repo. @@ -43,11 +43,11 @@ func Repository() *RepositoryApplyConfiguration { return &RepositoryApplyConfiguration{} } -// WithRepositoryURL sets the RepositoryURL field in the declarative configuration to the given value +// WithRepoURL sets the RepoURL field in the declarative configuration to the given value // and returns the receiver, so that objects can be built by chaining "With" function invocations. -// If called multiple times, the RepositoryURL field is set to the value of the last call. -func (b *RepositoryApplyConfiguration) WithRepositoryURL(value string) *RepositoryApplyConfiguration { - b.RepositoryURL = &value +// If called multiple times, the RepoURL field is set to the value of the last call. +func (b *RepositoryApplyConfiguration) WithRepoURL(value string) *RepositoryApplyConfiguration { + b.RepoURL = &value return b } diff --git a/pkg/generated/applyconfiguration/inv/v1alpha1/rolloutspec.go b/pkg/generated/applyconfiguration/inv/v1alpha1/rolloutspec.go index b4356814..df8b926d 100644 --- a/pkg/generated/applyconfiguration/inv/v1alpha1/rolloutspec.go +++ b/pkg/generated/applyconfiguration/inv/v1alpha1/rolloutspec.go @@ -37,11 +37,11 @@ func RolloutSpec() *RolloutSpecApplyConfiguration { return &RolloutSpecApplyConfiguration{} } -// WithRepositoryURL sets the RepositoryURL field in the declarative configuration to the given value +// WithRepoURL sets the RepoURL field in the declarative configuration to the given value // and returns the receiver, so that objects can be built by chaining "With" function invocations. -// If called multiple times, the RepositoryURL field is set to the value of the last call. -func (b *RolloutSpecApplyConfiguration) WithRepositoryURL(value string) *RolloutSpecApplyConfiguration { - b.RepositoryApplyConfiguration.RepositoryURL = &value +// If called multiple times, the RepoURL field is set to the value of the last call. +func (b *RolloutSpecApplyConfiguration) WithRepoURL(value string) *RolloutSpecApplyConfiguration { + b.RepositoryApplyConfiguration.RepoURL = &value return b } diff --git a/pkg/generated/applyconfiguration/inv/v1alpha1/schemaspecrepository.go b/pkg/generated/applyconfiguration/inv/v1alpha1/schemaspecrepository.go index 1c643d35..e2cffd7c 100644 --- a/pkg/generated/applyconfiguration/inv/v1alpha1/schemaspecrepository.go +++ b/pkg/generated/applyconfiguration/inv/v1alpha1/schemaspecrepository.go @@ -39,11 +39,11 @@ func SchemaSpecRepository() *SchemaSpecRepositoryApplyConfiguration { return &SchemaSpecRepositoryApplyConfiguration{} } -// WithRepositoryURL sets the RepositoryURL field in the declarative configuration to the given value +// WithRepoURL sets the RepoURL field in the declarative configuration to the given value // and returns the receiver, so that objects can be built by chaining "With" function invocations. -// If called multiple times, the RepositoryURL field is set to the value of the last call. -func (b *SchemaSpecRepositoryApplyConfiguration) WithRepositoryURL(value string) *SchemaSpecRepositoryApplyConfiguration { - b.RepositoryApplyConfiguration.RepositoryURL = &value +// If called multiple times, the RepoURL field is set to the value of the last call. +func (b *SchemaSpecRepositoryApplyConfiguration) WithRepoURL(value string) *SchemaSpecRepositoryApplyConfiguration { + b.RepositoryApplyConfiguration.RepoURL = &value return b } diff --git a/pkg/generated/applyconfiguration/inv/v1alpha1/workspacespec.go b/pkg/generated/applyconfiguration/inv/v1alpha1/workspacespec.go index cbaf7a3f..824b9a47 100644 --- a/pkg/generated/applyconfiguration/inv/v1alpha1/workspacespec.go +++ b/pkg/generated/applyconfiguration/inv/v1alpha1/workspacespec.go @@ -35,11 +35,11 @@ func WorkspaceSpec() *WorkspaceSpecApplyConfiguration { return &WorkspaceSpecApplyConfiguration{} } -// WithRepositoryURL sets the RepositoryURL field in the declarative configuration to the given value +// WithRepoURL sets the RepoURL field in the declarative configuration to the given value // and returns the receiver, so that objects can be built by chaining "With" function invocations. -// If called multiple times, the RepositoryURL field is set to the value of the last call. -func (b *WorkspaceSpecApplyConfiguration) WithRepositoryURL(value string) *WorkspaceSpecApplyConfiguration { - b.RepositoryApplyConfiguration.RepositoryURL = &value +// If called multiple times, the RepoURL field is set to the value of the last call. +func (b *WorkspaceSpecApplyConfiguration) WithRepoURL(value string) *WorkspaceSpecApplyConfiguration { + b.RepositoryApplyConfiguration.RepoURL = &value return b } diff --git a/pkg/generated/openapi/zz_generated.openapi.go b/pkg/generated/openapi/zz_generated.openapi.go index c6b6eaf2..1d6cba6f 100644 --- a/pkg/generated/openapi/zz_generated.openapi.go +++ b/pkg/generated/openapi/zz_generated.openapi.go @@ -21,43 +21,520 @@ limitations under the License. package openapi import ( + v1 "k8s.io/api/core/v1" + resource "k8s.io/apimachinery/pkg/api/resource" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + runtime "k8s.io/apimachinery/pkg/runtime" + version "k8s.io/apimachinery/pkg/version" common "k8s.io/kube-openapi/pkg/common" spec "k8s.io/kube-openapi/pkg/validation/spec" ) func GetOpenAPIDefinitions(ref common.ReferenceCallback) map[string]common.OpenAPIDefinition { return map[string]common.OpenAPIDefinition{ - "github.com/sdcio/config-server/apis/config/v1alpha1.Config": schema_config_server_apis_config_v1alpha1_Config(ref), - "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigBlame": schema_config_server_apis_config_v1alpha1_ConfigBlame(ref), - "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigBlameList": schema_config_server_apis_config_v1alpha1_ConfigBlameList(ref), - "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigBlameSpec": schema_config_server_apis_config_v1alpha1_ConfigBlameSpec(ref), - "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigBlameStatus": schema_config_server_apis_config_v1alpha1_ConfigBlameStatus(ref), - "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigBlob": schema_config_server_apis_config_v1alpha1_ConfigBlob(ref), - "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigDeviation": schema_config_server_apis_config_v1alpha1_ConfigDeviation(ref), - "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigList": schema_config_server_apis_config_v1alpha1_ConfigList(ref), - "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigSet": schema_config_server_apis_config_v1alpha1_ConfigSet(ref), - "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigSetList": schema_config_server_apis_config_v1alpha1_ConfigSetList(ref), - "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigSetSpec": schema_config_server_apis_config_v1alpha1_ConfigSetSpec(ref), - "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigSetStatus": schema_config_server_apis_config_v1alpha1_ConfigSetStatus(ref), - "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigSpec": schema_config_server_apis_config_v1alpha1_ConfigSpec(ref), - "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigStatus": schema_config_server_apis_config_v1alpha1_ConfigStatus(ref), - "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigStatusLastKnownGoodSchema": schema_config_server_apis_config_v1alpha1_ConfigStatusLastKnownGoodSchema(ref), - "github.com/sdcio/config-server/apis/config/v1alpha1.Deviation": schema_config_server_apis_config_v1alpha1_Deviation(ref), - "github.com/sdcio/config-server/apis/config/v1alpha1.DeviationList": schema_config_server_apis_config_v1alpha1_DeviationList(ref), - "github.com/sdcio/config-server/apis/config/v1alpha1.DeviationSpec": schema_config_server_apis_config_v1alpha1_DeviationSpec(ref), - "github.com/sdcio/config-server/apis/config/v1alpha1.DeviationStatus": schema_config_server_apis_config_v1alpha1_DeviationStatus(ref), - "github.com/sdcio/config-server/apis/config/v1alpha1.Lifecycle": schema_config_server_apis_config_v1alpha1_Lifecycle(ref), - "github.com/sdcio/config-server/apis/config/v1alpha1.RunningConfig": schema_config_server_apis_config_v1alpha1_RunningConfig(ref), - "github.com/sdcio/config-server/apis/config/v1alpha1.RunningConfigList": schema_config_server_apis_config_v1alpha1_RunningConfigList(ref), - "github.com/sdcio/config-server/apis/config/v1alpha1.RunningConfigSpec": schema_config_server_apis_config_v1alpha1_RunningConfigSpec(ref), - "github.com/sdcio/config-server/apis/config/v1alpha1.RunningConfigStatus": schema_config_server_apis_config_v1alpha1_RunningConfigStatus(ref), - "github.com/sdcio/config-server/apis/config/v1alpha1.SensitiveConfig": schema_config_server_apis_config_v1alpha1_SensitiveConfig(ref), - "github.com/sdcio/config-server/apis/config/v1alpha1.SensitiveConfigData": schema_config_server_apis_config_v1alpha1_SensitiveConfigData(ref), - "github.com/sdcio/config-server/apis/config/v1alpha1.SensitiveConfigList": schema_config_server_apis_config_v1alpha1_SensitiveConfigList(ref), - "github.com/sdcio/config-server/apis/config/v1alpha1.SensitiveConfigSpec": schema_config_server_apis_config_v1alpha1_SensitiveConfigSpec(ref), - "github.com/sdcio/config-server/apis/config/v1alpha1.SensitiveConfigStatus": schema_config_server_apis_config_v1alpha1_SensitiveConfigStatus(ref), - "github.com/sdcio/config-server/apis/config/v1alpha1.Target": schema_config_server_apis_config_v1alpha1_Target(ref), - "github.com/sdcio/config-server/apis/config/v1alpha1.TargetStatus": schema_config_server_apis_config_v1alpha1_TargetStatus(ref), + "github.com/sdcio/config-server/apis/condition/v1alpha1.Condition": schema_config_server_apis_condition_v1alpha1_Condition(ref), + "github.com/sdcio/config-server/apis/condition/v1alpha1.ConditionedStatus": schema_config_server_apis_condition_v1alpha1_ConditionedStatus(ref), + "github.com/sdcio/config-server/apis/condition/v1alpha1.UnrecoverableMessage": schema_config_server_apis_condition_v1alpha1_UnrecoverableMessage(ref), + "github.com/sdcio/config-server/apis/config/v1alpha1.Config": schema_config_server_apis_config_v1alpha1_Config(ref), + "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigBlame": schema_config_server_apis_config_v1alpha1_ConfigBlame(ref), + "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigBlameList": schema_config_server_apis_config_v1alpha1_ConfigBlameList(ref), + "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigBlameSpec": schema_config_server_apis_config_v1alpha1_ConfigBlameSpec(ref), + "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigBlameStatus": schema_config_server_apis_config_v1alpha1_ConfigBlameStatus(ref), + "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigBlob": schema_config_server_apis_config_v1alpha1_ConfigBlob(ref), + "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigDeviation": schema_config_server_apis_config_v1alpha1_ConfigDeviation(ref), + "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigList": schema_config_server_apis_config_v1alpha1_ConfigList(ref), + "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigSet": schema_config_server_apis_config_v1alpha1_ConfigSet(ref), + "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigSetList": schema_config_server_apis_config_v1alpha1_ConfigSetList(ref), + "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigSetSpec": schema_config_server_apis_config_v1alpha1_ConfigSetSpec(ref), + "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigSetStatus": schema_config_server_apis_config_v1alpha1_ConfigSetStatus(ref), + "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigSpec": schema_config_server_apis_config_v1alpha1_ConfigSpec(ref), + "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigStatus": schema_config_server_apis_config_v1alpha1_ConfigStatus(ref), + "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigStatusLastKnownGoodSchema": schema_config_server_apis_config_v1alpha1_ConfigStatusLastKnownGoodSchema(ref), + "github.com/sdcio/config-server/apis/config/v1alpha1.Deviation": schema_config_server_apis_config_v1alpha1_Deviation(ref), + "github.com/sdcio/config-server/apis/config/v1alpha1.DeviationList": schema_config_server_apis_config_v1alpha1_DeviationList(ref), + "github.com/sdcio/config-server/apis/config/v1alpha1.DeviationSpec": schema_config_server_apis_config_v1alpha1_DeviationSpec(ref), + "github.com/sdcio/config-server/apis/config/v1alpha1.DeviationStatus": schema_config_server_apis_config_v1alpha1_DeviationStatus(ref), + "github.com/sdcio/config-server/apis/config/v1alpha1.Lifecycle": schema_config_server_apis_config_v1alpha1_Lifecycle(ref), + "github.com/sdcio/config-server/apis/config/v1alpha1.RunningConfig": schema_config_server_apis_config_v1alpha1_RunningConfig(ref), + "github.com/sdcio/config-server/apis/config/v1alpha1.RunningConfigList": schema_config_server_apis_config_v1alpha1_RunningConfigList(ref), + "github.com/sdcio/config-server/apis/config/v1alpha1.RunningConfigSpec": schema_config_server_apis_config_v1alpha1_RunningConfigSpec(ref), + "github.com/sdcio/config-server/apis/config/v1alpha1.RunningConfigStatus": schema_config_server_apis_config_v1alpha1_RunningConfigStatus(ref), + "github.com/sdcio/config-server/apis/config/v1alpha1.SensitiveConfig": schema_config_server_apis_config_v1alpha1_SensitiveConfig(ref), + "github.com/sdcio/config-server/apis/config/v1alpha1.SensitiveConfigData": schema_config_server_apis_config_v1alpha1_SensitiveConfigData(ref), + "github.com/sdcio/config-server/apis/config/v1alpha1.SensitiveConfigList": schema_config_server_apis_config_v1alpha1_SensitiveConfigList(ref), + "github.com/sdcio/config-server/apis/config/v1alpha1.SensitiveConfigSpec": schema_config_server_apis_config_v1alpha1_SensitiveConfigSpec(ref), + "github.com/sdcio/config-server/apis/config/v1alpha1.SensitiveConfigStatus": schema_config_server_apis_config_v1alpha1_SensitiveConfigStatus(ref), + "github.com/sdcio/config-server/apis/config/v1alpha1.Target": schema_config_server_apis_config_v1alpha1_Target(ref), + "github.com/sdcio/config-server/apis/config/v1alpha1.TargetStatus": schema_config_server_apis_config_v1alpha1_TargetStatus(ref), + "github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryInfo": schema_config_server_apis_inv_v1alpha1_DiscoveryInfo(ref), + "github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryParameters": schema_config_server_apis_inv_v1alpha1_DiscoveryParameters(ref), + "github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryPathDefinition": schema_config_server_apis_inv_v1alpha1_DiscoveryPathDefinition(ref), + "github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryProfile": schema_config_server_apis_inv_v1alpha1_DiscoveryProfile(ref), + "github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryRule": schema_config_server_apis_inv_v1alpha1_DiscoveryRule(ref), + "github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryRuleAddress": schema_config_server_apis_inv_v1alpha1_DiscoveryRuleAddress(ref), + "github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryRuleList": schema_config_server_apis_inv_v1alpha1_DiscoveryRuleList(ref), + "github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryRulePrefix": schema_config_server_apis_inv_v1alpha1_DiscoveryRulePrefix(ref), + "github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryRuleSpec": schema_config_server_apis_inv_v1alpha1_DiscoveryRuleSpec(ref), + "github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryRuleStatus": schema_config_server_apis_inv_v1alpha1_DiscoveryRuleStatus(ref), + "github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryVendorProfile": schema_config_server_apis_inv_v1alpha1_DiscoveryVendorProfile(ref), + "github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryVendorProfileList": schema_config_server_apis_inv_v1alpha1_DiscoveryVendorProfileList(ref), + "github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryVendorProfileSpec": schema_config_server_apis_inv_v1alpha1_DiscoveryVendorProfileSpec(ref), + "github.com/sdcio/config-server/apis/inv/v1alpha1.GnmiDiscoveryVendorProfileParameters": schema_config_server_apis_inv_v1alpha1_GnmiDiscoveryVendorProfileParameters(ref), + "github.com/sdcio/config-server/apis/inv/v1alpha1.Proxy": schema_config_server_apis_inv_v1alpha1_Proxy(ref), + "github.com/sdcio/config-server/apis/inv/v1alpha1.Repository": schema_config_server_apis_inv_v1alpha1_Repository(ref), + "github.com/sdcio/config-server/apis/inv/v1alpha1.Rollout": schema_config_server_apis_inv_v1alpha1_Rollout(ref), + "github.com/sdcio/config-server/apis/inv/v1alpha1.RolloutList": schema_config_server_apis_inv_v1alpha1_RolloutList(ref), + "github.com/sdcio/config-server/apis/inv/v1alpha1.RolloutSpec": schema_config_server_apis_inv_v1alpha1_RolloutSpec(ref), + "github.com/sdcio/config-server/apis/inv/v1alpha1.RolloutStatus": schema_config_server_apis_inv_v1alpha1_RolloutStatus(ref), + "github.com/sdcio/config-server/apis/inv/v1alpha1.RolloutTargetStatus": schema_config_server_apis_inv_v1alpha1_RolloutTargetStatus(ref), + "github.com/sdcio/config-server/apis/inv/v1alpha1.Schema": schema_config_server_apis_inv_v1alpha1_Schema(ref), + "github.com/sdcio/config-server/apis/inv/v1alpha1.SchemaKey": schema_config_server_apis_inv_v1alpha1_SchemaKey(ref), + "github.com/sdcio/config-server/apis/inv/v1alpha1.SchemaList": schema_config_server_apis_inv_v1alpha1_SchemaList(ref), + "github.com/sdcio/config-server/apis/inv/v1alpha1.SchemaRepositoryStatus": schema_config_server_apis_inv_v1alpha1_SchemaRepositoryStatus(ref), + "github.com/sdcio/config-server/apis/inv/v1alpha1.SchemaSpec": schema_config_server_apis_inv_v1alpha1_SchemaSpec(ref), + "github.com/sdcio/config-server/apis/inv/v1alpha1.SchemaSpecRepository": schema_config_server_apis_inv_v1alpha1_SchemaSpecRepository(ref), + "github.com/sdcio/config-server/apis/inv/v1alpha1.SchemaSpecSchema": schema_config_server_apis_inv_v1alpha1_SchemaSpecSchema(ref), + "github.com/sdcio/config-server/apis/inv/v1alpha1.SchemaStatus": schema_config_server_apis_inv_v1alpha1_SchemaStatus(ref), + "github.com/sdcio/config-server/apis/inv/v1alpha1.SrcDstPath": schema_config_server_apis_inv_v1alpha1_SrcDstPath(ref), + "github.com/sdcio/config-server/apis/inv/v1alpha1.Subscription": schema_config_server_apis_inv_v1alpha1_Subscription(ref), + "github.com/sdcio/config-server/apis/inv/v1alpha1.SubscriptionList": schema_config_server_apis_inv_v1alpha1_SubscriptionList(ref), + "github.com/sdcio/config-server/apis/inv/v1alpha1.SubscriptionParameters": schema_config_server_apis_inv_v1alpha1_SubscriptionParameters(ref), + "github.com/sdcio/config-server/apis/inv/v1alpha1.SubscriptionSpec": schema_config_server_apis_inv_v1alpha1_SubscriptionSpec(ref), + "github.com/sdcio/config-server/apis/inv/v1alpha1.SubscriptionStatus": schema_config_server_apis_inv_v1alpha1_SubscriptionStatus(ref), + "github.com/sdcio/config-server/apis/inv/v1alpha1.SubscriptionTarget": schema_config_server_apis_inv_v1alpha1_SubscriptionTarget(ref), + "github.com/sdcio/config-server/apis/inv/v1alpha1.Target": schema_config_server_apis_inv_v1alpha1_Target(ref), + "github.com/sdcio/config-server/apis/inv/v1alpha1.TargetConnectionProfile": schema_config_server_apis_inv_v1alpha1_TargetConnectionProfile(ref), + "github.com/sdcio/config-server/apis/inv/v1alpha1.TargetConnectionProfileList": schema_config_server_apis_inv_v1alpha1_TargetConnectionProfileList(ref), + "github.com/sdcio/config-server/apis/inv/v1alpha1.TargetConnectionProfileSpec": schema_config_server_apis_inv_v1alpha1_TargetConnectionProfileSpec(ref), + "github.com/sdcio/config-server/apis/inv/v1alpha1.TargetList": schema_config_server_apis_inv_v1alpha1_TargetList(ref), + "github.com/sdcio/config-server/apis/inv/v1alpha1.TargetProfile": schema_config_server_apis_inv_v1alpha1_TargetProfile(ref), + "github.com/sdcio/config-server/apis/inv/v1alpha1.TargetSpec": schema_config_server_apis_inv_v1alpha1_TargetSpec(ref), + "github.com/sdcio/config-server/apis/inv/v1alpha1.TargetStatus": schema_config_server_apis_inv_v1alpha1_TargetStatus(ref), + "github.com/sdcio/config-server/apis/inv/v1alpha1.TargetStatusUsedReferences": schema_config_server_apis_inv_v1alpha1_TargetStatusUsedReferences(ref), + "github.com/sdcio/config-server/apis/inv/v1alpha1.TargetSyncProfile": schema_config_server_apis_inv_v1alpha1_TargetSyncProfile(ref), + "github.com/sdcio/config-server/apis/inv/v1alpha1.TargetSyncProfileList": schema_config_server_apis_inv_v1alpha1_TargetSyncProfileList(ref), + "github.com/sdcio/config-server/apis/inv/v1alpha1.TargetSyncProfileSpec": schema_config_server_apis_inv_v1alpha1_TargetSyncProfileSpec(ref), + "github.com/sdcio/config-server/apis/inv/v1alpha1.TargetSyncProfileSync": schema_config_server_apis_inv_v1alpha1_TargetSyncProfileSync(ref), + "github.com/sdcio/config-server/apis/inv/v1alpha1.TargetTemplate": schema_config_server_apis_inv_v1alpha1_TargetTemplate(ref), + "github.com/sdcio/config-server/apis/inv/v1alpha1.Workspace": schema_config_server_apis_inv_v1alpha1_Workspace(ref), + "github.com/sdcio/config-server/apis/inv/v1alpha1.WorkspaceList": schema_config_server_apis_inv_v1alpha1_WorkspaceList(ref), + "github.com/sdcio/config-server/apis/inv/v1alpha1.WorkspaceSpec": schema_config_server_apis_inv_v1alpha1_WorkspaceSpec(ref), + "github.com/sdcio/config-server/apis/inv/v1alpha1.WorkspaceStatus": schema_config_server_apis_inv_v1alpha1_WorkspaceStatus(ref), + v1.AWSElasticBlockStoreVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_AWSElasticBlockStoreVolumeSource(ref), + v1.Affinity{}.OpenAPIModelName(): schema_k8sio_api_core_v1_Affinity(ref), + v1.AppArmorProfile{}.OpenAPIModelName(): schema_k8sio_api_core_v1_AppArmorProfile(ref), + v1.AttachedVolume{}.OpenAPIModelName(): schema_k8sio_api_core_v1_AttachedVolume(ref), + v1.AvoidPods{}.OpenAPIModelName(): schema_k8sio_api_core_v1_AvoidPods(ref), + v1.AzureDiskVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_AzureDiskVolumeSource(ref), + v1.AzureFilePersistentVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_AzureFilePersistentVolumeSource(ref), + v1.AzureFileVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_AzureFileVolumeSource(ref), + v1.Binding{}.OpenAPIModelName(): schema_k8sio_api_core_v1_Binding(ref), + v1.CSIPersistentVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_CSIPersistentVolumeSource(ref), + v1.CSIVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_CSIVolumeSource(ref), + v1.Capabilities{}.OpenAPIModelName(): schema_k8sio_api_core_v1_Capabilities(ref), + v1.CephFSPersistentVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_CephFSPersistentVolumeSource(ref), + v1.CephFSVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_CephFSVolumeSource(ref), + v1.CinderPersistentVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_CinderPersistentVolumeSource(ref), + v1.CinderVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_CinderVolumeSource(ref), + v1.ClientIPConfig{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ClientIPConfig(ref), + v1.ClusterTrustBundleProjection{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ClusterTrustBundleProjection(ref), + v1.ComponentCondition{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ComponentCondition(ref), + v1.ComponentStatus{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ComponentStatus(ref), + v1.ComponentStatusList{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ComponentStatusList(ref), + v1.ConfigMap{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ConfigMap(ref), + v1.ConfigMapEnvSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ConfigMapEnvSource(ref), + v1.ConfigMapKeySelector{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ConfigMapKeySelector(ref), + v1.ConfigMapList{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ConfigMapList(ref), + v1.ConfigMapNodeConfigSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ConfigMapNodeConfigSource(ref), + v1.ConfigMapProjection{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ConfigMapProjection(ref), + v1.ConfigMapVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ConfigMapVolumeSource(ref), + v1.Container{}.OpenAPIModelName(): schema_k8sio_api_core_v1_Container(ref), + v1.ContainerExtendedResourceRequest{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ContainerExtendedResourceRequest(ref), + v1.ContainerImage{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ContainerImage(ref), + v1.ContainerPort{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ContainerPort(ref), + v1.ContainerResizePolicy{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ContainerResizePolicy(ref), + v1.ContainerRestartRule{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ContainerRestartRule(ref), + v1.ContainerRestartRuleOnExitCodes{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ContainerRestartRuleOnExitCodes(ref), + v1.ContainerState{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ContainerState(ref), + v1.ContainerStateRunning{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ContainerStateRunning(ref), + v1.ContainerStateTerminated{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ContainerStateTerminated(ref), + v1.ContainerStateWaiting{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ContainerStateWaiting(ref), + v1.ContainerStatus{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ContainerStatus(ref), + v1.ContainerUser{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ContainerUser(ref), + v1.DaemonEndpoint{}.OpenAPIModelName(): schema_k8sio_api_core_v1_DaemonEndpoint(ref), + v1.DownwardAPIProjection{}.OpenAPIModelName(): schema_k8sio_api_core_v1_DownwardAPIProjection(ref), + v1.DownwardAPIVolumeFile{}.OpenAPIModelName(): schema_k8sio_api_core_v1_DownwardAPIVolumeFile(ref), + v1.DownwardAPIVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_DownwardAPIVolumeSource(ref), + v1.EmptyDirVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_EmptyDirVolumeSource(ref), + v1.EndpointAddress{}.OpenAPIModelName(): schema_k8sio_api_core_v1_EndpointAddress(ref), + v1.EndpointPort{}.OpenAPIModelName(): schema_k8sio_api_core_v1_EndpointPort(ref), + v1.EndpointSubset{}.OpenAPIModelName(): schema_k8sio_api_core_v1_EndpointSubset(ref), + v1.Endpoints{}.OpenAPIModelName(): schema_k8sio_api_core_v1_Endpoints(ref), + v1.EndpointsList{}.OpenAPIModelName(): schema_k8sio_api_core_v1_EndpointsList(ref), + v1.EnvFromSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_EnvFromSource(ref), + v1.EnvVar{}.OpenAPIModelName(): schema_k8sio_api_core_v1_EnvVar(ref), + v1.EnvVarSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_EnvVarSource(ref), + v1.EphemeralContainer{}.OpenAPIModelName(): schema_k8sio_api_core_v1_EphemeralContainer(ref), + v1.EphemeralContainerCommon{}.OpenAPIModelName(): schema_k8sio_api_core_v1_EphemeralContainerCommon(ref), + v1.EphemeralVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_EphemeralVolumeSource(ref), + v1.Event{}.OpenAPIModelName(): schema_k8sio_api_core_v1_Event(ref), + v1.EventList{}.OpenAPIModelName(): schema_k8sio_api_core_v1_EventList(ref), + v1.EventSeries{}.OpenAPIModelName(): schema_k8sio_api_core_v1_EventSeries(ref), + v1.EventSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_EventSource(ref), + v1.ExecAction{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ExecAction(ref), + v1.FCVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_FCVolumeSource(ref), + v1.FileKeySelector{}.OpenAPIModelName(): schema_k8sio_api_core_v1_FileKeySelector(ref), + v1.FlexPersistentVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_FlexPersistentVolumeSource(ref), + v1.FlexVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_FlexVolumeSource(ref), + v1.FlockerVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_FlockerVolumeSource(ref), + v1.GCEPersistentDiskVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_GCEPersistentDiskVolumeSource(ref), + v1.GRPCAction{}.OpenAPIModelName(): schema_k8sio_api_core_v1_GRPCAction(ref), + v1.GitRepoVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_GitRepoVolumeSource(ref), + v1.GlusterfsPersistentVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_GlusterfsPersistentVolumeSource(ref), + v1.GlusterfsVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_GlusterfsVolumeSource(ref), + v1.HTTPGetAction{}.OpenAPIModelName(): schema_k8sio_api_core_v1_HTTPGetAction(ref), + v1.HTTPHeader{}.OpenAPIModelName(): schema_k8sio_api_core_v1_HTTPHeader(ref), + v1.HostAlias{}.OpenAPIModelName(): schema_k8sio_api_core_v1_HostAlias(ref), + v1.HostIP{}.OpenAPIModelName(): schema_k8sio_api_core_v1_HostIP(ref), + v1.HostPathVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_HostPathVolumeSource(ref), + v1.ISCSIPersistentVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ISCSIPersistentVolumeSource(ref), + v1.ISCSIVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ISCSIVolumeSource(ref), + v1.ImageVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ImageVolumeSource(ref), + v1.KeyToPath{}.OpenAPIModelName(): schema_k8sio_api_core_v1_KeyToPath(ref), + v1.Lifecycle{}.OpenAPIModelName(): schema_k8sio_api_core_v1_Lifecycle(ref), + v1.LifecycleHandler{}.OpenAPIModelName(): schema_k8sio_api_core_v1_LifecycleHandler(ref), + v1.LimitRange{}.OpenAPIModelName(): schema_k8sio_api_core_v1_LimitRange(ref), + v1.LimitRangeItem{}.OpenAPIModelName(): schema_k8sio_api_core_v1_LimitRangeItem(ref), + v1.LimitRangeList{}.OpenAPIModelName(): schema_k8sio_api_core_v1_LimitRangeList(ref), + v1.LimitRangeSpec{}.OpenAPIModelName(): schema_k8sio_api_core_v1_LimitRangeSpec(ref), + v1.LinuxContainerUser{}.OpenAPIModelName(): schema_k8sio_api_core_v1_LinuxContainerUser(ref), + v1.List{}.OpenAPIModelName(): schema_k8sio_api_core_v1_List(ref), + v1.LoadBalancerIngress{}.OpenAPIModelName(): schema_k8sio_api_core_v1_LoadBalancerIngress(ref), + v1.LoadBalancerStatus{}.OpenAPIModelName(): schema_k8sio_api_core_v1_LoadBalancerStatus(ref), + v1.LocalObjectReference{}.OpenAPIModelName(): schema_k8sio_api_core_v1_LocalObjectReference(ref), + v1.LocalVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_LocalVolumeSource(ref), + v1.ModifyVolumeStatus{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ModifyVolumeStatus(ref), + v1.NFSVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_NFSVolumeSource(ref), + v1.Namespace{}.OpenAPIModelName(): schema_k8sio_api_core_v1_Namespace(ref), + v1.NamespaceCondition{}.OpenAPIModelName(): schema_k8sio_api_core_v1_NamespaceCondition(ref), + v1.NamespaceList{}.OpenAPIModelName(): schema_k8sio_api_core_v1_NamespaceList(ref), + v1.NamespaceSpec{}.OpenAPIModelName(): schema_k8sio_api_core_v1_NamespaceSpec(ref), + v1.NamespaceStatus{}.OpenAPIModelName(): schema_k8sio_api_core_v1_NamespaceStatus(ref), + v1.Node{}.OpenAPIModelName(): schema_k8sio_api_core_v1_Node(ref), + v1.NodeAddress{}.OpenAPIModelName(): schema_k8sio_api_core_v1_NodeAddress(ref), + v1.NodeAffinity{}.OpenAPIModelName(): schema_k8sio_api_core_v1_NodeAffinity(ref), + v1.NodeCondition{}.OpenAPIModelName(): schema_k8sio_api_core_v1_NodeCondition(ref), + v1.NodeConfigSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_NodeConfigSource(ref), + v1.NodeConfigStatus{}.OpenAPIModelName(): schema_k8sio_api_core_v1_NodeConfigStatus(ref), + v1.NodeDaemonEndpoints{}.OpenAPIModelName(): schema_k8sio_api_core_v1_NodeDaemonEndpoints(ref), + v1.NodeFeatures{}.OpenAPIModelName(): schema_k8sio_api_core_v1_NodeFeatures(ref), + v1.NodeList{}.OpenAPIModelName(): schema_k8sio_api_core_v1_NodeList(ref), + v1.NodeProxyOptions{}.OpenAPIModelName(): schema_k8sio_api_core_v1_NodeProxyOptions(ref), + v1.NodeRuntimeHandler{}.OpenAPIModelName(): schema_k8sio_api_core_v1_NodeRuntimeHandler(ref), + v1.NodeRuntimeHandlerFeatures{}.OpenAPIModelName(): schema_k8sio_api_core_v1_NodeRuntimeHandlerFeatures(ref), + v1.NodeSelector{}.OpenAPIModelName(): schema_k8sio_api_core_v1_NodeSelector(ref), + v1.NodeSelectorRequirement{}.OpenAPIModelName(): schema_k8sio_api_core_v1_NodeSelectorRequirement(ref), + v1.NodeSelectorTerm{}.OpenAPIModelName(): schema_k8sio_api_core_v1_NodeSelectorTerm(ref), + v1.NodeSpec{}.OpenAPIModelName(): schema_k8sio_api_core_v1_NodeSpec(ref), + v1.NodeStatus{}.OpenAPIModelName(): schema_k8sio_api_core_v1_NodeStatus(ref), + v1.NodeSwapStatus{}.OpenAPIModelName(): schema_k8sio_api_core_v1_NodeSwapStatus(ref), + v1.NodeSystemInfo{}.OpenAPIModelName(): schema_k8sio_api_core_v1_NodeSystemInfo(ref), + v1.ObjectFieldSelector{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ObjectFieldSelector(ref), + v1.ObjectReference{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ObjectReference(ref), + v1.PersistentVolume{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PersistentVolume(ref), + v1.PersistentVolumeClaim{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PersistentVolumeClaim(ref), + v1.PersistentVolumeClaimCondition{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PersistentVolumeClaimCondition(ref), + v1.PersistentVolumeClaimList{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PersistentVolumeClaimList(ref), + v1.PersistentVolumeClaimSpec{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PersistentVolumeClaimSpec(ref), + v1.PersistentVolumeClaimStatus{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PersistentVolumeClaimStatus(ref), + v1.PersistentVolumeClaimTemplate{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PersistentVolumeClaimTemplate(ref), + v1.PersistentVolumeClaimVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PersistentVolumeClaimVolumeSource(ref), + v1.PersistentVolumeList{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PersistentVolumeList(ref), + v1.PersistentVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PersistentVolumeSource(ref), + v1.PersistentVolumeSpec{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PersistentVolumeSpec(ref), + v1.PersistentVolumeStatus{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PersistentVolumeStatus(ref), + v1.PhotonPersistentDiskVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PhotonPersistentDiskVolumeSource(ref), + v1.Pod{}.OpenAPIModelName(): schema_k8sio_api_core_v1_Pod(ref), + v1.PodAffinity{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PodAffinity(ref), + v1.PodAffinityTerm{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PodAffinityTerm(ref), + v1.PodAntiAffinity{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PodAntiAffinity(ref), + v1.PodAttachOptions{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PodAttachOptions(ref), + v1.PodCertificateProjection{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PodCertificateProjection(ref), + v1.PodCondition{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PodCondition(ref), + v1.PodDNSConfig{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PodDNSConfig(ref), + v1.PodDNSConfigOption{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PodDNSConfigOption(ref), + v1.PodExecOptions{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PodExecOptions(ref), + v1.PodExtendedResourceClaimStatus{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PodExtendedResourceClaimStatus(ref), + v1.PodIP{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PodIP(ref), + v1.PodList{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PodList(ref), + v1.PodLogOptions{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PodLogOptions(ref), + v1.PodOS{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PodOS(ref), + v1.PodPortForwardOptions{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PodPortForwardOptions(ref), + v1.PodProxyOptions{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PodProxyOptions(ref), + v1.PodReadinessGate{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PodReadinessGate(ref), + v1.PodResourceClaim{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PodResourceClaim(ref), + v1.PodResourceClaimStatus{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PodResourceClaimStatus(ref), + v1.PodSchedulingGate{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PodSchedulingGate(ref), + v1.PodSecurityContext{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PodSecurityContext(ref), + v1.PodSignature{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PodSignature(ref), + v1.PodSpec{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PodSpec(ref), + v1.PodStatus{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PodStatus(ref), + v1.PodStatusResult{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PodStatusResult(ref), + v1.PodTemplate{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PodTemplate(ref), + v1.PodTemplateList{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PodTemplateList(ref), + v1.PodTemplateSpec{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PodTemplateSpec(ref), + v1.PortStatus{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PortStatus(ref), + v1.PortworxVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PortworxVolumeSource(ref), + v1.PreferAvoidPodsEntry{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PreferAvoidPodsEntry(ref), + v1.PreferredSchedulingTerm{}.OpenAPIModelName(): schema_k8sio_api_core_v1_PreferredSchedulingTerm(ref), + v1.Probe{}.OpenAPIModelName(): schema_k8sio_api_core_v1_Probe(ref), + v1.ProbeHandler{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ProbeHandler(ref), + v1.ProjectedVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ProjectedVolumeSource(ref), + v1.QuobyteVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_QuobyteVolumeSource(ref), + v1.RBDPersistentVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_RBDPersistentVolumeSource(ref), + v1.RBDVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_RBDVolumeSource(ref), + v1.RangeAllocation{}.OpenAPIModelName(): schema_k8sio_api_core_v1_RangeAllocation(ref), + v1.ReplicationController{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ReplicationController(ref), + v1.ReplicationControllerCondition{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ReplicationControllerCondition(ref), + v1.ReplicationControllerList{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ReplicationControllerList(ref), + v1.ReplicationControllerSpec{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ReplicationControllerSpec(ref), + v1.ReplicationControllerStatus{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ReplicationControllerStatus(ref), + v1.ResourceClaim{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ResourceClaim(ref), + v1.ResourceFieldSelector{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ResourceFieldSelector(ref), + v1.ResourceHealth{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ResourceHealth(ref), + v1.ResourceQuota{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ResourceQuota(ref), + v1.ResourceQuotaList{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ResourceQuotaList(ref), + v1.ResourceQuotaSpec{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ResourceQuotaSpec(ref), + v1.ResourceQuotaStatus{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ResourceQuotaStatus(ref), + v1.ResourceRequirements{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ResourceRequirements(ref), + v1.ResourceStatus{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ResourceStatus(ref), + v1.SELinuxOptions{}.OpenAPIModelName(): schema_k8sio_api_core_v1_SELinuxOptions(ref), + v1.ScaleIOPersistentVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ScaleIOPersistentVolumeSource(ref), + v1.ScaleIOVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ScaleIOVolumeSource(ref), + v1.ScopeSelector{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ScopeSelector(ref), + v1.ScopedResourceSelectorRequirement{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ScopedResourceSelectorRequirement(ref), + v1.SeccompProfile{}.OpenAPIModelName(): schema_k8sio_api_core_v1_SeccompProfile(ref), + v1.Secret{}.OpenAPIModelName(): schema_k8sio_api_core_v1_Secret(ref), + v1.SecretEnvSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_SecretEnvSource(ref), + v1.SecretKeySelector{}.OpenAPIModelName(): schema_k8sio_api_core_v1_SecretKeySelector(ref), + v1.SecretList{}.OpenAPIModelName(): schema_k8sio_api_core_v1_SecretList(ref), + v1.SecretProjection{}.OpenAPIModelName(): schema_k8sio_api_core_v1_SecretProjection(ref), + v1.SecretReference{}.OpenAPIModelName(): schema_k8sio_api_core_v1_SecretReference(ref), + v1.SecretVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_SecretVolumeSource(ref), + v1.SecurityContext{}.OpenAPIModelName(): schema_k8sio_api_core_v1_SecurityContext(ref), + v1.SerializedReference{}.OpenAPIModelName(): schema_k8sio_api_core_v1_SerializedReference(ref), + v1.Service{}.OpenAPIModelName(): schema_k8sio_api_core_v1_Service(ref), + v1.ServiceAccount{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ServiceAccount(ref), + v1.ServiceAccountList{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ServiceAccountList(ref), + v1.ServiceAccountTokenProjection{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ServiceAccountTokenProjection(ref), + v1.ServiceList{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ServiceList(ref), + v1.ServicePort{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ServicePort(ref), + v1.ServiceProxyOptions{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ServiceProxyOptions(ref), + v1.ServiceSpec{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ServiceSpec(ref), + v1.ServiceStatus{}.OpenAPIModelName(): schema_k8sio_api_core_v1_ServiceStatus(ref), + v1.SessionAffinityConfig{}.OpenAPIModelName(): schema_k8sio_api_core_v1_SessionAffinityConfig(ref), + v1.SleepAction{}.OpenAPIModelName(): schema_k8sio_api_core_v1_SleepAction(ref), + v1.StorageOSPersistentVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_StorageOSPersistentVolumeSource(ref), + v1.StorageOSVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_StorageOSVolumeSource(ref), + v1.Sysctl{}.OpenAPIModelName(): schema_k8sio_api_core_v1_Sysctl(ref), + v1.TCPSocketAction{}.OpenAPIModelName(): schema_k8sio_api_core_v1_TCPSocketAction(ref), + v1.Taint{}.OpenAPIModelName(): schema_k8sio_api_core_v1_Taint(ref), + v1.Toleration{}.OpenAPIModelName(): schema_k8sio_api_core_v1_Toleration(ref), + v1.TopologySelectorLabelRequirement{}.OpenAPIModelName(): schema_k8sio_api_core_v1_TopologySelectorLabelRequirement(ref), + v1.TopologySelectorTerm{}.OpenAPIModelName(): schema_k8sio_api_core_v1_TopologySelectorTerm(ref), + v1.TopologySpreadConstraint{}.OpenAPIModelName(): schema_k8sio_api_core_v1_TopologySpreadConstraint(ref), + v1.TypedLocalObjectReference{}.OpenAPIModelName(): schema_k8sio_api_core_v1_TypedLocalObjectReference(ref), + v1.TypedObjectReference{}.OpenAPIModelName(): schema_k8sio_api_core_v1_TypedObjectReference(ref), + v1.Volume{}.OpenAPIModelName(): schema_k8sio_api_core_v1_Volume(ref), + v1.VolumeDevice{}.OpenAPIModelName(): schema_k8sio_api_core_v1_VolumeDevice(ref), + v1.VolumeMount{}.OpenAPIModelName(): schema_k8sio_api_core_v1_VolumeMount(ref), + v1.VolumeMountStatus{}.OpenAPIModelName(): schema_k8sio_api_core_v1_VolumeMountStatus(ref), + v1.VolumeNodeAffinity{}.OpenAPIModelName(): schema_k8sio_api_core_v1_VolumeNodeAffinity(ref), + v1.VolumeProjection{}.OpenAPIModelName(): schema_k8sio_api_core_v1_VolumeProjection(ref), + v1.VolumeResourceRequirements{}.OpenAPIModelName(): schema_k8sio_api_core_v1_VolumeResourceRequirements(ref), + v1.VolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_VolumeSource(ref), + v1.VsphereVirtualDiskVolumeSource{}.OpenAPIModelName(): schema_k8sio_api_core_v1_VsphereVirtualDiskVolumeSource(ref), + v1.WeightedPodAffinityTerm{}.OpenAPIModelName(): schema_k8sio_api_core_v1_WeightedPodAffinityTerm(ref), + v1.WindowsSecurityContextOptions{}.OpenAPIModelName(): schema_k8sio_api_core_v1_WindowsSecurityContextOptions(ref), + v1.WorkloadReference{}.OpenAPIModelName(): schema_k8sio_api_core_v1_WorkloadReference(ref), + resource.Quantity{}.OpenAPIModelName(): schema_apimachinery_pkg_api_resource_Quantity(ref), + metav1.APIGroup{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_APIGroup(ref), + metav1.APIGroupList{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_APIGroupList(ref), + metav1.APIResource{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_APIResource(ref), + metav1.APIResourceList{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_APIResourceList(ref), + metav1.APIVersions{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_APIVersions(ref), + metav1.ApplyOptions{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_ApplyOptions(ref), + metav1.Condition{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_Condition(ref), + metav1.CreateOptions{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_CreateOptions(ref), + metav1.DeleteOptions{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_DeleteOptions(ref), + metav1.Duration{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_Duration(ref), + metav1.FieldSelectorRequirement{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_FieldSelectorRequirement(ref), + metav1.FieldsV1{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_FieldsV1(ref), + metav1.GetOptions{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_GetOptions(ref), + metav1.GroupKind{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_GroupKind(ref), + metav1.GroupResource{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_GroupResource(ref), + metav1.GroupVersion{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_GroupVersion(ref), + metav1.GroupVersionForDiscovery{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_GroupVersionForDiscovery(ref), + metav1.GroupVersionKind{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_GroupVersionKind(ref), + metav1.GroupVersionResource{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_GroupVersionResource(ref), + metav1.InternalEvent{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_InternalEvent(ref), + metav1.LabelSelector{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_LabelSelector(ref), + metav1.LabelSelectorRequirement{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_LabelSelectorRequirement(ref), + metav1.List{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_List(ref), + metav1.ListMeta{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_ListMeta(ref), + metav1.ListOptions{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_ListOptions(ref), + metav1.ManagedFieldsEntry{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_ManagedFieldsEntry(ref), + metav1.MicroTime{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_MicroTime(ref), + metav1.ObjectMeta{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_ObjectMeta(ref), + metav1.OwnerReference{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_OwnerReference(ref), + metav1.PartialObjectMetadata{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_PartialObjectMetadata(ref), + metav1.PartialObjectMetadataList{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_PartialObjectMetadataList(ref), + metav1.Patch{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_Patch(ref), + metav1.PatchOptions{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_PatchOptions(ref), + metav1.Preconditions{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_Preconditions(ref), + metav1.RootPaths{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_RootPaths(ref), + metav1.ServerAddressByClientCIDR{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_ServerAddressByClientCIDR(ref), + metav1.Status{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_Status(ref), + metav1.StatusCause{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_StatusCause(ref), + metav1.StatusDetails{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_StatusDetails(ref), + metav1.Table{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_Table(ref), + metav1.TableColumnDefinition{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_TableColumnDefinition(ref), + metav1.TableOptions{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_TableOptions(ref), + metav1.TableRow{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_TableRow(ref), + metav1.TableRowCondition{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_TableRowCondition(ref), + metav1.Time{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_Time(ref), + metav1.Timestamp{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_Timestamp(ref), + metav1.TypeMeta{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_TypeMeta(ref), + metav1.UpdateOptions{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_UpdateOptions(ref), + metav1.WatchEvent{}.OpenAPIModelName(): schema_pkg_apis_meta_v1_WatchEvent(ref), + runtime.RawExtension{}.OpenAPIModelName(): schema_k8sio_apimachinery_pkg_runtime_RawExtension(ref), + runtime.TypeMeta{}.OpenAPIModelName(): schema_k8sio_apimachinery_pkg_runtime_TypeMeta(ref), + runtime.Unknown{}.OpenAPIModelName(): schema_k8sio_apimachinery_pkg_runtime_Unknown(ref), + version.Info{}.OpenAPIModelName(): schema_k8sio_apimachinery_pkg_version_Info(ref), + } +} + +func schema_config_server_apis_condition_v1alpha1_Condition(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "type": { + SchemaProps: spec.SchemaProps{ + Description: "type of condition in CamelCase or in foo.example.com/CamelCase.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "status": { + SchemaProps: spec.SchemaProps{ + Description: "status of the condition, one of True, False, Unknown.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "observedGeneration": { + SchemaProps: spec.SchemaProps{ + Description: "observedGeneration represents the .metadata.generation that the condition was set based upon. For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date with respect to the current state of the instance.", + Type: []string{"integer"}, + Format: "int64", + }, + }, + "lastTransitionTime": { + SchemaProps: spec.SchemaProps{ + Description: "lastTransitionTime is the last time the condition transitioned from one status to another. This should be when the underlying condition changed. If that is not known, then using the time when the API field changed is acceptable.", + Ref: ref(metav1.Time{}.OpenAPIModelName()), + }, + }, + "reason": { + SchemaProps: spec.SchemaProps{ + Description: "reason contains a programmatic identifier indicating the reason for the condition's last transition. Producers of specific condition types may define expected values and meanings for this field, and whether the values are considered a guaranteed API. The value should be a CamelCase string. This field may not be empty.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "message": { + SchemaProps: spec.SchemaProps{ + Description: "message is a human readable message indicating details about the transition. This may be an empty string.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"type", "status", "lastTransitionTime", "reason", "message"}, + }, + }, + Dependencies: []string{ + metav1.Time{}.OpenAPIModelName()}, + } +} + +func schema_config_server_apis_condition_v1alpha1_ConditionedStatus(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "A ConditionedStatus reflects the observed status of a resource. Only one condition of each type may exist.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "conditions": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-map-keys": []interface{}{ + "type", + }, + "x-kubernetes-list-type": "map", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "Conditions of the resource.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("github.com/sdcio/config-server/apis/condition/v1alpha1.Condition"), + }, + }, + }, + }, + }, + }, + }, + }, + Dependencies: []string{ + "github.com/sdcio/config-server/apis/condition/v1alpha1.Condition"}, + } +} + +func schema_config_server_apis_condition_v1alpha1_UnrecoverableMessage(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "resourceVersion": { + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "message": { + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"resourceVersion", "message"}, + }, + }, } } @@ -85,7 +562,7 @@ func schema_config_server_apis_config_v1alpha1_Config(ref common.ReferenceCallba "metadata": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"), + Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), }, }, "spec": { @@ -104,7 +581,7 @@ func schema_config_server_apis_config_v1alpha1_Config(ref common.ReferenceCallba }, }, Dependencies: []string{ - "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigSpec", "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigStatus", "k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"}, + "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigSpec", "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigStatus", metav1.ObjectMeta{}.OpenAPIModelName()}, } } @@ -132,7 +609,7 @@ func schema_config_server_apis_config_v1alpha1_ConfigBlame(ref common.ReferenceC "metadata": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"), + Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), }, }, "spec": { @@ -151,7 +628,7 @@ func schema_config_server_apis_config_v1alpha1_ConfigBlame(ref common.ReferenceC }, }, Dependencies: []string{ - "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigBlameSpec", "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigBlameStatus", "k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"}, + "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigBlameSpec", "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigBlameStatus", metav1.ObjectMeta{}.OpenAPIModelName()}, } } @@ -179,7 +656,7 @@ func schema_config_server_apis_config_v1alpha1_ConfigBlameList(ref common.Refere "metadata": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"), + Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), }, }, "items": { @@ -200,7 +677,7 @@ func schema_config_server_apis_config_v1alpha1_ConfigBlameList(ref common.Refere }, }, Dependencies: []string{ - "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigBlame", "k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"}, + "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigBlame", metav1.ListMeta{}.OpenAPIModelName()}, } } @@ -224,7 +701,7 @@ func schema_config_server_apis_config_v1alpha1_ConfigBlameStatus(ref common.Refe Properties: map[string]spec.Schema{ "value": { SchemaProps: spec.SchemaProps{ - Ref: ref("k8s.io/apimachinery/pkg/runtime.RawExtension"), + Ref: ref(runtime.RawExtension{}.OpenAPIModelName()), }, }, }, @@ -232,7 +709,7 @@ func schema_config_server_apis_config_v1alpha1_ConfigBlameStatus(ref common.Refe }, }, Dependencies: []string{ - "k8s.io/apimachinery/pkg/runtime.RawExtension"}, + runtime.RawExtension{}.OpenAPIModelName()}, } } @@ -251,7 +728,7 @@ func schema_config_server_apis_config_v1alpha1_ConfigBlob(ref common.ReferenceCa }, "value": { SchemaProps: spec.SchemaProps{ - Ref: ref("k8s.io/apimachinery/pkg/runtime.RawExtension"), + Ref: ref(runtime.RawExtension{}.OpenAPIModelName()), }, }, }, @@ -259,7 +736,7 @@ func schema_config_server_apis_config_v1alpha1_ConfigBlob(ref common.ReferenceCa }, }, Dependencies: []string{ - "k8s.io/apimachinery/pkg/runtime.RawExtension"}, + runtime.RawExtension{}.OpenAPIModelName()}, } } @@ -285,7 +762,7 @@ func schema_config_server_apis_config_v1alpha1_ConfigDeviation(ref common.Refere }, "actualValue": { SchemaProps: spec.SchemaProps{ - Description: "CurrentValue defines the current value of the config belonging to the path that is currently configured on the target", + Description: "ActualValue defines the current value of the config belonging to the path that is currently configured on the target", Type: []string{"string"}, Format: "", }, @@ -327,7 +804,7 @@ func schema_config_server_apis_config_v1alpha1_ConfigList(ref common.ReferenceCa "metadata": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"), + Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), }, }, "items": { @@ -348,7 +825,7 @@ func schema_config_server_apis_config_v1alpha1_ConfigList(ref common.ReferenceCa }, }, Dependencies: []string{ - "github.com/sdcio/config-server/apis/config/v1alpha1.Config", "k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"}, + "github.com/sdcio/config-server/apis/config/v1alpha1.Config", metav1.ListMeta{}.OpenAPIModelName()}, } } @@ -376,7 +853,7 @@ func schema_config_server_apis_config_v1alpha1_ConfigSet(ref common.ReferenceCal "metadata": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"), + Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), }, }, "spec": { @@ -395,7 +872,7 @@ func schema_config_server_apis_config_v1alpha1_ConfigSet(ref common.ReferenceCal }, }, Dependencies: []string{ - "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigSetSpec", "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigSetStatus", "k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"}, + "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigSetSpec", "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigSetStatus", metav1.ObjectMeta{}.OpenAPIModelName()}, } } @@ -423,7 +900,7 @@ func schema_config_server_apis_config_v1alpha1_ConfigSetList(ref common.Referenc "metadata": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"), + Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), }, }, "items": { @@ -444,7 +921,7 @@ func schema_config_server_apis_config_v1alpha1_ConfigSetList(ref common.Referenc }, }, Dependencies: []string{ - "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigSet", "k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"}, + "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigSet", metav1.ListMeta{}.OpenAPIModelName()}, } } @@ -483,6 +960,11 @@ func schema_config_server_apis_config_v1alpha1_ConfigSetSpec(ref common.Referenc }, }, "config": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, SchemaProps: spec.SchemaProps{ Description: "Config defines the configuration to be applied to a target device", Type: []string{"array"}, @@ -535,6 +1017,11 @@ func schema_config_server_apis_config_v1alpha1_ConfigSetStatus(ref common.Refere }, }, "targets": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, SchemaProps: spec.SchemaProps{ Description: "Targets defines the status of the configSet resource on the respective target", Type: []string{"array"}, @@ -584,6 +1071,11 @@ func schema_config_server_apis_config_v1alpha1_ConfigSpec(ref common.ReferenceCa }, }, "config": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, SchemaProps: spec.SchemaProps{ Description: "Config defines the configuration to be applied to a target device", Type: []string{"array"}, @@ -719,7 +1211,7 @@ func schema_config_server_apis_config_v1alpha1_Deviation(ref common.ReferenceCal "metadata": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"), + Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), }, }, "spec": { @@ -738,7 +1230,7 @@ func schema_config_server_apis_config_v1alpha1_Deviation(ref common.ReferenceCal }, }, Dependencies: []string{ - "github.com/sdcio/config-server/apis/config/v1alpha1.DeviationSpec", "github.com/sdcio/config-server/apis/config/v1alpha1.DeviationStatus", "k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"}, + "github.com/sdcio/config-server/apis/config/v1alpha1.DeviationSpec", "github.com/sdcio/config-server/apis/config/v1alpha1.DeviationStatus", metav1.ObjectMeta{}.OpenAPIModelName()}, } } @@ -766,7 +1258,7 @@ func schema_config_server_apis_config_v1alpha1_DeviationList(ref common.Referenc "metadata": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"), + Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), }, }, "items": { @@ -787,7 +1279,7 @@ func schema_config_server_apis_config_v1alpha1_DeviationList(ref common.Referenc }, }, Dependencies: []string{ - "github.com/sdcio/config-server/apis/config/v1alpha1.Deviation", "k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"}, + "github.com/sdcio/config-server/apis/config/v1alpha1.Deviation", metav1.ListMeta{}.OpenAPIModelName()}, } } @@ -805,6 +1297,11 @@ func schema_config_server_apis_config_v1alpha1_DeviationSpec(ref common.Referenc }, }, "deviations": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, SchemaProps: spec.SchemaProps{ Description: "Deviations identify the configuration deviation based on the last applied config CR", Type: []string{"array"}, @@ -906,7 +1403,7 @@ func schema_config_server_apis_config_v1alpha1_RunningConfig(ref common.Referenc "metadata": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"), + Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), }, }, "spec": { @@ -925,7 +1422,7 @@ func schema_config_server_apis_config_v1alpha1_RunningConfig(ref common.Referenc }, }, Dependencies: []string{ - "github.com/sdcio/config-server/apis/config/v1alpha1.RunningConfigSpec", "github.com/sdcio/config-server/apis/config/v1alpha1.RunningConfigStatus", "k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"}, + "github.com/sdcio/config-server/apis/config/v1alpha1.RunningConfigSpec", "github.com/sdcio/config-server/apis/config/v1alpha1.RunningConfigStatus", metav1.ObjectMeta{}.OpenAPIModelName()}, } } @@ -953,7 +1450,7 @@ func schema_config_server_apis_config_v1alpha1_RunningConfigList(ref common.Refe "metadata": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"), + Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), }, }, "items": { @@ -974,7 +1471,7 @@ func schema_config_server_apis_config_v1alpha1_RunningConfigList(ref common.Refe }, }, Dependencies: []string{ - "github.com/sdcio/config-server/apis/config/v1alpha1.RunningConfig", "k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"}, + "github.com/sdcio/config-server/apis/config/v1alpha1.RunningConfig", metav1.ListMeta{}.OpenAPIModelName()}, } } @@ -998,7 +1495,7 @@ func schema_config_server_apis_config_v1alpha1_RunningConfigStatus(ref common.Re Properties: map[string]spec.Schema{ "value": { SchemaProps: spec.SchemaProps{ - Ref: ref("k8s.io/apimachinery/pkg/runtime.RawExtension"), + Ref: ref(runtime.RawExtension{}.OpenAPIModelName()), }, }, }, @@ -1006,7 +1503,7 @@ func schema_config_server_apis_config_v1alpha1_RunningConfigStatus(ref common.Re }, }, Dependencies: []string{ - "k8s.io/apimachinery/pkg/runtime.RawExtension"}, + runtime.RawExtension{}.OpenAPIModelName()}, } } @@ -1034,7 +1531,7 @@ func schema_config_server_apis_config_v1alpha1_SensitiveConfig(ref common.Refere "metadata": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"), + Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), }, }, "spec": { @@ -1053,7 +1550,7 @@ func schema_config_server_apis_config_v1alpha1_SensitiveConfig(ref common.Refere }, }, Dependencies: []string{ - "github.com/sdcio/config-server/apis/config/v1alpha1.SensitiveConfigSpec", "github.com/sdcio/config-server/apis/config/v1alpha1.SensitiveConfigStatus", "k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"}, + "github.com/sdcio/config-server/apis/config/v1alpha1.SensitiveConfigSpec", "github.com/sdcio/config-server/apis/config/v1alpha1.SensitiveConfigStatus", metav1.ObjectMeta{}.OpenAPIModelName()}, } } @@ -1075,7 +1572,7 @@ func schema_config_server_apis_config_v1alpha1_SensitiveConfigData(ref common.Re SchemaProps: spec.SchemaProps{ Description: "SecretKeyRef refers to a secret in the same namesapce as the config", Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.SecretKeySelector"), + Ref: ref(v1.SecretKeySelector{}.OpenAPIModelName()), }, }, }, @@ -1083,7 +1580,7 @@ func schema_config_server_apis_config_v1alpha1_SensitiveConfigData(ref common.Re }, }, Dependencies: []string{ - "k8s.io/api/core/v1.SecretKeySelector"}, + v1.SecretKeySelector{}.OpenAPIModelName()}, } } @@ -1111,7 +1608,7 @@ func schema_config_server_apis_config_v1alpha1_SensitiveConfigList(ref common.Re "metadata": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"), + Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), }, }, "items": { @@ -1132,7 +1629,7 @@ func schema_config_server_apis_config_v1alpha1_SensitiveConfigList(ref common.Re }, }, Dependencies: []string{ - "github.com/sdcio/config-server/apis/config/v1alpha1.SensitiveConfig", "k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"}, + "github.com/sdcio/config-server/apis/config/v1alpha1.SensitiveConfig", metav1.ListMeta{}.OpenAPIModelName()}, } } @@ -1164,6 +1661,11 @@ func schema_config_server_apis_config_v1alpha1_SensitiveConfigSpec(ref common.Re }, }, "config": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, SchemaProps: spec.SchemaProps{ Description: "SensitiveConfig defines the SensitiveConfiguration to be applied to a target device", Type: []string{"array"}, @@ -1251,14 +1753,14 @@ func schema_config_server_apis_config_v1alpha1_Target(ref common.ReferenceCallba "targetSelector": { SchemaProps: spec.SchemaProps{ Description: "TargetSelector defines the selector used to select the targets to which the config applies", - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.LabelSelector"), + Ref: ref(metav1.LabelSelector{}.OpenAPIModelName()), }, }, }, }, }, Dependencies: []string{ - "k8s.io/apimachinery/pkg/apis/meta/v1.LabelSelector"}, + metav1.LabelSelector{}.OpenAPIModelName()}, } } @@ -1301,7 +1803,7 @@ func schema_config_server_apis_config_v1alpha1_TargetStatus(ref common.Reference "lastTransitionTime": { SchemaProps: spec.SchemaProps{ Description: "lastTransitionTime is the last time the condition transitioned from one status to another. This should be when the underlying condition changed. If that is not known, then using the time when the API field changed is acceptable.", - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.Time"), + Ref: ref(metav1.Time{}.OpenAPIModelName()), }, }, "reason": { @@ -1325,6 +1827,19378 @@ func schema_config_server_apis_config_v1alpha1_TargetStatus(ref common.Reference }, }, Dependencies: []string{ - "k8s.io/apimachinery/pkg/apis/meta/v1.Time"}, + metav1.Time{}.OpenAPIModelName()}, + } +} + +func schema_config_server_apis_inv_v1alpha1_DiscoveryInfo(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "protocol": { + SchemaProps: spec.SchemaProps{ + Description: "Protocol used for discovery", + Type: []string{"string"}, + Format: "", + }, + }, + "provider": { + SchemaProps: spec.SchemaProps{ + Description: "Type associated with the target", + Type: []string{"string"}, + Format: "", + }, + }, + "version": { + SchemaProps: spec.SchemaProps{ + Description: "Version associated with the target", + Type: []string{"string"}, + Format: "", + }, + }, + "hostname": { + SchemaProps: spec.SchemaProps{ + Description: "Hostname associated with the target", + Type: []string{"string"}, + Format: "", + }, + }, + "platform": { + SchemaProps: spec.SchemaProps{ + Description: "Platform associated with the target", + Type: []string{"string"}, + Format: "", + }, + }, + "macAddress": { + SchemaProps: spec.SchemaProps{ + Description: "MacAddress associated with the target", + Type: []string{"string"}, + Format: "", + }, + }, + "serialNumber": { + SchemaProps: spec.SchemaProps{ + Description: "SerialNumber associated with the target", + Type: []string{"string"}, + Format: "", + }, + }, + "supportedEncodings": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "Supported Encodings of the target", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + }, + }, + }, + } +} + +func schema_config_server_apis_inv_v1alpha1_DiscoveryParameters(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "defaultSchema": { + SchemaProps: spec.SchemaProps{ + Description: "DefaultSchema define the default schema used to connect to a target Indicates that discovery is disable; cannot be used for prefix based discovery rules", + Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.SchemaKey"), + }, + }, + "discoveryProfile": { + SchemaProps: spec.SchemaProps{ + Description: "DiscoveryProfile define the profiles the discovery controller uses to discover targets", + Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryProfile"), + }, + }, + "targetConnectionProfiles": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "TargetConnectionProfiles define the profile the discovery controller uses to create targets once discovered", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.TargetProfile"), + }, + }, + }, + }, + }, + "targetTemplate": { + SchemaProps: spec.SchemaProps{ + Description: "TargetTemplate defines the template the discovery controller uses to create the targets as a result of the discovery", + Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.TargetTemplate"), + }, + }, + "period": { + SchemaProps: spec.SchemaProps{ + Description: "Period defines the wait period between discovery rule runs", + Ref: ref(metav1.Duration{}.OpenAPIModelName()), + }, + }, + "concurrentScans": { + SchemaProps: spec.SchemaProps{ + Description: "number of concurrent IP scan", + Type: []string{"integer"}, + Format: "int64", + }, + }, + }, + Required: []string{"targetConnectionProfiles"}, + }, + }, + Dependencies: []string{ + "github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryProfile", "github.com/sdcio/config-server/apis/inv/v1alpha1.SchemaKey", "github.com/sdcio/config-server/apis/inv/v1alpha1.TargetProfile", "github.com/sdcio/config-server/apis/inv/v1alpha1.TargetTemplate", metav1.Duration{}.OpenAPIModelName()}, + } +} + +func schema_config_server_apis_inv_v1alpha1_DiscoveryPathDefinition(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "key": { + SchemaProps: spec.SchemaProps{ + Description: "Key defines the key of the path for fast lookup", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "path": { + SchemaProps: spec.SchemaProps{ + Description: "Path associated with the key", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "script": { + SchemaProps: spec.SchemaProps{ + Description: "Script defines the starlark script to transform the value", + Type: []string{"string"}, + Format: "", + }, + }, + "regex": { + SchemaProps: spec.SchemaProps{ + Description: "Regex defines the regex to transform the value", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"key", "path"}, + }, + }, + } +} + +func schema_config_server_apis_inv_v1alpha1_DiscoveryProfile(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "credentials": { + SchemaProps: spec.SchemaProps{ + Description: "Credentials defines the name of the secret that holds the credentials to connect to the target", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "tlsSecret": { + SchemaProps: spec.SchemaProps{ + Description: "TLSSecret defines the name of the TLS secret to connect to the target if mtls is used", + Type: []string{"string"}, + Format: "", + }, + }, + "connectionProfiles": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "ConnectionProfiles define the list of profiles the discovery controller uses to discover the target. The order in which they are specified is the order in which discovery is executed.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + }, + Required: []string{"credentials", "connectionProfiles"}, + }, + }, + } +} + +func schema_config_server_apis_inv_v1alpha1_DiscoveryRule(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "DiscoveryRule is the Schema for the DiscoveryRule API", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "metadata": { + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), + }, + }, + "spec": { + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryRuleSpec"), + }, + }, + "status": { + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryRuleStatus"), + }, + }, + }, + }, + }, + Dependencies: []string{ + "github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryRuleSpec", "github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryRuleStatus", metav1.ObjectMeta{}.OpenAPIModelName()}, + } +} + +func schema_config_server_apis_inv_v1alpha1_DiscoveryRuleAddress(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "address": { + SchemaProps: spec.SchemaProps{ + Description: "Address (specified as IP or DNS name) of the target/target(s)", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "hostName": { + SchemaProps: spec.SchemaProps{ + Description: "HostName of the ip prefix; used for /32 or /128 addresses with discovery disabled", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"address"}, + }, + }, + } +} + +func schema_config_server_apis_inv_v1alpha1_DiscoveryRuleList(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "DiscoveryRuleList contains a list of DiscoveryRules", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "metadata": { + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), + }, + }, + "items": { + SchemaProps: spec.SchemaProps{ + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryRule"), + }, + }, + }, + }, + }, + }, + Required: []string{"items"}, + }, + }, + Dependencies: []string{ + "github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryRule", metav1.ListMeta{}.OpenAPIModelName()}, + } +} + +func schema_config_server_apis_inv_v1alpha1_DiscoveryRulePrefix(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "prefix": { + SchemaProps: spec.SchemaProps{ + Description: "Prefix of the target/target(s)", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "excludes": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "IP Prefixes to be excluded", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + }, + Required: []string{"prefix"}, + }, + }, + } +} + +func schema_config_server_apis_inv_v1alpha1_DiscoveryRuleSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "DiscoveryRuleSpec defines the desired state of DiscoveryRule", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "prefixes": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "IP Prefixes for which this discovery rule applies", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryRulePrefix"), + }, + }, + }, + }, + }, + "addresses": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "IP Prefixes for which this discovery rule applies", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryRuleAddress"), + }, + }, + }, + }, + }, + "podSelector": { + SchemaProps: spec.SchemaProps{ + Description: "PodSelector defines the pod selector for which this discovery rule applies", + Ref: ref(metav1.LabelSelector{}.OpenAPIModelName()), + }, + }, + "serviceSelector": { + SchemaProps: spec.SchemaProps{ + Description: "ServiceSelector defines the service selector for which this discovery rule applies", + Ref: ref(metav1.LabelSelector{}.OpenAPIModelName()), + }, + }, + "serviceDomain": { + SchemaProps: spec.SchemaProps{ + Description: "ServiceDomain defines the service domain of the cluster, used by svc discovery to identify the domain name in the k8s cluster where the service reside.", + Type: []string{"string"}, + Format: "", + }, + }, + "defaultSchema": { + SchemaProps: spec.SchemaProps{ + Description: "DefaultSchema define the default schema used to connect to a target Indicates that discovery is disable; cannot be used for prefix based discovery rules", + Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.SchemaKey"), + }, + }, + "discoveryProfile": { + SchemaProps: spec.SchemaProps{ + Description: "DiscoveryProfile define the profiles the discovery controller uses to discover targets", + Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryProfile"), + }, + }, + "targetConnectionProfiles": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "TargetConnectionProfiles define the profile the discovery controller uses to create targets once discovered", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.TargetProfile"), + }, + }, + }, + }, + }, + "targetTemplate": { + SchemaProps: spec.SchemaProps{ + Description: "TargetTemplate defines the template the discovery controller uses to create the targets as a result of the discovery", + Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.TargetTemplate"), + }, + }, + "period": { + SchemaProps: spec.SchemaProps{ + Description: "Period defines the wait period between discovery rule runs", + Ref: ref(metav1.Duration{}.OpenAPIModelName()), + }, + }, + "concurrentScans": { + SchemaProps: spec.SchemaProps{ + Description: "number of concurrent IP scan", + Type: []string{"integer"}, + Format: "int64", + }, + }, + }, + Required: []string{"targetConnectionProfiles"}, + }, + }, + Dependencies: []string{ + "github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryProfile", "github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryRuleAddress", "github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryRulePrefix", "github.com/sdcio/config-server/apis/inv/v1alpha1.SchemaKey", "github.com/sdcio/config-server/apis/inv/v1alpha1.TargetProfile", "github.com/sdcio/config-server/apis/inv/v1alpha1.TargetTemplate", metav1.Duration{}.OpenAPIModelName(), metav1.LabelSelector{}.OpenAPIModelName()}, + } +} + +func schema_config_server_apis_inv_v1alpha1_DiscoveryRuleStatus(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "DiscoveryRuleStatus defines the observed state of DiscoveryRule", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "conditions": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-map-keys": []interface{}{ + "type", + }, + "x-kubernetes-list-type": "map", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "Conditions of the resource.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("github.com/sdcio/config-server/apis/condition/v1alpha1.Condition"), + }, + }, + }, + }, + }, + "startTime": { + SchemaProps: spec.SchemaProps{ + Description: "StartTime identifies when the dr got started", + Ref: ref(metav1.Time{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + Dependencies: []string{ + "github.com/sdcio/config-server/apis/condition/v1alpha1.Condition", metav1.Time{}.OpenAPIModelName()}, + } +} + +func schema_config_server_apis_inv_v1alpha1_DiscoveryVendorProfile(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "DiscoveryVendorProfile is the Schema for the DiscoveryVendorProfile API", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "metadata": { + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), + }, + }, + "spec": { + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryVendorProfileSpec"), + }, + }, + }, + }, + }, + Dependencies: []string{ + "github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryVendorProfileSpec", metav1.ObjectMeta{}.OpenAPIModelName()}, + } +} + +func schema_config_server_apis_inv_v1alpha1_DiscoveryVendorProfileList(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "DiscoveryVendorProfileList contains a list of DiscoveryVendorProfileList", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "metadata": { + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), + }, + }, + "items": { + SchemaProps: spec.SchemaProps{ + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryVendorProfile"), + }, + }, + }, + }, + }, + }, + Required: []string{"items"}, + }, + }, + Dependencies: []string{ + "github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryVendorProfile", metav1.ListMeta{}.OpenAPIModelName()}, + } +} + +func schema_config_server_apis_inv_v1alpha1_DiscoveryVendorProfileSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "DiscoveryProfileSpec defines the desired state of DiscoveryProfile", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "gnmi": { + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.GnmiDiscoveryVendorProfileParameters"), + }, + }, + }, + Required: []string{"gnmi"}, + }, + }, + Dependencies: []string{ + "github.com/sdcio/config-server/apis/inv/v1alpha1.GnmiDiscoveryVendorProfileParameters"}, + } +} + +func schema_config_server_apis_inv_v1alpha1_GnmiDiscoveryVendorProfileParameters(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "organization": { + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "modelMatch": { + SchemaProps: spec.SchemaProps{ + Type: []string{"string"}, + Format: "", + }, + }, + "paths": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "Paths DiscoveryPaths `json:\"paths\" protobuf:\"bytes,3,opt,name=paths\"`", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryPathDefinition"), + }, + }, + }, + }, + }, + "encoding": { + SchemaProps: spec.SchemaProps{ + Type: []string{"string"}, + Format: "", + }, + }, + "preserveNamespace": { + SchemaProps: spec.SchemaProps{ + Type: []string{"boolean"}, + Format: "", + }, + }, + }, + Required: []string{"organization", "paths"}, + }, + }, + Dependencies: []string{ + "github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryPathDefinition"}, + } +} + +func schema_config_server_apis_inv_v1alpha1_Proxy(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "url": { + SchemaProps: spec.SchemaProps{ + Description: "URL specifies the base URL of the HTTP/HTTPS proxy server.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "credentials": { + SchemaProps: spec.SchemaProps{ + Description: "Credentials defines the name of the secret that holds the credentials to connect to the proxy server", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"url", "credentials"}, + }, + }, + } +} + +func schema_config_server_apis_inv_v1alpha1_Repository(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "repoURL": { + SchemaProps: spec.SchemaProps{ + Description: "RepoURL specifies the base URL for a given repository", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "credentials": { + SchemaProps: spec.SchemaProps{ + Description: "Credentials defines the name of the secret that holds the credentials to connect to the repo", + Type: []string{"string"}, + Format: "", + }, + }, + "proxy": { + SchemaProps: spec.SchemaProps{ + Description: "Proxy defines the HTTP/HTTPS proxy to be used to connect to the repo.", + Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.Proxy"), + }, + }, + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind defines the that the BranchOrTag string is a repository branch or a tag", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "ref": { + SchemaProps: spec.SchemaProps{ + Description: "Ref defines the branch or tag of the repository corresponding to the provider schema version", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"repoURL", "kind", "ref"}, + }, + }, + Dependencies: []string{ + "github.com/sdcio/config-server/apis/inv/v1alpha1.Proxy"}, + } +} + +func schema_config_server_apis_inv_v1alpha1_Rollout(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "Rollout is the Rollout for the Rollout API", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "metadata": { + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), + }, + }, + "spec": { + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.RolloutSpec"), + }, + }, + "status": { + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.RolloutStatus"), + }, + }, + }, + }, + }, + Dependencies: []string{ + "github.com/sdcio/config-server/apis/inv/v1alpha1.RolloutSpec", "github.com/sdcio/config-server/apis/inv/v1alpha1.RolloutStatus", metav1.ObjectMeta{}.OpenAPIModelName()}, + } +} + +func schema_config_server_apis_inv_v1alpha1_RolloutList(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "RolloutList contains a list of Rollouts", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "metadata": { + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), + }, + }, + "items": { + SchemaProps: spec.SchemaProps{ + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.Rollout"), + }, + }, + }, + }, + }, + }, + Required: []string{"items"}, + }, + }, + Dependencies: []string{ + "github.com/sdcio/config-server/apis/inv/v1alpha1.Rollout", metav1.ListMeta{}.OpenAPIModelName()}, + } +} + +func schema_config_server_apis_inv_v1alpha1_RolloutSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "RolloutSpec defines the desired state of Rollout", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "repoURL": { + SchemaProps: spec.SchemaProps{ + Description: "RepoURL specifies the base URL for a given repository", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "credentials": { + SchemaProps: spec.SchemaProps{ + Description: "Credentials defines the name of the secret that holds the credentials to connect to the repo", + Type: []string{"string"}, + Format: "", + }, + }, + "proxy": { + SchemaProps: spec.SchemaProps{ + Description: "Proxy defines the HTTP/HTTPS proxy to be used to connect to the repo.", + Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.Proxy"), + }, + }, + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind defines the that the BranchOrTag string is a repository branch or a tag", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "ref": { + SchemaProps: spec.SchemaProps{ + Description: "Ref defines the branch or tag of the repository corresponding to the provider schema version", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "strategy": { + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "skipUnavailableTarget": { + SchemaProps: spec.SchemaProps{ + Type: []string{"boolean"}, + Format: "", + }, + }, + }, + Required: []string{"repoURL", "kind", "ref", "strategy"}, + }, + }, + Dependencies: []string{ + "github.com/sdcio/config-server/apis/inv/v1alpha1.Proxy"}, + } +} + +func schema_config_server_apis_inv_v1alpha1_RolloutStatus(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "RolloutStatus defines the observed state of Rollout", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "conditions": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-map-keys": []interface{}{ + "type", + }, + "x-kubernetes-list-type": "map", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "Conditions of the resource.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("github.com/sdcio/config-server/apis/condition/v1alpha1.Condition"), + }, + }, + }, + }, + }, + "targets": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "Targets defines the status of the rollout on the respective target", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.RolloutTargetStatus"), + }, + }, + }, + }, + }, + }, + }, + }, + Dependencies: []string{ + "github.com/sdcio/config-server/apis/condition/v1alpha1.Condition", "github.com/sdcio/config-server/apis/inv/v1alpha1.RolloutTargetStatus"}, + } +} + +func schema_config_server_apis_inv_v1alpha1_RolloutTargetStatus(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "name": { + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "conditions": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-map-keys": []interface{}{ + "type", + }, + "x-kubernetes-list-type": "map", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "Conditions of the resource.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("github.com/sdcio/config-server/apis/condition/v1alpha1.Condition"), + }, + }, + }, + }, + }, + }, + Required: []string{"name"}, + }, + }, + Dependencies: []string{ + "github.com/sdcio/config-server/apis/condition/v1alpha1.Condition"}, + } +} + +func schema_config_server_apis_inv_v1alpha1_Schema(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "Schema is the Schema for the Schema API", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "metadata": { + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), + }, + }, + "spec": { + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.SchemaSpec"), + }, + }, + "status": { + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.SchemaStatus"), + }, + }, + }, + }, + }, + Dependencies: []string{ + "github.com/sdcio/config-server/apis/inv/v1alpha1.SchemaSpec", "github.com/sdcio/config-server/apis/inv/v1alpha1.SchemaStatus", metav1.ObjectMeta{}.OpenAPIModelName()}, + } +} + +func schema_config_server_apis_inv_v1alpha1_SchemaKey(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "provider": { + SchemaProps: spec.SchemaProps{ + Description: "Provider specifies the provider of the schema.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "version": { + SchemaProps: spec.SchemaProps{ + Description: "Version defines the version of the schema", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"provider", "version"}, + }, + }, + } +} + +func schema_config_server_apis_inv_v1alpha1_SchemaList(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "SchemaList contains a list of Schemas", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "metadata": { + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), + }, + }, + "items": { + SchemaProps: spec.SchemaProps{ + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.Schema"), + }, + }, + }, + }, + }, + }, + Required: []string{"items"}, + }, + }, + Dependencies: []string{ + "github.com/sdcio/config-server/apis/inv/v1alpha1.Schema", metav1.ListMeta{}.OpenAPIModelName()}, + } +} + +func schema_config_server_apis_inv_v1alpha1_SchemaRepositoryStatus(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "SchemaRepositoryStatus provides the observed hash of a repository", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "repoURL": { + SchemaProps: spec.SchemaProps{ + Description: "RepoURL defines URL of the repository", + Type: []string{"string"}, + Format: "", + }, + }, + "reference": { + SchemaProps: spec.SchemaProps{ + Description: "Reference indicating version of loaded repository", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + } +} + +func schema_config_server_apis_inv_v1alpha1_SchemaSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "SchemaSpec defines the desired state of Schema", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "provider": { + SchemaProps: spec.SchemaProps{ + Description: "Provider specifies the provider of the schema.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "version": { + SchemaProps: spec.SchemaProps{ + Description: "Version defines the version of the schema", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "repositories": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "Repositories define the repositories used for building the provider schema", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.SchemaSpecRepository"), + }, + }, + }, + }, + }, + }, + Required: []string{"provider", "version", "repositories"}, + }, + }, + Dependencies: []string{ + "github.com/sdcio/config-server/apis/inv/v1alpha1.SchemaSpecRepository"}, + } +} + +func schema_config_server_apis_inv_v1alpha1_SchemaSpecRepository(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "repoURL": { + SchemaProps: spec.SchemaProps{ + Description: "RepoURL specifies the base URL for a given repository", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "credentials": { + SchemaProps: spec.SchemaProps{ + Description: "Credentials defines the name of the secret that holds the credentials to connect to the repo", + Type: []string{"string"}, + Format: "", + }, + }, + "proxy": { + SchemaProps: spec.SchemaProps{ + Description: "Proxy defines the HTTP/HTTPS proxy to be used to connect to the repo.", + Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.Proxy"), + }, + }, + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind defines the that the BranchOrTag string is a repository branch or a tag", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "ref": { + SchemaProps: spec.SchemaProps{ + Description: "Ref defines the branch or tag of the repository corresponding to the provider schema version", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "dirs": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "Dirs defines the list of directories that identified the provider schema in src/dst pairs relative within the repository", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.SrcDstPath"), + }, + }, + }, + }, + }, + "schema": { + SchemaProps: spec.SchemaProps{ + Description: "Schema provides the details of which files must be used for the models and which files/directories cana be excludes", + Default: map[string]interface{}{}, + Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.SchemaSpecSchema"), + }, + }, + }, + Required: []string{"repoURL", "kind", "ref", "schema"}, + }, + }, + Dependencies: []string{ + "github.com/sdcio/config-server/apis/inv/v1alpha1.Proxy", "github.com/sdcio/config-server/apis/inv/v1alpha1.SchemaSpecSchema", "github.com/sdcio/config-server/apis/inv/v1alpha1.SrcDstPath"}, + } +} + +func schema_config_server_apis_inv_v1alpha1_SchemaSpecSchema(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "models": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "Models defines the list of files/directories to be used as a model", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + "includes": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "Excludes defines the list of files/directories to be excluded", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + "excludes": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "Excludes defines the list of files/directories to be excluded", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + }, + }, + }, + } +} + +func schema_config_server_apis_inv_v1alpha1_SchemaStatus(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "SchemaStatus defines the observed state of Schema", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "conditions": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-map-keys": []interface{}{ + "type", + }, + "x-kubernetes-list-type": "map", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "Conditions of the resource.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("github.com/sdcio/config-server/apis/condition/v1alpha1.Condition"), + }, + }, + }, + }, + }, + "repositories": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "SchemaRepositoryStatus provides the array of repositories", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.SchemaRepositoryStatus"), + }, + }, + }, + }, + }, + }, + }, + }, + Dependencies: []string{ + "github.com/sdcio/config-server/apis/condition/v1alpha1.Condition", "github.com/sdcio/config-server/apis/inv/v1alpha1.SchemaRepositoryStatus"}, + } +} + +func schema_config_server_apis_inv_v1alpha1_SrcDstPath(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "SrcDstPath provide a src/dst pair for the loader to download the schema from a specific src in the repository to a given destination in the schema server", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "src": { + SchemaProps: spec.SchemaProps{ + Description: "Src is the relative directory in the repository URL", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "dst": { + SchemaProps: spec.SchemaProps{ + Description: "Dst is the relative directory in the schema server", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"src", "dst"}, + }, + }, + } +} + +func schema_config_server_apis_inv_v1alpha1_Subscription(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "Subscription is the Schema for the Subscription API", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "metadata": { + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), + }, + }, + "spec": { + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.SubscriptionSpec"), + }, + }, + "status": { + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.SubscriptionStatus"), + }, + }, + }, + }, + }, + Dependencies: []string{ + "github.com/sdcio/config-server/apis/inv/v1alpha1.SubscriptionSpec", "github.com/sdcio/config-server/apis/inv/v1alpha1.SubscriptionStatus", metav1.ObjectMeta{}.OpenAPIModelName()}, + } +} + +func schema_config_server_apis_inv_v1alpha1_SubscriptionList(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "SubscriptionList contains a list of Subscriptions", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "metadata": { + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), + }, + }, + "items": { + SchemaProps: spec.SchemaProps{ + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.Subscription"), + }, + }, + }, + }, + }, + }, + Required: []string{"items"}, + }, + }, + Dependencies: []string{ + "github.com/sdcio/config-server/apis/inv/v1alpha1.Subscription", metav1.ListMeta{}.OpenAPIModelName()}, + } +} + +func schema_config_server_apis_inv_v1alpha1_SubscriptionParameters(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "SubscriptionSync defines the desired Subscription of SubscriptionSync", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "name": { + SchemaProps: spec.SchemaProps{ + Description: "Name defines the name of the group of the Subscription to be collected", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "description": { + SchemaProps: spec.SchemaProps{ + Description: "Description details what the Subscription collection is about", + Type: []string{"string"}, + Format: "", + }, + }, + "labels": { + SchemaProps: spec.SchemaProps{ + Description: "Labels can be defined as user defined data to provide extra context", + Type: []string{"object"}, + AdditionalProperties: &spec.SchemaOrBool{ + Allows: true, + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + "adminState": { + SchemaProps: spec.SchemaProps{ + Description: "AdminState allows to disable the subscription", + Type: []string{"string"}, + Format: "", + }, + }, + "mode": { + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "interval": { + SchemaProps: spec.SchemaProps{ + Ref: ref(metav1.Duration{}.OpenAPIModelName()), + }, + }, + "paths": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + }, + Required: []string{"name", "mode", "paths"}, + }, + }, + Dependencies: []string{ + metav1.Duration{}.OpenAPIModelName()}, + } +} + +func schema_config_server_apis_inv_v1alpha1_SubscriptionSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "SubscriptionSpec defines the desired Subscription of Subscription", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "target": { + SchemaProps: spec.SchemaProps{ + Description: "Targets defines the targets on which this Subscription applies", + Default: map[string]interface{}{}, + Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.SubscriptionTarget"), + }, + }, + "protocol": { + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "port": { + SchemaProps: spec.SchemaProps{ + Description: "Port defines the port on which the scan runs", + Default: 0, + Type: []string{"integer"}, + Format: "int64", + }, + }, + "encoding": { + SchemaProps: spec.SchemaProps{ + Type: []string{"string"}, + Format: "", + }, + }, + "subscriptions": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.SubscriptionParameters"), + }, + }, + }, + }, + }, + }, + Required: []string{"target", "protocol", "port", "subscriptions"}, + }, + }, + Dependencies: []string{ + "github.com/sdcio/config-server/apis/inv/v1alpha1.SubscriptionParameters", "github.com/sdcio/config-server/apis/inv/v1alpha1.SubscriptionTarget"}, + } +} + +func schema_config_server_apis_inv_v1alpha1_SubscriptionStatus(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "conditions": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-map-keys": []interface{}{ + "type", + }, + "x-kubernetes-list-type": "map", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "Conditions of the resource.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("github.com/sdcio/config-server/apis/condition/v1alpha1.Condition"), + }, + }, + }, + }, + }, + "targets": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "Targets defines the list of targets this resource applies to", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + }, + }, + }, + Dependencies: []string{ + "github.com/sdcio/config-server/apis/condition/v1alpha1.Condition"}, + } +} + +func schema_config_server_apis_inv_v1alpha1_SubscriptionTarget(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "targetSelector": { + SchemaProps: spec.SchemaProps{ + Description: "TargetSelector defines the selector used to select the targets to which the config applies", + Ref: ref(metav1.LabelSelector{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + Dependencies: []string{ + metav1.LabelSelector{}.OpenAPIModelName()}, + } +} + +func schema_config_server_apis_inv_v1alpha1_Target(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "Target is the Schema for the Target API", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "metadata": { + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), + }, + }, + "spec": { + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.TargetSpec"), + }, + }, + "status": { + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.TargetStatus"), + }, + }, + }, + }, + }, + Dependencies: []string{ + "github.com/sdcio/config-server/apis/inv/v1alpha1.TargetSpec", "github.com/sdcio/config-server/apis/inv/v1alpha1.TargetStatus", metav1.ObjectMeta{}.OpenAPIModelName()}, + } +} + +func schema_config_server_apis_inv_v1alpha1_TargetConnectionProfile(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "TargetConnectionProfile is the Schema for the TargetConnectionProfile API", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "metadata": { + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), + }, + }, + "spec": { + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.TargetConnectionProfileSpec"), + }, + }, + }, + }, + }, + Dependencies: []string{ + "github.com/sdcio/config-server/apis/inv/v1alpha1.TargetConnectionProfileSpec", metav1.ObjectMeta{}.OpenAPIModelName()}, + } +} + +func schema_config_server_apis_inv_v1alpha1_TargetConnectionProfileList(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "TargetConnectionProfileList contains a list of TargetConnectionProfile", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "metadata": { + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), + }, + }, + "items": { + SchemaProps: spec.SchemaProps{ + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.TargetConnectionProfile"), + }, + }, + }, + }, + }, + }, + Required: []string{"items"}, + }, + }, + Dependencies: []string{ + "github.com/sdcio/config-server/apis/inv/v1alpha1.TargetConnectionProfile", metav1.ListMeta{}.OpenAPIModelName()}, + } +} + +func schema_config_server_apis_inv_v1alpha1_TargetConnectionProfileSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "TargetConnectionProfileSpec defines the desired state of TargetConnectionProfile", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "connectRetry": { + SchemaProps: spec.SchemaProps{ + Ref: ref(metav1.Duration{}.OpenAPIModelName()), + }, + }, + "timeout": { + SchemaProps: spec.SchemaProps{ + Ref: ref(metav1.Duration{}.OpenAPIModelName()), + }, + }, + "protocol": { + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "port": { + SchemaProps: spec.SchemaProps{ + Description: "Port defines the port on which the scan runs", + Default: 0, + Type: []string{"integer"}, + Format: "int64", + }, + }, + "encoding": { + SchemaProps: spec.SchemaProps{ + Type: []string{"string"}, + Format: "", + }, + }, + "preferredNetconfVersion": { + SchemaProps: spec.SchemaProps{ + Type: []string{"string"}, + Format: "", + }, + }, + "insecure": { + SchemaProps: spec.SchemaProps{ + Type: []string{"boolean"}, + Format: "", + }, + }, + "skipVerify": { + SchemaProps: spec.SchemaProps{ + Type: []string{"boolean"}, + Format: "", + }, + }, + "includeNS": { + SchemaProps: spec.SchemaProps{ + Type: []string{"boolean"}, + Format: "", + }, + }, + "operationWithNS": { + SchemaProps: spec.SchemaProps{ + Type: []string{"boolean"}, + Format: "", + }, + }, + "useOperationRemove": { + SchemaProps: spec.SchemaProps{ + Type: []string{"boolean"}, + Format: "", + }, + }, + "commitCandidate": { + SchemaProps: spec.SchemaProps{ + Type: []string{"string"}, + Format: "", + }, + }, + "targetName": { + SchemaProps: spec.SchemaProps{ + Description: "TargetName specifies the target field value in gNMI Path prefix Examples: \"OC-YANG\" (SONiC), \"openconfig\" (some vendors), or empty", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"protocol", "port"}, + }, + }, + Dependencies: []string{ + metav1.Duration{}.OpenAPIModelName()}, + } +} + +func schema_config_server_apis_inv_v1alpha1_TargetList(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "TargetList contains a list of Targets", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "metadata": { + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), + }, + }, + "items": { + SchemaProps: spec.SchemaProps{ + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.Target"), + }, + }, + }, + }, + }, + }, + Required: []string{"items"}, + }, + }, + Dependencies: []string{ + "github.com/sdcio/config-server/apis/inv/v1alpha1.Target", metav1.ListMeta{}.OpenAPIModelName()}, + } +} + +func schema_config_server_apis_inv_v1alpha1_TargetProfile(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "credentials": { + SchemaProps: spec.SchemaProps{ + Description: "Credentials defines the name of the secret that holds the credentials to connect to the target", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "tlsSecret": { + SchemaProps: spec.SchemaProps{ + Description: "TLSSecret defines the name of the TLS secret to connect to the target if mtls is used", + Type: []string{"string"}, + Format: "", + }, + }, + "connectionProfile": { + SchemaProps: spec.SchemaProps{ + Description: "ConnectionProfile define the profile used to connect to the target once discovered", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "syncProfile": { + SchemaProps: spec.SchemaProps{ + Description: "SyncProfile define the profile used to sync to the target config once discovered", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"credentials", "connectionProfile"}, + }, + }, + } +} + +func schema_config_server_apis_inv_v1alpha1_TargetSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "TargetSpec defines the desired state of Target", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "provider": { + SchemaProps: spec.SchemaProps{ + Description: "Provider specifies the provider using this target.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "address": { + SchemaProps: spec.SchemaProps{ + Description: "Address defines the address to connect to the target", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "credentials": { + SchemaProps: spec.SchemaProps{ + Description: "Credentials defines the name of the secret that holds the credentials to connect to the target", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "tlsSecret": { + SchemaProps: spec.SchemaProps{ + Description: "TLSSecret defines the name of the TLS secret to connect to the target if mtls is used", + Type: []string{"string"}, + Format: "", + }, + }, + "connectionProfile": { + SchemaProps: spec.SchemaProps{ + Description: "ConnectionProfile define the profile used to connect to the target once discovered", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "syncProfile": { + SchemaProps: spec.SchemaProps{ + Description: "SyncProfile define the profile used to sync to the target config once discovered", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"provider", "address", "credentials", "connectionProfile"}, + }, + }, + } +} + +func schema_config_server_apis_inv_v1alpha1_TargetStatus(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "TargetStatus defines the observed state of Target", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "conditions": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-map-keys": []interface{}{ + "type", + }, + "x-kubernetes-list-type": "map", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "Conditions of the resource.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("github.com/sdcio/config-server/apis/condition/v1alpha1.Condition"), + }, + }, + }, + }, + }, + "discoveryInfo": { + SchemaProps: spec.SchemaProps{ + Description: "Discovery info defines the information retrieved during discovery", + Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryInfo"), + }, + }, + "usedReferences": { + SchemaProps: spec.SchemaProps{ + Description: "UsedReferences track the resource used to reconcile the cr", + Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.TargetStatusUsedReferences"), + }, + }, + }, + }, + }, + Dependencies: []string{ + "github.com/sdcio/config-server/apis/condition/v1alpha1.Condition", "github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryInfo", "github.com/sdcio/config-server/apis/inv/v1alpha1.TargetStatusUsedReferences"}, + } +} + +func schema_config_server_apis_inv_v1alpha1_TargetStatusUsedReferences(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "secretResourceVersion": { + SchemaProps: spec.SchemaProps{ + Type: []string{"string"}, + Format: "", + }, + }, + "tlsSecretResourceVersion": { + SchemaProps: spec.SchemaProps{ + Type: []string{"string"}, + Format: "", + }, + }, + "connectionProfileResourceVersion": { + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "syncProfileResourceVersion": { + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"connectionProfileResourceVersion", "syncProfileResourceVersion"}, + }, + }, + } +} + +func schema_config_server_apis_inv_v1alpha1_TargetSyncProfile(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "TargetSyncProfile is the Schema for the TargetSyncProfile API", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "metadata": { + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), + }, + }, + "spec": { + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.TargetSyncProfileSpec"), + }, + }, + }, + }, + }, + Dependencies: []string{ + "github.com/sdcio/config-server/apis/inv/v1alpha1.TargetSyncProfileSpec", metav1.ObjectMeta{}.OpenAPIModelName()}, + } +} + +func schema_config_server_apis_inv_v1alpha1_TargetSyncProfileList(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "TargetSyncProfileList contains a list of TargetSyncProfiles", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "metadata": { + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), + }, + }, + "items": { + SchemaProps: spec.SchemaProps{ + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.TargetSyncProfile"), + }, + }, + }, + }, + }, + }, + Required: []string{"items"}, + }, + }, + Dependencies: []string{ + "github.com/sdcio/config-server/apis/inv/v1alpha1.TargetSyncProfile", metav1.ListMeta{}.OpenAPIModelName()}, + } +} + +func schema_config_server_apis_inv_v1alpha1_TargetSyncProfileSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "TargetSyncProfileSpec defines the desired state of TargetSyncProfile", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "validate": { + SchemaProps: spec.SchemaProps{ + Type: []string{"boolean"}, + Format: "", + }, + }, + "buffer": { + SchemaProps: spec.SchemaProps{ + Type: []string{"integer"}, + Format: "int64", + }, + }, + "workers": { + SchemaProps: spec.SchemaProps{ + Type: []string{"integer"}, + Format: "int64", + }, + }, + "sync": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.TargetSyncProfileSync"), + }, + }, + }, + }, + }, + }, + Required: []string{"sync"}, + }, + }, + Dependencies: []string{ + "github.com/sdcio/config-server/apis/inv/v1alpha1.TargetSyncProfileSync"}, + } +} + +func schema_config_server_apis_inv_v1alpha1_TargetSyncProfileSync(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "TargetSyncProfileSync defines the desired state of TargetSyncProfileSync", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "name": { + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "protocol": { + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "port": { + SchemaProps: spec.SchemaProps{ + Description: "Port defines the port on which the scan runs", + Default: 0, + Type: []string{"integer"}, + Format: "int64", + }, + }, + "paths": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + "mode": { + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "encoding": { + SchemaProps: spec.SchemaProps{ + Type: []string{"string"}, + Format: "", + }, + }, + "interval": { + SchemaProps: spec.SchemaProps{ + Ref: ref(metav1.Duration{}.OpenAPIModelName()), + }, + }, + }, + Required: []string{"name", "protocol", "port", "paths", "mode"}, + }, + }, + Dependencies: []string{ + metav1.Duration{}.OpenAPIModelName()}, + } +} + +func schema_config_server_apis_inv_v1alpha1_TargetTemplate(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "TargetTemplate defines the template of the target", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "nameTemplate": { + SchemaProps: spec.SchemaProps{ + Description: "target name template", + Type: []string{"string"}, + Format: "", + }, + }, + "annotations": { + SchemaProps: spec.SchemaProps{ + Description: "Annotations is a key value map to be copied to the target CR.", + Type: []string{"object"}, + AdditionalProperties: &spec.SchemaOrBool{ + Allows: true, + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + "labels": { + SchemaProps: spec.SchemaProps{ + Description: "Labels is a key value map to be copied to the target CR.", + Type: []string{"object"}, + AdditionalProperties: &spec.SchemaOrBool{ + Allows: true, + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + }, + }, + }, + } +} + +func schema_config_server_apis_inv_v1alpha1_Workspace(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "Workspace is the Workspace for the Workspace API", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "metadata": { + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), + }, + }, + "spec": { + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.WorkspaceSpec"), + }, + }, + "status": { + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.WorkspaceStatus"), + }, + }, + }, + }, + }, + Dependencies: []string{ + "github.com/sdcio/config-server/apis/inv/v1alpha1.WorkspaceSpec", "github.com/sdcio/config-server/apis/inv/v1alpha1.WorkspaceStatus", metav1.ObjectMeta{}.OpenAPIModelName()}, + } +} + +func schema_config_server_apis_inv_v1alpha1_WorkspaceList(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "WorkspaceList contains a list of Workspaces", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "metadata": { + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), + }, + }, + "items": { + SchemaProps: spec.SchemaProps{ + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.Workspace"), + }, + }, + }, + }, + }, + }, + Required: []string{"items"}, + }, + }, + Dependencies: []string{ + "github.com/sdcio/config-server/apis/inv/v1alpha1.Workspace", metav1.ListMeta{}.OpenAPIModelName()}, + } +} + +func schema_config_server_apis_inv_v1alpha1_WorkspaceSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "WorkspaceSpec defines the desired state of Workspace", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "repoURL": { + SchemaProps: spec.SchemaProps{ + Description: "RepoURL specifies the base URL for a given repository", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "credentials": { + SchemaProps: spec.SchemaProps{ + Description: "Credentials defines the name of the secret that holds the credentials to connect to the repo", + Type: []string{"string"}, + Format: "", + }, + }, + "proxy": { + SchemaProps: spec.SchemaProps{ + Description: "Proxy defines the HTTP/HTTPS proxy to be used to connect to the repo.", + Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.Proxy"), + }, + }, + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind defines the that the BranchOrTag string is a repository branch or a tag", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "ref": { + SchemaProps: spec.SchemaProps{ + Description: "Ref defines the branch or tag of the repository corresponding to the provider schema version", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"repoURL", "kind", "ref"}, + }, + }, + Dependencies: []string{ + "github.com/sdcio/config-server/apis/inv/v1alpha1.Proxy"}, + } +} + +func schema_config_server_apis_inv_v1alpha1_WorkspaceStatus(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "WorkspaceStatus defines the observed state of Workspace", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "conditions": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-map-keys": []interface{}{ + "type", + }, + "x-kubernetes-list-type": "map", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "Conditions of the resource.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("github.com/sdcio/config-server/apis/condition/v1alpha1.Condition"), + }, + }, + }, + }, + }, + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind defines the that the BranchOrTag string is a repository branch or a tag", + Type: []string{"string"}, + Format: "", + }, + }, + "deployedRef": { + SchemaProps: spec.SchemaProps{ + Description: "DeployedRef is the reference that is deployed", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + Dependencies: []string{ + "github.com/sdcio/config-server/apis/condition/v1alpha1.Condition"}, + } +} + +func schema_k8sio_api_core_v1_AWSElasticBlockStoreVolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "Represents a Persistent Disk resource in AWS.\n\nAn AWS EBS disk must exist before mounting to a container. The disk must also be in the same AWS zone as the kubelet. An AWS EBS disk can only be mounted as read/write once. AWS EBS volumes support ownership management and SELinux relabeling.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "volumeID": { + SchemaProps: spec.SchemaProps{ + Description: "volumeID is unique ID of the persistent disk resource in AWS (Amazon EBS volume). More info: https://kubernetes.io/docs/concepts/storage/volumes#awselasticblockstore", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "fsType": { + SchemaProps: spec.SchemaProps{ + Description: "fsType is the filesystem type of the volume that you want to mount. Tip: Ensure that the filesystem type is supported by the host operating system. Examples: \"ext4\", \"xfs\", \"ntfs\". Implicitly inferred to be \"ext4\" if unspecified. More info: https://kubernetes.io/docs/concepts/storage/volumes#awselasticblockstore", + Type: []string{"string"}, + Format: "", + }, + }, + "partition": { + SchemaProps: spec.SchemaProps{ + Description: "partition is the partition in the volume that you want to mount. If omitted, the default is to mount by volume name. Examples: For volume /dev/sda1, you specify the partition as \"1\". Similarly, the volume partition for /dev/sda is \"0\" (or you can leave the property empty).", + Type: []string{"integer"}, + Format: "int32", + }, + }, + "readOnly": { + SchemaProps: spec.SchemaProps{ + Description: "readOnly value true will force the readOnly setting in VolumeMounts. More info: https://kubernetes.io/docs/concepts/storage/volumes#awselasticblockstore", + Type: []string{"boolean"}, + Format: "", + }, + }, + }, + Required: []string{"volumeID"}, + }, + }, + } +} + +func schema_k8sio_api_core_v1_Affinity(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "Affinity is a group of affinity scheduling rules.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "nodeAffinity": { + SchemaProps: spec.SchemaProps{ + Description: "Describes node affinity scheduling rules for the pod.", + Ref: ref(v1.NodeAffinity{}.OpenAPIModelName()), + }, + }, + "podAffinity": { + SchemaProps: spec.SchemaProps{ + Description: "Describes pod affinity scheduling rules (e.g. co-locate this pod in the same node, zone, etc. as some other pod(s)).", + Ref: ref(v1.PodAffinity{}.OpenAPIModelName()), + }, + }, + "podAntiAffinity": { + SchemaProps: spec.SchemaProps{ + Description: "Describes pod anti-affinity scheduling rules (e.g. avoid putting this pod in the same node, zone, etc. as some other pod(s)).", + Ref: ref(v1.PodAntiAffinity{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + Dependencies: []string{ + v1.NodeAffinity{}.OpenAPIModelName(), v1.PodAffinity{}.OpenAPIModelName(), v1.PodAntiAffinity{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_AppArmorProfile(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "AppArmorProfile defines a pod or container's AppArmor settings.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "type": { + SchemaProps: spec.SchemaProps{ + Description: "type indicates which kind of AppArmor profile will be applied. Valid options are:\n Localhost - a profile pre-loaded on the node.\n RuntimeDefault - the container runtime's default profile.\n Unconfined - no AppArmor enforcement.\n\nPossible enum values:\n - `\"Localhost\"` indicates that a profile pre-loaded on the node should be used.\n - `\"RuntimeDefault\"` indicates that the container runtime's default AppArmor profile should be used.\n - `\"Unconfined\"` indicates that no AppArmor profile should be enforced.", + Default: "", + Type: []string{"string"}, + Format: "", + Enum: []interface{}{"Localhost", "RuntimeDefault", "Unconfined"}, + }, + }, + "localhostProfile": { + SchemaProps: spec.SchemaProps{ + Description: "localhostProfile indicates a profile loaded on the node that should be used. The profile must be preconfigured on the node to work. Must match the loaded name of the profile. Must be set if and only if type is \"Localhost\".", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"type"}, + }, + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-unions": []interface{}{ + map[string]interface{}{ + "discriminator": "type", + "fields-to-discriminateBy": map[string]interface{}{ + "localhostProfile": "LocalhostProfile", + }, + }, + }, + }, + }, + }, + } +} + +func schema_k8sio_api_core_v1_AttachedVolume(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "AttachedVolume describes a volume attached to a node", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "name": { + SchemaProps: spec.SchemaProps{ + Description: "Name of the attached volume", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "devicePath": { + SchemaProps: spec.SchemaProps{ + Description: "DevicePath represents the device path where the volume should be available", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"name", "devicePath"}, + }, + }, + } +} + +func schema_k8sio_api_core_v1_AvoidPods(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "AvoidPods describes pods that should avoid this node. This is the value for a Node annotation with key scheduler.alpha.kubernetes.io/preferAvoidPods and will eventually become a field of NodeStatus.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "preferAvoidPods": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "Bounded-sized list of signatures of pods that should avoid this node, sorted in timestamp order from oldest to newest. Size of the slice is unspecified.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.PreferAvoidPodsEntry{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + }, + }, + }, + Dependencies: []string{ + v1.PreferAvoidPodsEntry{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_AzureDiskVolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "AzureDisk represents an Azure Data Disk mount on the host and bind mount to the pod.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "diskName": { + SchemaProps: spec.SchemaProps{ + Description: "diskName is the Name of the data disk in the blob storage", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "diskURI": { + SchemaProps: spec.SchemaProps{ + Description: "diskURI is the URI of data disk in the blob storage", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "cachingMode": { + SchemaProps: spec.SchemaProps{ + Description: "cachingMode is the Host Caching mode: None, Read Only, Read Write.\n\nPossible enum values:\n - `\"None\"`\n - `\"ReadOnly\"`\n - `\"ReadWrite\"`", + Default: v1.AzureDataDiskCachingReadWrite, + Type: []string{"string"}, + Format: "", + Enum: []interface{}{"None", "ReadOnly", "ReadWrite"}, + }, + }, + "fsType": { + SchemaProps: spec.SchemaProps{ + Description: "fsType is Filesystem type to mount. Must be a filesystem type supported by the host operating system. Ex. \"ext4\", \"xfs\", \"ntfs\". Implicitly inferred to be \"ext4\" if unspecified.", + Default: "ext4", + Type: []string{"string"}, + Format: "", + }, + }, + "readOnly": { + SchemaProps: spec.SchemaProps{ + Description: "readOnly Defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts.", + Default: false, + Type: []string{"boolean"}, + Format: "", + }, + }, + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "kind expected values are Shared: multiple blob disks per storage account Dedicated: single blob disk per storage account Managed: azure managed data disk (only in managed availability set). defaults to shared\n\nPossible enum values:\n - `\"Dedicated\"`\n - `\"Managed\"`\n - `\"Shared\"`", + Default: v1.AzureSharedBlobDisk, + Type: []string{"string"}, + Format: "", + Enum: []interface{}{"Dedicated", "Managed", "Shared"}, + }, + }, + }, + Required: []string{"diskName", "diskURI"}, + }, + }, + } +} + +func schema_k8sio_api_core_v1_AzureFilePersistentVolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "AzureFile represents an Azure File Service mount on the host and bind mount to the pod.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "secretName": { + SchemaProps: spec.SchemaProps{ + Description: "secretName is the name of secret that contains Azure Storage Account Name and Key", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "shareName": { + SchemaProps: spec.SchemaProps{ + Description: "shareName is the azure Share Name", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "readOnly": { + SchemaProps: spec.SchemaProps{ + Description: "readOnly defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts.", + Type: []string{"boolean"}, + Format: "", + }, + }, + "secretNamespace": { + SchemaProps: spec.SchemaProps{ + Description: "secretNamespace is the namespace of the secret that contains Azure Storage Account Name and Key default is the same as the Pod", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"secretName", "shareName"}, + }, + }, + } +} + +func schema_k8sio_api_core_v1_AzureFileVolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "AzureFile represents an Azure File Service mount on the host and bind mount to the pod.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "secretName": { + SchemaProps: spec.SchemaProps{ + Description: "secretName is the name of secret that contains Azure Storage Account Name and Key", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "shareName": { + SchemaProps: spec.SchemaProps{ + Description: "shareName is the azure share Name", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "readOnly": { + SchemaProps: spec.SchemaProps{ + Description: "readOnly defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts.", + Type: []string{"boolean"}, + Format: "", + }, + }, + }, + Required: []string{"secretName", "shareName"}, + }, + }, + } +} + +func schema_k8sio_api_core_v1_Binding(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "Binding ties one object to another; for example, a pod is bound to a node by a scheduler.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "metadata": { + SchemaProps: spec.SchemaProps{ + Description: "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata", + Default: map[string]interface{}{}, + Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), + }, + }, + "target": { + SchemaProps: spec.SchemaProps{ + Description: "The target object that you want to bind to the standard object.", + Default: map[string]interface{}{}, + Ref: ref(v1.ObjectReference{}.OpenAPIModelName()), + }, + }, + }, + Required: []string{"target"}, + }, + }, + Dependencies: []string{ + v1.ObjectReference{}.OpenAPIModelName(), metav1.ObjectMeta{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_CSIPersistentVolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "Represents storage that is managed by an external CSI volume driver", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "driver": { + SchemaProps: spec.SchemaProps{ + Description: "driver is the name of the driver to use for this volume. Required.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "volumeHandle": { + SchemaProps: spec.SchemaProps{ + Description: "volumeHandle is the unique volume name returned by the CSI volume plugin’s CreateVolume to refer to the volume on all subsequent calls. Required.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "readOnly": { + SchemaProps: spec.SchemaProps{ + Description: "readOnly value to pass to ControllerPublishVolumeRequest. Defaults to false (read/write).", + Type: []string{"boolean"}, + Format: "", + }, + }, + "fsType": { + SchemaProps: spec.SchemaProps{ + Description: "fsType to mount. Must be a filesystem type supported by the host operating system. Ex. \"ext4\", \"xfs\", \"ntfs\".", + Type: []string{"string"}, + Format: "", + }, + }, + "volumeAttributes": { + SchemaProps: spec.SchemaProps{ + Description: "volumeAttributes of the volume to publish.", + Type: []string{"object"}, + AdditionalProperties: &spec.SchemaOrBool{ + Allows: true, + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + "controllerPublishSecretRef": { + SchemaProps: spec.SchemaProps{ + Description: "controllerPublishSecretRef is a reference to the secret object containing sensitive information to pass to the CSI driver to complete the CSI ControllerPublishVolume and ControllerUnpublishVolume calls. This field is optional, and may be empty if no secret is required. If the secret object contains more than one secret, all secrets are passed.", + Ref: ref(v1.SecretReference{}.OpenAPIModelName()), + }, + }, + "nodeStageSecretRef": { + SchemaProps: spec.SchemaProps{ + Description: "nodeStageSecretRef is a reference to the secret object containing sensitive information to pass to the CSI driver to complete the CSI NodeStageVolume and NodeStageVolume and NodeUnstageVolume calls. This field is optional, and may be empty if no secret is required. If the secret object contains more than one secret, all secrets are passed.", + Ref: ref(v1.SecretReference{}.OpenAPIModelName()), + }, + }, + "nodePublishSecretRef": { + SchemaProps: spec.SchemaProps{ + Description: "nodePublishSecretRef is a reference to the secret object containing sensitive information to pass to the CSI driver to complete the CSI NodePublishVolume and NodeUnpublishVolume calls. This field is optional, and may be empty if no secret is required. If the secret object contains more than one secret, all secrets are passed.", + Ref: ref(v1.SecretReference{}.OpenAPIModelName()), + }, + }, + "controllerExpandSecretRef": { + SchemaProps: spec.SchemaProps{ + Description: "controllerExpandSecretRef is a reference to the secret object containing sensitive information to pass to the CSI driver to complete the CSI ControllerExpandVolume call. This field is optional, and may be empty if no secret is required. If the secret object contains more than one secret, all secrets are passed.", + Ref: ref(v1.SecretReference{}.OpenAPIModelName()), + }, + }, + "nodeExpandSecretRef": { + SchemaProps: spec.SchemaProps{ + Description: "nodeExpandSecretRef is a reference to the secret object containing sensitive information to pass to the CSI driver to complete the CSI NodeExpandVolume call. This field is optional, may be omitted if no secret is required. If the secret object contains more than one secret, all secrets are passed.", + Ref: ref(v1.SecretReference{}.OpenAPIModelName()), + }, + }, + }, + Required: []string{"driver", "volumeHandle"}, + }, + }, + Dependencies: []string{ + v1.SecretReference{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_CSIVolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "Represents a source location of a volume to mount, managed by an external CSI driver", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "driver": { + SchemaProps: spec.SchemaProps{ + Description: "driver is the name of the CSI driver that handles this volume. Consult with your admin for the correct name as registered in the cluster.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "readOnly": { + SchemaProps: spec.SchemaProps{ + Description: "readOnly specifies a read-only configuration for the volume. Defaults to false (read/write).", + Type: []string{"boolean"}, + Format: "", + }, + }, + "fsType": { + SchemaProps: spec.SchemaProps{ + Description: "fsType to mount. Ex. \"ext4\", \"xfs\", \"ntfs\". If not provided, the empty value is passed to the associated CSI driver which will determine the default filesystem to apply.", + Type: []string{"string"}, + Format: "", + }, + }, + "volumeAttributes": { + SchemaProps: spec.SchemaProps{ + Description: "volumeAttributes stores driver-specific properties that are passed to the CSI driver. Consult your driver's documentation for supported values.", + Type: []string{"object"}, + AdditionalProperties: &spec.SchemaOrBool{ + Allows: true, + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + "nodePublishSecretRef": { + SchemaProps: spec.SchemaProps{ + Description: "nodePublishSecretRef is a reference to the secret object containing sensitive information to pass to the CSI driver to complete the CSI NodePublishVolume and NodeUnpublishVolume calls. This field is optional, and may be empty if no secret is required. If the secret object contains more than one secret, all secret references are passed.", + Ref: ref(v1.LocalObjectReference{}.OpenAPIModelName()), + }, + }, + }, + Required: []string{"driver"}, + }, + }, + Dependencies: []string{ + v1.LocalObjectReference{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_Capabilities(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "Adds and removes POSIX capabilities from running containers.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "add": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "Added capabilities", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + "drop": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "Removed capabilities", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + }, + }, + }, + } +} + +func schema_k8sio_api_core_v1_CephFSPersistentVolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "Represents a Ceph Filesystem mount that lasts the lifetime of a pod Cephfs volumes do not support ownership management or SELinux relabeling.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "monitors": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "monitors is Required: Monitors is a collection of Ceph monitors More info: https://examples.k8s.io/volumes/cephfs/README.md#how-to-use-it", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + "path": { + SchemaProps: spec.SchemaProps{ + Description: "path is Optional: Used as the mounted root, rather than the full Ceph tree, default is /", + Type: []string{"string"}, + Format: "", + }, + }, + "user": { + SchemaProps: spec.SchemaProps{ + Description: "user is Optional: User is the rados user name, default is admin More info: https://examples.k8s.io/volumes/cephfs/README.md#how-to-use-it", + Type: []string{"string"}, + Format: "", + }, + }, + "secretFile": { + SchemaProps: spec.SchemaProps{ + Description: "secretFile is Optional: SecretFile is the path to key ring for User, default is /etc/ceph/user.secret More info: https://examples.k8s.io/volumes/cephfs/README.md#how-to-use-it", + Type: []string{"string"}, + Format: "", + }, + }, + "secretRef": { + SchemaProps: spec.SchemaProps{ + Description: "secretRef is Optional: SecretRef is reference to the authentication secret for User, default is empty. More info: https://examples.k8s.io/volumes/cephfs/README.md#how-to-use-it", + Ref: ref(v1.SecretReference{}.OpenAPIModelName()), + }, + }, + "readOnly": { + SchemaProps: spec.SchemaProps{ + Description: "readOnly is Optional: Defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts. More info: https://examples.k8s.io/volumes/cephfs/README.md#how-to-use-it", + Type: []string{"boolean"}, + Format: "", + }, + }, + }, + Required: []string{"monitors"}, + }, + }, + Dependencies: []string{ + v1.SecretReference{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_CephFSVolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "Represents a Ceph Filesystem mount that lasts the lifetime of a pod Cephfs volumes do not support ownership management or SELinux relabeling.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "monitors": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "monitors is Required: Monitors is a collection of Ceph monitors More info: https://examples.k8s.io/volumes/cephfs/README.md#how-to-use-it", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + "path": { + SchemaProps: spec.SchemaProps{ + Description: "path is Optional: Used as the mounted root, rather than the full Ceph tree, default is /", + Type: []string{"string"}, + Format: "", + }, + }, + "user": { + SchemaProps: spec.SchemaProps{ + Description: "user is optional: User is the rados user name, default is admin More info: https://examples.k8s.io/volumes/cephfs/README.md#how-to-use-it", + Type: []string{"string"}, + Format: "", + }, + }, + "secretFile": { + SchemaProps: spec.SchemaProps{ + Description: "secretFile is Optional: SecretFile is the path to key ring for User, default is /etc/ceph/user.secret More info: https://examples.k8s.io/volumes/cephfs/README.md#how-to-use-it", + Type: []string{"string"}, + Format: "", + }, + }, + "secretRef": { + SchemaProps: spec.SchemaProps{ + Description: "secretRef is Optional: SecretRef is reference to the authentication secret for User, default is empty. More info: https://examples.k8s.io/volumes/cephfs/README.md#how-to-use-it", + Ref: ref(v1.LocalObjectReference{}.OpenAPIModelName()), + }, + }, + "readOnly": { + SchemaProps: spec.SchemaProps{ + Description: "readOnly is Optional: Defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts. More info: https://examples.k8s.io/volumes/cephfs/README.md#how-to-use-it", + Type: []string{"boolean"}, + Format: "", + }, + }, + }, + Required: []string{"monitors"}, + }, + }, + Dependencies: []string{ + v1.LocalObjectReference{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_CinderPersistentVolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "Represents a cinder volume resource in Openstack. A Cinder volume must exist before mounting to a container. The volume must also be in the same region as the kubelet. Cinder volumes support ownership management and SELinux relabeling.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "volumeID": { + SchemaProps: spec.SchemaProps{ + Description: "volumeID used to identify the volume in cinder. More info: https://examples.k8s.io/mysql-cinder-pd/README.md", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "fsType": { + SchemaProps: spec.SchemaProps{ + Description: "fsType Filesystem type to mount. Must be a filesystem type supported by the host operating system. Examples: \"ext4\", \"xfs\", \"ntfs\". Implicitly inferred to be \"ext4\" if unspecified. More info: https://examples.k8s.io/mysql-cinder-pd/README.md", + Type: []string{"string"}, + Format: "", + }, + }, + "readOnly": { + SchemaProps: spec.SchemaProps{ + Description: "readOnly is Optional: Defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts. More info: https://examples.k8s.io/mysql-cinder-pd/README.md", + Type: []string{"boolean"}, + Format: "", + }, + }, + "secretRef": { + SchemaProps: spec.SchemaProps{ + Description: "secretRef is Optional: points to a secret object containing parameters used to connect to OpenStack.", + Ref: ref(v1.SecretReference{}.OpenAPIModelName()), + }, + }, + }, + Required: []string{"volumeID"}, + }, + }, + Dependencies: []string{ + v1.SecretReference{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_CinderVolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "Represents a cinder volume resource in Openstack. A Cinder volume must exist before mounting to a container. The volume must also be in the same region as the kubelet. Cinder volumes support ownership management and SELinux relabeling.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "volumeID": { + SchemaProps: spec.SchemaProps{ + Description: "volumeID used to identify the volume in cinder. More info: https://examples.k8s.io/mysql-cinder-pd/README.md", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "fsType": { + SchemaProps: spec.SchemaProps{ + Description: "fsType is the filesystem type to mount. Must be a filesystem type supported by the host operating system. Examples: \"ext4\", \"xfs\", \"ntfs\". Implicitly inferred to be \"ext4\" if unspecified. More info: https://examples.k8s.io/mysql-cinder-pd/README.md", + Type: []string{"string"}, + Format: "", + }, + }, + "readOnly": { + SchemaProps: spec.SchemaProps{ + Description: "readOnly defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts. More info: https://examples.k8s.io/mysql-cinder-pd/README.md", + Type: []string{"boolean"}, + Format: "", + }, + }, + "secretRef": { + SchemaProps: spec.SchemaProps{ + Description: "secretRef is optional: points to a secret object containing parameters used to connect to OpenStack.", + Ref: ref(v1.LocalObjectReference{}.OpenAPIModelName()), + }, + }, + }, + Required: []string{"volumeID"}, + }, + }, + Dependencies: []string{ + v1.LocalObjectReference{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_ClientIPConfig(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "ClientIPConfig represents the configurations of Client IP based session affinity.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "timeoutSeconds": { + SchemaProps: spec.SchemaProps{ + Description: "timeoutSeconds specifies the seconds of ClientIP type session sticky time. The value must be >0 && <=86400(for 1 day) if ServiceAffinity == \"ClientIP\". Default value is 10800(for 3 hours).", + Type: []string{"integer"}, + Format: "int32", + }, + }, + }, + }, + }, + } +} + +func schema_k8sio_api_core_v1_ClusterTrustBundleProjection(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "ClusterTrustBundleProjection describes how to select a set of ClusterTrustBundle objects and project their contents into the pod filesystem.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "name": { + SchemaProps: spec.SchemaProps{ + Description: "Select a single ClusterTrustBundle by object name. Mutually-exclusive with signerName and labelSelector.", + Type: []string{"string"}, + Format: "", + }, + }, + "signerName": { + SchemaProps: spec.SchemaProps{ + Description: "Select all ClusterTrustBundles that match this signer name. Mutually-exclusive with name. The contents of all selected ClusterTrustBundles will be unified and deduplicated.", + Type: []string{"string"}, + Format: "", + }, + }, + "labelSelector": { + SchemaProps: spec.SchemaProps{ + Description: "Select all ClusterTrustBundles that match this label selector. Only has effect if signerName is set. Mutually-exclusive with name. If unset, interpreted as \"match nothing\". If set but empty, interpreted as \"match everything\".", + Ref: ref(metav1.LabelSelector{}.OpenAPIModelName()), + }, + }, + "optional": { + SchemaProps: spec.SchemaProps{ + Description: "If true, don't block pod startup if the referenced ClusterTrustBundle(s) aren't available. If using name, then the named ClusterTrustBundle is allowed not to exist. If using signerName, then the combination of signerName and labelSelector is allowed to match zero ClusterTrustBundles.", + Type: []string{"boolean"}, + Format: "", + }, + }, + "path": { + SchemaProps: spec.SchemaProps{ + Description: "Relative path from the volume root to write the bundle.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"path"}, + }, + }, + Dependencies: []string{ + metav1.LabelSelector{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_ComponentCondition(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "Information about the condition of a component.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "type": { + SchemaProps: spec.SchemaProps{ + Description: "Type of condition for a component. Valid value: \"Healthy\"", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "status": { + SchemaProps: spec.SchemaProps{ + Description: "Status of the condition for a component. Valid values for \"Healthy\": \"True\", \"False\", or \"Unknown\".", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "message": { + SchemaProps: spec.SchemaProps{ + Description: "Message about the condition for a component. For example, information about a health check.", + Type: []string{"string"}, + Format: "", + }, + }, + "error": { + SchemaProps: spec.SchemaProps{ + Description: "Condition error code for a component. For example, a health check error code.", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"type", "status"}, + }, + }, + } +} + +func schema_k8sio_api_core_v1_ComponentStatus(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "ComponentStatus (and ComponentStatusList) holds the cluster validation info. Deprecated: This API is deprecated in v1.19+", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "metadata": { + SchemaProps: spec.SchemaProps{ + Description: "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata", + Default: map[string]interface{}{}, + Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), + }, + }, + "conditions": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-map-keys": []interface{}{ + "type", + }, + "x-kubernetes-list-type": "map", + "x-kubernetes-patch-merge-key": "type", + "x-kubernetes-patch-strategy": "merge", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "List of component conditions observed", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.ComponentCondition{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + }, + }, + }, + Dependencies: []string{ + v1.ComponentCondition{}.OpenAPIModelName(), metav1.ObjectMeta{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_ComponentStatusList(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "Status of all the conditions for the component as a list of ComponentStatus objects. Deprecated: This API is deprecated in v1.19+", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "metadata": { + SchemaProps: spec.SchemaProps{ + Description: "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Default: map[string]interface{}{}, + Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), + }, + }, + "items": { + SchemaProps: spec.SchemaProps{ + Description: "List of ComponentStatus objects.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.ComponentStatus{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + }, + Required: []string{"items"}, + }, + }, + Dependencies: []string{ + v1.ComponentStatus{}.OpenAPIModelName(), metav1.ListMeta{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_ConfigMap(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "ConfigMap holds configuration data for pods to consume.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "metadata": { + SchemaProps: spec.SchemaProps{ + Description: "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata", + Default: map[string]interface{}{}, + Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), + }, + }, + "immutable": { + SchemaProps: spec.SchemaProps{ + Description: "Immutable, if set to true, ensures that data stored in the ConfigMap cannot be updated (only object metadata can be modified). If not set to true, the field can be modified at any time. Defaulted to nil.", + Type: []string{"boolean"}, + Format: "", + }, + }, + "data": { + SchemaProps: spec.SchemaProps{ + Description: "Data contains the configuration data. Each key must consist of alphanumeric characters, '-', '_' or '.'. Values with non-UTF-8 byte sequences must use the BinaryData field. The keys stored in Data must not overlap with the keys in the BinaryData field, this is enforced during validation process.", + Type: []string{"object"}, + AdditionalProperties: &spec.SchemaOrBool{ + Allows: true, + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + "binaryData": { + SchemaProps: spec.SchemaProps{ + Description: "BinaryData contains the binary data. Each key must consist of alphanumeric characters, '-', '_' or '.'. BinaryData can contain byte sequences that are not in the UTF-8 range. The keys stored in BinaryData must not overlap with the ones in the Data field, this is enforced during validation process. Using this field will require 1.10+ apiserver and kubelet.", + Type: []string{"object"}, + AdditionalProperties: &spec.SchemaOrBool{ + Allows: true, + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"string"}, + Format: "byte", + }, + }, + }, + }, + }, + }, + }, + }, + Dependencies: []string{ + metav1.ObjectMeta{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_ConfigMapEnvSource(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "ConfigMapEnvSource selects a ConfigMap to populate the environment variables with.\n\nThe contents of the target ConfigMap's Data field will represent the key-value pairs as environment variables.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "name": { + SchemaProps: spec.SchemaProps{ + Description: "Name of the referent. This field is effectively required, but due to backwards compatibility is allowed to be empty. Instances of this type with an empty value here are almost certainly wrong. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "optional": { + SchemaProps: spec.SchemaProps{ + Description: "Specify whether the ConfigMap must be defined", + Type: []string{"boolean"}, + Format: "", + }, + }, + }, + }, + }, + } +} + +func schema_k8sio_api_core_v1_ConfigMapKeySelector(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "Selects a key from a ConfigMap.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "name": { + SchemaProps: spec.SchemaProps{ + Description: "Name of the referent. This field is effectively required, but due to backwards compatibility is allowed to be empty. Instances of this type with an empty value here are almost certainly wrong. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "key": { + SchemaProps: spec.SchemaProps{ + Description: "The key to select.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "optional": { + SchemaProps: spec.SchemaProps{ + Description: "Specify whether the ConfigMap or its key must be defined", + Type: []string{"boolean"}, + Format: "", + }, + }, + }, + Required: []string{"key"}, + }, + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-map-type": "atomic", + }, + }, + }, + } +} + +func schema_k8sio_api_core_v1_ConfigMapList(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "ConfigMapList is a resource containing a list of ConfigMap objects.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "metadata": { + SchemaProps: spec.SchemaProps{ + Description: "More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata", + Default: map[string]interface{}{}, + Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), + }, + }, + "items": { + SchemaProps: spec.SchemaProps{ + Description: "Items is the list of ConfigMaps.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.ConfigMap{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + }, + Required: []string{"items"}, + }, + }, + Dependencies: []string{ + v1.ConfigMap{}.OpenAPIModelName(), metav1.ListMeta{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_ConfigMapNodeConfigSource(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "ConfigMapNodeConfigSource contains the information to reference a ConfigMap as a config source for the Node. This API is deprecated since 1.22: https://git.k8s.io/enhancements/keps/sig-node/281-dynamic-kubelet-configuration", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "namespace": { + SchemaProps: spec.SchemaProps{ + Description: "Namespace is the metadata.namespace of the referenced ConfigMap. This field is required in all cases.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "name": { + SchemaProps: spec.SchemaProps{ + Description: "Name is the metadata.name of the referenced ConfigMap. This field is required in all cases.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "uid": { + SchemaProps: spec.SchemaProps{ + Description: "UID is the metadata.UID of the referenced ConfigMap. This field is forbidden in Node.Spec, and required in Node.Status.", + Type: []string{"string"}, + Format: "", + }, + }, + "resourceVersion": { + SchemaProps: spec.SchemaProps{ + Description: "ResourceVersion is the metadata.ResourceVersion of the referenced ConfigMap. This field is forbidden in Node.Spec, and required in Node.Status.", + Type: []string{"string"}, + Format: "", + }, + }, + "kubeletConfigKey": { + SchemaProps: spec.SchemaProps{ + Description: "KubeletConfigKey declares which key of the referenced ConfigMap corresponds to the KubeletConfiguration structure This field is required in all cases.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"namespace", "name", "kubeletConfigKey"}, + }, + }, + } +} + +func schema_k8sio_api_core_v1_ConfigMapProjection(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "Adapts a ConfigMap into a projected volume.\n\nThe contents of the target ConfigMap's Data field will be presented in a projected volume as files using the keys in the Data field as the file names, unless the items element is populated with specific mappings of keys to paths. Note that this is identical to a configmap volume source without the default mode.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "name": { + SchemaProps: spec.SchemaProps{ + Description: "Name of the referent. This field is effectively required, but due to backwards compatibility is allowed to be empty. Instances of this type with an empty value here are almost certainly wrong. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "items": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "items if unspecified, each key-value pair in the Data field of the referenced ConfigMap will be projected into the volume as a file whose name is the key and content is the value. If specified, the listed keys will be projected into the specified paths, and unlisted keys will not be present. If a key is specified which is not present in the ConfigMap, the volume setup will error unless it is marked optional. Paths must be relative and may not contain the '..' path or start with '..'.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.KeyToPath{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "optional": { + SchemaProps: spec.SchemaProps{ + Description: "optional specify whether the ConfigMap or its keys must be defined", + Type: []string{"boolean"}, + Format: "", + }, + }, + }, + }, + }, + Dependencies: []string{ + v1.KeyToPath{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_ConfigMapVolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "Adapts a ConfigMap into a volume.\n\nThe contents of the target ConfigMap's Data field will be presented in a volume as files using the keys in the Data field as the file names, unless the items element is populated with specific mappings of keys to paths. ConfigMap volumes support ownership management and SELinux relabeling.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "name": { + SchemaProps: spec.SchemaProps{ + Description: "Name of the referent. This field is effectively required, but due to backwards compatibility is allowed to be empty. Instances of this type with an empty value here are almost certainly wrong. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "items": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "items if unspecified, each key-value pair in the Data field of the referenced ConfigMap will be projected into the volume as a file whose name is the key and content is the value. If specified, the listed keys will be projected into the specified paths, and unlisted keys will not be present. If a key is specified which is not present in the ConfigMap, the volume setup will error unless it is marked optional. Paths must be relative and may not contain the '..' path or start with '..'.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.KeyToPath{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "defaultMode": { + SchemaProps: spec.SchemaProps{ + Description: "defaultMode is optional: mode bits used to set permissions on created files by default. Must be an octal value between 0000 and 0777 or a decimal value between 0 and 511. YAML accepts both octal and decimal values, JSON requires decimal values for mode bits. Defaults to 0644. Directories within the path are not affected by this setting. This might be in conflict with other options that affect the file mode, like fsGroup, and the result can be other mode bits set.", + Type: []string{"integer"}, + Format: "int32", + }, + }, + "optional": { + SchemaProps: spec.SchemaProps{ + Description: "optional specify whether the ConfigMap or its keys must be defined", + Type: []string{"boolean"}, + Format: "", + }, + }, + }, + }, + }, + Dependencies: []string{ + v1.KeyToPath{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_Container(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "A single application container that you want to run within a pod.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "name": { + SchemaProps: spec.SchemaProps{ + Description: "Name of the container specified as a DNS_LABEL. Each container in a pod must have a unique name (DNS_LABEL). Cannot be updated.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "image": { + SchemaProps: spec.SchemaProps{ + Description: "Container image name. More info: https://kubernetes.io/docs/concepts/containers/images This field is optional to allow higher level config management to default or override container images in workload controllers like Deployments and StatefulSets.", + Type: []string{"string"}, + Format: "", + }, + }, + "command": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "Entrypoint array. Not executed within a shell. The container image's ENTRYPOINT is used if this is not provided. Variable references $(VAR_NAME) are expanded using the container's environment. If a variable cannot be resolved, the reference in the input string will be unchanged. Double $$ are reduced to a single $, which allows for escaping the $(VAR_NAME) syntax: i.e. \"$$(VAR_NAME)\" will produce the string literal \"$(VAR_NAME)\". Escaped references will never be expanded, regardless of whether the variable exists or not. Cannot be updated. More info: https://kubernetes.io/docs/tasks/inject-data-application/define-command-argument-container/#running-a-command-in-a-shell", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + "args": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "Arguments to the entrypoint. The container image's CMD is used if this is not provided. Variable references $(VAR_NAME) are expanded using the container's environment. If a variable cannot be resolved, the reference in the input string will be unchanged. Double $$ are reduced to a single $, which allows for escaping the $(VAR_NAME) syntax: i.e. \"$$(VAR_NAME)\" will produce the string literal \"$(VAR_NAME)\". Escaped references will never be expanded, regardless of whether the variable exists or not. Cannot be updated. More info: https://kubernetes.io/docs/tasks/inject-data-application/define-command-argument-container/#running-a-command-in-a-shell", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + "workingDir": { + SchemaProps: spec.SchemaProps{ + Description: "Container's working directory. If not specified, the container runtime's default will be used, which might be configured in the container image. Cannot be updated.", + Type: []string{"string"}, + Format: "", + }, + }, + "ports": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-map-keys": []interface{}{ + "containerPort", + "protocol", + }, + "x-kubernetes-list-type": "map", + "x-kubernetes-patch-merge-key": "containerPort", + "x-kubernetes-patch-strategy": "merge", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "List of ports to expose from the container. Not specifying a port here DOES NOT prevent that port from being exposed. Any port which is listening on the default \"0.0.0.0\" address inside a container will be accessible from the network. Modifying this array with strategic merge patch may corrupt the data. For more information See https://github.com/kubernetes/kubernetes/issues/108255. Cannot be updated.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.ContainerPort{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "envFrom": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "List of sources to populate environment variables in the container. The keys defined within a source may consist of any printable ASCII characters except '='. When a key exists in multiple sources, the value associated with the last source will take precedence. Values defined by an Env with a duplicate key will take precedence. Cannot be updated.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.EnvFromSource{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "env": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-map-keys": []interface{}{ + "name", + }, + "x-kubernetes-list-type": "map", + "x-kubernetes-patch-merge-key": "name", + "x-kubernetes-patch-strategy": "merge", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "List of environment variables to set in the container. Cannot be updated.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.EnvVar{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "resources": { + SchemaProps: spec.SchemaProps{ + Description: "Compute Resources required by this container. Cannot be updated. More info: https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/", + Default: map[string]interface{}{}, + Ref: ref(v1.ResourceRequirements{}.OpenAPIModelName()), + }, + }, + "resizePolicy": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "Resources resize policy for the container. This field cannot be set on ephemeral containers.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.ContainerResizePolicy{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "restartPolicy": { + SchemaProps: spec.SchemaProps{ + Description: "RestartPolicy defines the restart behavior of individual containers in a pod. This overrides the pod-level restart policy. When this field is not specified, the restart behavior is defined by the Pod's restart policy and the container type. Additionally, setting the RestartPolicy as \"Always\" for the init container will have the following effect: this init container will be continually restarted on exit until all regular containers have terminated. Once all regular containers have completed, all init containers with restartPolicy \"Always\" will be shut down. This lifecycle differs from normal init containers and is often referred to as a \"sidecar\" container. Although this init container still starts in the init container sequence, it does not wait for the container to complete before proceeding to the next init container. Instead, the next init container starts immediately after this init container is started, or after any startupProbe has successfully completed.", + Type: []string{"string"}, + Format: "", + }, + }, + "restartPolicyRules": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "Represents a list of rules to be checked to determine if the container should be restarted on exit. The rules are evaluated in order. Once a rule matches a container exit condition, the remaining rules are ignored. If no rule matches the container exit condition, the Container-level restart policy determines the whether the container is restarted or not. Constraints on the rules: - At most 20 rules are allowed. - Rules can have the same action. - Identical rules are not forbidden in validations. When rules are specified, container MUST set RestartPolicy explicitly even it if matches the Pod's RestartPolicy.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.ContainerRestartRule{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "volumeMounts": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-map-keys": []interface{}{ + "mountPath", + }, + "x-kubernetes-list-type": "map", + "x-kubernetes-patch-merge-key": "mountPath", + "x-kubernetes-patch-strategy": "merge", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "Pod volumes to mount into the container's filesystem. Cannot be updated.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.VolumeMount{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "volumeDevices": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-map-keys": []interface{}{ + "devicePath", + }, + "x-kubernetes-list-type": "map", + "x-kubernetes-patch-merge-key": "devicePath", + "x-kubernetes-patch-strategy": "merge", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "volumeDevices is the list of block devices to be used by the container.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.VolumeDevice{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "livenessProbe": { + SchemaProps: spec.SchemaProps{ + Description: "Periodic probe of container liveness. Container will be restarted if the probe fails. Cannot be updated. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#container-probes", + Ref: ref(v1.Probe{}.OpenAPIModelName()), + }, + }, + "readinessProbe": { + SchemaProps: spec.SchemaProps{ + Description: "Periodic probe of container service readiness. Container will be removed from service endpoints if the probe fails. Cannot be updated. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#container-probes", + Ref: ref(v1.Probe{}.OpenAPIModelName()), + }, + }, + "startupProbe": { + SchemaProps: spec.SchemaProps{ + Description: "StartupProbe indicates that the Pod has successfully initialized. If specified, no other probes are executed until this completes successfully. If this probe fails, the Pod will be restarted, just as if the livenessProbe failed. This can be used to provide different probe parameters at the beginning of a Pod's lifecycle, when it might take a long time to load data or warm a cache, than during steady-state operation. This cannot be updated. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#container-probes", + Ref: ref(v1.Probe{}.OpenAPIModelName()), + }, + }, + "lifecycle": { + SchemaProps: spec.SchemaProps{ + Description: "Actions that the management system should take in response to container lifecycle events. Cannot be updated.", + Ref: ref(v1.Lifecycle{}.OpenAPIModelName()), + }, + }, + "terminationMessagePath": { + SchemaProps: spec.SchemaProps{ + Description: "Optional: Path at which the file to which the container's termination message will be written is mounted into the container's filesystem. Message written is intended to be brief final status, such as an assertion failure message. Will be truncated by the node if greater than 4096 bytes. The total message length across all containers will be limited to 12kb. Defaults to /dev/termination-log. Cannot be updated.", + Type: []string{"string"}, + Format: "", + }, + }, + "terminationMessagePolicy": { + SchemaProps: spec.SchemaProps{ + Description: "Indicate how the termination message should be populated. File will use the contents of terminationMessagePath to populate the container status message on both success and failure. FallbackToLogsOnError will use the last chunk of container log output if the termination message file is empty and the container exited with an error. The log output is limited to 2048 bytes or 80 lines, whichever is smaller. Defaults to File. Cannot be updated.\n\nPossible enum values:\n - `\"FallbackToLogsOnError\"` will read the most recent contents of the container logs for the container status message when the container exits with an error and the terminationMessagePath has no contents.\n - `\"File\"` is the default behavior and will set the container status message to the contents of the container's terminationMessagePath when the container exits.", + Type: []string{"string"}, + Format: "", + Enum: []interface{}{"FallbackToLogsOnError", "File"}, + }, + }, + "imagePullPolicy": { + SchemaProps: spec.SchemaProps{ + Description: "Image pull policy. One of Always, Never, IfNotPresent. Defaults to Always if :latest tag is specified, or IfNotPresent otherwise. Cannot be updated. More info: https://kubernetes.io/docs/concepts/containers/images#updating-images\n\nPossible enum values:\n - `\"Always\"` means that kubelet always attempts to pull the latest image. Container will fail If the pull fails.\n - `\"IfNotPresent\"` means that kubelet pulls if the image isn't present on disk. Container will fail if the image isn't present and the pull fails.\n - `\"Never\"` means that kubelet never pulls an image, but only uses a local image. Container will fail if the image isn't present", + Type: []string{"string"}, + Format: "", + Enum: []interface{}{"Always", "IfNotPresent", "Never"}, + }, + }, + "securityContext": { + SchemaProps: spec.SchemaProps{ + Description: "SecurityContext defines the security options the container should be run with. If set, the fields of SecurityContext override the equivalent fields of PodSecurityContext. More info: https://kubernetes.io/docs/tasks/configure-pod-container/security-context/", + Ref: ref(v1.SecurityContext{}.OpenAPIModelName()), + }, + }, + "stdin": { + SchemaProps: spec.SchemaProps{ + Description: "Whether this container should allocate a buffer for stdin in the container runtime. If this is not set, reads from stdin in the container will always result in EOF. Default is false.", + Type: []string{"boolean"}, + Format: "", + }, + }, + "stdinOnce": { + SchemaProps: spec.SchemaProps{ + Description: "Whether the container runtime should close the stdin channel after it has been opened by a single attach. When stdin is true the stdin stream will remain open across multiple attach sessions. If stdinOnce is set to true, stdin is opened on container start, is empty until the first client attaches to stdin, and then remains open and accepts data until the client disconnects, at which time stdin is closed and remains closed until the container is restarted. If this flag is false, a container processes that reads from stdin will never receive an EOF. Default is false", + Type: []string{"boolean"}, + Format: "", + }, + }, + "tty": { + SchemaProps: spec.SchemaProps{ + Description: "Whether this container should allocate a TTY for itself, also requires 'stdin' to be true. Default is false.", + Type: []string{"boolean"}, + Format: "", + }, + }, + }, + Required: []string{"name"}, + }, + }, + Dependencies: []string{ + v1.ContainerPort{}.OpenAPIModelName(), v1.ContainerResizePolicy{}.OpenAPIModelName(), v1.ContainerRestartRule{}.OpenAPIModelName(), v1.EnvFromSource{}.OpenAPIModelName(), v1.EnvVar{}.OpenAPIModelName(), v1.Lifecycle{}.OpenAPIModelName(), v1.Probe{}.OpenAPIModelName(), v1.ResourceRequirements{}.OpenAPIModelName(), v1.SecurityContext{}.OpenAPIModelName(), v1.VolumeDevice{}.OpenAPIModelName(), v1.VolumeMount{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_ContainerExtendedResourceRequest(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "ContainerExtendedResourceRequest has the mapping of container name, extended resource name to the device request name.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "containerName": { + SchemaProps: spec.SchemaProps{ + Description: "The name of the container requesting resources.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "resourceName": { + SchemaProps: spec.SchemaProps{ + Description: "The name of the extended resource in that container which gets backed by DRA.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "requestName": { + SchemaProps: spec.SchemaProps{ + Description: "The name of the request in the special ResourceClaim which corresponds to the extended resource.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"containerName", "resourceName", "requestName"}, + }, + }, + } +} + +func schema_k8sio_api_core_v1_ContainerImage(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "Describe a container image", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "names": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "Names by which this image is known. e.g. [\"kubernetes.example/hyperkube:v1.0.7\", \"cloud-vendor.registry.example/cloud-vendor/hyperkube:v1.0.7\"]", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + "sizeBytes": { + SchemaProps: spec.SchemaProps{ + Description: "The size of the image in bytes.", + Type: []string{"integer"}, + Format: "int64", + }, + }, + }, + }, + }, + } +} + +func schema_k8sio_api_core_v1_ContainerPort(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "ContainerPort represents a network port in a single container.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "name": { + SchemaProps: spec.SchemaProps{ + Description: "If specified, this must be an IANA_SVC_NAME and unique within the pod. Each named port in a pod must have a unique name. Name for the port that can be referred to by services.", + Type: []string{"string"}, + Format: "", + }, + }, + "hostPort": { + SchemaProps: spec.SchemaProps{ + Description: "Number of port to expose on the host. If specified, this must be a valid port number, 0 < x < 65536. If HostNetwork is specified, this must match ContainerPort. Most containers do not need this.", + Type: []string{"integer"}, + Format: "int32", + }, + }, + "containerPort": { + SchemaProps: spec.SchemaProps{ + Description: "Number of port to expose on the pod's IP address. This must be a valid port number, 0 < x < 65536.", + Default: 0, + Type: []string{"integer"}, + Format: "int32", + }, + }, + "protocol": { + SchemaProps: spec.SchemaProps{ + Description: "Protocol for port. Must be UDP, TCP, or SCTP. Defaults to \"TCP\".\n\nPossible enum values:\n - `\"SCTP\"` is the SCTP protocol.\n - `\"TCP\"` is the TCP protocol.\n - `\"UDP\"` is the UDP protocol.", + Default: "TCP", + Type: []string{"string"}, + Format: "", + Enum: []interface{}{"SCTP", "TCP", "UDP"}, + }, + }, + "hostIP": { + SchemaProps: spec.SchemaProps{ + Description: "What host IP to bind the external port to.", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"containerPort"}, + }, + }, + } +} + +func schema_k8sio_api_core_v1_ContainerResizePolicy(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "ContainerResizePolicy represents resource resize policy for the container.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "resourceName": { + SchemaProps: spec.SchemaProps{ + Description: "Name of the resource to which this resource resize policy applies. Supported values: cpu, memory.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "restartPolicy": { + SchemaProps: spec.SchemaProps{ + Description: "Restart policy to apply when specified resource is resized. If not specified, it defaults to NotRequired.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"resourceName", "restartPolicy"}, + }, + }, + } +} + +func schema_k8sio_api_core_v1_ContainerRestartRule(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "ContainerRestartRule describes how a container exit is handled.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "action": { + SchemaProps: spec.SchemaProps{ + Description: "Specifies the action taken on a container exit if the requirements are satisfied. The only possible value is \"Restart\" to restart the container.", + Type: []string{"string"}, + Format: "", + }, + }, + "exitCodes": { + SchemaProps: spec.SchemaProps{ + Description: "Represents the exit codes to check on container exits.", + Ref: ref(v1.ContainerRestartRuleOnExitCodes{}.OpenAPIModelName()), + }, + }, + }, + Required: []string{"action"}, + }, + }, + Dependencies: []string{ + v1.ContainerRestartRuleOnExitCodes{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_ContainerRestartRuleOnExitCodes(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "ContainerRestartRuleOnExitCodes describes the condition for handling an exited container based on its exit codes.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "operator": { + SchemaProps: spec.SchemaProps{ + Description: "Represents the relationship between the container exit code(s) and the specified values. Possible values are: - In: the requirement is satisfied if the container exit code is in the\n set of specified values.\n- NotIn: the requirement is satisfied if the container exit code is\n not in the set of specified values.", + Type: []string{"string"}, + Format: "", + }, + }, + "values": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "set", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "Specifies the set of values to check for container exit codes. At most 255 elements are allowed.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: 0, + Type: []string{"integer"}, + Format: "int32", + }, + }, + }, + }, + }, + }, + Required: []string{"operator"}, + }, + }, + } +} + +func schema_k8sio_api_core_v1_ContainerState(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "ContainerState holds a possible state of container. Only one of its members may be specified. If none of them is specified, the default one is ContainerStateWaiting.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "waiting": { + SchemaProps: spec.SchemaProps{ + Description: "Details about a waiting container", + Ref: ref(v1.ContainerStateWaiting{}.OpenAPIModelName()), + }, + }, + "running": { + SchemaProps: spec.SchemaProps{ + Description: "Details about a running container", + Ref: ref(v1.ContainerStateRunning{}.OpenAPIModelName()), + }, + }, + "terminated": { + SchemaProps: spec.SchemaProps{ + Description: "Details about a terminated container", + Ref: ref(v1.ContainerStateTerminated{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + Dependencies: []string{ + v1.ContainerStateRunning{}.OpenAPIModelName(), v1.ContainerStateTerminated{}.OpenAPIModelName(), v1.ContainerStateWaiting{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_ContainerStateRunning(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "ContainerStateRunning is a running state of a container.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "startedAt": { + SchemaProps: spec.SchemaProps{ + Description: "Time at which the container was last (re-)started", + Ref: ref(metav1.Time{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + Dependencies: []string{ + metav1.Time{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_ContainerStateTerminated(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "ContainerStateTerminated is a terminated state of a container.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "exitCode": { + SchemaProps: spec.SchemaProps{ + Description: "Exit status from the last termination of the container", + Default: 0, + Type: []string{"integer"}, + Format: "int32", + }, + }, + "signal": { + SchemaProps: spec.SchemaProps{ + Description: "Signal from the last termination of the container", + Type: []string{"integer"}, + Format: "int32", + }, + }, + "reason": { + SchemaProps: spec.SchemaProps{ + Description: "(brief) reason from the last termination of the container", + Type: []string{"string"}, + Format: "", + }, + }, + "message": { + SchemaProps: spec.SchemaProps{ + Description: "Message regarding the last termination of the container", + Type: []string{"string"}, + Format: "", + }, + }, + "startedAt": { + SchemaProps: spec.SchemaProps{ + Description: "Time at which previous execution of the container started", + Ref: ref(metav1.Time{}.OpenAPIModelName()), + }, + }, + "finishedAt": { + SchemaProps: spec.SchemaProps{ + Description: "Time at which the container last terminated", + Ref: ref(metav1.Time{}.OpenAPIModelName()), + }, + }, + "containerID": { + SchemaProps: spec.SchemaProps{ + Description: "Container's ID in the format '://'", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"exitCode"}, + }, + }, + Dependencies: []string{ + metav1.Time{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_ContainerStateWaiting(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "ContainerStateWaiting is a waiting state of a container.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "reason": { + SchemaProps: spec.SchemaProps{ + Description: "(brief) reason the container is not yet running.", + Type: []string{"string"}, + Format: "", + }, + }, + "message": { + SchemaProps: spec.SchemaProps{ + Description: "Message regarding why the container is not yet running.", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + } +} + +func schema_k8sio_api_core_v1_ContainerStatus(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "ContainerStatus contains details for the current status of this container.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "name": { + SchemaProps: spec.SchemaProps{ + Description: "Name is a DNS_LABEL representing the unique name of the container. Each container in a pod must have a unique name across all container types. Cannot be updated.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "state": { + SchemaProps: spec.SchemaProps{ + Description: "State holds details about the container's current condition.", + Default: map[string]interface{}{}, + Ref: ref(v1.ContainerState{}.OpenAPIModelName()), + }, + }, + "lastState": { + SchemaProps: spec.SchemaProps{ + Description: "LastTerminationState holds the last termination state of the container to help debug container crashes and restarts. This field is not populated if the container is still running and RestartCount is 0.", + Default: map[string]interface{}{}, + Ref: ref(v1.ContainerState{}.OpenAPIModelName()), + }, + }, + "ready": { + SchemaProps: spec.SchemaProps{ + Description: "Ready specifies whether the container is currently passing its readiness check. The value will change as readiness probes keep executing. If no readiness probes are specified, this field defaults to true once the container is fully started (see Started field).\n\nThe value is typically used to determine whether a container is ready to accept traffic.", + Default: false, + Type: []string{"boolean"}, + Format: "", + }, + }, + "restartCount": { + SchemaProps: spec.SchemaProps{ + Description: "RestartCount holds the number of times the container has been restarted. Kubelet makes an effort to always increment the value, but there are cases when the state may be lost due to node restarts and then the value may be reset to 0. The value is never negative.", + Default: 0, + Type: []string{"integer"}, + Format: "int32", + }, + }, + "image": { + SchemaProps: spec.SchemaProps{ + Description: "Image is the name of container image that the container is running. The container image may not match the image used in the PodSpec, as it may have been resolved by the runtime. More info: https://kubernetes.io/docs/concepts/containers/images.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "imageID": { + SchemaProps: spec.SchemaProps{ + Description: "ImageID is the image ID of the container's image. The image ID may not match the image ID of the image used in the PodSpec, as it may have been resolved by the runtime.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "containerID": { + SchemaProps: spec.SchemaProps{ + Description: "ContainerID is the ID of the container in the format '://'. Where type is a container runtime identifier, returned from Version call of CRI API (for example \"containerd\").", + Type: []string{"string"}, + Format: "", + }, + }, + "started": { + SchemaProps: spec.SchemaProps{ + Description: "Started indicates whether the container has finished its postStart lifecycle hook and passed its startup probe. Initialized as false, becomes true after startupProbe is considered successful. Resets to false when the container is restarted, or if kubelet loses state temporarily. In both cases, startup probes will run again. Is always true when no startupProbe is defined and container is running and has passed the postStart lifecycle hook. The null value must be treated the same as false.", + Type: []string{"boolean"}, + Format: "", + }, + }, + "allocatedResources": { + SchemaProps: spec.SchemaProps{ + Description: "AllocatedResources represents the compute resources allocated for this container by the node. Kubelet sets this value to Container.Resources.Requests upon successful pod admission and after successfully admitting desired pod resize.", + Type: []string{"object"}, + AdditionalProperties: &spec.SchemaOrBool{ + Allows: true, + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Ref: ref(resource.Quantity{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "resources": { + SchemaProps: spec.SchemaProps{ + Description: "Resources represents the compute resource requests and limits that have been successfully enacted on the running container after it has been started or has been successfully resized.", + Ref: ref(v1.ResourceRequirements{}.OpenAPIModelName()), + }, + }, + "volumeMounts": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-map-keys": []interface{}{ + "mountPath", + }, + "x-kubernetes-list-type": "map", + "x-kubernetes-patch-merge-key": "mountPath", + "x-kubernetes-patch-strategy": "merge", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "Status of volume mounts.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.VolumeMountStatus{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "user": { + SchemaProps: spec.SchemaProps{ + Description: "User represents user identity information initially attached to the first process of the container", + Ref: ref(v1.ContainerUser{}.OpenAPIModelName()), + }, + }, + "allocatedResourcesStatus": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-map-keys": []interface{}{ + "name", + }, + "x-kubernetes-list-type": "map", + "x-kubernetes-patch-merge-key": "name", + "x-kubernetes-patch-strategy": "merge", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "AllocatedResourcesStatus represents the status of various resources allocated for this Pod.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.ResourceStatus{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "stopSignal": { + SchemaProps: spec.SchemaProps{ + Description: "StopSignal reports the effective stop signal for this container\n\nPossible enum values:\n - `\"SIGABRT\"`\n - `\"SIGALRM\"`\n - `\"SIGBUS\"`\n - `\"SIGCHLD\"`\n - `\"SIGCLD\"`\n - `\"SIGCONT\"`\n - `\"SIGFPE\"`\n - `\"SIGHUP\"`\n - `\"SIGILL\"`\n - `\"SIGINT\"`\n - `\"SIGIO\"`\n - `\"SIGIOT\"`\n - `\"SIGKILL\"`\n - `\"SIGPIPE\"`\n - `\"SIGPOLL\"`\n - `\"SIGPROF\"`\n - `\"SIGPWR\"`\n - `\"SIGQUIT\"`\n - `\"SIGRTMAX\"`\n - `\"SIGRTMAX-1\"`\n - `\"SIGRTMAX-10\"`\n - `\"SIGRTMAX-11\"`\n - `\"SIGRTMAX-12\"`\n - `\"SIGRTMAX-13\"`\n - `\"SIGRTMAX-14\"`\n - `\"SIGRTMAX-2\"`\n - `\"SIGRTMAX-3\"`\n - `\"SIGRTMAX-4\"`\n - `\"SIGRTMAX-5\"`\n - `\"SIGRTMAX-6\"`\n - `\"SIGRTMAX-7\"`\n - `\"SIGRTMAX-8\"`\n - `\"SIGRTMAX-9\"`\n - `\"SIGRTMIN\"`\n - `\"SIGRTMIN+1\"`\n - `\"SIGRTMIN+10\"`\n - `\"SIGRTMIN+11\"`\n - `\"SIGRTMIN+12\"`\n - `\"SIGRTMIN+13\"`\n - `\"SIGRTMIN+14\"`\n - `\"SIGRTMIN+15\"`\n - `\"SIGRTMIN+2\"`\n - `\"SIGRTMIN+3\"`\n - `\"SIGRTMIN+4\"`\n - `\"SIGRTMIN+5\"`\n - `\"SIGRTMIN+6\"`\n - `\"SIGRTMIN+7\"`\n - `\"SIGRTMIN+8\"`\n - `\"SIGRTMIN+9\"`\n - `\"SIGSEGV\"`\n - `\"SIGSTKFLT\"`\n - `\"SIGSTOP\"`\n - `\"SIGSYS\"`\n - `\"SIGTERM\"`\n - `\"SIGTRAP\"`\n - `\"SIGTSTP\"`\n - `\"SIGTTIN\"`\n - `\"SIGTTOU\"`\n - `\"SIGURG\"`\n - `\"SIGUSR1\"`\n - `\"SIGUSR2\"`\n - `\"SIGVTALRM\"`\n - `\"SIGWINCH\"`\n - `\"SIGXCPU\"`\n - `\"SIGXFSZ\"`", + Type: []string{"string"}, + Format: "", + Enum: []interface{}{"SIGABRT", "SIGALRM", "SIGBUS", "SIGCHLD", "SIGCLD", "SIGCONT", "SIGFPE", "SIGHUP", "SIGILL", "SIGINT", "SIGIO", "SIGIOT", "SIGKILL", "SIGPIPE", "SIGPOLL", "SIGPROF", "SIGPWR", "SIGQUIT", "SIGRTMAX", "SIGRTMAX-1", "SIGRTMAX-10", "SIGRTMAX-11", "SIGRTMAX-12", "SIGRTMAX-13", "SIGRTMAX-14", "SIGRTMAX-2", "SIGRTMAX-3", "SIGRTMAX-4", "SIGRTMAX-5", "SIGRTMAX-6", "SIGRTMAX-7", "SIGRTMAX-8", "SIGRTMAX-9", "SIGRTMIN", "SIGRTMIN+1", "SIGRTMIN+10", "SIGRTMIN+11", "SIGRTMIN+12", "SIGRTMIN+13", "SIGRTMIN+14", "SIGRTMIN+15", "SIGRTMIN+2", "SIGRTMIN+3", "SIGRTMIN+4", "SIGRTMIN+5", "SIGRTMIN+6", "SIGRTMIN+7", "SIGRTMIN+8", "SIGRTMIN+9", "SIGSEGV", "SIGSTKFLT", "SIGSTOP", "SIGSYS", "SIGTERM", "SIGTRAP", "SIGTSTP", "SIGTTIN", "SIGTTOU", "SIGURG", "SIGUSR1", "SIGUSR2", "SIGVTALRM", "SIGWINCH", "SIGXCPU", "SIGXFSZ"}, + }, + }, + }, + Required: []string{"name", "ready", "restartCount", "image", "imageID"}, + }, + }, + Dependencies: []string{ + v1.ContainerState{}.OpenAPIModelName(), v1.ContainerUser{}.OpenAPIModelName(), v1.ResourceRequirements{}.OpenAPIModelName(), v1.ResourceStatus{}.OpenAPIModelName(), v1.VolumeMountStatus{}.OpenAPIModelName(), resource.Quantity{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_ContainerUser(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "ContainerUser represents user identity information", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "linux": { + SchemaProps: spec.SchemaProps{ + Description: "Linux holds user identity information initially attached to the first process of the containers in Linux. Note that the actual running identity can be changed if the process has enough privilege to do so.", + Ref: ref(v1.LinuxContainerUser{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + Dependencies: []string{ + v1.LinuxContainerUser{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_DaemonEndpoint(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "DaemonEndpoint contains information about a single Daemon endpoint.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "Port": { + SchemaProps: spec.SchemaProps{ + Description: "Port number of the given endpoint.", + Default: 0, + Type: []string{"integer"}, + Format: "int32", + }, + }, + }, + Required: []string{"Port"}, + }, + }, + } +} + +func schema_k8sio_api_core_v1_DownwardAPIProjection(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "Represents downward API info for projecting into a projected volume. Note that this is identical to a downwardAPI volume source without the default mode.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "items": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "Items is a list of DownwardAPIVolume file", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.DownwardAPIVolumeFile{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + }, + }, + }, + Dependencies: []string{ + v1.DownwardAPIVolumeFile{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_DownwardAPIVolumeFile(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "DownwardAPIVolumeFile represents information to create the file containing the pod field", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "path": { + SchemaProps: spec.SchemaProps{ + Description: "Required: Path is the relative path name of the file to be created. Must not be absolute or contain the '..' path. Must be utf-8 encoded. The first item of the relative path must not start with '..'", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "fieldRef": { + SchemaProps: spec.SchemaProps{ + Description: "Required: Selects a field of the pod: only annotations, labels, name, namespace and uid are supported.", + Ref: ref(v1.ObjectFieldSelector{}.OpenAPIModelName()), + }, + }, + "resourceFieldRef": { + SchemaProps: spec.SchemaProps{ + Description: "Selects a resource of the container: only resources limits and requests (limits.cpu, limits.memory, requests.cpu and requests.memory) are currently supported.", + Ref: ref(v1.ResourceFieldSelector{}.OpenAPIModelName()), + }, + }, + "mode": { + SchemaProps: spec.SchemaProps{ + Description: "Optional: mode bits used to set permissions on this file, must be an octal value between 0000 and 0777 or a decimal value between 0 and 511. YAML accepts both octal and decimal values, JSON requires decimal values for mode bits. If not specified, the volume defaultMode will be used. This might be in conflict with other options that affect the file mode, like fsGroup, and the result can be other mode bits set.", + Type: []string{"integer"}, + Format: "int32", + }, + }, + }, + Required: []string{"path"}, + }, + }, + Dependencies: []string{ + v1.ObjectFieldSelector{}.OpenAPIModelName(), v1.ResourceFieldSelector{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_DownwardAPIVolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "DownwardAPIVolumeSource represents a volume containing downward API info. Downward API volumes support ownership management and SELinux relabeling.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "items": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "Items is a list of downward API volume file", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.DownwardAPIVolumeFile{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "defaultMode": { + SchemaProps: spec.SchemaProps{ + Description: "Optional: mode bits to use on created files by default. Must be a Optional: mode bits used to set permissions on created files by default. Must be an octal value between 0000 and 0777 or a decimal value between 0 and 511. YAML accepts both octal and decimal values, JSON requires decimal values for mode bits. Defaults to 0644. Directories within the path are not affected by this setting. This might be in conflict with other options that affect the file mode, like fsGroup, and the result can be other mode bits set.", + Type: []string{"integer"}, + Format: "int32", + }, + }, + }, + }, + }, + Dependencies: []string{ + v1.DownwardAPIVolumeFile{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_EmptyDirVolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "Represents an empty directory for a pod. Empty directory volumes support ownership management and SELinux relabeling.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "medium": { + SchemaProps: spec.SchemaProps{ + Description: "medium represents what type of storage medium should back this directory. The default is \"\" which means to use the node's default medium. Must be an empty string (default) or Memory. More info: https://kubernetes.io/docs/concepts/storage/volumes#emptydir", + Type: []string{"string"}, + Format: "", + }, + }, + "sizeLimit": { + SchemaProps: spec.SchemaProps{ + Description: "sizeLimit is the total amount of local storage required for this EmptyDir volume. The size limit is also applicable for memory medium. The maximum usage on memory medium EmptyDir would be the minimum value between the SizeLimit specified here and the sum of memory limits of all containers in a pod. The default is nil which means that the limit is undefined. More info: https://kubernetes.io/docs/concepts/storage/volumes#emptydir", + Ref: ref(resource.Quantity{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + Dependencies: []string{ + resource.Quantity{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_EndpointAddress(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "EndpointAddress is a tuple that describes single IP address. Deprecated: This API is deprecated in v1.33+.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "ip": { + SchemaProps: spec.SchemaProps{ + Description: "The IP of this endpoint. May not be loopback (127.0.0.0/8 or ::1), link-local (169.254.0.0/16 or fe80::/10), or link-local multicast (224.0.0.0/24 or ff02::/16).", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "hostname": { + SchemaProps: spec.SchemaProps{ + Description: "The Hostname of this endpoint", + Type: []string{"string"}, + Format: "", + }, + }, + "nodeName": { + SchemaProps: spec.SchemaProps{ + Description: "Optional: Node hosting this endpoint. This can be used to determine endpoints local to a node.", + Type: []string{"string"}, + Format: "", + }, + }, + "targetRef": { + SchemaProps: spec.SchemaProps{ + Description: "Reference to object providing the endpoint.", + Ref: ref(v1.ObjectReference{}.OpenAPIModelName()), + }, + }, + }, + Required: []string{"ip"}, + }, + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-map-type": "atomic", + }, + }, + }, + Dependencies: []string{ + v1.ObjectReference{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_EndpointPort(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "EndpointPort is a tuple that describes a single port. Deprecated: This API is deprecated in v1.33+.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "name": { + SchemaProps: spec.SchemaProps{ + Description: "The name of this port. This must match the 'name' field in the corresponding ServicePort. Must be a DNS_LABEL. Optional only if one port is defined.", + Type: []string{"string"}, + Format: "", + }, + }, + "port": { + SchemaProps: spec.SchemaProps{ + Description: "The port number of the endpoint.", + Default: 0, + Type: []string{"integer"}, + Format: "int32", + }, + }, + "protocol": { + SchemaProps: spec.SchemaProps{ + Description: "The IP protocol for this port. Must be UDP, TCP, or SCTP. Default is TCP.\n\nPossible enum values:\n - `\"SCTP\"` is the SCTP protocol.\n - `\"TCP\"` is the TCP protocol.\n - `\"UDP\"` is the UDP protocol.", + Type: []string{"string"}, + Format: "", + Enum: []interface{}{"SCTP", "TCP", "UDP"}, + }, + }, + "appProtocol": { + SchemaProps: spec.SchemaProps{ + Description: "The application protocol for this port. This is used as a hint for implementations to offer richer behavior for protocols that they understand. This field follows standard Kubernetes label syntax. Valid values are either:\n\n* Un-prefixed protocol names - reserved for IANA standard service names (as per RFC-6335 and https://www.iana.org/assignments/service-names).\n\n* Kubernetes-defined prefixed names:\n * 'kubernetes.io/h2c' - HTTP/2 prior knowledge over cleartext as described in https://www.rfc-editor.org/rfc/rfc9113.html#name-starting-http-2-with-prior-\n * 'kubernetes.io/ws' - WebSocket over cleartext as described in https://www.rfc-editor.org/rfc/rfc6455\n * 'kubernetes.io/wss' - WebSocket over TLS as described in https://www.rfc-editor.org/rfc/rfc6455\n\n* Other protocols should use implementation-defined prefixed names such as mycompany.com/my-custom-protocol.", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"port"}, + }, + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-map-type": "atomic", + }, + }, + }, + } +} + +func schema_k8sio_api_core_v1_EndpointSubset(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "EndpointSubset is a group of addresses with a common set of ports. The expanded set of endpoints is the Cartesian product of Addresses x Ports. For example, given:\n\n\t{\n\t Addresses: [{\"ip\": \"10.10.1.1\"}, {\"ip\": \"10.10.2.2\"}],\n\t Ports: [{\"name\": \"a\", \"port\": 8675}, {\"name\": \"b\", \"port\": 309}]\n\t}\n\nThe resulting set of endpoints can be viewed as:\n\n\ta: [ 10.10.1.1:8675, 10.10.2.2:8675 ],\n\tb: [ 10.10.1.1:309, 10.10.2.2:309 ]\n\nDeprecated: This API is deprecated in v1.33+.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "addresses": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "IP addresses which offer the related ports that are marked as ready. These endpoints should be considered safe for load balancers and clients to utilize.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.EndpointAddress{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "notReadyAddresses": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "IP addresses which offer the related ports but are not currently marked as ready because they have not yet finished starting, have recently failed a readiness check, or have recently failed a liveness check.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.EndpointAddress{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "ports": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "Port numbers available on the related IP addresses.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.EndpointPort{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + }, + }, + }, + Dependencies: []string{ + v1.EndpointAddress{}.OpenAPIModelName(), v1.EndpointPort{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_Endpoints(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "Endpoints is a collection of endpoints that implement the actual service. Example:\n\n\t Name: \"mysvc\",\n\t Subsets: [\n\t {\n\t Addresses: [{\"ip\": \"10.10.1.1\"}, {\"ip\": \"10.10.2.2\"}],\n\t Ports: [{\"name\": \"a\", \"port\": 8675}, {\"name\": \"b\", \"port\": 309}]\n\t },\n\t {\n\t Addresses: [{\"ip\": \"10.10.3.3\"}],\n\t Ports: [{\"name\": \"a\", \"port\": 93}, {\"name\": \"b\", \"port\": 76}]\n\t },\n\t]\n\nEndpoints is a legacy API and does not contain information about all Service features. Use discoveryv1.EndpointSlice for complete information about Service endpoints.\n\nDeprecated: This API is deprecated in v1.33+. Use discoveryv1.EndpointSlice.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "metadata": { + SchemaProps: spec.SchemaProps{ + Description: "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata", + Default: map[string]interface{}{}, + Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), + }, + }, + "subsets": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "The set of all endpoints is the union of all subsets. Addresses are placed into subsets according to the IPs they share. A single address with multiple ports, some of which are ready and some of which are not (because they come from different containers) will result in the address being displayed in different subsets for the different ports. No address will appear in both Addresses and NotReadyAddresses in the same subset. Sets of addresses and ports that comprise a service.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.EndpointSubset{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + }, + }, + }, + Dependencies: []string{ + v1.EndpointSubset{}.OpenAPIModelName(), metav1.ObjectMeta{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_EndpointsList(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "EndpointsList is a list of endpoints. Deprecated: This API is deprecated in v1.33+.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "metadata": { + SchemaProps: spec.SchemaProps{ + Description: "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Default: map[string]interface{}{}, + Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), + }, + }, + "items": { + SchemaProps: spec.SchemaProps{ + Description: "List of endpoints.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.Endpoints{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + }, + Required: []string{"items"}, + }, + }, + Dependencies: []string{ + v1.Endpoints{}.OpenAPIModelName(), metav1.ListMeta{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_EnvFromSource(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "EnvFromSource represents the source of a set of ConfigMaps or Secrets", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "prefix": { + SchemaProps: spec.SchemaProps{ + Description: "Optional text to prepend to the name of each environment variable. May consist of any printable ASCII characters except '='.", + Type: []string{"string"}, + Format: "", + }, + }, + "configMapRef": { + SchemaProps: spec.SchemaProps{ + Description: "The ConfigMap to select from", + Ref: ref(v1.ConfigMapEnvSource{}.OpenAPIModelName()), + }, + }, + "secretRef": { + SchemaProps: spec.SchemaProps{ + Description: "The Secret to select from", + Ref: ref(v1.SecretEnvSource{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + Dependencies: []string{ + v1.ConfigMapEnvSource{}.OpenAPIModelName(), v1.SecretEnvSource{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_EnvVar(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "EnvVar represents an environment variable present in a Container.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "name": { + SchemaProps: spec.SchemaProps{ + Description: "Name of the environment variable. May consist of any printable ASCII characters except '='.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "value": { + SchemaProps: spec.SchemaProps{ + Description: "Variable references $(VAR_NAME) are expanded using the previously defined environment variables in the container and any service environment variables. If a variable cannot be resolved, the reference in the input string will be unchanged. Double $$ are reduced to a single $, which allows for escaping the $(VAR_NAME) syntax: i.e. \"$$(VAR_NAME)\" will produce the string literal \"$(VAR_NAME)\". Escaped references will never be expanded, regardless of whether the variable exists or not. Defaults to \"\".", + Type: []string{"string"}, + Format: "", + }, + }, + "valueFrom": { + SchemaProps: spec.SchemaProps{ + Description: "Source for the environment variable's value. Cannot be used if value is not empty.", + Ref: ref(v1.EnvVarSource{}.OpenAPIModelName()), + }, + }, + }, + Required: []string{"name"}, + }, + }, + Dependencies: []string{ + v1.EnvVarSource{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_EnvVarSource(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "EnvVarSource represents a source for the value of an EnvVar.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "fieldRef": { + SchemaProps: spec.SchemaProps{ + Description: "Selects a field of the pod: supports metadata.name, metadata.namespace, `metadata.labels['']`, `metadata.annotations['']`, spec.nodeName, spec.serviceAccountName, status.hostIP, status.podIP, status.podIPs.", + Ref: ref(v1.ObjectFieldSelector{}.OpenAPIModelName()), + }, + }, + "resourceFieldRef": { + SchemaProps: spec.SchemaProps{ + Description: "Selects a resource of the container: only resources limits and requests (limits.cpu, limits.memory, limits.ephemeral-storage, requests.cpu, requests.memory and requests.ephemeral-storage) are currently supported.", + Ref: ref(v1.ResourceFieldSelector{}.OpenAPIModelName()), + }, + }, + "configMapKeyRef": { + SchemaProps: spec.SchemaProps{ + Description: "Selects a key of a ConfigMap.", + Ref: ref(v1.ConfigMapKeySelector{}.OpenAPIModelName()), + }, + }, + "secretKeyRef": { + SchemaProps: spec.SchemaProps{ + Description: "Selects a key of a secret in the pod's namespace", + Ref: ref(v1.SecretKeySelector{}.OpenAPIModelName()), + }, + }, + "fileKeyRef": { + SchemaProps: spec.SchemaProps{ + Description: "FileKeyRef selects a key of the env file. Requires the EnvFiles feature gate to be enabled.", + Ref: ref(v1.FileKeySelector{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + Dependencies: []string{ + v1.ConfigMapKeySelector{}.OpenAPIModelName(), v1.FileKeySelector{}.OpenAPIModelName(), v1.ObjectFieldSelector{}.OpenAPIModelName(), v1.ResourceFieldSelector{}.OpenAPIModelName(), v1.SecretKeySelector{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_EphemeralContainer(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "An EphemeralContainer is a temporary container that you may add to an existing Pod for user-initiated activities such as debugging. Ephemeral containers have no resource or scheduling guarantees, and they will not be restarted when they exit or when a Pod is removed or restarted. The kubelet may evict a Pod if an ephemeral container causes the Pod to exceed its resource allocation.\n\nTo add an ephemeral container, use the ephemeralcontainers subresource of an existing Pod. Ephemeral containers may not be removed or restarted.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "name": { + SchemaProps: spec.SchemaProps{ + Description: "Name of the ephemeral container specified as a DNS_LABEL. This name must be unique among all containers, init containers and ephemeral containers.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "image": { + SchemaProps: spec.SchemaProps{ + Description: "Container image name. More info: https://kubernetes.io/docs/concepts/containers/images", + Type: []string{"string"}, + Format: "", + }, + }, + "command": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "Entrypoint array. Not executed within a shell. The image's ENTRYPOINT is used if this is not provided. Variable references $(VAR_NAME) are expanded using the container's environment. If a variable cannot be resolved, the reference in the input string will be unchanged. Double $$ are reduced to a single $, which allows for escaping the $(VAR_NAME) syntax: i.e. \"$$(VAR_NAME)\" will produce the string literal \"$(VAR_NAME)\". Escaped references will never be expanded, regardless of whether the variable exists or not. Cannot be updated. More info: https://kubernetes.io/docs/tasks/inject-data-application/define-command-argument-container/#running-a-command-in-a-shell", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + "args": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "Arguments to the entrypoint. The image's CMD is used if this is not provided. Variable references $(VAR_NAME) are expanded using the container's environment. If a variable cannot be resolved, the reference in the input string will be unchanged. Double $$ are reduced to a single $, which allows for escaping the $(VAR_NAME) syntax: i.e. \"$$(VAR_NAME)\" will produce the string literal \"$(VAR_NAME)\". Escaped references will never be expanded, regardless of whether the variable exists or not. Cannot be updated. More info: https://kubernetes.io/docs/tasks/inject-data-application/define-command-argument-container/#running-a-command-in-a-shell", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + "workingDir": { + SchemaProps: spec.SchemaProps{ + Description: "Container's working directory. If not specified, the container runtime's default will be used, which might be configured in the container image. Cannot be updated.", + Type: []string{"string"}, + Format: "", + }, + }, + "ports": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-map-keys": []interface{}{ + "containerPort", + "protocol", + }, + "x-kubernetes-list-type": "map", + "x-kubernetes-patch-merge-key": "containerPort", + "x-kubernetes-patch-strategy": "merge", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "Ports are not allowed for ephemeral containers.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.ContainerPort{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "envFrom": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "List of sources to populate environment variables in the container. The keys defined within a source may consist of any printable ASCII characters except '='. When a key exists in multiple sources, the value associated with the last source will take precedence. Values defined by an Env with a duplicate key will take precedence. Cannot be updated.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.EnvFromSource{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "env": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-map-keys": []interface{}{ + "name", + }, + "x-kubernetes-list-type": "map", + "x-kubernetes-patch-merge-key": "name", + "x-kubernetes-patch-strategy": "merge", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "List of environment variables to set in the container. Cannot be updated.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.EnvVar{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "resources": { + SchemaProps: spec.SchemaProps{ + Description: "Resources are not allowed for ephemeral containers. Ephemeral containers use spare resources already allocated to the pod.", + Default: map[string]interface{}{}, + Ref: ref(v1.ResourceRequirements{}.OpenAPIModelName()), + }, + }, + "resizePolicy": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "Resources resize policy for the container.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.ContainerResizePolicy{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "restartPolicy": { + SchemaProps: spec.SchemaProps{ + Description: "Restart policy for the container to manage the restart behavior of each container within a pod. You cannot set this field on ephemeral containers.", + Type: []string{"string"}, + Format: "", + }, + }, + "restartPolicyRules": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "Represents a list of rules to be checked to determine if the container should be restarted on exit. You cannot set this field on ephemeral containers.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.ContainerRestartRule{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "volumeMounts": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-map-keys": []interface{}{ + "mountPath", + }, + "x-kubernetes-list-type": "map", + "x-kubernetes-patch-merge-key": "mountPath", + "x-kubernetes-patch-strategy": "merge", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "Pod volumes to mount into the container's filesystem. Subpath mounts are not allowed for ephemeral containers. Cannot be updated.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.VolumeMount{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "volumeDevices": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-map-keys": []interface{}{ + "devicePath", + }, + "x-kubernetes-list-type": "map", + "x-kubernetes-patch-merge-key": "devicePath", + "x-kubernetes-patch-strategy": "merge", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "volumeDevices is the list of block devices to be used by the container.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.VolumeDevice{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "livenessProbe": { + SchemaProps: spec.SchemaProps{ + Description: "Probes are not allowed for ephemeral containers.", + Ref: ref(v1.Probe{}.OpenAPIModelName()), + }, + }, + "readinessProbe": { + SchemaProps: spec.SchemaProps{ + Description: "Probes are not allowed for ephemeral containers.", + Ref: ref(v1.Probe{}.OpenAPIModelName()), + }, + }, + "startupProbe": { + SchemaProps: spec.SchemaProps{ + Description: "Probes are not allowed for ephemeral containers.", + Ref: ref(v1.Probe{}.OpenAPIModelName()), + }, + }, + "lifecycle": { + SchemaProps: spec.SchemaProps{ + Description: "Lifecycle is not allowed for ephemeral containers.", + Ref: ref(v1.Lifecycle{}.OpenAPIModelName()), + }, + }, + "terminationMessagePath": { + SchemaProps: spec.SchemaProps{ + Description: "Optional: Path at which the file to which the container's termination message will be written is mounted into the container's filesystem. Message written is intended to be brief final status, such as an assertion failure message. Will be truncated by the node if greater than 4096 bytes. The total message length across all containers will be limited to 12kb. Defaults to /dev/termination-log. Cannot be updated.", + Type: []string{"string"}, + Format: "", + }, + }, + "terminationMessagePolicy": { + SchemaProps: spec.SchemaProps{ + Description: "Indicate how the termination message should be populated. File will use the contents of terminationMessagePath to populate the container status message on both success and failure. FallbackToLogsOnError will use the last chunk of container log output if the termination message file is empty and the container exited with an error. The log output is limited to 2048 bytes or 80 lines, whichever is smaller. Defaults to File. Cannot be updated.\n\nPossible enum values:\n - `\"FallbackToLogsOnError\"` will read the most recent contents of the container logs for the container status message when the container exits with an error and the terminationMessagePath has no contents.\n - `\"File\"` is the default behavior and will set the container status message to the contents of the container's terminationMessagePath when the container exits.", + Type: []string{"string"}, + Format: "", + Enum: []interface{}{"FallbackToLogsOnError", "File"}, + }, + }, + "imagePullPolicy": { + SchemaProps: spec.SchemaProps{ + Description: "Image pull policy. One of Always, Never, IfNotPresent. Defaults to Always if :latest tag is specified, or IfNotPresent otherwise. Cannot be updated. More info: https://kubernetes.io/docs/concepts/containers/images#updating-images\n\nPossible enum values:\n - `\"Always\"` means that kubelet always attempts to pull the latest image. Container will fail If the pull fails.\n - `\"IfNotPresent\"` means that kubelet pulls if the image isn't present on disk. Container will fail if the image isn't present and the pull fails.\n - `\"Never\"` means that kubelet never pulls an image, but only uses a local image. Container will fail if the image isn't present", + Type: []string{"string"}, + Format: "", + Enum: []interface{}{"Always", "IfNotPresent", "Never"}, + }, + }, + "securityContext": { + SchemaProps: spec.SchemaProps{ + Description: "Optional: SecurityContext defines the security options the ephemeral container should be run with. If set, the fields of SecurityContext override the equivalent fields of PodSecurityContext.", + Ref: ref(v1.SecurityContext{}.OpenAPIModelName()), + }, + }, + "stdin": { + SchemaProps: spec.SchemaProps{ + Description: "Whether this container should allocate a buffer for stdin in the container runtime. If this is not set, reads from stdin in the container will always result in EOF. Default is false.", + Type: []string{"boolean"}, + Format: "", + }, + }, + "stdinOnce": { + SchemaProps: spec.SchemaProps{ + Description: "Whether the container runtime should close the stdin channel after it has been opened by a single attach. When stdin is true the stdin stream will remain open across multiple attach sessions. If stdinOnce is set to true, stdin is opened on container start, is empty until the first client attaches to stdin, and then remains open and accepts data until the client disconnects, at which time stdin is closed and remains closed until the container is restarted. If this flag is false, a container processes that reads from stdin will never receive an EOF. Default is false", + Type: []string{"boolean"}, + Format: "", + }, + }, + "tty": { + SchemaProps: spec.SchemaProps{ + Description: "Whether this container should allocate a TTY for itself, also requires 'stdin' to be true. Default is false.", + Type: []string{"boolean"}, + Format: "", + }, + }, + "targetContainerName": { + SchemaProps: spec.SchemaProps{ + Description: "If set, the name of the container from PodSpec that this ephemeral container targets. The ephemeral container will be run in the namespaces (IPC, PID, etc) of this container. If not set then the ephemeral container uses the namespaces configured in the Pod spec.\n\nThe container runtime must implement support for this feature. If the runtime does not support namespace targeting then the result of setting this field is undefined.", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"name"}, + }, + }, + Dependencies: []string{ + v1.ContainerPort{}.OpenAPIModelName(), v1.ContainerResizePolicy{}.OpenAPIModelName(), v1.ContainerRestartRule{}.OpenAPIModelName(), v1.EnvFromSource{}.OpenAPIModelName(), v1.EnvVar{}.OpenAPIModelName(), v1.Lifecycle{}.OpenAPIModelName(), v1.Probe{}.OpenAPIModelName(), v1.ResourceRequirements{}.OpenAPIModelName(), v1.SecurityContext{}.OpenAPIModelName(), v1.VolumeDevice{}.OpenAPIModelName(), v1.VolumeMount{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_EphemeralContainerCommon(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "EphemeralContainerCommon is a copy of all fields in Container to be inlined in EphemeralContainer. This separate type allows easy conversion from EphemeralContainer to Container and allows separate documentation for the fields of EphemeralContainer. When a new field is added to Container it must be added here as well.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "name": { + SchemaProps: spec.SchemaProps{ + Description: "Name of the ephemeral container specified as a DNS_LABEL. This name must be unique among all containers, init containers and ephemeral containers.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "image": { + SchemaProps: spec.SchemaProps{ + Description: "Container image name. More info: https://kubernetes.io/docs/concepts/containers/images", + Type: []string{"string"}, + Format: "", + }, + }, + "command": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "Entrypoint array. Not executed within a shell. The image's ENTRYPOINT is used if this is not provided. Variable references $(VAR_NAME) are expanded using the container's environment. If a variable cannot be resolved, the reference in the input string will be unchanged. Double $$ are reduced to a single $, which allows for escaping the $(VAR_NAME) syntax: i.e. \"$$(VAR_NAME)\" will produce the string literal \"$(VAR_NAME)\". Escaped references will never be expanded, regardless of whether the variable exists or not. Cannot be updated. More info: https://kubernetes.io/docs/tasks/inject-data-application/define-command-argument-container/#running-a-command-in-a-shell", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + "args": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "Arguments to the entrypoint. The image's CMD is used if this is not provided. Variable references $(VAR_NAME) are expanded using the container's environment. If a variable cannot be resolved, the reference in the input string will be unchanged. Double $$ are reduced to a single $, which allows for escaping the $(VAR_NAME) syntax: i.e. \"$$(VAR_NAME)\" will produce the string literal \"$(VAR_NAME)\". Escaped references will never be expanded, regardless of whether the variable exists or not. Cannot be updated. More info: https://kubernetes.io/docs/tasks/inject-data-application/define-command-argument-container/#running-a-command-in-a-shell", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + "workingDir": { + SchemaProps: spec.SchemaProps{ + Description: "Container's working directory. If not specified, the container runtime's default will be used, which might be configured in the container image. Cannot be updated.", + Type: []string{"string"}, + Format: "", + }, + }, + "ports": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-map-keys": []interface{}{ + "containerPort", + "protocol", + }, + "x-kubernetes-list-type": "map", + "x-kubernetes-patch-merge-key": "containerPort", + "x-kubernetes-patch-strategy": "merge", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "Ports are not allowed for ephemeral containers.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.ContainerPort{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "envFrom": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "List of sources to populate environment variables in the container. The keys defined within a source may consist of any printable ASCII characters except '='. When a key exists in multiple sources, the value associated with the last source will take precedence. Values defined by an Env with a duplicate key will take precedence. Cannot be updated.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.EnvFromSource{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "env": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-map-keys": []interface{}{ + "name", + }, + "x-kubernetes-list-type": "map", + "x-kubernetes-patch-merge-key": "name", + "x-kubernetes-patch-strategy": "merge", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "List of environment variables to set in the container. Cannot be updated.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.EnvVar{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "resources": { + SchemaProps: spec.SchemaProps{ + Description: "Resources are not allowed for ephemeral containers. Ephemeral containers use spare resources already allocated to the pod.", + Default: map[string]interface{}{}, + Ref: ref(v1.ResourceRequirements{}.OpenAPIModelName()), + }, + }, + "resizePolicy": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "Resources resize policy for the container.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.ContainerResizePolicy{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "restartPolicy": { + SchemaProps: spec.SchemaProps{ + Description: "Restart policy for the container to manage the restart behavior of each container within a pod. You cannot set this field on ephemeral containers.", + Type: []string{"string"}, + Format: "", + }, + }, + "restartPolicyRules": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "Represents a list of rules to be checked to determine if the container should be restarted on exit. You cannot set this field on ephemeral containers.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.ContainerRestartRule{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "volumeMounts": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-map-keys": []interface{}{ + "mountPath", + }, + "x-kubernetes-list-type": "map", + "x-kubernetes-patch-merge-key": "mountPath", + "x-kubernetes-patch-strategy": "merge", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "Pod volumes to mount into the container's filesystem. Subpath mounts are not allowed for ephemeral containers. Cannot be updated.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.VolumeMount{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "volumeDevices": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-map-keys": []interface{}{ + "devicePath", + }, + "x-kubernetes-list-type": "map", + "x-kubernetes-patch-merge-key": "devicePath", + "x-kubernetes-patch-strategy": "merge", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "volumeDevices is the list of block devices to be used by the container.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.VolumeDevice{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "livenessProbe": { + SchemaProps: spec.SchemaProps{ + Description: "Probes are not allowed for ephemeral containers.", + Ref: ref(v1.Probe{}.OpenAPIModelName()), + }, + }, + "readinessProbe": { + SchemaProps: spec.SchemaProps{ + Description: "Probes are not allowed for ephemeral containers.", + Ref: ref(v1.Probe{}.OpenAPIModelName()), + }, + }, + "startupProbe": { + SchemaProps: spec.SchemaProps{ + Description: "Probes are not allowed for ephemeral containers.", + Ref: ref(v1.Probe{}.OpenAPIModelName()), + }, + }, + "lifecycle": { + SchemaProps: spec.SchemaProps{ + Description: "Lifecycle is not allowed for ephemeral containers.", + Ref: ref(v1.Lifecycle{}.OpenAPIModelName()), + }, + }, + "terminationMessagePath": { + SchemaProps: spec.SchemaProps{ + Description: "Optional: Path at which the file to which the container's termination message will be written is mounted into the container's filesystem. Message written is intended to be brief final status, such as an assertion failure message. Will be truncated by the node if greater than 4096 bytes. The total message length across all containers will be limited to 12kb. Defaults to /dev/termination-log. Cannot be updated.", + Type: []string{"string"}, + Format: "", + }, + }, + "terminationMessagePolicy": { + SchemaProps: spec.SchemaProps{ + Description: "Indicate how the termination message should be populated. File will use the contents of terminationMessagePath to populate the container status message on both success and failure. FallbackToLogsOnError will use the last chunk of container log output if the termination message file is empty and the container exited with an error. The log output is limited to 2048 bytes or 80 lines, whichever is smaller. Defaults to File. Cannot be updated.\n\nPossible enum values:\n - `\"FallbackToLogsOnError\"` will read the most recent contents of the container logs for the container status message when the container exits with an error and the terminationMessagePath has no contents.\n - `\"File\"` is the default behavior and will set the container status message to the contents of the container's terminationMessagePath when the container exits.", + Type: []string{"string"}, + Format: "", + Enum: []interface{}{"FallbackToLogsOnError", "File"}, + }, + }, + "imagePullPolicy": { + SchemaProps: spec.SchemaProps{ + Description: "Image pull policy. One of Always, Never, IfNotPresent. Defaults to Always if :latest tag is specified, or IfNotPresent otherwise. Cannot be updated. More info: https://kubernetes.io/docs/concepts/containers/images#updating-images\n\nPossible enum values:\n - `\"Always\"` means that kubelet always attempts to pull the latest image. Container will fail If the pull fails.\n - `\"IfNotPresent\"` means that kubelet pulls if the image isn't present on disk. Container will fail if the image isn't present and the pull fails.\n - `\"Never\"` means that kubelet never pulls an image, but only uses a local image. Container will fail if the image isn't present", + Type: []string{"string"}, + Format: "", + Enum: []interface{}{"Always", "IfNotPresent", "Never"}, + }, + }, + "securityContext": { + SchemaProps: spec.SchemaProps{ + Description: "Optional: SecurityContext defines the security options the ephemeral container should be run with. If set, the fields of SecurityContext override the equivalent fields of PodSecurityContext.", + Ref: ref(v1.SecurityContext{}.OpenAPIModelName()), + }, + }, + "stdin": { + SchemaProps: spec.SchemaProps{ + Description: "Whether this container should allocate a buffer for stdin in the container runtime. If this is not set, reads from stdin in the container will always result in EOF. Default is false.", + Type: []string{"boolean"}, + Format: "", + }, + }, + "stdinOnce": { + SchemaProps: spec.SchemaProps{ + Description: "Whether the container runtime should close the stdin channel after it has been opened by a single attach. When stdin is true the stdin stream will remain open across multiple attach sessions. If stdinOnce is set to true, stdin is opened on container start, is empty until the first client attaches to stdin, and then remains open and accepts data until the client disconnects, at which time stdin is closed and remains closed until the container is restarted. If this flag is false, a container processes that reads from stdin will never receive an EOF. Default is false", + Type: []string{"boolean"}, + Format: "", + }, + }, + "tty": { + SchemaProps: spec.SchemaProps{ + Description: "Whether this container should allocate a TTY for itself, also requires 'stdin' to be true. Default is false.", + Type: []string{"boolean"}, + Format: "", + }, + }, + }, + Required: []string{"name"}, + }, + }, + Dependencies: []string{ + v1.ContainerPort{}.OpenAPIModelName(), v1.ContainerResizePolicy{}.OpenAPIModelName(), v1.ContainerRestartRule{}.OpenAPIModelName(), v1.EnvFromSource{}.OpenAPIModelName(), v1.EnvVar{}.OpenAPIModelName(), v1.Lifecycle{}.OpenAPIModelName(), v1.Probe{}.OpenAPIModelName(), v1.ResourceRequirements{}.OpenAPIModelName(), v1.SecurityContext{}.OpenAPIModelName(), v1.VolumeDevice{}.OpenAPIModelName(), v1.VolumeMount{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_EphemeralVolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "Represents an ephemeral volume that is handled by a normal storage driver.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "volumeClaimTemplate": { + SchemaProps: spec.SchemaProps{ + Description: "Will be used to create a stand-alone PVC to provision the volume. The pod in which this EphemeralVolumeSource is embedded will be the owner of the PVC, i.e. the PVC will be deleted together with the pod. The name of the PVC will be `-` where `` is the name from the `PodSpec.Volumes` array entry. Pod validation will reject the pod if the concatenated name is not valid for a PVC (for example, too long).\n\nAn existing PVC with that name that is not owned by the pod will *not* be used for the pod to avoid using an unrelated volume by mistake. Starting the pod is then blocked until the unrelated PVC is removed. If such a pre-created PVC is meant to be used by the pod, the PVC has to updated with an owner reference to the pod once the pod exists. Normally this should not be necessary, but it may be useful when manually reconstructing a broken cluster.\n\nThis field is read-only and no changes will be made by Kubernetes to the PVC after it has been created.\n\nRequired, must not be nil.", + Ref: ref(v1.PersistentVolumeClaimTemplate{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + Dependencies: []string{ + v1.PersistentVolumeClaimTemplate{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_Event(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "Event is a report of an event somewhere in the cluster. Events have a limited retention time and triggers and messages may evolve with time. Event consumers should not rely on the timing of an event with a given Reason reflecting a consistent underlying trigger, or the continued existence of events with that Reason. Events should be treated as informative, best-effort, supplemental data.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "metadata": { + SchemaProps: spec.SchemaProps{ + Description: "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata", + Default: map[string]interface{}{}, + Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), + }, + }, + "involvedObject": { + SchemaProps: spec.SchemaProps{ + Description: "The object that this event is about.", + Default: map[string]interface{}{}, + Ref: ref(v1.ObjectReference{}.OpenAPIModelName()), + }, + }, + "reason": { + SchemaProps: spec.SchemaProps{ + Description: "This should be a short, machine understandable string that gives the reason for the transition into the object's current status.", + Type: []string{"string"}, + Format: "", + }, + }, + "message": { + SchemaProps: spec.SchemaProps{ + Description: "A human-readable description of the status of this operation.", + Type: []string{"string"}, + Format: "", + }, + }, + "source": { + SchemaProps: spec.SchemaProps{ + Description: "The component reporting this event. Should be a short machine understandable string.", + Default: map[string]interface{}{}, + Ref: ref(v1.EventSource{}.OpenAPIModelName()), + }, + }, + "firstTimestamp": { + SchemaProps: spec.SchemaProps{ + Description: "The time at which the event was first recorded. (Time of server receipt is in TypeMeta.)", + Ref: ref(metav1.Time{}.OpenAPIModelName()), + }, + }, + "lastTimestamp": { + SchemaProps: spec.SchemaProps{ + Description: "The time at which the most recent occurrence of this event was recorded.", + Ref: ref(metav1.Time{}.OpenAPIModelName()), + }, + }, + "count": { + SchemaProps: spec.SchemaProps{ + Description: "The number of times this event has occurred.", + Type: []string{"integer"}, + Format: "int32", + }, + }, + "type": { + SchemaProps: spec.SchemaProps{ + Description: "Type of this event (Normal, Warning), new types could be added in the future", + Type: []string{"string"}, + Format: "", + }, + }, + "eventTime": { + SchemaProps: spec.SchemaProps{ + Description: "Time when this Event was first observed.", + Ref: ref(metav1.MicroTime{}.OpenAPIModelName()), + }, + }, + "series": { + SchemaProps: spec.SchemaProps{ + Description: "Data about the Event series this event represents or nil if it's a singleton Event.", + Ref: ref(v1.EventSeries{}.OpenAPIModelName()), + }, + }, + "action": { + SchemaProps: spec.SchemaProps{ + Description: "What action was taken/failed regarding to the Regarding object.", + Type: []string{"string"}, + Format: "", + }, + }, + "related": { + SchemaProps: spec.SchemaProps{ + Description: "Optional secondary object for more complex actions.", + Ref: ref(v1.ObjectReference{}.OpenAPIModelName()), + }, + }, + "reportingComponent": { + SchemaProps: spec.SchemaProps{ + Description: "Name of the controller that emitted this Event, e.g. `kubernetes.io/kubelet`.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "reportingInstance": { + SchemaProps: spec.SchemaProps{ + Description: "ID of the controller instance, e.g. `kubelet-xyzf`.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"metadata", "involvedObject"}, + }, + }, + Dependencies: []string{ + v1.EventSeries{}.OpenAPIModelName(), v1.EventSource{}.OpenAPIModelName(), v1.ObjectReference{}.OpenAPIModelName(), metav1.MicroTime{}.OpenAPIModelName(), metav1.ObjectMeta{}.OpenAPIModelName(), metav1.Time{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_EventList(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "EventList is a list of events.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "metadata": { + SchemaProps: spec.SchemaProps{ + Description: "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Default: map[string]interface{}{}, + Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), + }, + }, + "items": { + SchemaProps: spec.SchemaProps{ + Description: "List of events", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.Event{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + }, + Required: []string{"items"}, + }, + }, + Dependencies: []string{ + v1.Event{}.OpenAPIModelName(), metav1.ListMeta{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_EventSeries(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "EventSeries contain information on series of events, i.e. thing that was/is happening continuously for some time.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "count": { + SchemaProps: spec.SchemaProps{ + Description: "Number of occurrences in this series up to the last heartbeat time", + Type: []string{"integer"}, + Format: "int32", + }, + }, + "lastObservedTime": { + SchemaProps: spec.SchemaProps{ + Description: "Time of the last occurrence observed", + Ref: ref(metav1.MicroTime{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + Dependencies: []string{ + metav1.MicroTime{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_EventSource(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "EventSource contains information for an event.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "component": { + SchemaProps: spec.SchemaProps{ + Description: "Component from which the event is generated.", + Type: []string{"string"}, + Format: "", + }, + }, + "host": { + SchemaProps: spec.SchemaProps{ + Description: "Node name on which the event is generated.", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + } +} + +func schema_k8sio_api_core_v1_ExecAction(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "ExecAction describes a \"run in container\" action.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "command": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "Command is the command line to execute inside the container, the working directory for the command is root ('/') in the container's filesystem. The command is simply exec'd, it is not run inside a shell, so traditional shell instructions ('|', etc) won't work. To use a shell, you need to explicitly call out to that shell. Exit status of 0 is treated as live/healthy and non-zero is unhealthy.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + }, + }, + }, + } +} + +func schema_k8sio_api_core_v1_FCVolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "Represents a Fibre Channel volume. Fibre Channel volumes can only be mounted as read/write once. Fibre Channel volumes support ownership management and SELinux relabeling.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "targetWWNs": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "targetWWNs is Optional: FC target worldwide names (WWNs)", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + "lun": { + SchemaProps: spec.SchemaProps{ + Description: "lun is Optional: FC target lun number", + Type: []string{"integer"}, + Format: "int32", + }, + }, + "fsType": { + SchemaProps: spec.SchemaProps{ + Description: "fsType is the filesystem type to mount. Must be a filesystem type supported by the host operating system. Ex. \"ext4\", \"xfs\", \"ntfs\". Implicitly inferred to be \"ext4\" if unspecified.", + Type: []string{"string"}, + Format: "", + }, + }, + "readOnly": { + SchemaProps: spec.SchemaProps{ + Description: "readOnly is Optional: Defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts.", + Type: []string{"boolean"}, + Format: "", + }, + }, + "wwids": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "wwids Optional: FC volume world wide identifiers (wwids) Either wwids or combination of targetWWNs and lun must be set, but not both simultaneously.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + }, + }, + }, + } +} + +func schema_k8sio_api_core_v1_FileKeySelector(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "FileKeySelector selects a key of the env file.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "volumeName": { + SchemaProps: spec.SchemaProps{ + Description: "The name of the volume mount containing the env file.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "path": { + SchemaProps: spec.SchemaProps{ + Description: "The path within the volume from which to select the file. Must be relative and may not contain the '..' path or start with '..'.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "key": { + SchemaProps: spec.SchemaProps{ + Description: "The key within the env file. An invalid key will prevent the pod from starting. The keys defined within a source may consist of any printable ASCII characters except '='. During Alpha stage of the EnvFiles feature gate, the key size is limited to 128 characters.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "optional": { + SchemaProps: spec.SchemaProps{ + Description: "Specify whether the file or its key must be defined. If the file or key does not exist, then the env var is not published. If optional is set to true and the specified key does not exist, the environment variable will not be set in the Pod's containers.\n\nIf optional is set to false and the specified key does not exist, an error will be returned during Pod creation.", + Default: false, + Type: []string{"boolean"}, + Format: "", + }, + }, + }, + Required: []string{"volumeName", "path", "key"}, + }, + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-map-type": "atomic", + }, + }, + }, + } +} + +func schema_k8sio_api_core_v1_FlexPersistentVolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "FlexPersistentVolumeSource represents a generic persistent volume resource that is provisioned/attached using an exec based plugin.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "driver": { + SchemaProps: spec.SchemaProps{ + Description: "driver is the name of the driver to use for this volume.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "fsType": { + SchemaProps: spec.SchemaProps{ + Description: "fsType is the Filesystem type to mount. Must be a filesystem type supported by the host operating system. Ex. \"ext4\", \"xfs\", \"ntfs\". The default filesystem depends on FlexVolume script.", + Type: []string{"string"}, + Format: "", + }, + }, + "secretRef": { + SchemaProps: spec.SchemaProps{ + Description: "secretRef is Optional: SecretRef is reference to the secret object containing sensitive information to pass to the plugin scripts. This may be empty if no secret object is specified. If the secret object contains more than one secret, all secrets are passed to the plugin scripts.", + Ref: ref(v1.SecretReference{}.OpenAPIModelName()), + }, + }, + "readOnly": { + SchemaProps: spec.SchemaProps{ + Description: "readOnly is Optional: defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts.", + Type: []string{"boolean"}, + Format: "", + }, + }, + "options": { + SchemaProps: spec.SchemaProps{ + Description: "options is Optional: this field holds extra command options if any.", + Type: []string{"object"}, + AdditionalProperties: &spec.SchemaOrBool{ + Allows: true, + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + }, + Required: []string{"driver"}, + }, + }, + Dependencies: []string{ + v1.SecretReference{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_FlexVolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "FlexVolume represents a generic volume resource that is provisioned/attached using an exec based plugin.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "driver": { + SchemaProps: spec.SchemaProps{ + Description: "driver is the name of the driver to use for this volume.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "fsType": { + SchemaProps: spec.SchemaProps{ + Description: "fsType is the filesystem type to mount. Must be a filesystem type supported by the host operating system. Ex. \"ext4\", \"xfs\", \"ntfs\". The default filesystem depends on FlexVolume script.", + Type: []string{"string"}, + Format: "", + }, + }, + "secretRef": { + SchemaProps: spec.SchemaProps{ + Description: "secretRef is Optional: secretRef is reference to the secret object containing sensitive information to pass to the plugin scripts. This may be empty if no secret object is specified. If the secret object contains more than one secret, all secrets are passed to the plugin scripts.", + Ref: ref(v1.LocalObjectReference{}.OpenAPIModelName()), + }, + }, + "readOnly": { + SchemaProps: spec.SchemaProps{ + Description: "readOnly is Optional: defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts.", + Type: []string{"boolean"}, + Format: "", + }, + }, + "options": { + SchemaProps: spec.SchemaProps{ + Description: "options is Optional: this field holds extra command options if any.", + Type: []string{"object"}, + AdditionalProperties: &spec.SchemaOrBool{ + Allows: true, + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + }, + Required: []string{"driver"}, + }, + }, + Dependencies: []string{ + v1.LocalObjectReference{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_FlockerVolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "Represents a Flocker volume mounted by the Flocker agent. One and only one of datasetName and datasetUUID should be set. Flocker volumes do not support ownership management or SELinux relabeling.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "datasetName": { + SchemaProps: spec.SchemaProps{ + Description: "datasetName is Name of the dataset stored as metadata -> name on the dataset for Flocker should be considered as deprecated", + Type: []string{"string"}, + Format: "", + }, + }, + "datasetUUID": { + SchemaProps: spec.SchemaProps{ + Description: "datasetUUID is the UUID of the dataset. This is unique identifier of a Flocker dataset", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + } +} + +func schema_k8sio_api_core_v1_GCEPersistentDiskVolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "Represents a Persistent Disk resource in Google Compute Engine.\n\nA GCE PD must exist before mounting to a container. The disk must also be in the same GCE project and zone as the kubelet. A GCE PD can only be mounted as read/write once or read-only many times. GCE PDs support ownership management and SELinux relabeling.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "pdName": { + SchemaProps: spec.SchemaProps{ + Description: "pdName is unique name of the PD resource in GCE. Used to identify the disk in GCE. More info: https://kubernetes.io/docs/concepts/storage/volumes#gcepersistentdisk", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "fsType": { + SchemaProps: spec.SchemaProps{ + Description: "fsType is filesystem type of the volume that you want to mount. Tip: Ensure that the filesystem type is supported by the host operating system. Examples: \"ext4\", \"xfs\", \"ntfs\". Implicitly inferred to be \"ext4\" if unspecified. More info: https://kubernetes.io/docs/concepts/storage/volumes#gcepersistentdisk", + Type: []string{"string"}, + Format: "", + }, + }, + "partition": { + SchemaProps: spec.SchemaProps{ + Description: "partition is the partition in the volume that you want to mount. If omitted, the default is to mount by volume name. Examples: For volume /dev/sda1, you specify the partition as \"1\". Similarly, the volume partition for /dev/sda is \"0\" (or you can leave the property empty). More info: https://kubernetes.io/docs/concepts/storage/volumes#gcepersistentdisk", + Type: []string{"integer"}, + Format: "int32", + }, + }, + "readOnly": { + SchemaProps: spec.SchemaProps{ + Description: "readOnly here will force the ReadOnly setting in VolumeMounts. Defaults to false. More info: https://kubernetes.io/docs/concepts/storage/volumes#gcepersistentdisk", + Type: []string{"boolean"}, + Format: "", + }, + }, + }, + Required: []string{"pdName"}, + }, + }, + } +} + +func schema_k8sio_api_core_v1_GRPCAction(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "GRPCAction specifies an action involving a GRPC service.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "port": { + SchemaProps: spec.SchemaProps{ + Description: "Port number of the gRPC service. Number must be in the range 1 to 65535.", + Default: 0, + Type: []string{"integer"}, + Format: "int32", + }, + }, + "service": { + SchemaProps: spec.SchemaProps{ + Description: "Service is the name of the service to place in the gRPC HealthCheckRequest (see https://github.com/grpc/grpc/blob/master/doc/health-checking.md).\n\nIf this is not specified, the default behavior is defined by gRPC.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"port"}, + }, + }, + } +} + +func schema_k8sio_api_core_v1_GitRepoVolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "Represents a volume that is populated with the contents of a git repository. Git repo volumes do not support ownership management. Git repo volumes support SELinux relabeling.\n\nDEPRECATED: GitRepo is deprecated. To provision a container with a git repo, mount an EmptyDir into an InitContainer that clones the repo using git, then mount the EmptyDir into the Pod's container.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "repository": { + SchemaProps: spec.SchemaProps{ + Description: "repository is the URL", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "revision": { + SchemaProps: spec.SchemaProps{ + Description: "revision is the commit hash for the specified revision.", + Type: []string{"string"}, + Format: "", + }, + }, + "directory": { + SchemaProps: spec.SchemaProps{ + Description: "directory is the target directory name. Must not contain or start with '..'. If '.' is supplied, the volume directory will be the git repository. Otherwise, if specified, the volume will contain the git repository in the subdirectory with the given name.", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"repository"}, + }, + }, + } +} + +func schema_k8sio_api_core_v1_GlusterfsPersistentVolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "Represents a Glusterfs mount that lasts the lifetime of a pod. Glusterfs volumes do not support ownership management or SELinux relabeling.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "endpoints": { + SchemaProps: spec.SchemaProps{ + Description: "endpoints is the endpoint name that details Glusterfs topology. More info: https://examples.k8s.io/volumes/glusterfs/README.md#create-a-pod", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "path": { + SchemaProps: spec.SchemaProps{ + Description: "path is the Glusterfs volume path. More info: https://examples.k8s.io/volumes/glusterfs/README.md#create-a-pod", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "readOnly": { + SchemaProps: spec.SchemaProps{ + Description: "readOnly here will force the Glusterfs volume to be mounted with read-only permissions. Defaults to false. More info: https://examples.k8s.io/volumes/glusterfs/README.md#create-a-pod", + Type: []string{"boolean"}, + Format: "", + }, + }, + "endpointsNamespace": { + SchemaProps: spec.SchemaProps{ + Description: "endpointsNamespace is the namespace that contains Glusterfs endpoint. If this field is empty, the EndpointNamespace defaults to the same namespace as the bound PVC. More info: https://examples.k8s.io/volumes/glusterfs/README.md#create-a-pod", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"endpoints", "path"}, + }, + }, + } +} + +func schema_k8sio_api_core_v1_GlusterfsVolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "Represents a Glusterfs mount that lasts the lifetime of a pod. Glusterfs volumes do not support ownership management or SELinux relabeling.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "endpoints": { + SchemaProps: spec.SchemaProps{ + Description: "endpoints is the endpoint name that details Glusterfs topology.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "path": { + SchemaProps: spec.SchemaProps{ + Description: "path is the Glusterfs volume path. More info: https://examples.k8s.io/volumes/glusterfs/README.md#create-a-pod", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "readOnly": { + SchemaProps: spec.SchemaProps{ + Description: "readOnly here will force the Glusterfs volume to be mounted with read-only permissions. Defaults to false. More info: https://examples.k8s.io/volumes/glusterfs/README.md#create-a-pod", + Type: []string{"boolean"}, + Format: "", + }, + }, + }, + Required: []string{"endpoints", "path"}, + }, + }, + } +} + +func schema_k8sio_api_core_v1_HTTPGetAction(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "HTTPGetAction describes an action based on HTTP Get requests.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "path": { + SchemaProps: spec.SchemaProps{ + Description: "Path to access on the HTTP server.", + Type: []string{"string"}, + Format: "", + }, + }, + "port": { + SchemaProps: spec.SchemaProps{ + Description: "Name or number of the port to access on the container. Number must be in the range 1 to 65535. Name must be an IANA_SVC_NAME.", + Ref: ref("k8s.io/apimachinery/pkg/util/intstr.IntOrString"), + }, + }, + "host": { + SchemaProps: spec.SchemaProps{ + Description: "Host name to connect to, defaults to the pod IP. You probably want to set \"Host\" in httpHeaders instead.", + Type: []string{"string"}, + Format: "", + }, + }, + "scheme": { + SchemaProps: spec.SchemaProps{ + Description: "Scheme to use for connecting to the host. Defaults to HTTP.\n\nPossible enum values:\n - `\"HTTP\"` means that the scheme used will be http://\n - `\"HTTPS\"` means that the scheme used will be https://", + Type: []string{"string"}, + Format: "", + Enum: []interface{}{"HTTP", "HTTPS"}, + }, + }, + "httpHeaders": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "Custom headers to set in the request. HTTP allows repeated headers.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.HTTPHeader{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + }, + Required: []string{"port"}, + }, + }, + Dependencies: []string{ + v1.HTTPHeader{}.OpenAPIModelName(), "k8s.io/apimachinery/pkg/util/intstr.IntOrString"}, + } +} + +func schema_k8sio_api_core_v1_HTTPHeader(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "HTTPHeader describes a custom header to be used in HTTP probes", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "name": { + SchemaProps: spec.SchemaProps{ + Description: "The header field name. This will be canonicalized upon output, so case-variant names will be understood as the same header.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "value": { + SchemaProps: spec.SchemaProps{ + Description: "The header field value", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"name", "value"}, + }, + }, + } +} + +func schema_k8sio_api_core_v1_HostAlias(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "HostAlias holds the mapping between IP and hostnames that will be injected as an entry in the pod's hosts file.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "ip": { + SchemaProps: spec.SchemaProps{ + Description: "IP address of the host file entry.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "hostnames": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "Hostnames for the above IP address.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + }, + Required: []string{"ip"}, + }, + }, + } +} + +func schema_k8sio_api_core_v1_HostIP(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "HostIP represents a single IP address allocated to the host.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "ip": { + SchemaProps: spec.SchemaProps{ + Description: "IP is the IP address assigned to the host", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"ip"}, + }, + }, + } +} + +func schema_k8sio_api_core_v1_HostPathVolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "Represents a host path mapped into a pod. Host path volumes do not support ownership management or SELinux relabeling.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "path": { + SchemaProps: spec.SchemaProps{ + Description: "path of the directory on the host. If the path is a symlink, it will follow the link to the real path. More info: https://kubernetes.io/docs/concepts/storage/volumes#hostpath", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "type": { + SchemaProps: spec.SchemaProps{ + Description: "type for HostPath Volume Defaults to \"\" More info: https://kubernetes.io/docs/concepts/storage/volumes#hostpath\n\nPossible enum values:\n - `\"\"` For backwards compatible, leave it empty if unset\n - `\"BlockDevice\"` A block device must exist at the given path\n - `\"CharDevice\"` A character device must exist at the given path\n - `\"Directory\"` A directory must exist at the given path\n - `\"DirectoryOrCreate\"` If nothing exists at the given path, an empty directory will be created there as needed with file mode 0755, having the same group and ownership with Kubelet.\n - `\"File\"` A file must exist at the given path\n - `\"FileOrCreate\"` If nothing exists at the given path, an empty file will be created there as needed with file mode 0644, having the same group and ownership with Kubelet.\n - `\"Socket\"` A UNIX socket must exist at the given path", + Type: []string{"string"}, + Format: "", + Enum: []interface{}{"", "BlockDevice", "CharDevice", "Directory", "DirectoryOrCreate", "File", "FileOrCreate", "Socket"}, + }, + }, + }, + Required: []string{"path"}, + }, + }, + } +} + +func schema_k8sio_api_core_v1_ISCSIPersistentVolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "ISCSIPersistentVolumeSource represents an ISCSI disk. ISCSI volumes can only be mounted as read/write once. ISCSI volumes support ownership management and SELinux relabeling.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "targetPortal": { + SchemaProps: spec.SchemaProps{ + Description: "targetPortal is iSCSI Target Portal. The Portal is either an IP or ip_addr:port if the port is other than default (typically TCP ports 860 and 3260).", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "iqn": { + SchemaProps: spec.SchemaProps{ + Description: "iqn is Target iSCSI Qualified Name.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "lun": { + SchemaProps: spec.SchemaProps{ + Description: "lun is iSCSI Target Lun number.", + Default: 0, + Type: []string{"integer"}, + Format: "int32", + }, + }, + "iscsiInterface": { + SchemaProps: spec.SchemaProps{ + Description: "iscsiInterface is the interface Name that uses an iSCSI transport. Defaults to 'default' (tcp).", + Default: "default", + Type: []string{"string"}, + Format: "", + }, + }, + "fsType": { + SchemaProps: spec.SchemaProps{ + Description: "fsType is the filesystem type of the volume that you want to mount. Tip: Ensure that the filesystem type is supported by the host operating system. Examples: \"ext4\", \"xfs\", \"ntfs\". Implicitly inferred to be \"ext4\" if unspecified. More info: https://kubernetes.io/docs/concepts/storage/volumes#iscsi", + Type: []string{"string"}, + Format: "", + }, + }, + "readOnly": { + SchemaProps: spec.SchemaProps{ + Description: "readOnly here will force the ReadOnly setting in VolumeMounts. Defaults to false.", + Type: []string{"boolean"}, + Format: "", + }, + }, + "portals": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "portals is the iSCSI Target Portal List. The Portal is either an IP or ip_addr:port if the port is other than default (typically TCP ports 860 and 3260).", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + "chapAuthDiscovery": { + SchemaProps: spec.SchemaProps{ + Description: "chapAuthDiscovery defines whether support iSCSI Discovery CHAP authentication", + Type: []string{"boolean"}, + Format: "", + }, + }, + "chapAuthSession": { + SchemaProps: spec.SchemaProps{ + Description: "chapAuthSession defines whether support iSCSI Session CHAP authentication", + Type: []string{"boolean"}, + Format: "", + }, + }, + "secretRef": { + SchemaProps: spec.SchemaProps{ + Description: "secretRef is the CHAP Secret for iSCSI target and initiator authentication", + Ref: ref(v1.SecretReference{}.OpenAPIModelName()), + }, + }, + "initiatorName": { + SchemaProps: spec.SchemaProps{ + Description: "initiatorName is the custom iSCSI Initiator Name. If initiatorName is specified with iscsiInterface simultaneously, new iSCSI interface : will be created for the connection.", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"targetPortal", "iqn", "lun"}, + }, + }, + Dependencies: []string{ + v1.SecretReference{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_ISCSIVolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "Represents an ISCSI disk. ISCSI volumes can only be mounted as read/write once. ISCSI volumes support ownership management and SELinux relabeling.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "targetPortal": { + SchemaProps: spec.SchemaProps{ + Description: "targetPortal is iSCSI Target Portal. The Portal is either an IP or ip_addr:port if the port is other than default (typically TCP ports 860 and 3260).", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "iqn": { + SchemaProps: spec.SchemaProps{ + Description: "iqn is the target iSCSI Qualified Name.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "lun": { + SchemaProps: spec.SchemaProps{ + Description: "lun represents iSCSI Target Lun number.", + Default: 0, + Type: []string{"integer"}, + Format: "int32", + }, + }, + "iscsiInterface": { + SchemaProps: spec.SchemaProps{ + Description: "iscsiInterface is the interface Name that uses an iSCSI transport. Defaults to 'default' (tcp).", + Default: "default", + Type: []string{"string"}, + Format: "", + }, + }, + "fsType": { + SchemaProps: spec.SchemaProps{ + Description: "fsType is the filesystem type of the volume that you want to mount. Tip: Ensure that the filesystem type is supported by the host operating system. Examples: \"ext4\", \"xfs\", \"ntfs\". Implicitly inferred to be \"ext4\" if unspecified. More info: https://kubernetes.io/docs/concepts/storage/volumes#iscsi", + Type: []string{"string"}, + Format: "", + }, + }, + "readOnly": { + SchemaProps: spec.SchemaProps{ + Description: "readOnly here will force the ReadOnly setting in VolumeMounts. Defaults to false.", + Type: []string{"boolean"}, + Format: "", + }, + }, + "portals": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "portals is the iSCSI Target Portal List. The portal is either an IP or ip_addr:port if the port is other than default (typically TCP ports 860 and 3260).", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + "chapAuthDiscovery": { + SchemaProps: spec.SchemaProps{ + Description: "chapAuthDiscovery defines whether support iSCSI Discovery CHAP authentication", + Type: []string{"boolean"}, + Format: "", + }, + }, + "chapAuthSession": { + SchemaProps: spec.SchemaProps{ + Description: "chapAuthSession defines whether support iSCSI Session CHAP authentication", + Type: []string{"boolean"}, + Format: "", + }, + }, + "secretRef": { + SchemaProps: spec.SchemaProps{ + Description: "secretRef is the CHAP Secret for iSCSI target and initiator authentication", + Ref: ref(v1.LocalObjectReference{}.OpenAPIModelName()), + }, + }, + "initiatorName": { + SchemaProps: spec.SchemaProps{ + Description: "initiatorName is the custom iSCSI Initiator Name. If initiatorName is specified with iscsiInterface simultaneously, new iSCSI interface : will be created for the connection.", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"targetPortal", "iqn", "lun"}, + }, + }, + Dependencies: []string{ + v1.LocalObjectReference{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_ImageVolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "ImageVolumeSource represents a image volume resource.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "reference": { + SchemaProps: spec.SchemaProps{ + Description: "Required: Image or artifact reference to be used. Behaves in the same way as pod.spec.containers[*].image. Pull secrets will be assembled in the same way as for the container image by looking up node credentials, SA image pull secrets, and pod spec image pull secrets. More info: https://kubernetes.io/docs/concepts/containers/images This field is optional to allow higher level config management to default or override container images in workload controllers like Deployments and StatefulSets.", + Type: []string{"string"}, + Format: "", + }, + }, + "pullPolicy": { + SchemaProps: spec.SchemaProps{ + Description: "Policy for pulling OCI objects. Possible values are: Always: the kubelet always attempts to pull the reference. Container creation will fail If the pull fails. Never: the kubelet never pulls the reference and only uses a local image or artifact. Container creation will fail if the reference isn't present. IfNotPresent: the kubelet pulls if the reference isn't already present on disk. Container creation will fail if the reference isn't present and the pull fails. Defaults to Always if :latest tag is specified, or IfNotPresent otherwise.\n\nPossible enum values:\n - `\"Always\"` means that kubelet always attempts to pull the latest image. Container will fail If the pull fails.\n - `\"IfNotPresent\"` means that kubelet pulls if the image isn't present on disk. Container will fail if the image isn't present and the pull fails.\n - `\"Never\"` means that kubelet never pulls an image, but only uses a local image. Container will fail if the image isn't present", + Type: []string{"string"}, + Format: "", + Enum: []interface{}{"Always", "IfNotPresent", "Never"}, + }, + }, + }, + }, + }, + } +} + +func schema_k8sio_api_core_v1_KeyToPath(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "Maps a string key to a path within a volume.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "key": { + SchemaProps: spec.SchemaProps{ + Description: "key is the key to project.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "path": { + SchemaProps: spec.SchemaProps{ + Description: "path is the relative path of the file to map the key to. May not be an absolute path. May not contain the path element '..'. May not start with the string '..'.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "mode": { + SchemaProps: spec.SchemaProps{ + Description: "mode is Optional: mode bits used to set permissions on this file. Must be an octal value between 0000 and 0777 or a decimal value between 0 and 511. YAML accepts both octal and decimal values, JSON requires decimal values for mode bits. If not specified, the volume defaultMode will be used. This might be in conflict with other options that affect the file mode, like fsGroup, and the result can be other mode bits set.", + Type: []string{"integer"}, + Format: "int32", + }, + }, + }, + Required: []string{"key", "path"}, + }, + }, + } +} + +func schema_k8sio_api_core_v1_Lifecycle(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "Lifecycle describes actions that the management system should take in response to container lifecycle events. For the PostStart and PreStop lifecycle handlers, management of the container blocks until the action is complete, unless the container process fails, in which case the handler is aborted.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "postStart": { + SchemaProps: spec.SchemaProps{ + Description: "PostStart is called immediately after a container is created. If the handler fails, the container is terminated and restarted according to its restart policy. Other management of the container blocks until the hook completes. More info: https://kubernetes.io/docs/concepts/containers/container-lifecycle-hooks/#container-hooks", + Ref: ref(v1.LifecycleHandler{}.OpenAPIModelName()), + }, + }, + "preStop": { + SchemaProps: spec.SchemaProps{ + Description: "PreStop is called immediately before a container is terminated due to an API request or management event such as liveness/startup probe failure, preemption, resource contention, etc. The handler is not called if the container crashes or exits. The Pod's termination grace period countdown begins before the PreStop hook is executed. Regardless of the outcome of the handler, the container will eventually terminate within the Pod's termination grace period (unless delayed by finalizers). Other management of the container blocks until the hook completes or until the termination grace period is reached. More info: https://kubernetes.io/docs/concepts/containers/container-lifecycle-hooks/#container-hooks", + Ref: ref(v1.LifecycleHandler{}.OpenAPIModelName()), + }, + }, + "stopSignal": { + SchemaProps: spec.SchemaProps{ + Description: "StopSignal defines which signal will be sent to a container when it is being stopped. If not specified, the default is defined by the container runtime in use. StopSignal can only be set for Pods with a non-empty .spec.os.name\n\nPossible enum values:\n - `\"SIGABRT\"`\n - `\"SIGALRM\"`\n - `\"SIGBUS\"`\n - `\"SIGCHLD\"`\n - `\"SIGCLD\"`\n - `\"SIGCONT\"`\n - `\"SIGFPE\"`\n - `\"SIGHUP\"`\n - `\"SIGILL\"`\n - `\"SIGINT\"`\n - `\"SIGIO\"`\n - `\"SIGIOT\"`\n - `\"SIGKILL\"`\n - `\"SIGPIPE\"`\n - `\"SIGPOLL\"`\n - `\"SIGPROF\"`\n - `\"SIGPWR\"`\n - `\"SIGQUIT\"`\n - `\"SIGRTMAX\"`\n - `\"SIGRTMAX-1\"`\n - `\"SIGRTMAX-10\"`\n - `\"SIGRTMAX-11\"`\n - `\"SIGRTMAX-12\"`\n - `\"SIGRTMAX-13\"`\n - `\"SIGRTMAX-14\"`\n - `\"SIGRTMAX-2\"`\n - `\"SIGRTMAX-3\"`\n - `\"SIGRTMAX-4\"`\n - `\"SIGRTMAX-5\"`\n - `\"SIGRTMAX-6\"`\n - `\"SIGRTMAX-7\"`\n - `\"SIGRTMAX-8\"`\n - `\"SIGRTMAX-9\"`\n - `\"SIGRTMIN\"`\n - `\"SIGRTMIN+1\"`\n - `\"SIGRTMIN+10\"`\n - `\"SIGRTMIN+11\"`\n - `\"SIGRTMIN+12\"`\n - `\"SIGRTMIN+13\"`\n - `\"SIGRTMIN+14\"`\n - `\"SIGRTMIN+15\"`\n - `\"SIGRTMIN+2\"`\n - `\"SIGRTMIN+3\"`\n - `\"SIGRTMIN+4\"`\n - `\"SIGRTMIN+5\"`\n - `\"SIGRTMIN+6\"`\n - `\"SIGRTMIN+7\"`\n - `\"SIGRTMIN+8\"`\n - `\"SIGRTMIN+9\"`\n - `\"SIGSEGV\"`\n - `\"SIGSTKFLT\"`\n - `\"SIGSTOP\"`\n - `\"SIGSYS\"`\n - `\"SIGTERM\"`\n - `\"SIGTRAP\"`\n - `\"SIGTSTP\"`\n - `\"SIGTTIN\"`\n - `\"SIGTTOU\"`\n - `\"SIGURG\"`\n - `\"SIGUSR1\"`\n - `\"SIGUSR2\"`\n - `\"SIGVTALRM\"`\n - `\"SIGWINCH\"`\n - `\"SIGXCPU\"`\n - `\"SIGXFSZ\"`", + Type: []string{"string"}, + Format: "", + Enum: []interface{}{"SIGABRT", "SIGALRM", "SIGBUS", "SIGCHLD", "SIGCLD", "SIGCONT", "SIGFPE", "SIGHUP", "SIGILL", "SIGINT", "SIGIO", "SIGIOT", "SIGKILL", "SIGPIPE", "SIGPOLL", "SIGPROF", "SIGPWR", "SIGQUIT", "SIGRTMAX", "SIGRTMAX-1", "SIGRTMAX-10", "SIGRTMAX-11", "SIGRTMAX-12", "SIGRTMAX-13", "SIGRTMAX-14", "SIGRTMAX-2", "SIGRTMAX-3", "SIGRTMAX-4", "SIGRTMAX-5", "SIGRTMAX-6", "SIGRTMAX-7", "SIGRTMAX-8", "SIGRTMAX-9", "SIGRTMIN", "SIGRTMIN+1", "SIGRTMIN+10", "SIGRTMIN+11", "SIGRTMIN+12", "SIGRTMIN+13", "SIGRTMIN+14", "SIGRTMIN+15", "SIGRTMIN+2", "SIGRTMIN+3", "SIGRTMIN+4", "SIGRTMIN+5", "SIGRTMIN+6", "SIGRTMIN+7", "SIGRTMIN+8", "SIGRTMIN+9", "SIGSEGV", "SIGSTKFLT", "SIGSTOP", "SIGSYS", "SIGTERM", "SIGTRAP", "SIGTSTP", "SIGTTIN", "SIGTTOU", "SIGURG", "SIGUSR1", "SIGUSR2", "SIGVTALRM", "SIGWINCH", "SIGXCPU", "SIGXFSZ"}, + }, + }, + }, + }, + }, + Dependencies: []string{ + v1.LifecycleHandler{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_LifecycleHandler(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "LifecycleHandler defines a specific action that should be taken in a lifecycle hook. One and only one of the fields, except TCPSocket must be specified.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "exec": { + SchemaProps: spec.SchemaProps{ + Description: "Exec specifies a command to execute in the container.", + Ref: ref(v1.ExecAction{}.OpenAPIModelName()), + }, + }, + "httpGet": { + SchemaProps: spec.SchemaProps{ + Description: "HTTPGet specifies an HTTP GET request to perform.", + Ref: ref(v1.HTTPGetAction{}.OpenAPIModelName()), + }, + }, + "tcpSocket": { + SchemaProps: spec.SchemaProps{ + Description: "Deprecated. TCPSocket is NOT supported as a LifecycleHandler and kept for backward compatibility. There is no validation of this field and lifecycle hooks will fail at runtime when it is specified.", + Ref: ref(v1.TCPSocketAction{}.OpenAPIModelName()), + }, + }, + "sleep": { + SchemaProps: spec.SchemaProps{ + Description: "Sleep represents a duration that the container should sleep.", + Ref: ref(v1.SleepAction{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + Dependencies: []string{ + v1.ExecAction{}.OpenAPIModelName(), v1.HTTPGetAction{}.OpenAPIModelName(), v1.SleepAction{}.OpenAPIModelName(), v1.TCPSocketAction{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_LimitRange(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "LimitRange sets resource usage limits for each kind of resource in a Namespace.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "metadata": { + SchemaProps: spec.SchemaProps{ + Description: "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata", + Default: map[string]interface{}{}, + Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), + }, + }, + "spec": { + SchemaProps: spec.SchemaProps{ + Description: "Spec defines the limits enforced. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status", + Default: map[string]interface{}{}, + Ref: ref(v1.LimitRangeSpec{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + Dependencies: []string{ + v1.LimitRangeSpec{}.OpenAPIModelName(), metav1.ObjectMeta{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_LimitRangeItem(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "LimitRangeItem defines a min/max usage limit for any resource that matches on kind.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "type": { + SchemaProps: spec.SchemaProps{ + Description: "Type of resource that this limit applies to.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "max": { + SchemaProps: spec.SchemaProps{ + Description: "Max usage constraints on this kind by resource name.", + Type: []string{"object"}, + AdditionalProperties: &spec.SchemaOrBool{ + Allows: true, + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Ref: ref(resource.Quantity{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "min": { + SchemaProps: spec.SchemaProps{ + Description: "Min usage constraints on this kind by resource name.", + Type: []string{"object"}, + AdditionalProperties: &spec.SchemaOrBool{ + Allows: true, + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Ref: ref(resource.Quantity{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "default": { + SchemaProps: spec.SchemaProps{ + Description: "Default resource requirement limit value by resource name if resource limit is omitted.", + Type: []string{"object"}, + AdditionalProperties: &spec.SchemaOrBool{ + Allows: true, + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Ref: ref(resource.Quantity{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "defaultRequest": { + SchemaProps: spec.SchemaProps{ + Description: "DefaultRequest is the default resource requirement request value by resource name if resource request is omitted.", + Type: []string{"object"}, + AdditionalProperties: &spec.SchemaOrBool{ + Allows: true, + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Ref: ref(resource.Quantity{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "maxLimitRequestRatio": { + SchemaProps: spec.SchemaProps{ + Description: "MaxLimitRequestRatio if specified, the named resource must have a request and limit that are both non-zero where limit divided by request is less than or equal to the enumerated value; this represents the max burst for the named resource.", + Type: []string{"object"}, + AdditionalProperties: &spec.SchemaOrBool{ + Allows: true, + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Ref: ref(resource.Quantity{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + }, + Required: []string{"type"}, + }, + }, + Dependencies: []string{ + resource.Quantity{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_LimitRangeList(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "LimitRangeList is a list of LimitRange items.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "metadata": { + SchemaProps: spec.SchemaProps{ + Description: "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Default: map[string]interface{}{}, + Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), + }, + }, + "items": { + SchemaProps: spec.SchemaProps{ + Description: "Items is a list of LimitRange objects. More info: https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.LimitRange{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + }, + Required: []string{"items"}, + }, + }, + Dependencies: []string{ + v1.LimitRange{}.OpenAPIModelName(), metav1.ListMeta{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_LimitRangeSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "LimitRangeSpec defines a min/max usage limit for resources that match on kind.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "limits": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "Limits is the list of LimitRangeItem objects that are enforced.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.LimitRangeItem{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + }, + Required: []string{"limits"}, + }, + }, + Dependencies: []string{ + v1.LimitRangeItem{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_LinuxContainerUser(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "LinuxContainerUser represents user identity information in Linux containers", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "uid": { + SchemaProps: spec.SchemaProps{ + Description: "UID is the primary uid initially attached to the first process in the container", + Default: 0, + Type: []string{"integer"}, + Format: "int64", + }, + }, + "gid": { + SchemaProps: spec.SchemaProps{ + Description: "GID is the primary gid initially attached to the first process in the container", + Default: 0, + Type: []string{"integer"}, + Format: "int64", + }, + }, + "supplementalGroups": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "SupplementalGroups are the supplemental groups initially attached to the first process in the container", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: 0, + Type: []string{"integer"}, + Format: "int64", + }, + }, + }, + }, + }, + }, + Required: []string{"uid", "gid"}, + }, + }, + } +} + +func schema_k8sio_api_core_v1_List(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "List holds a list of objects, which may not be known by the server.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "metadata": { + SchemaProps: spec.SchemaProps{ + Description: "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Default: map[string]interface{}{}, + Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), + }, + }, + "items": { + SchemaProps: spec.SchemaProps{ + Description: "List of objects", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Ref: ref(runtime.RawExtension{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + }, + Required: []string{"items"}, + }, + }, + Dependencies: []string{ + metav1.ListMeta{}.OpenAPIModelName(), runtime.RawExtension{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_LoadBalancerIngress(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "LoadBalancerIngress represents the status of a load-balancer ingress point: traffic intended for the service should be sent to an ingress point.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "ip": { + SchemaProps: spec.SchemaProps{ + Description: "IP is set for load-balancer ingress points that are IP based (typically GCE or OpenStack load-balancers)", + Type: []string{"string"}, + Format: "", + }, + }, + "hostname": { + SchemaProps: spec.SchemaProps{ + Description: "Hostname is set for load-balancer ingress points that are DNS based (typically AWS load-balancers)", + Type: []string{"string"}, + Format: "", + }, + }, + "ipMode": { + SchemaProps: spec.SchemaProps{ + Description: "IPMode specifies how the load-balancer IP behaves, and may only be specified when the ip field is specified. Setting this to \"VIP\" indicates that traffic is delivered to the node with the destination set to the load-balancer's IP and port. Setting this to \"Proxy\" indicates that traffic is delivered to the node or pod with the destination set to the node's IP and node port or the pod's IP and port. Service implementations may use this information to adjust traffic routing.", + Type: []string{"string"}, + Format: "", + }, + }, + "ports": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "Ports is a list of records of service ports If used, every port defined in the service should have an entry in it", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.PortStatus{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + }, + }, + }, + Dependencies: []string{ + v1.PortStatus{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_LoadBalancerStatus(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "LoadBalancerStatus represents the status of a load-balancer.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "ingress": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "Ingress is a list containing ingress points for the load-balancer. Traffic intended for the service should be sent to these ingress points.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.LoadBalancerIngress{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + }, + }, + }, + Dependencies: []string{ + v1.LoadBalancerIngress{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_LocalObjectReference(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "LocalObjectReference contains enough information to let you locate the referenced object inside the same namespace.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "name": { + SchemaProps: spec.SchemaProps{ + Description: "Name of the referent. This field is effectively required, but due to backwards compatibility is allowed to be empty. Instances of this type with an empty value here are almost certainly wrong. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-map-type": "atomic", + }, + }, + }, + } +} + +func schema_k8sio_api_core_v1_LocalVolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "Local represents directly-attached storage with node affinity", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "path": { + SchemaProps: spec.SchemaProps{ + Description: "path of the full path to the volume on the node. It can be either a directory or block device (disk, partition, ...).", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "fsType": { + SchemaProps: spec.SchemaProps{ + Description: "fsType is the filesystem type to mount. It applies only when the Path is a block device. Must be a filesystem type supported by the host operating system. Ex. \"ext4\", \"xfs\", \"ntfs\". The default value is to auto-select a filesystem if unspecified.", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"path"}, + }, + }, + } +} + +func schema_k8sio_api_core_v1_ModifyVolumeStatus(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "ModifyVolumeStatus represents the status object of ControllerModifyVolume operation", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "targetVolumeAttributesClassName": { + SchemaProps: spec.SchemaProps{ + Description: "targetVolumeAttributesClassName is the name of the VolumeAttributesClass the PVC currently being reconciled", + Type: []string{"string"}, + Format: "", + }, + }, + "status": { + SchemaProps: spec.SchemaProps{ + Description: "status is the status of the ControllerModifyVolume operation. It can be in any of following states:\n - Pending\n Pending indicates that the PersistentVolumeClaim cannot be modified due to unmet requirements, such as\n the specified VolumeAttributesClass not existing.\n - InProgress\n InProgress indicates that the volume is being modified.\n - Infeasible\n Infeasible indicates that the request has been rejected as invalid by the CSI driver. To\n\t resolve the error, a valid VolumeAttributesClass needs to be specified.\nNote: New statuses can be added in the future. Consumers should check for unknown statuses and fail appropriately.\n\nPossible enum values:\n - `\"InProgress\"` InProgress indicates that the volume is being modified\n - `\"Infeasible\"` Infeasible indicates that the request has been rejected as invalid by the CSI driver. To resolve the error, a valid VolumeAttributesClass needs to be specified\n - `\"Pending\"` Pending indicates that the PersistentVolumeClaim cannot be modified due to unmet requirements, such as the specified VolumeAttributesClass not existing", + Default: "", + Type: []string{"string"}, + Format: "", + Enum: []interface{}{"InProgress", "Infeasible", "Pending"}, + }, + }, + }, + Required: []string{"status"}, + }, + }, + } +} + +func schema_k8sio_api_core_v1_NFSVolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "Represents an NFS mount that lasts the lifetime of a pod. NFS volumes do not support ownership management or SELinux relabeling.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "server": { + SchemaProps: spec.SchemaProps{ + Description: "server is the hostname or IP address of the NFS server. More info: https://kubernetes.io/docs/concepts/storage/volumes#nfs", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "path": { + SchemaProps: spec.SchemaProps{ + Description: "path that is exported by the NFS server. More info: https://kubernetes.io/docs/concepts/storage/volumes#nfs", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "readOnly": { + SchemaProps: spec.SchemaProps{ + Description: "readOnly here will force the NFS export to be mounted with read-only permissions. Defaults to false. More info: https://kubernetes.io/docs/concepts/storage/volumes#nfs", + Type: []string{"boolean"}, + Format: "", + }, + }, + }, + Required: []string{"server", "path"}, + }, + }, + } +} + +func schema_k8sio_api_core_v1_Namespace(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "Namespace provides a scope for Names. Use of multiple namespaces is optional.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "metadata": { + SchemaProps: spec.SchemaProps{ + Description: "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata", + Default: map[string]interface{}{}, + Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), + }, + }, + "spec": { + SchemaProps: spec.SchemaProps{ + Description: "Spec defines the behavior of the Namespace. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status", + Default: map[string]interface{}{}, + Ref: ref(v1.NamespaceSpec{}.OpenAPIModelName()), + }, + }, + "status": { + SchemaProps: spec.SchemaProps{ + Description: "Status describes the current status of a Namespace. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status", + Default: map[string]interface{}{}, + Ref: ref(v1.NamespaceStatus{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + Dependencies: []string{ + v1.NamespaceSpec{}.OpenAPIModelName(), v1.NamespaceStatus{}.OpenAPIModelName(), metav1.ObjectMeta{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_NamespaceCondition(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "NamespaceCondition contains details about state of namespace.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "type": { + SchemaProps: spec.SchemaProps{ + Description: "Type of namespace controller condition.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "status": { + SchemaProps: spec.SchemaProps{ + Description: "Status of the condition, one of True, False, Unknown.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "lastTransitionTime": { + SchemaProps: spec.SchemaProps{ + Description: "Last time the condition transitioned from one status to another.", + Ref: ref(metav1.Time{}.OpenAPIModelName()), + }, + }, + "reason": { + SchemaProps: spec.SchemaProps{ + Description: "Unique, one-word, CamelCase reason for the condition's last transition.", + Type: []string{"string"}, + Format: "", + }, + }, + "message": { + SchemaProps: spec.SchemaProps{ + Description: "Human-readable message indicating details about last transition.", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"type", "status"}, + }, + }, + Dependencies: []string{ + metav1.Time{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_NamespaceList(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "NamespaceList is a list of Namespaces.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "metadata": { + SchemaProps: spec.SchemaProps{ + Description: "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Default: map[string]interface{}{}, + Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), + }, + }, + "items": { + SchemaProps: spec.SchemaProps{ + Description: "Items is the list of Namespace objects in the list. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/namespaces/", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.Namespace{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + }, + Required: []string{"items"}, + }, + }, + Dependencies: []string{ + v1.Namespace{}.OpenAPIModelName(), metav1.ListMeta{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_NamespaceSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "NamespaceSpec describes the attributes on a Namespace.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "finalizers": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "Finalizers is an opaque list of values that must be empty to permanently remove object from storage. More info: https://kubernetes.io/docs/tasks/administer-cluster/namespaces/", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + }, + }, + }, + } +} + +func schema_k8sio_api_core_v1_NamespaceStatus(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "NamespaceStatus is information about the current status of a Namespace.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "phase": { + SchemaProps: spec.SchemaProps{ + Description: "Phase is the current lifecycle phase of the namespace. More info: https://kubernetes.io/docs/tasks/administer-cluster/namespaces/\n\nPossible enum values:\n - `\"Active\"` means the namespace is available for use in the system\n - `\"Terminating\"` means the namespace is undergoing graceful termination", + Type: []string{"string"}, + Format: "", + Enum: []interface{}{"Active", "Terminating"}, + }, + }, + "conditions": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-map-keys": []interface{}{ + "type", + }, + "x-kubernetes-list-type": "map", + "x-kubernetes-patch-merge-key": "type", + "x-kubernetes-patch-strategy": "merge", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "Represents the latest available observations of a namespace's current state.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.NamespaceCondition{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + }, + }, + }, + Dependencies: []string{ + v1.NamespaceCondition{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_Node(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "Node is a worker node in Kubernetes. Each node will have a unique identifier in the cache (i.e. in etcd).", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "metadata": { + SchemaProps: spec.SchemaProps{ + Description: "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata", + Default: map[string]interface{}{}, + Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), + }, + }, + "spec": { + SchemaProps: spec.SchemaProps{ + Description: "Spec defines the behavior of a node. https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status", + Default: map[string]interface{}{}, + Ref: ref(v1.NodeSpec{}.OpenAPIModelName()), + }, + }, + "status": { + SchemaProps: spec.SchemaProps{ + Description: "Most recently observed status of the node. Populated by the system. Read-only. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status", + Default: map[string]interface{}{}, + Ref: ref(v1.NodeStatus{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + Dependencies: []string{ + v1.NodeSpec{}.OpenAPIModelName(), v1.NodeStatus{}.OpenAPIModelName(), metav1.ObjectMeta{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_NodeAddress(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "NodeAddress contains information for the node's address.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "type": { + SchemaProps: spec.SchemaProps{ + Description: "Node address type, one of Hostname, ExternalIP or InternalIP.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "address": { + SchemaProps: spec.SchemaProps{ + Description: "The node address.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"type", "address"}, + }, + }, + } +} + +func schema_k8sio_api_core_v1_NodeAffinity(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "Node affinity is a group of node affinity scheduling rules.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "requiredDuringSchedulingIgnoredDuringExecution": { + SchemaProps: spec.SchemaProps{ + Description: "If the affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to an update), the system may or may not try to eventually evict the pod from its node.", + Ref: ref(v1.NodeSelector{}.OpenAPIModelName()), + }, + }, + "preferredDuringSchedulingIgnoredDuringExecution": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "The scheduler will prefer to schedule pods to nodes that satisfy the affinity expressions specified by this field, but it may choose a node that violates one or more of the expressions. The node that is most preferred is the one with the greatest sum of weights, i.e. for each node that meets all of the scheduling requirements (resource request, requiredDuringScheduling affinity expressions, etc.), compute a sum by iterating through the elements of this field and adding \"weight\" to the sum if the node matches the corresponding matchExpressions; the node(s) with the highest sum are the most preferred.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.PreferredSchedulingTerm{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + }, + }, + }, + Dependencies: []string{ + v1.NodeSelector{}.OpenAPIModelName(), v1.PreferredSchedulingTerm{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_NodeCondition(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "NodeCondition contains condition information for a node.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "type": { + SchemaProps: spec.SchemaProps{ + Description: "Type of node condition.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "status": { + SchemaProps: spec.SchemaProps{ + Description: "Status of the condition, one of True, False, Unknown.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "lastHeartbeatTime": { + SchemaProps: spec.SchemaProps{ + Description: "Last time we got an update on a given condition.", + Ref: ref(metav1.Time{}.OpenAPIModelName()), + }, + }, + "lastTransitionTime": { + SchemaProps: spec.SchemaProps{ + Description: "Last time the condition transit from one status to another.", + Ref: ref(metav1.Time{}.OpenAPIModelName()), + }, + }, + "reason": { + SchemaProps: spec.SchemaProps{ + Description: "(brief) reason for the condition's last transition.", + Type: []string{"string"}, + Format: "", + }, + }, + "message": { + SchemaProps: spec.SchemaProps{ + Description: "Human readable message indicating details about last transition.", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"type", "status"}, + }, + }, + Dependencies: []string{ + metav1.Time{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_NodeConfigSource(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "NodeConfigSource specifies a source of node configuration. Exactly one subfield (excluding metadata) must be non-nil. This API is deprecated since 1.22", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "configMap": { + SchemaProps: spec.SchemaProps{ + Description: "ConfigMap is a reference to a Node's ConfigMap", + Ref: ref(v1.ConfigMapNodeConfigSource{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + Dependencies: []string{ + v1.ConfigMapNodeConfigSource{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_NodeConfigStatus(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "NodeConfigStatus describes the status of the config assigned by Node.Spec.ConfigSource.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "assigned": { + SchemaProps: spec.SchemaProps{ + Description: "Assigned reports the checkpointed config the node will try to use. When Node.Spec.ConfigSource is updated, the node checkpoints the associated config payload to local disk, along with a record indicating intended config. The node refers to this record to choose its config checkpoint, and reports this record in Assigned. Assigned only updates in the status after the record has been checkpointed to disk. When the Kubelet is restarted, it tries to make the Assigned config the Active config by loading and validating the checkpointed payload identified by Assigned.", + Ref: ref(v1.NodeConfigSource{}.OpenAPIModelName()), + }, + }, + "active": { + SchemaProps: spec.SchemaProps{ + Description: "Active reports the checkpointed config the node is actively using. Active will represent either the current version of the Assigned config, or the current LastKnownGood config, depending on whether attempting to use the Assigned config results in an error.", + Ref: ref(v1.NodeConfigSource{}.OpenAPIModelName()), + }, + }, + "lastKnownGood": { + SchemaProps: spec.SchemaProps{ + Description: "LastKnownGood reports the checkpointed config the node will fall back to when it encounters an error attempting to use the Assigned config. The Assigned config becomes the LastKnownGood config when the node determines that the Assigned config is stable and correct. This is currently implemented as a 10-minute soak period starting when the local record of Assigned config is updated. If the Assigned config is Active at the end of this period, it becomes the LastKnownGood. Note that if Spec.ConfigSource is reset to nil (use local defaults), the LastKnownGood is also immediately reset to nil, because the local default config is always assumed good. You should not make assumptions about the node's method of determining config stability and correctness, as this may change or become configurable in the future.", + Ref: ref(v1.NodeConfigSource{}.OpenAPIModelName()), + }, + }, + "error": { + SchemaProps: spec.SchemaProps{ + Description: "Error describes any problems reconciling the Spec.ConfigSource to the Active config. Errors may occur, for example, attempting to checkpoint Spec.ConfigSource to the local Assigned record, attempting to checkpoint the payload associated with Spec.ConfigSource, attempting to load or validate the Assigned config, etc. Errors may occur at different points while syncing config. Earlier errors (e.g. download or checkpointing errors) will not result in a rollback to LastKnownGood, and may resolve across Kubelet retries. Later errors (e.g. loading or validating a checkpointed config) will result in a rollback to LastKnownGood. In the latter case, it is usually possible to resolve the error by fixing the config assigned in Spec.ConfigSource. You can find additional information for debugging by searching the error message in the Kubelet log. Error is a human-readable description of the error state; machines can check whether or not Error is empty, but should not rely on the stability of the Error text across Kubelet versions.", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + Dependencies: []string{ + v1.NodeConfigSource{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_NodeDaemonEndpoints(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "NodeDaemonEndpoints lists ports opened by daemons running on the Node.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kubeletEndpoint": { + SchemaProps: spec.SchemaProps{ + Description: "Endpoint on which Kubelet is listening.", + Default: map[string]interface{}{}, + Ref: ref(v1.DaemonEndpoint{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + Dependencies: []string{ + v1.DaemonEndpoint{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_NodeFeatures(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "NodeFeatures describes the set of features implemented by the CRI implementation. The features contained in the NodeFeatures should depend only on the cri implementation independent of runtime handlers.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "supplementalGroupsPolicy": { + SchemaProps: spec.SchemaProps{ + Description: "SupplementalGroupsPolicy is set to true if the runtime supports SupplementalGroupsPolicy and ContainerUser.", + Type: []string{"boolean"}, + Format: "", + }, + }, + }, + }, + }, + } +} + +func schema_k8sio_api_core_v1_NodeList(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "NodeList is the whole list of all Nodes which have been registered with master.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "metadata": { + SchemaProps: spec.SchemaProps{ + Description: "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Default: map[string]interface{}{}, + Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), + }, + }, + "items": { + SchemaProps: spec.SchemaProps{ + Description: "List of nodes", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.Node{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + }, + Required: []string{"items"}, + }, + }, + Dependencies: []string{ + v1.Node{}.OpenAPIModelName(), metav1.ListMeta{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_NodeProxyOptions(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "NodeProxyOptions is the query options to a Node's proxy call.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "path": { + SchemaProps: spec.SchemaProps{ + Description: "Path is the URL path to use for the current proxy request to node.", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + } +} + +func schema_k8sio_api_core_v1_NodeRuntimeHandler(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "NodeRuntimeHandler is a set of runtime handler information.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "name": { + SchemaProps: spec.SchemaProps{ + Description: "Runtime handler name. Empty for the default runtime handler.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "features": { + SchemaProps: spec.SchemaProps{ + Description: "Supported features.", + Ref: ref(v1.NodeRuntimeHandlerFeatures{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + Dependencies: []string{ + v1.NodeRuntimeHandlerFeatures{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_NodeRuntimeHandlerFeatures(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "NodeRuntimeHandlerFeatures is a set of features implemented by the runtime handler.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "recursiveReadOnlyMounts": { + SchemaProps: spec.SchemaProps{ + Description: "RecursiveReadOnlyMounts is set to true if the runtime handler supports RecursiveReadOnlyMounts.", + Type: []string{"boolean"}, + Format: "", + }, + }, + "userNamespaces": { + SchemaProps: spec.SchemaProps{ + Description: "UserNamespaces is set to true if the runtime handler supports UserNamespaces, including for volumes.", + Type: []string{"boolean"}, + Format: "", + }, + }, + }, + }, + }, + } +} + +func schema_k8sio_api_core_v1_NodeSelector(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "A node selector represents the union of the results of one or more label queries over a set of nodes; that is, it represents the OR of the selectors represented by the node selector terms.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "nodeSelectorTerms": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "Required. A list of node selector terms. The terms are ORed.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.NodeSelectorTerm{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + }, + Required: []string{"nodeSelectorTerms"}, + }, + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-map-type": "atomic", + }, + }, + }, + Dependencies: []string{ + v1.NodeSelectorTerm{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_NodeSelectorRequirement(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "A node selector requirement is a selector that contains values, a key, and an operator that relates the key and values.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "key": { + SchemaProps: spec.SchemaProps{ + Description: "The label key that the selector applies to.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "operator": { + SchemaProps: spec.SchemaProps{ + Description: "Represents a key's relationship to a set of values. Valid operators are In, NotIn, Exists, DoesNotExist. Gt, and Lt.\n\nPossible enum values:\n - `\"DoesNotExist\"`\n - `\"Exists\"`\n - `\"Gt\"`\n - `\"In\"`\n - `\"Lt\"`\n - `\"NotIn\"`", + Default: "", + Type: []string{"string"}, + Format: "", + Enum: []interface{}{"DoesNotExist", "Exists", "Gt", "In", "Lt", "NotIn"}, + }, + }, + "values": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "An array of string values. If the operator is In or NotIn, the values array must be non-empty. If the operator is Exists or DoesNotExist, the values array must be empty. If the operator is Gt or Lt, the values array must have a single element, which will be interpreted as an integer. This array is replaced during a strategic merge patch.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + }, + Required: []string{"key", "operator"}, + }, + }, + } +} + +func schema_k8sio_api_core_v1_NodeSelectorTerm(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "A null or empty node selector term matches no objects. The requirements of them are ANDed. The TopologySelectorTerm type implements a subset of the NodeSelectorTerm.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "matchExpressions": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "A list of node selector requirements by node's labels.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.NodeSelectorRequirement{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "matchFields": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "A list of node selector requirements by node's fields.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.NodeSelectorRequirement{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + }, + }, + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-map-type": "atomic", + }, + }, + }, + Dependencies: []string{ + v1.NodeSelectorRequirement{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_NodeSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "NodeSpec describes the attributes that a node is created with.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "podCIDR": { + SchemaProps: spec.SchemaProps{ + Description: "PodCIDR represents the pod IP range assigned to the node.", + Type: []string{"string"}, + Format: "", + }, + }, + "podCIDRs": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "set", + "x-kubernetes-patch-strategy": "merge", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "podCIDRs represents the IP ranges assigned to the node for usage by Pods on that node. If this field is specified, the 0th entry must match the podCIDR field. It may contain at most 1 value for each of IPv4 and IPv6.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + "providerID": { + SchemaProps: spec.SchemaProps{ + Description: "ID of the node assigned by the cloud provider in the format: ://", + Type: []string{"string"}, + Format: "", + }, + }, + "unschedulable": { + SchemaProps: spec.SchemaProps{ + Description: "Unschedulable controls node schedulability of new pods. By default, node is schedulable. More info: https://kubernetes.io/docs/concepts/nodes/node/#manual-node-administration", + Type: []string{"boolean"}, + Format: "", + }, + }, + "taints": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "If specified, the node's taints.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.Taint{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "configSource": { + SchemaProps: spec.SchemaProps{ + Description: "Deprecated: Previously used to specify the source of the node's configuration for the DynamicKubeletConfig feature. This feature is removed.", + Ref: ref(v1.NodeConfigSource{}.OpenAPIModelName()), + }, + }, + "externalID": { + SchemaProps: spec.SchemaProps{ + Description: "Deprecated. Not all kubelets will set this field. Remove field after 1.13. see: https://issues.k8s.io/61966", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + Dependencies: []string{ + v1.NodeConfigSource{}.OpenAPIModelName(), v1.Taint{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_NodeStatus(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "NodeStatus is information about the current status of a node.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "capacity": { + SchemaProps: spec.SchemaProps{ + Description: "Capacity represents the total resources of a node. More info: https://kubernetes.io/docs/reference/node/node-status/#capacity", + Type: []string{"object"}, + AdditionalProperties: &spec.SchemaOrBool{ + Allows: true, + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Ref: ref(resource.Quantity{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "allocatable": { + SchemaProps: spec.SchemaProps{ + Description: "Allocatable represents the resources of a node that are available for scheduling. Defaults to Capacity.", + Type: []string{"object"}, + AdditionalProperties: &spec.SchemaOrBool{ + Allows: true, + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Ref: ref(resource.Quantity{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "phase": { + SchemaProps: spec.SchemaProps{ + Description: "NodePhase is the recently observed lifecycle phase of the node. More info: https://kubernetes.io/docs/concepts/nodes/node/#phase The field is never populated, and now is deprecated.\n\nPossible enum values:\n - `\"Pending\"` means the node has been created/added by the system, but not configured.\n - `\"Running\"` means the node has been configured and has Kubernetes components running.\n - `\"Terminated\"` means the node has been removed from the cluster.", + Type: []string{"string"}, + Format: "", + Enum: []interface{}{"Pending", "Running", "Terminated"}, + }, + }, + "conditions": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-map-keys": []interface{}{ + "type", + }, + "x-kubernetes-list-type": "map", + "x-kubernetes-patch-merge-key": "type", + "x-kubernetes-patch-strategy": "merge", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "Conditions is an array of current observed node conditions. More info: https://kubernetes.io/docs/reference/node/node-status/#condition", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.NodeCondition{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "addresses": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-map-keys": []interface{}{ + "type", + }, + "x-kubernetes-list-type": "map", + "x-kubernetes-patch-merge-key": "type", + "x-kubernetes-patch-strategy": "merge", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "List of addresses reachable to the node. Queried from cloud provider, if available. More info: https://kubernetes.io/docs/reference/node/node-status/#addresses Note: This field is declared as mergeable, but the merge key is not sufficiently unique, which can cause data corruption when it is merged. Callers should instead use a full-replacement patch. See https://pr.k8s.io/79391 for an example. Consumers should assume that addresses can change during the lifetime of a Node. However, there are some exceptions where this may not be possible, such as Pods that inherit a Node's address in its own status or consumers of the downward API (status.hostIP).", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.NodeAddress{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "daemonEndpoints": { + SchemaProps: spec.SchemaProps{ + Description: "Endpoints of daemons running on the Node.", + Default: map[string]interface{}{}, + Ref: ref(v1.NodeDaemonEndpoints{}.OpenAPIModelName()), + }, + }, + "nodeInfo": { + SchemaProps: spec.SchemaProps{ + Description: "Set of ids/uuids to uniquely identify the node. More info: https://kubernetes.io/docs/reference/node/node-status/#info", + Default: map[string]interface{}{}, + Ref: ref(v1.NodeSystemInfo{}.OpenAPIModelName()), + }, + }, + "images": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "List of container images on this node", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.ContainerImage{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "volumesInUse": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "List of attachable volumes in use (mounted) by the node.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + "volumesAttached": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "List of volumes that are attached to the node.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.AttachedVolume{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "config": { + SchemaProps: spec.SchemaProps{ + Description: "Status of the config assigned to the node via the dynamic Kubelet config feature.", + Ref: ref(v1.NodeConfigStatus{}.OpenAPIModelName()), + }, + }, + "runtimeHandlers": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "The available runtime handlers.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.NodeRuntimeHandler{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "features": { + SchemaProps: spec.SchemaProps{ + Description: "Features describes the set of features implemented by the CRI implementation.", + Ref: ref(v1.NodeFeatures{}.OpenAPIModelName()), + }, + }, + "declaredFeatures": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "DeclaredFeatures represents the features related to feature gates that are declared by the node.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + }, + }, + }, + Dependencies: []string{ + v1.AttachedVolume{}.OpenAPIModelName(), v1.ContainerImage{}.OpenAPIModelName(), v1.NodeAddress{}.OpenAPIModelName(), v1.NodeCondition{}.OpenAPIModelName(), v1.NodeConfigStatus{}.OpenAPIModelName(), v1.NodeDaemonEndpoints{}.OpenAPIModelName(), v1.NodeFeatures{}.OpenAPIModelName(), v1.NodeRuntimeHandler{}.OpenAPIModelName(), v1.NodeSystemInfo{}.OpenAPIModelName(), resource.Quantity{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_NodeSwapStatus(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "NodeSwapStatus represents swap memory information.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "capacity": { + SchemaProps: spec.SchemaProps{ + Description: "Total amount of swap memory in bytes.", + Type: []string{"integer"}, + Format: "int64", + }, + }, + }, + }, + }, + } +} + +func schema_k8sio_api_core_v1_NodeSystemInfo(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "NodeSystemInfo is a set of ids/uuids to uniquely identify the node.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "machineID": { + SchemaProps: spec.SchemaProps{ + Description: "MachineID reported by the node. For unique machine identification in the cluster this field is preferred. Learn more from man(5) machine-id: http://man7.org/linux/man-pages/man5/machine-id.5.html", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "systemUUID": { + SchemaProps: spec.SchemaProps{ + Description: "SystemUUID reported by the node. For unique machine identification MachineID is preferred. This field is specific to Red Hat hosts https://access.redhat.com/documentation/en-us/red_hat_subscription_management/1/html/rhsm/uuid", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "bootID": { + SchemaProps: spec.SchemaProps{ + Description: "Boot ID reported by the node.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "kernelVersion": { + SchemaProps: spec.SchemaProps{ + Description: "Kernel Version reported by the node from 'uname -r' (e.g. 3.16.0-0.bpo.4-amd64).", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "osImage": { + SchemaProps: spec.SchemaProps{ + Description: "OS Image reported by the node from /etc/os-release (e.g. Debian GNU/Linux 7 (wheezy)).", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "containerRuntimeVersion": { + SchemaProps: spec.SchemaProps{ + Description: "ContainerRuntime Version reported by the node through runtime remote API (e.g. containerd://1.4.2).", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "kubeletVersion": { + SchemaProps: spec.SchemaProps{ + Description: "Kubelet Version reported by the node.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "kubeProxyVersion": { + SchemaProps: spec.SchemaProps{ + Description: "Deprecated: KubeProxy Version reported by the node.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "operatingSystem": { + SchemaProps: spec.SchemaProps{ + Description: "The Operating System reported by the node", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "architecture": { + SchemaProps: spec.SchemaProps{ + Description: "The Architecture reported by the node", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "swap": { + SchemaProps: spec.SchemaProps{ + Description: "Swap Info reported by the node.", + Ref: ref(v1.NodeSwapStatus{}.OpenAPIModelName()), + }, + }, + }, + Required: []string{"machineID", "systemUUID", "bootID", "kernelVersion", "osImage", "containerRuntimeVersion", "kubeletVersion", "kubeProxyVersion", "operatingSystem", "architecture"}, + }, + }, + Dependencies: []string{ + v1.NodeSwapStatus{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_ObjectFieldSelector(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "ObjectFieldSelector selects an APIVersioned field of an object.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "Version of the schema the FieldPath is written in terms of, defaults to \"v1\".", + Type: []string{"string"}, + Format: "", + }, + }, + "fieldPath": { + SchemaProps: spec.SchemaProps{ + Description: "Path of the field to select in the specified API version.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"fieldPath"}, + }, + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-map-type": "atomic", + }, + }, + }, + } +} + +func schema_k8sio_api_core_v1_ObjectReference(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "ObjectReference contains enough information to let you inspect or modify the referred object.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind of the referent. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "namespace": { + SchemaProps: spec.SchemaProps{ + Description: "Namespace of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/namespaces/", + Type: []string{"string"}, + Format: "", + }, + }, + "name": { + SchemaProps: spec.SchemaProps{ + Description: "Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names", + Type: []string{"string"}, + Format: "", + }, + }, + "uid": { + SchemaProps: spec.SchemaProps{ + Description: "UID of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#uids", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "API version of the referent.", + Type: []string{"string"}, + Format: "", + }, + }, + "resourceVersion": { + SchemaProps: spec.SchemaProps{ + Description: "Specific resourceVersion to which this reference is made, if any. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#concurrency-control-and-consistency", + Type: []string{"string"}, + Format: "", + }, + }, + "fieldPath": { + SchemaProps: spec.SchemaProps{ + Description: "If referring to a piece of an object instead of an entire object, this string should contain a valid JSON/Go field access statement, such as desiredState.manifest.containers[2]. For example, if the object reference is to a container within a pod, this would take on a value like: \"spec.containers{name}\" (where \"name\" refers to the name of the container that triggered the event) or if no container name is specified \"spec.containers[2]\" (container with index 2 in this pod). This syntax is chosen only to have some well-defined way of referencing a part of an object.", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-map-type": "atomic", + }, + }, + }, + } +} + +func schema_k8sio_api_core_v1_PersistentVolume(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "PersistentVolume (PV) is a storage resource provisioned by an administrator. It is analogous to a node. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "metadata": { + SchemaProps: spec.SchemaProps{ + Description: "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata", + Default: map[string]interface{}{}, + Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), + }, + }, + "spec": { + SchemaProps: spec.SchemaProps{ + Description: "spec defines a specification of a persistent volume owned by the cluster. Provisioned by an administrator. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#persistent-volumes", + Default: map[string]interface{}{}, + Ref: ref(v1.PersistentVolumeSpec{}.OpenAPIModelName()), + }, + }, + "status": { + SchemaProps: spec.SchemaProps{ + Description: "status represents the current information/status for the persistent volume. Populated by the system. Read-only. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#persistent-volumes", + Default: map[string]interface{}{}, + Ref: ref(v1.PersistentVolumeStatus{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + Dependencies: []string{ + v1.PersistentVolumeSpec{}.OpenAPIModelName(), v1.PersistentVolumeStatus{}.OpenAPIModelName(), metav1.ObjectMeta{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_PersistentVolumeClaim(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "PersistentVolumeClaim is a user's request for and claim to a persistent volume", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "metadata": { + SchemaProps: spec.SchemaProps{ + Description: "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata", + Default: map[string]interface{}{}, + Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), + }, + }, + "spec": { + SchemaProps: spec.SchemaProps{ + Description: "spec defines the desired characteristics of a volume requested by a pod author. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#persistentvolumeclaims", + Default: map[string]interface{}{}, + Ref: ref(v1.PersistentVolumeClaimSpec{}.OpenAPIModelName()), + }, + }, + "status": { + SchemaProps: spec.SchemaProps{ + Description: "status represents the current information/status of a persistent volume claim. Read-only. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#persistentvolumeclaims", + Default: map[string]interface{}{}, + Ref: ref(v1.PersistentVolumeClaimStatus{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + Dependencies: []string{ + v1.PersistentVolumeClaimSpec{}.OpenAPIModelName(), v1.PersistentVolumeClaimStatus{}.OpenAPIModelName(), metav1.ObjectMeta{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_PersistentVolumeClaimCondition(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "PersistentVolumeClaimCondition contains details about state of pvc", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "type": { + SchemaProps: spec.SchemaProps{ + Description: "Type is the type of the condition. More info: https://kubernetes.io/docs/reference/kubernetes-api/config-and-storage-resources/persistent-volume-claim-v1/#:~:text=set%20to%20%27ResizeStarted%27.-,PersistentVolumeClaimCondition,-contains%20details%20about", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "status": { + SchemaProps: spec.SchemaProps{ + Description: "Status is the status of the condition. Can be True, False, Unknown. More info: https://kubernetes.io/docs/reference/kubernetes-api/config-and-storage-resources/persistent-volume-claim-v1/#:~:text=state%20of%20pvc-,conditions.status,-(string)%2C%20required", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "lastProbeTime": { + SchemaProps: spec.SchemaProps{ + Description: "lastProbeTime is the time we probed the condition.", + Ref: ref(metav1.Time{}.OpenAPIModelName()), + }, + }, + "lastTransitionTime": { + SchemaProps: spec.SchemaProps{ + Description: "lastTransitionTime is the time the condition transitioned from one status to another.", + Ref: ref(metav1.Time{}.OpenAPIModelName()), + }, + }, + "reason": { + SchemaProps: spec.SchemaProps{ + Description: "reason is a unique, this should be a short, machine understandable string that gives the reason for condition's last transition. If it reports \"Resizing\" that means the underlying persistent volume is being resized.", + Type: []string{"string"}, + Format: "", + }, + }, + "message": { + SchemaProps: spec.SchemaProps{ + Description: "message is the human-readable message indicating details about last transition.", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"type", "status"}, + }, + }, + Dependencies: []string{ + metav1.Time{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_PersistentVolumeClaimList(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "PersistentVolumeClaimList is a list of PersistentVolumeClaim items.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "metadata": { + SchemaProps: spec.SchemaProps{ + Description: "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Default: map[string]interface{}{}, + Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), + }, + }, + "items": { + SchemaProps: spec.SchemaProps{ + Description: "items is a list of persistent volume claims. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#persistentvolumeclaims", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.PersistentVolumeClaim{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + }, + Required: []string{"items"}, + }, + }, + Dependencies: []string{ + v1.PersistentVolumeClaim{}.OpenAPIModelName(), metav1.ListMeta{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_PersistentVolumeClaimSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "PersistentVolumeClaimSpec describes the common attributes of storage devices and allows a Source for provider-specific attributes", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "accessModes": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "accessModes contains the desired access modes the volume should have. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#access-modes-1", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + Enum: []interface{}{"ReadOnlyMany", "ReadWriteMany", "ReadWriteOnce", "ReadWriteOncePod"}, + }, + }, + }, + }, + }, + "selector": { + SchemaProps: spec.SchemaProps{ + Description: "selector is a label query over volumes to consider for binding.", + Ref: ref(metav1.LabelSelector{}.OpenAPIModelName()), + }, + }, + "resources": { + SchemaProps: spec.SchemaProps{ + Description: "resources represents the minimum resources the volume should have. Users are allowed to specify resource requirements that are lower than previous value but must still be higher than capacity recorded in the status field of the claim. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#resources", + Default: map[string]interface{}{}, + Ref: ref(v1.VolumeResourceRequirements{}.OpenAPIModelName()), + }, + }, + "volumeName": { + SchemaProps: spec.SchemaProps{ + Description: "volumeName is the binding reference to the PersistentVolume backing this claim.", + Type: []string{"string"}, + Format: "", + }, + }, + "storageClassName": { + SchemaProps: spec.SchemaProps{ + Description: "storageClassName is the name of the StorageClass required by the claim. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#class-1", + Type: []string{"string"}, + Format: "", + }, + }, + "volumeMode": { + SchemaProps: spec.SchemaProps{ + Description: "volumeMode defines what type of volume is required by the claim. Value of Filesystem is implied when not included in claim spec.\n\nPossible enum values:\n - `\"Block\"` means the volume will not be formatted with a filesystem and will remain a raw block device.\n - `\"Filesystem\"` means the volume will be or is formatted with a filesystem.", + Type: []string{"string"}, + Format: "", + Enum: []interface{}{"Block", "Filesystem"}, + }, + }, + "dataSource": { + SchemaProps: spec.SchemaProps{ + Description: "dataSource field can be used to specify either: * An existing VolumeSnapshot object (snapshot.storage.k8s.io/VolumeSnapshot) * An existing PVC (PersistentVolumeClaim) If the provisioner or an external controller can support the specified data source, it will create a new volume based on the contents of the specified data source. When the AnyVolumeDataSource feature gate is enabled, dataSource contents will be copied to dataSourceRef, and dataSourceRef contents will be copied to dataSource when dataSourceRef.namespace is not specified. If the namespace is specified, then dataSourceRef will not be copied to dataSource.", + Ref: ref(v1.TypedLocalObjectReference{}.OpenAPIModelName()), + }, + }, + "dataSourceRef": { + SchemaProps: spec.SchemaProps{ + Description: "dataSourceRef specifies the object from which to populate the volume with data, if a non-empty volume is desired. This may be any object from a non-empty API group (non core object) or a PersistentVolumeClaim object. When this field is specified, volume binding will only succeed if the type of the specified object matches some installed volume populator or dynamic provisioner. This field will replace the functionality of the dataSource field and as such if both fields are non-empty, they must have the same value. For backwards compatibility, when namespace isn't specified in dataSourceRef, both fields (dataSource and dataSourceRef) will be set to the same value automatically if one of them is empty and the other is non-empty. When namespace is specified in dataSourceRef, dataSource isn't set to the same value and must be empty. There are three important differences between dataSource and dataSourceRef: * While dataSource only allows two specific types of objects, dataSourceRef\n allows any non-core object, as well as PersistentVolumeClaim objects.\n* While dataSource ignores disallowed values (dropping them), dataSourceRef\n preserves all values, and generates an error if a disallowed value is\n specified.\n* While dataSource only allows local objects, dataSourceRef allows objects\n in any namespaces.\n(Beta) Using this field requires the AnyVolumeDataSource feature gate to be enabled. (Alpha) Using the namespace field of dataSourceRef requires the CrossNamespaceVolumeDataSource feature gate to be enabled.", + Ref: ref(v1.TypedObjectReference{}.OpenAPIModelName()), + }, + }, + "volumeAttributesClassName": { + SchemaProps: spec.SchemaProps{ + Description: "volumeAttributesClassName may be used to set the VolumeAttributesClass used by this claim. If specified, the CSI driver will create or update the volume with the attributes defined in the corresponding VolumeAttributesClass. This has a different purpose than storageClassName, it can be changed after the claim is created. An empty string or nil value indicates that no VolumeAttributesClass will be applied to the claim. If the claim enters an Infeasible error state, this field can be reset to its previous value (including nil) to cancel the modification. If the resource referred to by volumeAttributesClass does not exist, this PersistentVolumeClaim will be set to a Pending state, as reflected by the modifyVolumeStatus field, until such as a resource exists. More info: https://kubernetes.io/docs/concepts/storage/volume-attributes-classes/", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + Dependencies: []string{ + v1.TypedLocalObjectReference{}.OpenAPIModelName(), v1.TypedObjectReference{}.OpenAPIModelName(), v1.VolumeResourceRequirements{}.OpenAPIModelName(), metav1.LabelSelector{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_PersistentVolumeClaimStatus(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "PersistentVolumeClaimStatus is the current status of a persistent volume claim.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "phase": { + SchemaProps: spec.SchemaProps{ + Description: "phase represents the current phase of PersistentVolumeClaim.\n\nPossible enum values:\n - `\"Bound\"` used for PersistentVolumeClaims that are bound\n - `\"Lost\"` used for PersistentVolumeClaims that lost their underlying PersistentVolume. The claim was bound to a PersistentVolume and this volume does not exist any longer and all data on it was lost.\n - `\"Pending\"` used for PersistentVolumeClaims that are not yet bound", + Type: []string{"string"}, + Format: "", + Enum: []interface{}{"Bound", "Lost", "Pending"}, + }, + }, + "accessModes": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "accessModes contains the actual access modes the volume backing the PVC has. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#access-modes-1", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + Enum: []interface{}{"ReadOnlyMany", "ReadWriteMany", "ReadWriteOnce", "ReadWriteOncePod"}, + }, + }, + }, + }, + }, + "capacity": { + SchemaProps: spec.SchemaProps{ + Description: "capacity represents the actual resources of the underlying volume.", + Type: []string{"object"}, + AdditionalProperties: &spec.SchemaOrBool{ + Allows: true, + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Ref: ref(resource.Quantity{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "conditions": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-map-keys": []interface{}{ + "type", + }, + "x-kubernetes-list-type": "map", + "x-kubernetes-patch-merge-key": "type", + "x-kubernetes-patch-strategy": "merge", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "conditions is the current Condition of persistent volume claim. If underlying persistent volume is being resized then the Condition will be set to 'Resizing'.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.PersistentVolumeClaimCondition{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "allocatedResources": { + SchemaProps: spec.SchemaProps{ + Description: "allocatedResources tracks the resources allocated to a PVC including its capacity. Key names follow standard Kubernetes label syntax. Valid values are either:\n\t* Un-prefixed keys:\n\t\t- storage - the capacity of the volume.\n\t* Custom resources must use implementation-defined prefixed names such as \"example.com/my-custom-resource\"\nApart from above values - keys that are unprefixed or have kubernetes.io prefix are considered reserved and hence may not be used.\n\nCapacity reported here may be larger than the actual capacity when a volume expansion operation is requested. For storage quota, the larger value from allocatedResources and PVC.spec.resources is used. If allocatedResources is not set, PVC.spec.resources alone is used for quota calculation. If a volume expansion capacity request is lowered, allocatedResources is only lowered if there are no expansion operations in progress and if the actual volume capacity is equal or lower than the requested capacity.\n\nA controller that receives PVC update with previously unknown resourceName should ignore the update for the purpose it was designed. For example - a controller that only is responsible for resizing capacity of the volume, should ignore PVC updates that change other valid resources associated with PVC.", + Type: []string{"object"}, + AdditionalProperties: &spec.SchemaOrBool{ + Allows: true, + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Ref: ref(resource.Quantity{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "allocatedResourceStatuses": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-map-type": "granular", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "allocatedResourceStatuses stores status of resource being resized for the given PVC. Key names follow standard Kubernetes label syntax. Valid values are either:\n\t* Un-prefixed keys:\n\t\t- storage - the capacity of the volume.\n\t* Custom resources must use implementation-defined prefixed names such as \"example.com/my-custom-resource\"\nApart from above values - keys that are unprefixed or have kubernetes.io prefix are considered reserved and hence may not be used.\n\nClaimResourceStatus can be in any of following states:\n\t- ControllerResizeInProgress:\n\t\tState set when resize controller starts resizing the volume in control-plane.\n\t- ControllerResizeFailed:\n\t\tState set when resize has failed in resize controller with a terminal error.\n\t- NodeResizePending:\n\t\tState set when resize controller has finished resizing the volume but further resizing of\n\t\tvolume is needed on the node.\n\t- NodeResizeInProgress:\n\t\tState set when kubelet starts resizing the volume.\n\t- NodeResizeFailed:\n\t\tState set when resizing has failed in kubelet with a terminal error. Transient errors don't set\n\t\tNodeResizeFailed.\nFor example: if expanding a PVC for more capacity - this field can be one of the following states:\n\t- pvc.status.allocatedResourceStatus['storage'] = \"ControllerResizeInProgress\"\n - pvc.status.allocatedResourceStatus['storage'] = \"ControllerResizeFailed\"\n - pvc.status.allocatedResourceStatus['storage'] = \"NodeResizePending\"\n - pvc.status.allocatedResourceStatus['storage'] = \"NodeResizeInProgress\"\n - pvc.status.allocatedResourceStatus['storage'] = \"NodeResizeFailed\"\nWhen this field is not set, it means that no resize operation is in progress for the given PVC.\n\nA controller that receives PVC update with previously unknown resourceName or ClaimResourceStatus should ignore the update for the purpose it was designed. For example - a controller that only is responsible for resizing capacity of the volume, should ignore PVC updates that change other valid resources associated with PVC.", + Type: []string{"object"}, + AdditionalProperties: &spec.SchemaOrBool{ + Allows: true, + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + Enum: []interface{}{"ControllerResizeInProgress", "ControllerResizeInfeasible", "NodeResizeInProgress", "NodeResizeInfeasible", "NodeResizePending"}, + }, + }, + }, + }, + }, + "currentVolumeAttributesClassName": { + SchemaProps: spec.SchemaProps{ + Description: "currentVolumeAttributesClassName is the current name of the VolumeAttributesClass the PVC is using. When unset, there is no VolumeAttributeClass applied to this PersistentVolumeClaim", + Type: []string{"string"}, + Format: "", + }, + }, + "modifyVolumeStatus": { + SchemaProps: spec.SchemaProps{ + Description: "ModifyVolumeStatus represents the status object of ControllerModifyVolume operation. When this is unset, there is no ModifyVolume operation being attempted.", + Ref: ref(v1.ModifyVolumeStatus{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + Dependencies: []string{ + v1.ModifyVolumeStatus{}.OpenAPIModelName(), v1.PersistentVolumeClaimCondition{}.OpenAPIModelName(), resource.Quantity{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_PersistentVolumeClaimTemplate(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "PersistentVolumeClaimTemplate is used to produce PersistentVolumeClaim objects as part of an EphemeralVolumeSource.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "metadata": { + SchemaProps: spec.SchemaProps{ + Description: "May contain labels and annotations that will be copied into the PVC when creating it. No other fields are allowed and will be rejected during validation.", + Default: map[string]interface{}{}, + Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), + }, + }, + "spec": { + SchemaProps: spec.SchemaProps{ + Description: "The specification for the PersistentVolumeClaim. The entire content is copied unchanged into the PVC that gets created from this template. The same fields as in a PersistentVolumeClaim are also valid here.", + Default: map[string]interface{}{}, + Ref: ref(v1.PersistentVolumeClaimSpec{}.OpenAPIModelName()), + }, + }, + }, + Required: []string{"spec"}, + }, + }, + Dependencies: []string{ + v1.PersistentVolumeClaimSpec{}.OpenAPIModelName(), metav1.ObjectMeta{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_PersistentVolumeClaimVolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "PersistentVolumeClaimVolumeSource references the user's PVC in the same namespace. This volume finds the bound PV and mounts that volume for the pod. A PersistentVolumeClaimVolumeSource is, essentially, a wrapper around another type of volume that is owned by someone else (the system).", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "claimName": { + SchemaProps: spec.SchemaProps{ + Description: "claimName is the name of a PersistentVolumeClaim in the same namespace as the pod using this volume. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#persistentvolumeclaims", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "readOnly": { + SchemaProps: spec.SchemaProps{ + Description: "readOnly Will force the ReadOnly setting in VolumeMounts. Default false.", + Type: []string{"boolean"}, + Format: "", + }, + }, + }, + Required: []string{"claimName"}, + }, + }, + } +} + +func schema_k8sio_api_core_v1_PersistentVolumeList(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "PersistentVolumeList is a list of PersistentVolume items.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "metadata": { + SchemaProps: spec.SchemaProps{ + Description: "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Default: map[string]interface{}{}, + Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), + }, + }, + "items": { + SchemaProps: spec.SchemaProps{ + Description: "items is a list of persistent volumes. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.PersistentVolume{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + }, + Required: []string{"items"}, + }, + }, + Dependencies: []string{ + v1.PersistentVolume{}.OpenAPIModelName(), metav1.ListMeta{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_PersistentVolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "PersistentVolumeSource is similar to VolumeSource but meant for the administrator who creates PVs. Exactly one of its members must be set.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "gcePersistentDisk": { + SchemaProps: spec.SchemaProps{ + Description: "gcePersistentDisk represents a GCE Disk resource that is attached to a kubelet's host machine and then exposed to the pod. Provisioned by an admin. Deprecated: GCEPersistentDisk is deprecated. All operations for the in-tree gcePersistentDisk type are redirected to the pd.csi.storage.gke.io CSI driver. More info: https://kubernetes.io/docs/concepts/storage/volumes#gcepersistentdisk", + Ref: ref(v1.GCEPersistentDiskVolumeSource{}.OpenAPIModelName()), + }, + }, + "awsElasticBlockStore": { + SchemaProps: spec.SchemaProps{ + Description: "awsElasticBlockStore represents an AWS Disk resource that is attached to a kubelet's host machine and then exposed to the pod. Deprecated: AWSElasticBlockStore is deprecated. All operations for the in-tree awsElasticBlockStore type are redirected to the ebs.csi.aws.com CSI driver. More info: https://kubernetes.io/docs/concepts/storage/volumes#awselasticblockstore", + Ref: ref(v1.AWSElasticBlockStoreVolumeSource{}.OpenAPIModelName()), + }, + }, + "hostPath": { + SchemaProps: spec.SchemaProps{ + Description: "hostPath represents a directory on the host. Provisioned by a developer or tester. This is useful for single-node development and testing only! On-host storage is not supported in any way and WILL NOT WORK in a multi-node cluster. More info: https://kubernetes.io/docs/concepts/storage/volumes#hostpath", + Ref: ref(v1.HostPathVolumeSource{}.OpenAPIModelName()), + }, + }, + "glusterfs": { + SchemaProps: spec.SchemaProps{ + Description: "glusterfs represents a Glusterfs volume that is attached to a host and exposed to the pod. Provisioned by an admin. Deprecated: Glusterfs is deprecated and the in-tree glusterfs type is no longer supported. More info: https://examples.k8s.io/volumes/glusterfs/README.md", + Ref: ref(v1.GlusterfsPersistentVolumeSource{}.OpenAPIModelName()), + }, + }, + "nfs": { + SchemaProps: spec.SchemaProps{ + Description: "nfs represents an NFS mount on the host. Provisioned by an admin. More info: https://kubernetes.io/docs/concepts/storage/volumes#nfs", + Ref: ref(v1.NFSVolumeSource{}.OpenAPIModelName()), + }, + }, + "rbd": { + SchemaProps: spec.SchemaProps{ + Description: "rbd represents a Rados Block Device mount on the host that shares a pod's lifetime. Deprecated: RBD is deprecated and the in-tree rbd type is no longer supported. More info: https://examples.k8s.io/volumes/rbd/README.md", + Ref: ref(v1.RBDPersistentVolumeSource{}.OpenAPIModelName()), + }, + }, + "iscsi": { + SchemaProps: spec.SchemaProps{ + Description: "iscsi represents an ISCSI Disk resource that is attached to a kubelet's host machine and then exposed to the pod. Provisioned by an admin.", + Ref: ref(v1.ISCSIPersistentVolumeSource{}.OpenAPIModelName()), + }, + }, + "cinder": { + SchemaProps: spec.SchemaProps{ + Description: "cinder represents a cinder volume attached and mounted on kubelets host machine. Deprecated: Cinder is deprecated. All operations for the in-tree cinder type are redirected to the cinder.csi.openstack.org CSI driver. More info: https://examples.k8s.io/mysql-cinder-pd/README.md", + Ref: ref(v1.CinderPersistentVolumeSource{}.OpenAPIModelName()), + }, + }, + "cephfs": { + SchemaProps: spec.SchemaProps{ + Description: "cephFS represents a Ceph FS mount on the host that shares a pod's lifetime. Deprecated: CephFS is deprecated and the in-tree cephfs type is no longer supported.", + Ref: ref(v1.CephFSPersistentVolumeSource{}.OpenAPIModelName()), + }, + }, + "fc": { + SchemaProps: spec.SchemaProps{ + Description: "fc represents a Fibre Channel resource that is attached to a kubelet's host machine and then exposed to the pod.", + Ref: ref(v1.FCVolumeSource{}.OpenAPIModelName()), + }, + }, + "flocker": { + SchemaProps: spec.SchemaProps{ + Description: "flocker represents a Flocker volume attached to a kubelet's host machine and exposed to the pod for its usage. This depends on the Flocker control service being running. Deprecated: Flocker is deprecated and the in-tree flocker type is no longer supported.", + Ref: ref(v1.FlockerVolumeSource{}.OpenAPIModelName()), + }, + }, + "flexVolume": { + SchemaProps: spec.SchemaProps{ + Description: "flexVolume represents a generic volume resource that is provisioned/attached using an exec based plugin. Deprecated: FlexVolume is deprecated. Consider using a CSIDriver instead.", + Ref: ref(v1.FlexPersistentVolumeSource{}.OpenAPIModelName()), + }, + }, + "azureFile": { + SchemaProps: spec.SchemaProps{ + Description: "azureFile represents an Azure File Service mount on the host and bind mount to the pod. Deprecated: AzureFile is deprecated. All operations for the in-tree azureFile type are redirected to the file.csi.azure.com CSI driver.", + Ref: ref(v1.AzureFilePersistentVolumeSource{}.OpenAPIModelName()), + }, + }, + "vsphereVolume": { + SchemaProps: spec.SchemaProps{ + Description: "vsphereVolume represents a vSphere volume attached and mounted on kubelets host machine. Deprecated: VsphereVolume is deprecated. All operations for the in-tree vsphereVolume type are redirected to the csi.vsphere.vmware.com CSI driver.", + Ref: ref(v1.VsphereVirtualDiskVolumeSource{}.OpenAPIModelName()), + }, + }, + "quobyte": { + SchemaProps: spec.SchemaProps{ + Description: "quobyte represents a Quobyte mount on the host that shares a pod's lifetime. Deprecated: Quobyte is deprecated and the in-tree quobyte type is no longer supported.", + Ref: ref(v1.QuobyteVolumeSource{}.OpenAPIModelName()), + }, + }, + "azureDisk": { + SchemaProps: spec.SchemaProps{ + Description: "azureDisk represents an Azure Data Disk mount on the host and bind mount to the pod. Deprecated: AzureDisk is deprecated. All operations for the in-tree azureDisk type are redirected to the disk.csi.azure.com CSI driver.", + Ref: ref(v1.AzureDiskVolumeSource{}.OpenAPIModelName()), + }, + }, + "photonPersistentDisk": { + SchemaProps: spec.SchemaProps{ + Description: "photonPersistentDisk represents a PhotonController persistent disk attached and mounted on kubelets host machine. Deprecated: PhotonPersistentDisk is deprecated and the in-tree photonPersistentDisk type is no longer supported.", + Ref: ref(v1.PhotonPersistentDiskVolumeSource{}.OpenAPIModelName()), + }, + }, + "portworxVolume": { + SchemaProps: spec.SchemaProps{ + Description: "portworxVolume represents a portworx volume attached and mounted on kubelets host machine. Deprecated: PortworxVolume is deprecated. All operations for the in-tree portworxVolume type are redirected to the pxd.portworx.com CSI driver when the CSIMigrationPortworx feature-gate is on.", + Ref: ref(v1.PortworxVolumeSource{}.OpenAPIModelName()), + }, + }, + "scaleIO": { + SchemaProps: spec.SchemaProps{ + Description: "scaleIO represents a ScaleIO persistent volume attached and mounted on Kubernetes nodes. Deprecated: ScaleIO is deprecated and the in-tree scaleIO type is no longer supported.", + Ref: ref(v1.ScaleIOPersistentVolumeSource{}.OpenAPIModelName()), + }, + }, + "local": { + SchemaProps: spec.SchemaProps{ + Description: "local represents directly-attached storage with node affinity", + Ref: ref(v1.LocalVolumeSource{}.OpenAPIModelName()), + }, + }, + "storageos": { + SchemaProps: spec.SchemaProps{ + Description: "storageOS represents a StorageOS volume that is attached to the kubelet's host machine and mounted into the pod. Deprecated: StorageOS is deprecated and the in-tree storageos type is no longer supported. More info: https://examples.k8s.io/volumes/storageos/README.md", + Ref: ref(v1.StorageOSPersistentVolumeSource{}.OpenAPIModelName()), + }, + }, + "csi": { + SchemaProps: spec.SchemaProps{ + Description: "csi represents storage that is handled by an external CSI driver.", + Ref: ref(v1.CSIPersistentVolumeSource{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + Dependencies: []string{ + v1.AWSElasticBlockStoreVolumeSource{}.OpenAPIModelName(), v1.AzureDiskVolumeSource{}.OpenAPIModelName(), v1.AzureFilePersistentVolumeSource{}.OpenAPIModelName(), v1.CSIPersistentVolumeSource{}.OpenAPIModelName(), v1.CephFSPersistentVolumeSource{}.OpenAPIModelName(), v1.CinderPersistentVolumeSource{}.OpenAPIModelName(), v1.FCVolumeSource{}.OpenAPIModelName(), v1.FlexPersistentVolumeSource{}.OpenAPIModelName(), v1.FlockerVolumeSource{}.OpenAPIModelName(), v1.GCEPersistentDiskVolumeSource{}.OpenAPIModelName(), v1.GlusterfsPersistentVolumeSource{}.OpenAPIModelName(), v1.HostPathVolumeSource{}.OpenAPIModelName(), v1.ISCSIPersistentVolumeSource{}.OpenAPIModelName(), v1.LocalVolumeSource{}.OpenAPIModelName(), v1.NFSVolumeSource{}.OpenAPIModelName(), v1.PhotonPersistentDiskVolumeSource{}.OpenAPIModelName(), v1.PortworxVolumeSource{}.OpenAPIModelName(), v1.QuobyteVolumeSource{}.OpenAPIModelName(), v1.RBDPersistentVolumeSource{}.OpenAPIModelName(), v1.ScaleIOPersistentVolumeSource{}.OpenAPIModelName(), v1.StorageOSPersistentVolumeSource{}.OpenAPIModelName(), v1.VsphereVirtualDiskVolumeSource{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_PersistentVolumeSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "PersistentVolumeSpec is the specification of a persistent volume.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "capacity": { + SchemaProps: spec.SchemaProps{ + Description: "capacity is the description of the persistent volume's resources and capacity. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#capacity", + Type: []string{"object"}, + AdditionalProperties: &spec.SchemaOrBool{ + Allows: true, + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Ref: ref(resource.Quantity{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "gcePersistentDisk": { + SchemaProps: spec.SchemaProps{ + Description: "gcePersistentDisk represents a GCE Disk resource that is attached to a kubelet's host machine and then exposed to the pod. Provisioned by an admin. Deprecated: GCEPersistentDisk is deprecated. All operations for the in-tree gcePersistentDisk type are redirected to the pd.csi.storage.gke.io CSI driver. More info: https://kubernetes.io/docs/concepts/storage/volumes#gcepersistentdisk", + Ref: ref(v1.GCEPersistentDiskVolumeSource{}.OpenAPIModelName()), + }, + }, + "awsElasticBlockStore": { + SchemaProps: spec.SchemaProps{ + Description: "awsElasticBlockStore represents an AWS Disk resource that is attached to a kubelet's host machine and then exposed to the pod. Deprecated: AWSElasticBlockStore is deprecated. All operations for the in-tree awsElasticBlockStore type are redirected to the ebs.csi.aws.com CSI driver. More info: https://kubernetes.io/docs/concepts/storage/volumes#awselasticblockstore", + Ref: ref(v1.AWSElasticBlockStoreVolumeSource{}.OpenAPIModelName()), + }, + }, + "hostPath": { + SchemaProps: spec.SchemaProps{ + Description: "hostPath represents a directory on the host. Provisioned by a developer or tester. This is useful for single-node development and testing only! On-host storage is not supported in any way and WILL NOT WORK in a multi-node cluster. More info: https://kubernetes.io/docs/concepts/storage/volumes#hostpath", + Ref: ref(v1.HostPathVolumeSource{}.OpenAPIModelName()), + }, + }, + "glusterfs": { + SchemaProps: spec.SchemaProps{ + Description: "glusterfs represents a Glusterfs volume that is attached to a host and exposed to the pod. Provisioned by an admin. Deprecated: Glusterfs is deprecated and the in-tree glusterfs type is no longer supported. More info: https://examples.k8s.io/volumes/glusterfs/README.md", + Ref: ref(v1.GlusterfsPersistentVolumeSource{}.OpenAPIModelName()), + }, + }, + "nfs": { + SchemaProps: spec.SchemaProps{ + Description: "nfs represents an NFS mount on the host. Provisioned by an admin. More info: https://kubernetes.io/docs/concepts/storage/volumes#nfs", + Ref: ref(v1.NFSVolumeSource{}.OpenAPIModelName()), + }, + }, + "rbd": { + SchemaProps: spec.SchemaProps{ + Description: "rbd represents a Rados Block Device mount on the host that shares a pod's lifetime. Deprecated: RBD is deprecated and the in-tree rbd type is no longer supported. More info: https://examples.k8s.io/volumes/rbd/README.md", + Ref: ref(v1.RBDPersistentVolumeSource{}.OpenAPIModelName()), + }, + }, + "iscsi": { + SchemaProps: spec.SchemaProps{ + Description: "iscsi represents an ISCSI Disk resource that is attached to a kubelet's host machine and then exposed to the pod. Provisioned by an admin.", + Ref: ref(v1.ISCSIPersistentVolumeSource{}.OpenAPIModelName()), + }, + }, + "cinder": { + SchemaProps: spec.SchemaProps{ + Description: "cinder represents a cinder volume attached and mounted on kubelets host machine. Deprecated: Cinder is deprecated. All operations for the in-tree cinder type are redirected to the cinder.csi.openstack.org CSI driver. More info: https://examples.k8s.io/mysql-cinder-pd/README.md", + Ref: ref(v1.CinderPersistentVolumeSource{}.OpenAPIModelName()), + }, + }, + "cephfs": { + SchemaProps: spec.SchemaProps{ + Description: "cephFS represents a Ceph FS mount on the host that shares a pod's lifetime. Deprecated: CephFS is deprecated and the in-tree cephfs type is no longer supported.", + Ref: ref(v1.CephFSPersistentVolumeSource{}.OpenAPIModelName()), + }, + }, + "fc": { + SchemaProps: spec.SchemaProps{ + Description: "fc represents a Fibre Channel resource that is attached to a kubelet's host machine and then exposed to the pod.", + Ref: ref(v1.FCVolumeSource{}.OpenAPIModelName()), + }, + }, + "flocker": { + SchemaProps: spec.SchemaProps{ + Description: "flocker represents a Flocker volume attached to a kubelet's host machine and exposed to the pod for its usage. This depends on the Flocker control service being running. Deprecated: Flocker is deprecated and the in-tree flocker type is no longer supported.", + Ref: ref(v1.FlockerVolumeSource{}.OpenAPIModelName()), + }, + }, + "flexVolume": { + SchemaProps: spec.SchemaProps{ + Description: "flexVolume represents a generic volume resource that is provisioned/attached using an exec based plugin. Deprecated: FlexVolume is deprecated. Consider using a CSIDriver instead.", + Ref: ref(v1.FlexPersistentVolumeSource{}.OpenAPIModelName()), + }, + }, + "azureFile": { + SchemaProps: spec.SchemaProps{ + Description: "azureFile represents an Azure File Service mount on the host and bind mount to the pod. Deprecated: AzureFile is deprecated. All operations for the in-tree azureFile type are redirected to the file.csi.azure.com CSI driver.", + Ref: ref(v1.AzureFilePersistentVolumeSource{}.OpenAPIModelName()), + }, + }, + "vsphereVolume": { + SchemaProps: spec.SchemaProps{ + Description: "vsphereVolume represents a vSphere volume attached and mounted on kubelets host machine. Deprecated: VsphereVolume is deprecated. All operations for the in-tree vsphereVolume type are redirected to the csi.vsphere.vmware.com CSI driver.", + Ref: ref(v1.VsphereVirtualDiskVolumeSource{}.OpenAPIModelName()), + }, + }, + "quobyte": { + SchemaProps: spec.SchemaProps{ + Description: "quobyte represents a Quobyte mount on the host that shares a pod's lifetime. Deprecated: Quobyte is deprecated and the in-tree quobyte type is no longer supported.", + Ref: ref(v1.QuobyteVolumeSource{}.OpenAPIModelName()), + }, + }, + "azureDisk": { + SchemaProps: spec.SchemaProps{ + Description: "azureDisk represents an Azure Data Disk mount on the host and bind mount to the pod. Deprecated: AzureDisk is deprecated. All operations for the in-tree azureDisk type are redirected to the disk.csi.azure.com CSI driver.", + Ref: ref(v1.AzureDiskVolumeSource{}.OpenAPIModelName()), + }, + }, + "photonPersistentDisk": { + SchemaProps: spec.SchemaProps{ + Description: "photonPersistentDisk represents a PhotonController persistent disk attached and mounted on kubelets host machine. Deprecated: PhotonPersistentDisk is deprecated and the in-tree photonPersistentDisk type is no longer supported.", + Ref: ref(v1.PhotonPersistentDiskVolumeSource{}.OpenAPIModelName()), + }, + }, + "portworxVolume": { + SchemaProps: spec.SchemaProps{ + Description: "portworxVolume represents a portworx volume attached and mounted on kubelets host machine. Deprecated: PortworxVolume is deprecated. All operations for the in-tree portworxVolume type are redirected to the pxd.portworx.com CSI driver when the CSIMigrationPortworx feature-gate is on.", + Ref: ref(v1.PortworxVolumeSource{}.OpenAPIModelName()), + }, + }, + "scaleIO": { + SchemaProps: spec.SchemaProps{ + Description: "scaleIO represents a ScaleIO persistent volume attached and mounted on Kubernetes nodes. Deprecated: ScaleIO is deprecated and the in-tree scaleIO type is no longer supported.", + Ref: ref(v1.ScaleIOPersistentVolumeSource{}.OpenAPIModelName()), + }, + }, + "local": { + SchemaProps: spec.SchemaProps{ + Description: "local represents directly-attached storage with node affinity", + Ref: ref(v1.LocalVolumeSource{}.OpenAPIModelName()), + }, + }, + "storageos": { + SchemaProps: spec.SchemaProps{ + Description: "storageOS represents a StorageOS volume that is attached to the kubelet's host machine and mounted into the pod. Deprecated: StorageOS is deprecated and the in-tree storageos type is no longer supported. More info: https://examples.k8s.io/volumes/storageos/README.md", + Ref: ref(v1.StorageOSPersistentVolumeSource{}.OpenAPIModelName()), + }, + }, + "csi": { + SchemaProps: spec.SchemaProps{ + Description: "csi represents storage that is handled by an external CSI driver.", + Ref: ref(v1.CSIPersistentVolumeSource{}.OpenAPIModelName()), + }, + }, + "accessModes": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "accessModes contains all ways the volume can be mounted. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#access-modes", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + Enum: []interface{}{"ReadOnlyMany", "ReadWriteMany", "ReadWriteOnce", "ReadWriteOncePod"}, + }, + }, + }, + }, + }, + "claimRef": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-map-type": "granular", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "claimRef is part of a bi-directional binding between PersistentVolume and PersistentVolumeClaim. Expected to be non-nil when bound. claim.VolumeName is the authoritative bind between PV and PVC. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#binding", + Ref: ref(v1.ObjectReference{}.OpenAPIModelName()), + }, + }, + "persistentVolumeReclaimPolicy": { + SchemaProps: spec.SchemaProps{ + Description: "persistentVolumeReclaimPolicy defines what happens to a persistent volume when released from its claim. Valid options are Retain (default for manually created PersistentVolumes), Delete (default for dynamically provisioned PersistentVolumes), and Recycle (deprecated). Recycle must be supported by the volume plugin underlying this PersistentVolume. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#reclaiming\n\nPossible enum values:\n - `\"Delete\"` means the volume will be deleted from Kubernetes on release from its claim. The volume plugin must support Deletion.\n - `\"Recycle\"` means the volume will be recycled back into the pool of unbound persistent volumes on release from its claim. The volume plugin must support Recycling.\n - `\"Retain\"` means the volume will be left in its current phase (Released) for manual reclamation by the administrator. The default policy is Retain.", + Type: []string{"string"}, + Format: "", + Enum: []interface{}{"Delete", "Recycle", "Retain"}, + }, + }, + "storageClassName": { + SchemaProps: spec.SchemaProps{ + Description: "storageClassName is the name of StorageClass to which this persistent volume belongs. Empty value means that this volume does not belong to any StorageClass.", + Type: []string{"string"}, + Format: "", + }, + }, + "mountOptions": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "mountOptions is the list of mount options, e.g. [\"ro\", \"soft\"]. Not validated - mount will simply fail if one is invalid. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes/#mount-options", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + "volumeMode": { + SchemaProps: spec.SchemaProps{ + Description: "volumeMode defines if a volume is intended to be used with a formatted filesystem or to remain in raw block state. Value of Filesystem is implied when not included in spec.\n\nPossible enum values:\n - `\"Block\"` means the volume will not be formatted with a filesystem and will remain a raw block device.\n - `\"Filesystem\"` means the volume will be or is formatted with a filesystem.", + Type: []string{"string"}, + Format: "", + Enum: []interface{}{"Block", "Filesystem"}, + }, + }, + "nodeAffinity": { + SchemaProps: spec.SchemaProps{ + Description: "nodeAffinity defines constraints that limit what nodes this volume can be accessed from. This field influences the scheduling of pods that use this volume. This field is mutable if MutablePVNodeAffinity feature gate is enabled.", + Ref: ref(v1.VolumeNodeAffinity{}.OpenAPIModelName()), + }, + }, + "volumeAttributesClassName": { + SchemaProps: spec.SchemaProps{ + Description: "Name of VolumeAttributesClass to which this persistent volume belongs. Empty value is not allowed. When this field is not set, it indicates that this volume does not belong to any VolumeAttributesClass. This field is mutable and can be changed by the CSI driver after a volume has been updated successfully to a new class. For an unbound PersistentVolume, the volumeAttributesClassName will be matched with unbound PersistentVolumeClaims during the binding process.", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + Dependencies: []string{ + v1.AWSElasticBlockStoreVolumeSource{}.OpenAPIModelName(), v1.AzureDiskVolumeSource{}.OpenAPIModelName(), v1.AzureFilePersistentVolumeSource{}.OpenAPIModelName(), v1.CSIPersistentVolumeSource{}.OpenAPIModelName(), v1.CephFSPersistentVolumeSource{}.OpenAPIModelName(), v1.CinderPersistentVolumeSource{}.OpenAPIModelName(), v1.FCVolumeSource{}.OpenAPIModelName(), v1.FlexPersistentVolumeSource{}.OpenAPIModelName(), v1.FlockerVolumeSource{}.OpenAPIModelName(), v1.GCEPersistentDiskVolumeSource{}.OpenAPIModelName(), v1.GlusterfsPersistentVolumeSource{}.OpenAPIModelName(), v1.HostPathVolumeSource{}.OpenAPIModelName(), v1.ISCSIPersistentVolumeSource{}.OpenAPIModelName(), v1.LocalVolumeSource{}.OpenAPIModelName(), v1.NFSVolumeSource{}.OpenAPIModelName(), v1.ObjectReference{}.OpenAPIModelName(), v1.PhotonPersistentDiskVolumeSource{}.OpenAPIModelName(), v1.PortworxVolumeSource{}.OpenAPIModelName(), v1.QuobyteVolumeSource{}.OpenAPIModelName(), v1.RBDPersistentVolumeSource{}.OpenAPIModelName(), v1.ScaleIOPersistentVolumeSource{}.OpenAPIModelName(), v1.StorageOSPersistentVolumeSource{}.OpenAPIModelName(), v1.VolumeNodeAffinity{}.OpenAPIModelName(), v1.VsphereVirtualDiskVolumeSource{}.OpenAPIModelName(), resource.Quantity{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_PersistentVolumeStatus(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "PersistentVolumeStatus is the current status of a persistent volume.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "phase": { + SchemaProps: spec.SchemaProps{ + Description: "phase indicates if a volume is available, bound to a claim, or released by a claim. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#phase\n\nPossible enum values:\n - `\"Available\"` used for PersistentVolumes that are not yet bound Available volumes are held by the binder and matched to PersistentVolumeClaims\n - `\"Bound\"` used for PersistentVolumes that are bound\n - `\"Failed\"` used for PersistentVolumes that failed to be correctly recycled or deleted after being released from a claim\n - `\"Pending\"` used for PersistentVolumes that are not available\n - `\"Released\"` used for PersistentVolumes where the bound PersistentVolumeClaim was deleted released volumes must be recycled before becoming available again this phase is used by the persistent volume claim binder to signal to another process to reclaim the resource", + Type: []string{"string"}, + Format: "", + Enum: []interface{}{"Available", "Bound", "Failed", "Pending", "Released"}, + }, + }, + "message": { + SchemaProps: spec.SchemaProps{ + Description: "message is a human-readable message indicating details about why the volume is in this state.", + Type: []string{"string"}, + Format: "", + }, + }, + "reason": { + SchemaProps: spec.SchemaProps{ + Description: "reason is a brief CamelCase string that describes any failure and is meant for machine parsing and tidy display in the CLI.", + Type: []string{"string"}, + Format: "", + }, + }, + "lastPhaseTransitionTime": { + SchemaProps: spec.SchemaProps{ + Description: "lastPhaseTransitionTime is the time the phase transitioned from one to another and automatically resets to current time everytime a volume phase transitions.", + Ref: ref(metav1.Time{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + Dependencies: []string{ + metav1.Time{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_PhotonPersistentDiskVolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "Represents a Photon Controller persistent disk resource.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "pdID": { + SchemaProps: spec.SchemaProps{ + Description: "pdID is the ID that identifies Photon Controller persistent disk", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "fsType": { + SchemaProps: spec.SchemaProps{ + Description: "fsType is the filesystem type to mount. Must be a filesystem type supported by the host operating system. Ex. \"ext4\", \"xfs\", \"ntfs\". Implicitly inferred to be \"ext4\" if unspecified.", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"pdID"}, + }, + }, + } +} + +func schema_k8sio_api_core_v1_Pod(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "Pod is a collection of containers that can run on a host. This resource is created by clients and scheduled onto hosts.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "metadata": { + SchemaProps: spec.SchemaProps{ + Description: "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata", + Default: map[string]interface{}{}, + Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), + }, + }, + "spec": { + SchemaProps: spec.SchemaProps{ + Description: "Specification of the desired behavior of the pod. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status", + Default: map[string]interface{}{}, + Ref: ref(v1.PodSpec{}.OpenAPIModelName()), + }, + }, + "status": { + SchemaProps: spec.SchemaProps{ + Description: "Most recently observed status of the pod. This data may not be up to date. Populated by the system. Read-only. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status", + Default: map[string]interface{}{}, + Ref: ref(v1.PodStatus{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + Dependencies: []string{ + v1.PodSpec{}.OpenAPIModelName(), v1.PodStatus{}.OpenAPIModelName(), metav1.ObjectMeta{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_PodAffinity(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "Pod affinity is a group of inter pod affinity scheduling rules.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "requiredDuringSchedulingIgnoredDuringExecution": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "If the affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system may or may not try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.PodAffinityTerm{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "preferredDuringSchedulingIgnoredDuringExecution": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "The scheduler will prefer to schedule pods to nodes that satisfy the affinity expressions specified by this field, but it may choose a node that violates one or more of the expressions. The node that is most preferred is the one with the greatest sum of weights, i.e. for each node that meets all of the scheduling requirements (resource request, requiredDuringScheduling affinity expressions, etc.), compute a sum by iterating through the elements of this field and adding \"weight\" to the sum if the node has pods which matches the corresponding podAffinityTerm; the node(s) with the highest sum are the most preferred.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.WeightedPodAffinityTerm{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + }, + }, + }, + Dependencies: []string{ + v1.PodAffinityTerm{}.OpenAPIModelName(), v1.WeightedPodAffinityTerm{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_PodAffinityTerm(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "Defines a set of pods (namely those matching the labelSelector relative to the given namespace(s)) that this pod should be co-located (affinity) or not co-located (anti-affinity) with, where co-located is defined as running on a node whose value of the label with key matches that of any node on which a pod of the set of pods is running", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "labelSelector": { + SchemaProps: spec.SchemaProps{ + Description: "A label query over a set of resources, in this case pods. If it's null, this PodAffinityTerm matches with no Pods.", + Ref: ref(metav1.LabelSelector{}.OpenAPIModelName()), + }, + }, + "namespaces": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "namespaces specifies a static list of namespace names that the term applies to. The term is applied to the union of the namespaces listed in this field and the ones selected by namespaceSelector. null or empty namespaces list and null namespaceSelector means \"this pod's namespace\".", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + "topologyKey": { + SchemaProps: spec.SchemaProps{ + Description: "This pod should be co-located (affinity) or not co-located (anti-affinity) with the pods matching the labelSelector in the specified namespaces, where co-located is defined as running on a node whose value of the label with key topologyKey matches that of any node on which any of the selected pods is running. Empty topologyKey is not allowed.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "namespaceSelector": { + SchemaProps: spec.SchemaProps{ + Description: "A label query over the set of namespaces that the term applies to. The term is applied to the union of the namespaces selected by this field and the ones listed in the namespaces field. null selector and null or empty namespaces list means \"this pod's namespace\". An empty selector ({}) matches all namespaces.", + Ref: ref(metav1.LabelSelector{}.OpenAPIModelName()), + }, + }, + "matchLabelKeys": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "MatchLabelKeys is a set of pod label keys to select which pods will be taken into consideration. The keys are used to lookup values from the incoming pod labels, those key-value labels are merged with `labelSelector` as `key in (value)` to select the group of existing pods which pods will be taken into consideration for the incoming pod's pod (anti) affinity. Keys that don't exist in the incoming pod labels will be ignored. The default value is empty. The same key is forbidden to exist in both matchLabelKeys and labelSelector. Also, matchLabelKeys cannot be set when labelSelector isn't set.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + "mismatchLabelKeys": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "MismatchLabelKeys is a set of pod label keys to select which pods will be taken into consideration. The keys are used to lookup values from the incoming pod labels, those key-value labels are merged with `labelSelector` as `key notin (value)` to select the group of existing pods which pods will be taken into consideration for the incoming pod's pod (anti) affinity. Keys that don't exist in the incoming pod labels will be ignored. The default value is empty. The same key is forbidden to exist in both mismatchLabelKeys and labelSelector. Also, mismatchLabelKeys cannot be set when labelSelector isn't set.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + }, + Required: []string{"topologyKey"}, + }, + }, + Dependencies: []string{ + metav1.LabelSelector{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_PodAntiAffinity(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "Pod anti affinity is a group of inter pod anti affinity scheduling rules.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "requiredDuringSchedulingIgnoredDuringExecution": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "If the anti-affinity requirements specified by this field are not met at scheduling time, the pod will not be scheduled onto the node. If the anti-affinity requirements specified by this field cease to be met at some point during pod execution (e.g. due to a pod label update), the system may or may not try to eventually evict the pod from its node. When there are multiple elements, the lists of nodes corresponding to each podAffinityTerm are intersected, i.e. all terms must be satisfied.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.PodAffinityTerm{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "preferredDuringSchedulingIgnoredDuringExecution": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "The scheduler will prefer to schedule pods to nodes that satisfy the anti-affinity expressions specified by this field, but it may choose a node that violates one or more of the expressions. The node that is most preferred is the one with the greatest sum of weights, i.e. for each node that meets all of the scheduling requirements (resource request, requiredDuringScheduling anti-affinity expressions, etc.), compute a sum by iterating through the elements of this field and subtracting \"weight\" from the sum if the node has pods which matches the corresponding podAffinityTerm; the node(s) with the highest sum are the most preferred.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.WeightedPodAffinityTerm{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + }, + }, + }, + Dependencies: []string{ + v1.PodAffinityTerm{}.OpenAPIModelName(), v1.WeightedPodAffinityTerm{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_PodAttachOptions(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "PodAttachOptions is the query options to a Pod's remote attach call.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "stdin": { + SchemaProps: spec.SchemaProps{ + Description: "Stdin if true, redirects the standard input stream of the pod for this call. Defaults to false.", + Type: []string{"boolean"}, + Format: "", + }, + }, + "stdout": { + SchemaProps: spec.SchemaProps{ + Description: "Stdout if true indicates that stdout is to be redirected for the attach call. Defaults to true.", + Type: []string{"boolean"}, + Format: "", + }, + }, + "stderr": { + SchemaProps: spec.SchemaProps{ + Description: "Stderr if true indicates that stderr is to be redirected for the attach call. Defaults to true.", + Type: []string{"boolean"}, + Format: "", + }, + }, + "tty": { + SchemaProps: spec.SchemaProps{ + Description: "TTY if true indicates that a tty will be allocated for the attach call. This is passed through the container runtime so the tty is allocated on the worker node by the container runtime. Defaults to false.", + Type: []string{"boolean"}, + Format: "", + }, + }, + "container": { + SchemaProps: spec.SchemaProps{ + Description: "The container in which to execute the command. Defaults to only container if there is only one container in the pod.", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + } +} + +func schema_k8sio_api_core_v1_PodCertificateProjection(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "PodCertificateProjection provides a private key and X.509 certificate in the pod filesystem.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "signerName": { + SchemaProps: spec.SchemaProps{ + Description: "Kubelet's generated CSRs will be addressed to this signer.", + Type: []string{"string"}, + Format: "", + }, + }, + "keyType": { + SchemaProps: spec.SchemaProps{ + Description: "The type of keypair Kubelet will generate for the pod.\n\nValid values are \"RSA3072\", \"RSA4096\", \"ECDSAP256\", \"ECDSAP384\", \"ECDSAP521\", and \"ED25519\".", + Type: []string{"string"}, + Format: "", + }, + }, + "maxExpirationSeconds": { + SchemaProps: spec.SchemaProps{ + Description: "maxExpirationSeconds is the maximum lifetime permitted for the certificate.\n\nKubelet copies this value verbatim into the PodCertificateRequests it generates for this projection.\n\nIf omitted, kube-apiserver will set it to 86400(24 hours). kube-apiserver will reject values shorter than 3600 (1 hour). The maximum allowable value is 7862400 (91 days).\n\nThe signer implementation is then free to issue a certificate with any lifetime *shorter* than MaxExpirationSeconds, but no shorter than 3600 seconds (1 hour). This constraint is enforced by kube-apiserver. `kubernetes.io` signers will never issue certificates with a lifetime longer than 24 hours.", + Type: []string{"integer"}, + Format: "int32", + }, + }, + "credentialBundlePath": { + SchemaProps: spec.SchemaProps{ + Description: "Write the credential bundle at this path in the projected volume.\n\nThe credential bundle is a single file that contains multiple PEM blocks. The first PEM block is a PRIVATE KEY block, containing a PKCS#8 private key.\n\nThe remaining blocks are CERTIFICATE blocks, containing the issued certificate chain from the signer (leaf and any intermediates).\n\nUsing credentialBundlePath lets your Pod's application code make a single atomic read that retrieves a consistent key and certificate chain. If you project them to separate files, your application code will need to additionally check that the leaf certificate was issued to the key.", + Type: []string{"string"}, + Format: "", + }, + }, + "keyPath": { + SchemaProps: spec.SchemaProps{ + Description: "Write the key at this path in the projected volume.\n\nMost applications should use credentialBundlePath. When using keyPath and certificateChainPath, your application needs to check that the key and leaf certificate are consistent, because it is possible to read the files mid-rotation.", + Type: []string{"string"}, + Format: "", + }, + }, + "certificateChainPath": { + SchemaProps: spec.SchemaProps{ + Description: "Write the certificate chain at this path in the projected volume.\n\nMost applications should use credentialBundlePath. When using keyPath and certificateChainPath, your application needs to check that the key and leaf certificate are consistent, because it is possible to read the files mid-rotation.", + Type: []string{"string"}, + Format: "", + }, + }, + "userAnnotations": { + SchemaProps: spec.SchemaProps{ + Description: "userAnnotations allow pod authors to pass additional information to the signer implementation. Kubernetes does not restrict or validate this metadata in any way.\n\nThese values are copied verbatim into the `spec.unverifiedUserAnnotations` field of the PodCertificateRequest objects that Kubelet creates.\n\nEntries are subject to the same validation as object metadata annotations, with the addition that all keys must be domain-prefixed. No restrictions are placed on values, except an overall size limitation on the entire field.\n\nSigners should document the keys and values they support. Signers should deny requests that contain keys they do not recognize.", + Type: []string{"object"}, + AdditionalProperties: &spec.SchemaOrBool{ + Allows: true, + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + }, + Required: []string{"signerName", "keyType"}, + }, + }, + } +} + +func schema_k8sio_api_core_v1_PodCondition(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "PodCondition contains details for the current condition of this pod.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "type": { + SchemaProps: spec.SchemaProps{ + Description: "Type is the type of the condition. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#pod-conditions", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "observedGeneration": { + SchemaProps: spec.SchemaProps{ + Description: "If set, this represents the .metadata.generation that the pod condition was set based upon. The PodObservedGenerationTracking feature gate must be enabled to use this field.", + Type: []string{"integer"}, + Format: "int64", + }, + }, + "status": { + SchemaProps: spec.SchemaProps{ + Description: "Status is the status of the condition. Can be True, False, Unknown. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#pod-conditions", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "lastProbeTime": { + SchemaProps: spec.SchemaProps{ + Description: "Last time we probed the condition.", + Ref: ref(metav1.Time{}.OpenAPIModelName()), + }, + }, + "lastTransitionTime": { + SchemaProps: spec.SchemaProps{ + Description: "Last time the condition transitioned from one status to another.", + Ref: ref(metav1.Time{}.OpenAPIModelName()), + }, + }, + "reason": { + SchemaProps: spec.SchemaProps{ + Description: "Unique, one-word, CamelCase reason for the condition's last transition.", + Type: []string{"string"}, + Format: "", + }, + }, + "message": { + SchemaProps: spec.SchemaProps{ + Description: "Human-readable message indicating details about last transition.", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"type", "status"}, + }, + }, + Dependencies: []string{ + metav1.Time{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_PodDNSConfig(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "PodDNSConfig defines the DNS parameters of a pod in addition to those generated from DNSPolicy.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "nameservers": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "A list of DNS name server IP addresses. This will be appended to the base nameservers generated from DNSPolicy. Duplicated nameservers will be removed.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + "searches": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "A list of DNS search domains for host-name lookup. This will be appended to the base search paths generated from DNSPolicy. Duplicated search paths will be removed.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + "options": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "A list of DNS resolver options. This will be merged with the base options generated from DNSPolicy. Duplicated entries will be removed. Resolution options given in Options will override those that appear in the base DNSPolicy.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.PodDNSConfigOption{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + }, + }, + }, + Dependencies: []string{ + v1.PodDNSConfigOption{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_PodDNSConfigOption(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "PodDNSConfigOption defines DNS resolver options of a pod.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "name": { + SchemaProps: spec.SchemaProps{ + Description: "Name is this DNS resolver option's name. Required.", + Type: []string{"string"}, + Format: "", + }, + }, + "value": { + SchemaProps: spec.SchemaProps{ + Description: "Value is this DNS resolver option's value.", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + } +} + +func schema_k8sio_api_core_v1_PodExecOptions(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "PodExecOptions is the query options to a Pod's remote exec call.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "stdin": { + SchemaProps: spec.SchemaProps{ + Description: "Redirect the standard input stream of the pod for this call. Defaults to false.", + Type: []string{"boolean"}, + Format: "", + }, + }, + "stdout": { + SchemaProps: spec.SchemaProps{ + Description: "Redirect the standard output stream of the pod for this call.", + Type: []string{"boolean"}, + Format: "", + }, + }, + "stderr": { + SchemaProps: spec.SchemaProps{ + Description: "Redirect the standard error stream of the pod for this call.", + Type: []string{"boolean"}, + Format: "", + }, + }, + "tty": { + SchemaProps: spec.SchemaProps{ + Description: "TTY if true indicates that a tty will be allocated for the exec call. Defaults to false.", + Type: []string{"boolean"}, + Format: "", + }, + }, + "container": { + SchemaProps: spec.SchemaProps{ + Description: "Container in which to execute the command. Defaults to only container if there is only one container in the pod.", + Type: []string{"string"}, + Format: "", + }, + }, + "command": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "Command is the remote command to execute. argv array. Not executed within a shell.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + }, + Required: []string{"command"}, + }, + }, + } +} + +func schema_k8sio_api_core_v1_PodExtendedResourceClaimStatus(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "PodExtendedResourceClaimStatus is stored in the PodStatus for the extended resource requests backed by DRA. It stores the generated name for the corresponding special ResourceClaim created by the scheduler.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "requestMappings": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "RequestMappings identifies the mapping of to device request in the generated ResourceClaim.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.ContainerExtendedResourceRequest{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "resourceClaimName": { + SchemaProps: spec.SchemaProps{ + Description: "ResourceClaimName is the name of the ResourceClaim that was generated for the Pod in the namespace of the Pod.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"requestMappings", "resourceClaimName"}, + }, + }, + Dependencies: []string{ + v1.ContainerExtendedResourceRequest{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_PodIP(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "PodIP represents a single IP address allocated to the pod.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "ip": { + SchemaProps: spec.SchemaProps{ + Description: "IP is the IP address assigned to the pod", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"ip"}, + }, + }, + } +} + +func schema_k8sio_api_core_v1_PodList(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "PodList is a list of Pods.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "metadata": { + SchemaProps: spec.SchemaProps{ + Description: "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Default: map[string]interface{}{}, + Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), + }, + }, + "items": { + SchemaProps: spec.SchemaProps{ + Description: "List of pods. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.Pod{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + }, + Required: []string{"items"}, + }, + }, + Dependencies: []string{ + v1.Pod{}.OpenAPIModelName(), metav1.ListMeta{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_PodLogOptions(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "PodLogOptions is the query options for a Pod's logs REST call.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "container": { + SchemaProps: spec.SchemaProps{ + Description: "The container for which to stream logs. Defaults to only container if there is one container in the pod.", + Type: []string{"string"}, + Format: "", + }, + }, + "follow": { + SchemaProps: spec.SchemaProps{ + Description: "Follow the log stream of the pod. Defaults to false.", + Type: []string{"boolean"}, + Format: "", + }, + }, + "previous": { + SchemaProps: spec.SchemaProps{ + Description: "Return previous terminated container logs. Defaults to false.", + Type: []string{"boolean"}, + Format: "", + }, + }, + "sinceSeconds": { + SchemaProps: spec.SchemaProps{ + Description: "A relative time in seconds before the current time from which to show logs. If this value precedes the time a pod was started, only logs since the pod start will be returned. If this value is in the future, no logs will be returned. Only one of sinceSeconds or sinceTime may be specified.", + Type: []string{"integer"}, + Format: "int64", + }, + }, + "sinceTime": { + SchemaProps: spec.SchemaProps{ + Description: "An RFC3339 timestamp from which to show logs. If this value precedes the time a pod was started, only logs since the pod start will be returned. If this value is in the future, no logs will be returned. Only one of sinceSeconds or sinceTime may be specified.", + Ref: ref(metav1.Time{}.OpenAPIModelName()), + }, + }, + "timestamps": { + SchemaProps: spec.SchemaProps{ + Description: "If true, add an RFC3339 or RFC3339Nano timestamp at the beginning of every line of log output. Defaults to false.", + Type: []string{"boolean"}, + Format: "", + }, + }, + "tailLines": { + SchemaProps: spec.SchemaProps{ + Description: "If set, the number of lines from the end of the logs to show. If not specified, logs are shown from the creation of the container or sinceSeconds or sinceTime. Note that when \"TailLines\" is specified, \"Stream\" can only be set to nil or \"All\".", + Type: []string{"integer"}, + Format: "int64", + }, + }, + "limitBytes": { + SchemaProps: spec.SchemaProps{ + Description: "If set, the number of bytes to read from the server before terminating the log output. This may not display a complete final line of logging, and may return slightly more or slightly less than the specified limit.", + Type: []string{"integer"}, + Format: "int64", + }, + }, + "insecureSkipTLSVerifyBackend": { + SchemaProps: spec.SchemaProps{ + Description: "insecureSkipTLSVerifyBackend indicates that the apiserver should not confirm the validity of the serving certificate of the backend it is connecting to. This will make the HTTPS connection between the apiserver and the backend insecure. This means the apiserver cannot verify the log data it is receiving came from the real kubelet. If the kubelet is configured to verify the apiserver's TLS credentials, it does not mean the connection to the real kubelet is vulnerable to a man in the middle attack (e.g. an attacker could not intercept the actual log data coming from the real kubelet).", + Type: []string{"boolean"}, + Format: "", + }, + }, + "stream": { + SchemaProps: spec.SchemaProps{ + Description: "Specify which container log stream to return to the client. Acceptable values are \"All\", \"Stdout\" and \"Stderr\". If not specified, \"All\" is used, and both stdout and stderr are returned interleaved. Note that when \"TailLines\" is specified, \"Stream\" can only be set to nil or \"All\".", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + Dependencies: []string{ + metav1.Time{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_PodOS(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "PodOS defines the OS parameters of a pod.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "name": { + SchemaProps: spec.SchemaProps{ + Description: "Name is the name of the operating system. The currently supported values are linux and windows. Additional value may be defined in future and can be one of: https://github.com/opencontainers/runtime-spec/blob/master/config.md#platform-specific-configuration Clients should expect to handle additional values and treat unrecognized values in this field as os: null", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"name"}, + }, + }, + } +} + +func schema_k8sio_api_core_v1_PodPortForwardOptions(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "PodPortForwardOptions is the query options to a Pod's port forward call when using WebSockets. The `port` query parameter must specify the port or ports (comma separated) to forward over. Port forwarding over SPDY does not use these options. It requires the port to be passed in the `port` header as part of request.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "ports": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "List of ports to forward Required when using WebSockets", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: 0, + Type: []string{"integer"}, + Format: "int32", + }, + }, + }, + }, + }, + }, + }, + }, + } +} + +func schema_k8sio_api_core_v1_PodProxyOptions(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "PodProxyOptions is the query options to a Pod's proxy call.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "path": { + SchemaProps: spec.SchemaProps{ + Description: "Path is the URL path to use for the current proxy request to pod.", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + } +} + +func schema_k8sio_api_core_v1_PodReadinessGate(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "PodReadinessGate contains the reference to a pod condition", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "conditionType": { + SchemaProps: spec.SchemaProps{ + Description: "ConditionType refers to a condition in the pod's condition list with matching type.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"conditionType"}, + }, + }, + } +} + +func schema_k8sio_api_core_v1_PodResourceClaim(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "PodResourceClaim references exactly one ResourceClaim, either directly or by naming a ResourceClaimTemplate which is then turned into a ResourceClaim for the pod.\n\nIt adds a name to it that uniquely identifies the ResourceClaim inside the Pod. Containers that need access to the ResourceClaim reference it with this name.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "name": { + SchemaProps: spec.SchemaProps{ + Description: "Name uniquely identifies this resource claim inside the pod. This must be a DNS_LABEL.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "resourceClaimName": { + SchemaProps: spec.SchemaProps{ + Description: "ResourceClaimName is the name of a ResourceClaim object in the same namespace as this pod.\n\nExactly one of ResourceClaimName and ResourceClaimTemplateName must be set.", + Type: []string{"string"}, + Format: "", + }, + }, + "resourceClaimTemplateName": { + SchemaProps: spec.SchemaProps{ + Description: "ResourceClaimTemplateName is the name of a ResourceClaimTemplate object in the same namespace as this pod.\n\nThe template will be used to create a new ResourceClaim, which will be bound to this pod. When this pod is deleted, the ResourceClaim will also be deleted. The pod name and resource name, along with a generated component, will be used to form a unique name for the ResourceClaim, which will be recorded in pod.status.resourceClaimStatuses.\n\nThis field is immutable and no changes will be made to the corresponding ResourceClaim by the control plane after creating the ResourceClaim.\n\nExactly one of ResourceClaimName and ResourceClaimTemplateName must be set.", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"name"}, + }, + }, + } +} + +func schema_k8sio_api_core_v1_PodResourceClaimStatus(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "PodResourceClaimStatus is stored in the PodStatus for each PodResourceClaim which references a ResourceClaimTemplate. It stores the generated name for the corresponding ResourceClaim.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "name": { + SchemaProps: spec.SchemaProps{ + Description: "Name uniquely identifies this resource claim inside the pod. This must match the name of an entry in pod.spec.resourceClaims, which implies that the string must be a DNS_LABEL.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "resourceClaimName": { + SchemaProps: spec.SchemaProps{ + Description: "ResourceClaimName is the name of the ResourceClaim that was generated for the Pod in the namespace of the Pod. If this is unset, then generating a ResourceClaim was not necessary. The pod.spec.resourceClaims entry can be ignored in this case.", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"name"}, + }, + }, + } +} + +func schema_k8sio_api_core_v1_PodSchedulingGate(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "PodSchedulingGate is associated to a Pod to guard its scheduling.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "name": { + SchemaProps: spec.SchemaProps{ + Description: "Name of the scheduling gate. Each scheduling gate must have a unique name field.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"name"}, + }, + }, + } +} + +func schema_k8sio_api_core_v1_PodSecurityContext(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "PodSecurityContext holds pod-level security attributes and common container settings. Some fields are also present in container.securityContext. Field values of container.securityContext take precedence over field values of PodSecurityContext.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "seLinuxOptions": { + SchemaProps: spec.SchemaProps{ + Description: "The SELinux context to be applied to all containers. If unspecified, the container runtime will allocate a random SELinux context for each container. May also be set in SecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence for that container. Note that this field cannot be set when spec.os.name is windows.", + Ref: ref(v1.SELinuxOptions{}.OpenAPIModelName()), + }, + }, + "windowsOptions": { + SchemaProps: spec.SchemaProps{ + Description: "The Windows specific settings applied to all containers. If unspecified, the options within a container's SecurityContext will be used. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence. Note that this field cannot be set when spec.os.name is linux.", + Ref: ref(v1.WindowsSecurityContextOptions{}.OpenAPIModelName()), + }, + }, + "runAsUser": { + SchemaProps: spec.SchemaProps{ + Description: "The UID to run the entrypoint of the container process. Defaults to user specified in image metadata if unspecified. May also be set in SecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence for that container. Note that this field cannot be set when spec.os.name is windows.", + Type: []string{"integer"}, + Format: "int64", + }, + }, + "runAsGroup": { + SchemaProps: spec.SchemaProps{ + Description: "The GID to run the entrypoint of the container process. Uses runtime default if unset. May also be set in SecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence for that container. Note that this field cannot be set when spec.os.name is windows.", + Type: []string{"integer"}, + Format: "int64", + }, + }, + "runAsNonRoot": { + SchemaProps: spec.SchemaProps{ + Description: "Indicates that the container must run as a non-root user. If true, the Kubelet will validate the image at runtime to ensure that it does not run as UID 0 (root) and fail to start the container if it does. If unset or false, no such validation will be performed. May also be set in SecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence.", + Type: []string{"boolean"}, + Format: "", + }, + }, + "supplementalGroups": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "A list of groups applied to the first process run in each container, in addition to the container's primary GID and fsGroup (if specified). If the SupplementalGroupsPolicy feature is enabled, the supplementalGroupsPolicy field determines whether these are in addition to or instead of any group memberships defined in the container image. If unspecified, no additional groups are added, though group memberships defined in the container image may still be used, depending on the supplementalGroupsPolicy field. Note that this field cannot be set when spec.os.name is windows.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: 0, + Type: []string{"integer"}, + Format: "int64", + }, + }, + }, + }, + }, + "supplementalGroupsPolicy": { + SchemaProps: spec.SchemaProps{ + Description: "Defines how supplemental groups of the first container processes are calculated. Valid values are \"Merge\" and \"Strict\". If not specified, \"Merge\" is used. (Alpha) Using the field requires the SupplementalGroupsPolicy feature gate to be enabled and the container runtime must implement support for this feature. Note that this field cannot be set when spec.os.name is windows.\n\nPossible enum values:\n - `\"Merge\"` means that the container's provided SupplementalGroups and FsGroup (specified in SecurityContext) will be merged with the primary user's groups as defined in the container image (in /etc/group).\n - `\"Strict\"` means that the container's provided SupplementalGroups and FsGroup (specified in SecurityContext) will be used instead of any groups defined in the container image.", + Type: []string{"string"}, + Format: "", + Enum: []interface{}{"Merge", "Strict"}, + }, + }, + "fsGroup": { + SchemaProps: spec.SchemaProps{ + Description: "A special supplemental group that applies to all containers in a pod. Some volume types allow the Kubelet to change the ownership of that volume to be owned by the pod:\n\n1. The owning GID will be the FSGroup 2. The setgid bit is set (new files created in the volume will be owned by FSGroup) 3. The permission bits are OR'd with rw-rw----\n\nIf unset, the Kubelet will not modify the ownership and permissions of any volume. Note that this field cannot be set when spec.os.name is windows.", + Type: []string{"integer"}, + Format: "int64", + }, + }, + "sysctls": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "Sysctls hold a list of namespaced sysctls used for the pod. Pods with unsupported sysctls (by the container runtime) might fail to launch. Note that this field cannot be set when spec.os.name is windows.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.Sysctl{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "fsGroupChangePolicy": { + SchemaProps: spec.SchemaProps{ + Description: "fsGroupChangePolicy defines behavior of changing ownership and permission of the volume before being exposed inside Pod. This field will only apply to volume types which support fsGroup based ownership(and permissions). It will have no effect on ephemeral volume types such as: secret, configmaps and emptydir. Valid values are \"OnRootMismatch\" and \"Always\". If not specified, \"Always\" is used. Note that this field cannot be set when spec.os.name is windows.\n\nPossible enum values:\n - `\"Always\"` indicates that volume's ownership and permissions should always be changed whenever volume is mounted inside a Pod. This the default behavior.\n - `\"OnRootMismatch\"` indicates that volume's ownership and permissions will be changed only when permission and ownership of root directory does not match with expected permissions on the volume. This can help shorten the time it takes to change ownership and permissions of a volume.", + Type: []string{"string"}, + Format: "", + Enum: []interface{}{"Always", "OnRootMismatch"}, + }, + }, + "seccompProfile": { + SchemaProps: spec.SchemaProps{ + Description: "The seccomp options to use by the containers in this pod. Note that this field cannot be set when spec.os.name is windows.", + Ref: ref(v1.SeccompProfile{}.OpenAPIModelName()), + }, + }, + "appArmorProfile": { + SchemaProps: spec.SchemaProps{ + Description: "appArmorProfile is the AppArmor options to use by the containers in this pod. Note that this field cannot be set when spec.os.name is windows.", + Ref: ref(v1.AppArmorProfile{}.OpenAPIModelName()), + }, + }, + "seLinuxChangePolicy": { + SchemaProps: spec.SchemaProps{ + Description: "seLinuxChangePolicy defines how the container's SELinux label is applied to all volumes used by the Pod. It has no effect on nodes that do not support SELinux or to volumes does not support SELinux. Valid values are \"MountOption\" and \"Recursive\".\n\n\"Recursive\" means relabeling of all files on all Pod volumes by the container runtime. This may be slow for large volumes, but allows mixing privileged and unprivileged Pods sharing the same volume on the same node.\n\n\"MountOption\" mounts all eligible Pod volumes with `-o context` mount option. This requires all Pods that share the same volume to use the same SELinux label. It is not possible to share the same volume among privileged and unprivileged Pods. Eligible volumes are in-tree FibreChannel and iSCSI volumes, and all CSI volumes whose CSI driver announces SELinux support by setting spec.seLinuxMount: true in their CSIDriver instance. Other volumes are always re-labelled recursively. \"MountOption\" value is allowed only when SELinuxMount feature gate is enabled.\n\nIf not specified and SELinuxMount feature gate is enabled, \"MountOption\" is used. If not specified and SELinuxMount feature gate is disabled, \"MountOption\" is used for ReadWriteOncePod volumes and \"Recursive\" for all other volumes.\n\nThis field affects only Pods that have SELinux label set, either in PodSecurityContext or in SecurityContext of all containers.\n\nAll Pods that use the same volume should use the same seLinuxChangePolicy, otherwise some pods can get stuck in ContainerCreating state. Note that this field cannot be set when spec.os.name is windows.", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + Dependencies: []string{ + v1.AppArmorProfile{}.OpenAPIModelName(), v1.SELinuxOptions{}.OpenAPIModelName(), v1.SeccompProfile{}.OpenAPIModelName(), v1.Sysctl{}.OpenAPIModelName(), v1.WindowsSecurityContextOptions{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_PodSignature(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "Describes the class of pods that should avoid this node. Exactly one field should be set.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "podController": { + SchemaProps: spec.SchemaProps{ + Description: "Reference to controller whose pods should avoid this node.", + Ref: ref(metav1.OwnerReference{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + Dependencies: []string{ + metav1.OwnerReference{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_PodSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "PodSpec is a description of a pod.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "volumes": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-map-keys": []interface{}{ + "name", + }, + "x-kubernetes-list-type": "map", + "x-kubernetes-patch-merge-key": "name", + "x-kubernetes-patch-strategy": "merge,retainKeys", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "List of volumes that can be mounted by containers belonging to the pod. More info: https://kubernetes.io/docs/concepts/storage/volumes", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.Volume{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "initContainers": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-map-keys": []interface{}{ + "name", + }, + "x-kubernetes-list-type": "map", + "x-kubernetes-patch-merge-key": "name", + "x-kubernetes-patch-strategy": "merge", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "List of initialization containers belonging to the pod. Init containers are executed in order prior to containers being started. If any init container fails, the pod is considered to have failed and is handled according to its restartPolicy. The name for an init container or normal container must be unique among all containers. Init containers may not have Lifecycle actions, Readiness probes, Liveness probes, or Startup probes. The resourceRequirements of an init container are taken into account during scheduling by finding the highest request/limit for each resource type, and then using the max of that value or the sum of the normal containers. Limits are applied to init containers in a similar fashion. Init containers cannot currently be added or removed. Cannot be updated. More info: https://kubernetes.io/docs/concepts/workloads/pods/init-containers/", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.Container{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "containers": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-map-keys": []interface{}{ + "name", + }, + "x-kubernetes-list-type": "map", + "x-kubernetes-patch-merge-key": "name", + "x-kubernetes-patch-strategy": "merge", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "List of containers belonging to the pod. Containers cannot currently be added or removed. There must be at least one container in a Pod. Cannot be updated.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.Container{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "ephemeralContainers": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-map-keys": []interface{}{ + "name", + }, + "x-kubernetes-list-type": "map", + "x-kubernetes-patch-merge-key": "name", + "x-kubernetes-patch-strategy": "merge", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "List of ephemeral containers run in this pod. Ephemeral containers may be run in an existing pod to perform user-initiated actions such as debugging. This list cannot be specified when creating a pod, and it cannot be modified by updating the pod spec. In order to add an ephemeral container to an existing pod, use the pod's ephemeralcontainers subresource.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.EphemeralContainer{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "restartPolicy": { + SchemaProps: spec.SchemaProps{ + Description: "Restart policy for all containers within the pod. One of Always, OnFailure, Never. In some contexts, only a subset of those values may be permitted. Default to Always. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle/#restart-policy\n\nPossible enum values:\n - `\"Always\"`\n - `\"Never\"`\n - `\"OnFailure\"`", + Type: []string{"string"}, + Format: "", + Enum: []interface{}{"Always", "Never", "OnFailure"}, + }, + }, + "terminationGracePeriodSeconds": { + SchemaProps: spec.SchemaProps{ + Description: "Optional duration in seconds the pod needs to terminate gracefully. May be decreased in delete request. Value must be non-negative integer. The value zero indicates stop immediately via the kill signal (no opportunity to shut down). If this value is nil, the default grace period will be used instead. The grace period is the duration in seconds after the processes running in the pod are sent a termination signal and the time when the processes are forcibly halted with a kill signal. Set this value longer than the expected cleanup time for your process. Defaults to 30 seconds.", + Type: []string{"integer"}, + Format: "int64", + }, + }, + "activeDeadlineSeconds": { + SchemaProps: spec.SchemaProps{ + Description: "Optional duration in seconds the pod may be active on the node relative to StartTime before the system will actively try to mark it failed and kill associated containers. Value must be a positive integer.", + Type: []string{"integer"}, + Format: "int64", + }, + }, + "dnsPolicy": { + SchemaProps: spec.SchemaProps{ + Description: "Set DNS policy for the pod. Defaults to \"ClusterFirst\". Valid values are 'ClusterFirstWithHostNet', 'ClusterFirst', 'Default' or 'None'. DNS parameters given in DNSConfig will be merged with the policy selected with DNSPolicy. To have DNS options set along with hostNetwork, you have to specify DNS policy explicitly to 'ClusterFirstWithHostNet'.\n\nPossible enum values:\n - `\"ClusterFirst\"` indicates that the pod should use cluster DNS first unless hostNetwork is true, if it is available, then fall back on the default (as determined by kubelet) DNS settings.\n - `\"ClusterFirstWithHostNet\"` indicates that the pod should use cluster DNS first, if it is available, then fall back on the default (as determined by kubelet) DNS settings.\n - `\"Default\"` indicates that the pod should use the default (as determined by kubelet) DNS settings.\n - `\"None\"` indicates that the pod should use empty DNS settings. DNS parameters such as nameservers and search paths should be defined via DNSConfig.", + Type: []string{"string"}, + Format: "", + Enum: []interface{}{"ClusterFirst", "ClusterFirstWithHostNet", "Default", "None"}, + }, + }, + "nodeSelector": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-map-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "NodeSelector is a selector which must be true for the pod to fit on a node. Selector which must match a node's labels for the pod to be scheduled on that node. More info: https://kubernetes.io/docs/concepts/configuration/assign-pod-node/", + Type: []string{"object"}, + AdditionalProperties: &spec.SchemaOrBool{ + Allows: true, + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + "serviceAccountName": { + SchemaProps: spec.SchemaProps{ + Description: "ServiceAccountName is the name of the ServiceAccount to use to run this pod. More info: https://kubernetes.io/docs/tasks/configure-pod-container/configure-service-account/", + Type: []string{"string"}, + Format: "", + }, + }, + "serviceAccount": { + SchemaProps: spec.SchemaProps{ + Description: "DeprecatedServiceAccount is a deprecated alias for ServiceAccountName. Deprecated: Use serviceAccountName instead.", + Type: []string{"string"}, + Format: "", + }, + }, + "automountServiceAccountToken": { + SchemaProps: spec.SchemaProps{ + Description: "AutomountServiceAccountToken indicates whether a service account token should be automatically mounted.", + Type: []string{"boolean"}, + Format: "", + }, + }, + "nodeName": { + SchemaProps: spec.SchemaProps{ + Description: "NodeName indicates in which node this pod is scheduled. If empty, this pod is a candidate for scheduling by the scheduler defined in schedulerName. Once this field is set, the kubelet for this node becomes responsible for the lifecycle of this pod. This field should not be used to express a desire for the pod to be scheduled on a specific node. https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/#nodename", + Type: []string{"string"}, + Format: "", + }, + }, + "hostNetwork": { + SchemaProps: spec.SchemaProps{ + Description: "Host networking requested for this pod. Use the host's network namespace. When using HostNetwork you should specify ports so the scheduler is aware. When `hostNetwork` is true, specified `hostPort` fields in port definitions must match `containerPort`, and unspecified `hostPort` fields in port definitions are defaulted to match `containerPort`. Default to false.", + Type: []string{"boolean"}, + Format: "", + }, + }, + "hostPID": { + SchemaProps: spec.SchemaProps{ + Description: "Use the host's pid namespace. Optional: Default to false.", + Type: []string{"boolean"}, + Format: "", + }, + }, + "hostIPC": { + SchemaProps: spec.SchemaProps{ + Description: "Use the host's ipc namespace. Optional: Default to false.", + Type: []string{"boolean"}, + Format: "", + }, + }, + "shareProcessNamespace": { + SchemaProps: spec.SchemaProps{ + Description: "Share a single process namespace between all of the containers in a pod. When this is set containers will be able to view and signal processes from other containers in the same pod, and the first process in each container will not be assigned PID 1. HostPID and ShareProcessNamespace cannot both be set. Optional: Default to false.", + Type: []string{"boolean"}, + Format: "", + }, + }, + "securityContext": { + SchemaProps: spec.SchemaProps{ + Description: "SecurityContext holds pod-level security attributes and common container settings. Optional: Defaults to empty. See type description for default values of each field.", + Ref: ref(v1.PodSecurityContext{}.OpenAPIModelName()), + }, + }, + "imagePullSecrets": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-map-keys": []interface{}{ + "name", + }, + "x-kubernetes-list-type": "map", + "x-kubernetes-patch-merge-key": "name", + "x-kubernetes-patch-strategy": "merge", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "ImagePullSecrets is an optional list of references to secrets in the same namespace to use for pulling any of the images used by this PodSpec. If specified, these secrets will be passed to individual puller implementations for them to use. More info: https://kubernetes.io/docs/concepts/containers/images#specifying-imagepullsecrets-on-a-pod", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.LocalObjectReference{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "hostname": { + SchemaProps: spec.SchemaProps{ + Description: "Specifies the hostname of the Pod If not specified, the pod's hostname will be set to a system-defined value.", + Type: []string{"string"}, + Format: "", + }, + }, + "subdomain": { + SchemaProps: spec.SchemaProps{ + Description: "If specified, the fully qualified Pod hostname will be \"...svc.\". If not specified, the pod will not have a domainname at all.", + Type: []string{"string"}, + Format: "", + }, + }, + "affinity": { + SchemaProps: spec.SchemaProps{ + Description: "If specified, the pod's scheduling constraints", + Ref: ref(v1.Affinity{}.OpenAPIModelName()), + }, + }, + "schedulerName": { + SchemaProps: spec.SchemaProps{ + Description: "If specified, the pod will be dispatched by specified scheduler. If not specified, the pod will be dispatched by default scheduler.", + Type: []string{"string"}, + Format: "", + }, + }, + "tolerations": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "If specified, the pod's tolerations.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.Toleration{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "hostAliases": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-map-keys": []interface{}{ + "ip", + }, + "x-kubernetes-list-type": "map", + "x-kubernetes-patch-merge-key": "ip", + "x-kubernetes-patch-strategy": "merge", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "HostAliases is an optional list of hosts and IPs that will be injected into the pod's hosts file if specified.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.HostAlias{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "priorityClassName": { + SchemaProps: spec.SchemaProps{ + Description: "If specified, indicates the pod's priority. \"system-node-critical\" and \"system-cluster-critical\" are two special keywords which indicate the highest priorities with the former being the highest priority. Any other name must be defined by creating a PriorityClass object with that name. If not specified, the pod priority will be default or zero if there is no default.", + Type: []string{"string"}, + Format: "", + }, + }, + "priority": { + SchemaProps: spec.SchemaProps{ + Description: "The priority value. Various system components use this field to find the priority of the pod. When Priority Admission Controller is enabled, it prevents users from setting this field. The admission controller populates this field from PriorityClassName. The higher the value, the higher the priority.", + Type: []string{"integer"}, + Format: "int32", + }, + }, + "dnsConfig": { + SchemaProps: spec.SchemaProps{ + Description: "Specifies the DNS parameters of a pod. Parameters specified here will be merged to the generated DNS configuration based on DNSPolicy.", + Ref: ref(v1.PodDNSConfig{}.OpenAPIModelName()), + }, + }, + "readinessGates": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "If specified, all readiness gates will be evaluated for pod readiness. A pod is ready when all its containers are ready AND all conditions specified in the readiness gates have status equal to \"True\" More info: https://git.k8s.io/enhancements/keps/sig-network/580-pod-readiness-gates", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.PodReadinessGate{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "runtimeClassName": { + SchemaProps: spec.SchemaProps{ + Description: "RuntimeClassName refers to a RuntimeClass object in the node.k8s.io group, which should be used to run this pod. If no RuntimeClass resource matches the named class, the pod will not be run. If unset or empty, the \"legacy\" RuntimeClass will be used, which is an implicit class with an empty definition that uses the default runtime handler. More info: https://git.k8s.io/enhancements/keps/sig-node/585-runtime-class", + Type: []string{"string"}, + Format: "", + }, + }, + "enableServiceLinks": { + SchemaProps: spec.SchemaProps{ + Description: "EnableServiceLinks indicates whether information about services should be injected into pod's environment variables, matching the syntax of Docker links. Optional: Defaults to true.", + Type: []string{"boolean"}, + Format: "", + }, + }, + "preemptionPolicy": { + SchemaProps: spec.SchemaProps{ + Description: "PreemptionPolicy is the Policy for preempting pods with lower priority. One of Never, PreemptLowerPriority. Defaults to PreemptLowerPriority if unset.\n\nPossible enum values:\n - `\"Never\"` means that pod never preempts other pods with lower priority.\n - `\"PreemptLowerPriority\"` means that pod can preempt other pods with lower priority.", + Type: []string{"string"}, + Format: "", + Enum: []interface{}{"Never", "PreemptLowerPriority"}, + }, + }, + "overhead": { + SchemaProps: spec.SchemaProps{ + Description: "Overhead represents the resource overhead associated with running a pod for a given RuntimeClass. This field will be autopopulated at admission time by the RuntimeClass admission controller. If the RuntimeClass admission controller is enabled, overhead must not be set in Pod create requests. The RuntimeClass admission controller will reject Pod create requests which have the overhead already set. If RuntimeClass is configured and selected in the PodSpec, Overhead will be set to the value defined in the corresponding RuntimeClass, otherwise it will remain unset and treated as zero. More info: https://git.k8s.io/enhancements/keps/sig-node/688-pod-overhead/README.md", + Type: []string{"object"}, + AdditionalProperties: &spec.SchemaOrBool{ + Allows: true, + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Ref: ref(resource.Quantity{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "topologySpreadConstraints": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-map-keys": []interface{}{ + "topologyKey", + "whenUnsatisfiable", + }, + "x-kubernetes-list-type": "map", + "x-kubernetes-patch-merge-key": "topologyKey", + "x-kubernetes-patch-strategy": "merge", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "TopologySpreadConstraints describes how a group of pods ought to spread across topology domains. Scheduler will schedule pods in a way which abides by the constraints. All topologySpreadConstraints are ANDed.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.TopologySpreadConstraint{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "setHostnameAsFQDN": { + SchemaProps: spec.SchemaProps{ + Description: "If true the pod's hostname will be configured as the pod's FQDN, rather than the leaf name (the default). In Linux containers, this means setting the FQDN in the hostname field of the kernel (the nodename field of struct utsname). In Windows containers, this means setting the registry value of hostname for the registry key HKEY_LOCAL_MACHINE\\\\SYSTEM\\\\CurrentControlSet\\\\Services\\\\Tcpip\\\\Parameters to FQDN. If a pod does not have FQDN, this has no effect. Default to false.", + Type: []string{"boolean"}, + Format: "", + }, + }, + "os": { + SchemaProps: spec.SchemaProps{ + Description: "Specifies the OS of the containers in the pod. Some pod and container fields are restricted if this is set.\n\nIf the OS field is set to linux, the following fields must be unset: -securityContext.windowsOptions\n\nIf the OS field is set to windows, following fields must be unset: - spec.hostPID - spec.hostIPC - spec.hostUsers - spec.resources - spec.securityContext.appArmorProfile - spec.securityContext.seLinuxOptions - spec.securityContext.seccompProfile - spec.securityContext.fsGroup - spec.securityContext.fsGroupChangePolicy - spec.securityContext.sysctls - spec.shareProcessNamespace - spec.securityContext.runAsUser - spec.securityContext.runAsGroup - spec.securityContext.supplementalGroups - spec.securityContext.supplementalGroupsPolicy - spec.containers[*].securityContext.appArmorProfile - spec.containers[*].securityContext.seLinuxOptions - spec.containers[*].securityContext.seccompProfile - spec.containers[*].securityContext.capabilities - spec.containers[*].securityContext.readOnlyRootFilesystem - spec.containers[*].securityContext.privileged - spec.containers[*].securityContext.allowPrivilegeEscalation - spec.containers[*].securityContext.procMount - spec.containers[*].securityContext.runAsUser - spec.containers[*].securityContext.runAsGroup", + Ref: ref(v1.PodOS{}.OpenAPIModelName()), + }, + }, + "hostUsers": { + SchemaProps: spec.SchemaProps{ + Description: "Use the host's user namespace. Optional: Default to true. If set to true or not present, the pod will be run in the host user namespace, useful for when the pod needs a feature only available to the host user namespace, such as loading a kernel module with CAP_SYS_MODULE. When set to false, a new userns is created for the pod. Setting false is useful for mitigating container breakout vulnerabilities even allowing users to run their containers as root without actually having root privileges on the host. This field is alpha-level and is only honored by servers that enable the UserNamespacesSupport feature.", + Type: []string{"boolean"}, + Format: "", + }, + }, + "schedulingGates": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-map-keys": []interface{}{ + "name", + }, + "x-kubernetes-list-type": "map", + "x-kubernetes-patch-merge-key": "name", + "x-kubernetes-patch-strategy": "merge", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "SchedulingGates is an opaque list of values that if specified will block scheduling the pod. If schedulingGates is not empty, the pod will stay in the SchedulingGated state and the scheduler will not attempt to schedule the pod.\n\nSchedulingGates can only be set at pod creation time, and be removed only afterwards.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.PodSchedulingGate{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "resourceClaims": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-map-keys": []interface{}{ + "name", + }, + "x-kubernetes-list-type": "map", + "x-kubernetes-patch-merge-key": "name", + "x-kubernetes-patch-strategy": "merge,retainKeys", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "ResourceClaims defines which ResourceClaims must be allocated and reserved before the Pod is allowed to start. The resources will be made available to those containers which consume them by name.\n\nThis is a stable field but requires that the DynamicResourceAllocation feature gate is enabled.\n\nThis field is immutable.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.PodResourceClaim{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "resources": { + SchemaProps: spec.SchemaProps{ + Description: "Resources is the total amount of CPU and Memory resources required by all containers in the pod. It supports specifying Requests and Limits for \"cpu\", \"memory\" and \"hugepages-\" resource names only. ResourceClaims are not supported.\n\nThis field enables fine-grained control over resource allocation for the entire pod, allowing resource sharing among containers in a pod.\n\nThis is an alpha field and requires enabling the PodLevelResources feature gate.", + Ref: ref(v1.ResourceRequirements{}.OpenAPIModelName()), + }, + }, + "hostnameOverride": { + SchemaProps: spec.SchemaProps{ + Description: "HostnameOverride specifies an explicit override for the pod's hostname as perceived by the pod. This field only specifies the pod's hostname and does not affect its DNS records. When this field is set to a non-empty string: - It takes precedence over the values set in `hostname` and `subdomain`. - The Pod's hostname will be set to this value. - `setHostnameAsFQDN` must be nil or set to false. - `hostNetwork` must be set to false.\n\nThis field must be a valid DNS subdomain as defined in RFC 1123 and contain at most 64 characters. Requires the HostnameOverride feature gate to be enabled.", + Type: []string{"string"}, + Format: "", + }, + }, + "workloadRef": { + SchemaProps: spec.SchemaProps{ + Description: "WorkloadRef provides a reference to the Workload object that this Pod belongs to. This field is used by the scheduler to identify the PodGroup and apply the correct group scheduling policies. The Workload object referenced by this field may not exist at the time the Pod is created. This field is immutable, but a Workload object with the same name may be recreated with different policies. Doing this during pod scheduling may result in the placement not conforming to the expected policies.", + Ref: ref(v1.WorkloadReference{}.OpenAPIModelName()), + }, + }, + }, + Required: []string{"containers"}, + }, + }, + Dependencies: []string{ + v1.Affinity{}.OpenAPIModelName(), v1.Container{}.OpenAPIModelName(), v1.EphemeralContainer{}.OpenAPIModelName(), v1.HostAlias{}.OpenAPIModelName(), v1.LocalObjectReference{}.OpenAPIModelName(), v1.PodDNSConfig{}.OpenAPIModelName(), v1.PodOS{}.OpenAPIModelName(), v1.PodReadinessGate{}.OpenAPIModelName(), v1.PodResourceClaim{}.OpenAPIModelName(), v1.PodSchedulingGate{}.OpenAPIModelName(), v1.PodSecurityContext{}.OpenAPIModelName(), v1.ResourceRequirements{}.OpenAPIModelName(), v1.Toleration{}.OpenAPIModelName(), v1.TopologySpreadConstraint{}.OpenAPIModelName(), v1.Volume{}.OpenAPIModelName(), v1.WorkloadReference{}.OpenAPIModelName(), resource.Quantity{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_PodStatus(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "PodStatus represents information about the status of a pod. Status may trail the actual state of a system, especially if the node that hosts the pod cannot contact the control plane.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "observedGeneration": { + SchemaProps: spec.SchemaProps{ + Description: "If set, this represents the .metadata.generation that the pod status was set based upon. The PodObservedGenerationTracking feature gate must be enabled to use this field.", + Type: []string{"integer"}, + Format: "int64", + }, + }, + "phase": { + SchemaProps: spec.SchemaProps{ + Description: "The phase of a Pod is a simple, high-level summary of where the Pod is in its lifecycle. The conditions array, the reason and message fields, and the individual container status arrays contain more detail about the pod's status. There are five possible phase values:\n\nPending: The pod has been accepted by the Kubernetes system, but one or more of the container images has not been created. This includes time before being scheduled as well as time spent downloading images over the network, which could take a while. Running: The pod has been bound to a node, and all of the containers have been created. At least one container is still running, or is in the process of starting or restarting. Succeeded: All containers in the pod have terminated in success, and will not be restarted. Failed: All containers in the pod have terminated, and at least one container has terminated in failure. The container either exited with non-zero status or was terminated by the system. Unknown: For some reason the state of the pod could not be obtained, typically due to an error in communicating with the host of the pod.\n\nMore info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#pod-phase\n\nPossible enum values:\n - `\"Failed\"` means that all containers in the pod have terminated, and at least one container has terminated in a failure (exited with a non-zero exit code or was stopped by the system).\n - `\"Pending\"` means the pod has been accepted by the system, but one or more of the containers has not been started. This includes time before being bound to a node, as well as time spent pulling images onto the host.\n - `\"Running\"` means the pod has been bound to a node and all of the containers have been started. At least one container is still running or is in the process of being restarted.\n - `\"Succeeded\"` means that all containers in the pod have voluntarily terminated with a container exit code of 0, and the system is not going to restart any of these containers.\n - `\"Unknown\"` means that for some reason the state of the pod could not be obtained, typically due to an error in communicating with the host of the pod. Deprecated: It isn't being set since 2015 (74da3b14b0c0f658b3bb8d2def5094686d0e9095)", + Type: []string{"string"}, + Format: "", + Enum: []interface{}{"Failed", "Pending", "Running", "Succeeded", "Unknown"}, + }, + }, + "conditions": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-map-keys": []interface{}{ + "type", + }, + "x-kubernetes-list-type": "map", + "x-kubernetes-patch-merge-key": "type", + "x-kubernetes-patch-strategy": "merge", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "Current service state of pod. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#pod-conditions", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.PodCondition{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "message": { + SchemaProps: spec.SchemaProps{ + Description: "A human readable message indicating details about why the pod is in this condition.", + Type: []string{"string"}, + Format: "", + }, + }, + "reason": { + SchemaProps: spec.SchemaProps{ + Description: "A brief CamelCase message indicating details about why the pod is in this state. e.g. 'Evicted'", + Type: []string{"string"}, + Format: "", + }, + }, + "nominatedNodeName": { + SchemaProps: spec.SchemaProps{ + Description: "nominatedNodeName is set only when this pod preempts other pods on the node, but it cannot be scheduled right away as preemption victims receive their graceful termination periods. This field does not guarantee that the pod will be scheduled on this node. Scheduler may decide to place the pod elsewhere if other nodes become available sooner. Scheduler may also decide to give the resources on this node to a higher priority pod that is created after preemption. As a result, this field may be different than PodSpec.nodeName when the pod is scheduled.", + Type: []string{"string"}, + Format: "", + }, + }, + "hostIP": { + SchemaProps: spec.SchemaProps{ + Description: "hostIP holds the IP address of the host to which the pod is assigned. Empty if the pod has not started yet. A pod can be assigned to a node that has a problem in kubelet which in turns mean that HostIP will not be updated even if there is a node is assigned to pod", + Type: []string{"string"}, + Format: "", + }, + }, + "hostIPs": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + "x-kubernetes-patch-merge-key": "ip", + "x-kubernetes-patch-strategy": "merge", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "hostIPs holds the IP addresses allocated to the host. If this field is specified, the first entry must match the hostIP field. This list is empty if the pod has not started yet. A pod can be assigned to a node that has a problem in kubelet which in turns means that HostIPs will not be updated even if there is a node is assigned to this pod.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.HostIP{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "podIP": { + SchemaProps: spec.SchemaProps{ + Description: "podIP address allocated to the pod. Routable at least within the cluster. Empty if not yet allocated.", + Type: []string{"string"}, + Format: "", + }, + }, + "podIPs": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-map-keys": []interface{}{ + "ip", + }, + "x-kubernetes-list-type": "map", + "x-kubernetes-patch-merge-key": "ip", + "x-kubernetes-patch-strategy": "merge", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "podIPs holds the IP addresses allocated to the pod. If this field is specified, the 0th entry must match the podIP field. Pods may be allocated at most 1 value for each of IPv4 and IPv6. This list is empty if no IPs have been allocated yet.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.PodIP{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "startTime": { + SchemaProps: spec.SchemaProps{ + Description: "RFC 3339 date and time at which the object was acknowledged by the Kubelet. This is before the Kubelet pulled the container image(s) for the pod.", + Ref: ref(metav1.Time{}.OpenAPIModelName()), + }, + }, + "initContainerStatuses": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "Statuses of init containers in this pod. The most recent successful non-restartable init container will have ready = true, the most recently started container will have startTime set. Each init container in the pod should have at most one status in this list, and all statuses should be for containers in the pod. However this is not enforced. If a status for a non-existent container is present in the list, or the list has duplicate names, the behavior of various Kubernetes components is not defined and those statuses might be ignored. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle/#pod-and-container-status", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.ContainerStatus{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "containerStatuses": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "Statuses of containers in this pod. Each container in the pod should have at most one status in this list, and all statuses should be for containers in the pod. However this is not enforced. If a status for a non-existent container is present in the list, or the list has duplicate names, the behavior of various Kubernetes components is not defined and those statuses might be ignored. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#pod-and-container-status", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.ContainerStatus{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "qosClass": { + SchemaProps: spec.SchemaProps{ + Description: "The Quality of Service (QOS) classification assigned to the pod based on resource requirements See PodQOSClass type for available QOS classes More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-qos/#quality-of-service-classes\n\nPossible enum values:\n - `\"BestEffort\"` is the BestEffort qos class.\n - `\"Burstable\"` is the Burstable qos class.\n - `\"Guaranteed\"` is the Guaranteed qos class.", + Type: []string{"string"}, + Format: "", + Enum: []interface{}{"BestEffort", "Burstable", "Guaranteed"}, + }, + }, + "ephemeralContainerStatuses": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "Statuses for any ephemeral containers that have run in this pod. Each ephemeral container in the pod should have at most one status in this list, and all statuses should be for containers in the pod. However this is not enforced. If a status for a non-existent container is present in the list, or the list has duplicate names, the behavior of various Kubernetes components is not defined and those statuses might be ignored. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#pod-and-container-status", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.ContainerStatus{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "resize": { + SchemaProps: spec.SchemaProps{ + Description: "Status of resources resize desired for pod's containers. It is empty if no resources resize is pending. Any changes to container resources will automatically set this to \"Proposed\" Deprecated: Resize status is moved to two pod conditions PodResizePending and PodResizeInProgress. PodResizePending will track states where the spec has been resized, but the Kubelet has not yet allocated the resources. PodResizeInProgress will track in-progress resizes, and should be present whenever allocated resources != acknowledged resources.", + Type: []string{"string"}, + Format: "", + }, + }, + "resourceClaimStatuses": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-map-keys": []interface{}{ + "name", + }, + "x-kubernetes-list-type": "map", + "x-kubernetes-patch-merge-key": "name", + "x-kubernetes-patch-strategy": "merge,retainKeys", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "Status of resource claims.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.PodResourceClaimStatus{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "extendedResourceClaimStatus": { + SchemaProps: spec.SchemaProps{ + Description: "Status of extended resource claim backed by DRA.", + Ref: ref(v1.PodExtendedResourceClaimStatus{}.OpenAPIModelName()), + }, + }, + "allocatedResources": { + SchemaProps: spec.SchemaProps{ + Description: "AllocatedResources is the total requests allocated for this pod by the node. If pod-level requests are not set, this will be the total requests aggregated across containers in the pod.", + Type: []string{"object"}, + AdditionalProperties: &spec.SchemaOrBool{ + Allows: true, + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Ref: ref(resource.Quantity{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "resources": { + SchemaProps: spec.SchemaProps{ + Description: "Resources represents the compute resource requests and limits that have been applied at the pod level if pod-level requests or limits are set in PodSpec.Resources", + Ref: ref(v1.ResourceRequirements{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + Dependencies: []string{ + v1.ContainerStatus{}.OpenAPIModelName(), v1.HostIP{}.OpenAPIModelName(), v1.PodCondition{}.OpenAPIModelName(), v1.PodExtendedResourceClaimStatus{}.OpenAPIModelName(), v1.PodIP{}.OpenAPIModelName(), v1.PodResourceClaimStatus{}.OpenAPIModelName(), v1.ResourceRequirements{}.OpenAPIModelName(), resource.Quantity{}.OpenAPIModelName(), metav1.Time{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_PodStatusResult(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "PodStatusResult is a wrapper for PodStatus returned by kubelet that can be encode/decoded", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "metadata": { + SchemaProps: spec.SchemaProps{ + Description: "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata", + Default: map[string]interface{}{}, + Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), + }, + }, + "status": { + SchemaProps: spec.SchemaProps{ + Description: "Most recently observed status of the pod. This data may not be up to date. Populated by the system. Read-only. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status", + Default: map[string]interface{}{}, + Ref: ref(v1.PodStatus{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + Dependencies: []string{ + v1.PodStatus{}.OpenAPIModelName(), metav1.ObjectMeta{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_PodTemplate(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "PodTemplate describes a template for creating copies of a predefined pod.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "metadata": { + SchemaProps: spec.SchemaProps{ + Description: "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata", + Default: map[string]interface{}{}, + Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), + }, + }, + "template": { + SchemaProps: spec.SchemaProps{ + Description: "Template defines the pods that will be created from this pod template. https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status", + Default: map[string]interface{}{}, + Ref: ref(v1.PodTemplateSpec{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + Dependencies: []string{ + v1.PodTemplateSpec{}.OpenAPIModelName(), metav1.ObjectMeta{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_PodTemplateList(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "PodTemplateList is a list of PodTemplates.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "metadata": { + SchemaProps: spec.SchemaProps{ + Description: "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Default: map[string]interface{}{}, + Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), + }, + }, + "items": { + SchemaProps: spec.SchemaProps{ + Description: "List of pod templates", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.PodTemplate{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + }, + Required: []string{"items"}, + }, + }, + Dependencies: []string{ + v1.PodTemplate{}.OpenAPIModelName(), metav1.ListMeta{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_PodTemplateSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "PodTemplateSpec describes the data a pod should have when created from a template", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "metadata": { + SchemaProps: spec.SchemaProps{ + Description: "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata", + Default: map[string]interface{}{}, + Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), + }, + }, + "spec": { + SchemaProps: spec.SchemaProps{ + Description: "Specification of the desired behavior of the pod. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status", + Default: map[string]interface{}{}, + Ref: ref(v1.PodSpec{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + Dependencies: []string{ + v1.PodSpec{}.OpenAPIModelName(), metav1.ObjectMeta{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_PortStatus(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "PortStatus represents the error condition of a service port", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "port": { + SchemaProps: spec.SchemaProps{ + Description: "Port is the port number of the service port of which status is recorded here", + Default: 0, + Type: []string{"integer"}, + Format: "int32", + }, + }, + "protocol": { + SchemaProps: spec.SchemaProps{ + Description: "Protocol is the protocol of the service port of which status is recorded here The supported values are: \"TCP\", \"UDP\", \"SCTP\"\n\nPossible enum values:\n - `\"SCTP\"` is the SCTP protocol.\n - `\"TCP\"` is the TCP protocol.\n - `\"UDP\"` is the UDP protocol.", + Default: "", + Type: []string{"string"}, + Format: "", + Enum: []interface{}{"SCTP", "TCP", "UDP"}, + }, + }, + "error": { + SchemaProps: spec.SchemaProps{ + Description: "Error is to record the problem with the service port The format of the error shall comply with the following rules: - built-in error values shall be specified in this file and those shall use\n CamelCase names\n- cloud provider specific error values must have names that comply with the\n format foo.example.com/CamelCase.", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"port", "protocol"}, + }, + }, + } +} + +func schema_k8sio_api_core_v1_PortworxVolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "PortworxVolumeSource represents a Portworx volume resource.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "volumeID": { + SchemaProps: spec.SchemaProps{ + Description: "volumeID uniquely identifies a Portworx volume", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "fsType": { + SchemaProps: spec.SchemaProps{ + Description: "fSType represents the filesystem type to mount Must be a filesystem type supported by the host operating system. Ex. \"ext4\", \"xfs\". Implicitly inferred to be \"ext4\" if unspecified.", + Type: []string{"string"}, + Format: "", + }, + }, + "readOnly": { + SchemaProps: spec.SchemaProps{ + Description: "readOnly defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts.", + Type: []string{"boolean"}, + Format: "", + }, + }, + }, + Required: []string{"volumeID"}, + }, + }, + } +} + +func schema_k8sio_api_core_v1_PreferAvoidPodsEntry(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "Describes a class of pods that should avoid this node.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "podSignature": { + SchemaProps: spec.SchemaProps{ + Description: "The class of pods.", + Default: map[string]interface{}{}, + Ref: ref(v1.PodSignature{}.OpenAPIModelName()), + }, + }, + "evictionTime": { + SchemaProps: spec.SchemaProps{ + Description: "Time at which this entry was added to the list.", + Ref: ref(metav1.Time{}.OpenAPIModelName()), + }, + }, + "reason": { + SchemaProps: spec.SchemaProps{ + Description: "(brief) reason why this entry was added to the list.", + Type: []string{"string"}, + Format: "", + }, + }, + "message": { + SchemaProps: spec.SchemaProps{ + Description: "Human readable message indicating why this entry was added to the list.", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"podSignature"}, + }, + }, + Dependencies: []string{ + v1.PodSignature{}.OpenAPIModelName(), metav1.Time{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_PreferredSchedulingTerm(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "An empty preferred scheduling term matches all objects with implicit weight 0 (i.e. it's a no-op). A null preferred scheduling term matches no objects (i.e. is also a no-op).", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "weight": { + SchemaProps: spec.SchemaProps{ + Description: "Weight associated with matching the corresponding nodeSelectorTerm, in the range 1-100.", + Default: 0, + Type: []string{"integer"}, + Format: "int32", + }, + }, + "preference": { + SchemaProps: spec.SchemaProps{ + Description: "A node selector term, associated with the corresponding weight.", + Default: map[string]interface{}{}, + Ref: ref(v1.NodeSelectorTerm{}.OpenAPIModelName()), + }, + }, + }, + Required: []string{"weight", "preference"}, + }, + }, + Dependencies: []string{ + v1.NodeSelectorTerm{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_Probe(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "Probe describes a health check to be performed against a container to determine whether it is alive or ready to receive traffic.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "exec": { + SchemaProps: spec.SchemaProps{ + Description: "Exec specifies a command to execute in the container.", + Ref: ref(v1.ExecAction{}.OpenAPIModelName()), + }, + }, + "httpGet": { + SchemaProps: spec.SchemaProps{ + Description: "HTTPGet specifies an HTTP GET request to perform.", + Ref: ref(v1.HTTPGetAction{}.OpenAPIModelName()), + }, + }, + "tcpSocket": { + SchemaProps: spec.SchemaProps{ + Description: "TCPSocket specifies a connection to a TCP port.", + Ref: ref(v1.TCPSocketAction{}.OpenAPIModelName()), + }, + }, + "grpc": { + SchemaProps: spec.SchemaProps{ + Description: "GRPC specifies a GRPC HealthCheckRequest.", + Ref: ref(v1.GRPCAction{}.OpenAPIModelName()), + }, + }, + "initialDelaySeconds": { + SchemaProps: spec.SchemaProps{ + Description: "Number of seconds after the container has started before liveness probes are initiated. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#container-probes", + Type: []string{"integer"}, + Format: "int32", + }, + }, + "timeoutSeconds": { + SchemaProps: spec.SchemaProps{ + Description: "Number of seconds after which the probe times out. Defaults to 1 second. Minimum value is 1. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#container-probes", + Type: []string{"integer"}, + Format: "int32", + }, + }, + "periodSeconds": { + SchemaProps: spec.SchemaProps{ + Description: "How often (in seconds) to perform the probe. Default to 10 seconds. Minimum value is 1.", + Type: []string{"integer"}, + Format: "int32", + }, + }, + "successThreshold": { + SchemaProps: spec.SchemaProps{ + Description: "Minimum consecutive successes for the probe to be considered successful after having failed. Defaults to 1. Must be 1 for liveness and startup. Minimum value is 1.", + Type: []string{"integer"}, + Format: "int32", + }, + }, + "failureThreshold": { + SchemaProps: spec.SchemaProps{ + Description: "Minimum consecutive failures for the probe to be considered failed after having succeeded. Defaults to 3. Minimum value is 1.", + Type: []string{"integer"}, + Format: "int32", + }, + }, + "terminationGracePeriodSeconds": { + SchemaProps: spec.SchemaProps{ + Description: "Optional duration in seconds the pod needs to terminate gracefully upon probe failure. The grace period is the duration in seconds after the processes running in the pod are sent a termination signal and the time when the processes are forcibly halted with a kill signal. Set this value longer than the expected cleanup time for your process. If this value is nil, the pod's terminationGracePeriodSeconds will be used. Otherwise, this value overrides the value provided by the pod spec. Value must be non-negative integer. The value zero indicates stop immediately via the kill signal (no opportunity to shut down). This is a beta field and requires enabling ProbeTerminationGracePeriod feature gate. Minimum value is 1. spec.terminationGracePeriodSeconds is used if unset.", + Type: []string{"integer"}, + Format: "int64", + }, + }, + }, + }, + }, + Dependencies: []string{ + v1.ExecAction{}.OpenAPIModelName(), v1.GRPCAction{}.OpenAPIModelName(), v1.HTTPGetAction{}.OpenAPIModelName(), v1.TCPSocketAction{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_ProbeHandler(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "ProbeHandler defines a specific action that should be taken in a probe. One and only one of the fields must be specified.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "exec": { + SchemaProps: spec.SchemaProps{ + Description: "Exec specifies a command to execute in the container.", + Ref: ref(v1.ExecAction{}.OpenAPIModelName()), + }, + }, + "httpGet": { + SchemaProps: spec.SchemaProps{ + Description: "HTTPGet specifies an HTTP GET request to perform.", + Ref: ref(v1.HTTPGetAction{}.OpenAPIModelName()), + }, + }, + "tcpSocket": { + SchemaProps: spec.SchemaProps{ + Description: "TCPSocket specifies a connection to a TCP port.", + Ref: ref(v1.TCPSocketAction{}.OpenAPIModelName()), + }, + }, + "grpc": { + SchemaProps: spec.SchemaProps{ + Description: "GRPC specifies a GRPC HealthCheckRequest.", + Ref: ref(v1.GRPCAction{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + Dependencies: []string{ + v1.ExecAction{}.OpenAPIModelName(), v1.GRPCAction{}.OpenAPIModelName(), v1.HTTPGetAction{}.OpenAPIModelName(), v1.TCPSocketAction{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_ProjectedVolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "Represents a projected volume source", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "sources": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "sources is the list of volume projections. Each entry in this list handles one source.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.VolumeProjection{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "defaultMode": { + SchemaProps: spec.SchemaProps{ + Description: "defaultMode are the mode bits used to set permissions on created files by default. Must be an octal value between 0000 and 0777 or a decimal value between 0 and 511. YAML accepts both octal and decimal values, JSON requires decimal values for mode bits. Directories within the path are not affected by this setting. This might be in conflict with other options that affect the file mode, like fsGroup, and the result can be other mode bits set.", + Type: []string{"integer"}, + Format: "int32", + }, + }, + }, + }, + }, + Dependencies: []string{ + v1.VolumeProjection{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_QuobyteVolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "Represents a Quobyte mount that lasts the lifetime of a pod. Quobyte volumes do not support ownership management or SELinux relabeling.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "registry": { + SchemaProps: spec.SchemaProps{ + Description: "registry represents a single or multiple Quobyte Registry services specified as a string as host:port pair (multiple entries are separated with commas) which acts as the central registry for volumes", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "volume": { + SchemaProps: spec.SchemaProps{ + Description: "volume is a string that references an already created Quobyte volume by name.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "readOnly": { + SchemaProps: spec.SchemaProps{ + Description: "readOnly here will force the Quobyte volume to be mounted with read-only permissions. Defaults to false.", + Type: []string{"boolean"}, + Format: "", + }, + }, + "user": { + SchemaProps: spec.SchemaProps{ + Description: "user to map volume access to Defaults to serivceaccount user", + Type: []string{"string"}, + Format: "", + }, + }, + "group": { + SchemaProps: spec.SchemaProps{ + Description: "group to map volume access to Default is no group", + Type: []string{"string"}, + Format: "", + }, + }, + "tenant": { + SchemaProps: spec.SchemaProps{ + Description: "tenant owning the given Quobyte volume in the Backend Used with dynamically provisioned Quobyte volumes, value is set by the plugin", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"registry", "volume"}, + }, + }, + } +} + +func schema_k8sio_api_core_v1_RBDPersistentVolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "Represents a Rados Block Device mount that lasts the lifetime of a pod. RBD volumes support ownership management and SELinux relabeling.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "monitors": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "monitors is a collection of Ceph monitors. More info: https://examples.k8s.io/volumes/rbd/README.md#how-to-use-it", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + "image": { + SchemaProps: spec.SchemaProps{ + Description: "image is the rados image name. More info: https://examples.k8s.io/volumes/rbd/README.md#how-to-use-it", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "fsType": { + SchemaProps: spec.SchemaProps{ + Description: "fsType is the filesystem type of the volume that you want to mount. Tip: Ensure that the filesystem type is supported by the host operating system. Examples: \"ext4\", \"xfs\", \"ntfs\". Implicitly inferred to be \"ext4\" if unspecified. More info: https://kubernetes.io/docs/concepts/storage/volumes#rbd", + Type: []string{"string"}, + Format: "", + }, + }, + "pool": { + SchemaProps: spec.SchemaProps{ + Description: "pool is the rados pool name. Default is rbd. More info: https://examples.k8s.io/volumes/rbd/README.md#how-to-use-it", + Default: "rbd", + Type: []string{"string"}, + Format: "", + }, + }, + "user": { + SchemaProps: spec.SchemaProps{ + Description: "user is the rados user name. Default is admin. More info: https://examples.k8s.io/volumes/rbd/README.md#how-to-use-it", + Default: "admin", + Type: []string{"string"}, + Format: "", + }, + }, + "keyring": { + SchemaProps: spec.SchemaProps{ + Description: "keyring is the path to key ring for RBDUser. Default is /etc/ceph/keyring. More info: https://examples.k8s.io/volumes/rbd/README.md#how-to-use-it", + Default: "/etc/ceph/keyring", + Type: []string{"string"}, + Format: "", + }, + }, + "secretRef": { + SchemaProps: spec.SchemaProps{ + Description: "secretRef is name of the authentication secret for RBDUser. If provided overrides keyring. Default is nil. More info: https://examples.k8s.io/volumes/rbd/README.md#how-to-use-it", + Ref: ref(v1.SecretReference{}.OpenAPIModelName()), + }, + }, + "readOnly": { + SchemaProps: spec.SchemaProps{ + Description: "readOnly here will force the ReadOnly setting in VolumeMounts. Defaults to false. More info: https://examples.k8s.io/volumes/rbd/README.md#how-to-use-it", + Type: []string{"boolean"}, + Format: "", + }, + }, + }, + Required: []string{"monitors", "image"}, + }, + }, + Dependencies: []string{ + v1.SecretReference{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_RBDVolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "Represents a Rados Block Device mount that lasts the lifetime of a pod. RBD volumes support ownership management and SELinux relabeling.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "monitors": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "monitors is a collection of Ceph monitors. More info: https://examples.k8s.io/volumes/rbd/README.md#how-to-use-it", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + "image": { + SchemaProps: spec.SchemaProps{ + Description: "image is the rados image name. More info: https://examples.k8s.io/volumes/rbd/README.md#how-to-use-it", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "fsType": { + SchemaProps: spec.SchemaProps{ + Description: "fsType is the filesystem type of the volume that you want to mount. Tip: Ensure that the filesystem type is supported by the host operating system. Examples: \"ext4\", \"xfs\", \"ntfs\". Implicitly inferred to be \"ext4\" if unspecified. More info: https://kubernetes.io/docs/concepts/storage/volumes#rbd", + Type: []string{"string"}, + Format: "", + }, + }, + "pool": { + SchemaProps: spec.SchemaProps{ + Description: "pool is the rados pool name. Default is rbd. More info: https://examples.k8s.io/volumes/rbd/README.md#how-to-use-it", + Default: "rbd", + Type: []string{"string"}, + Format: "", + }, + }, + "user": { + SchemaProps: spec.SchemaProps{ + Description: "user is the rados user name. Default is admin. More info: https://examples.k8s.io/volumes/rbd/README.md#how-to-use-it", + Default: "admin", + Type: []string{"string"}, + Format: "", + }, + }, + "keyring": { + SchemaProps: spec.SchemaProps{ + Description: "keyring is the path to key ring for RBDUser. Default is /etc/ceph/keyring. More info: https://examples.k8s.io/volumes/rbd/README.md#how-to-use-it", + Default: "/etc/ceph/keyring", + Type: []string{"string"}, + Format: "", + }, + }, + "secretRef": { + SchemaProps: spec.SchemaProps{ + Description: "secretRef is name of the authentication secret for RBDUser. If provided overrides keyring. Default is nil. More info: https://examples.k8s.io/volumes/rbd/README.md#how-to-use-it", + Ref: ref(v1.LocalObjectReference{}.OpenAPIModelName()), + }, + }, + "readOnly": { + SchemaProps: spec.SchemaProps{ + Description: "readOnly here will force the ReadOnly setting in VolumeMounts. Defaults to false. More info: https://examples.k8s.io/volumes/rbd/README.md#how-to-use-it", + Type: []string{"boolean"}, + Format: "", + }, + }, + }, + Required: []string{"monitors", "image"}, + }, + }, + Dependencies: []string{ + v1.LocalObjectReference{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_RangeAllocation(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "RangeAllocation is not a public type.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "metadata": { + SchemaProps: spec.SchemaProps{ + Description: "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata", + Default: map[string]interface{}{}, + Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), + }, + }, + "range": { + SchemaProps: spec.SchemaProps{ + Description: "Range is string that identifies the range represented by 'data'.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "data": { + SchemaProps: spec.SchemaProps{ + Description: "Data is a bit array containing all allocated addresses in the previous segment.", + Type: []string{"string"}, + Format: "byte", + }, + }, + }, + Required: []string{"range", "data"}, + }, + }, + Dependencies: []string{ + metav1.ObjectMeta{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_ReplicationController(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "ReplicationController represents the configuration of a replication controller.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "metadata": { + SchemaProps: spec.SchemaProps{ + Description: "If the Labels of a ReplicationController are empty, they are defaulted to be the same as the Pod(s) that the replication controller manages. Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata", + Default: map[string]interface{}{}, + Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), + }, + }, + "spec": { + SchemaProps: spec.SchemaProps{ + Description: "Spec defines the specification of the desired behavior of the replication controller. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status", + Default: map[string]interface{}{}, + Ref: ref(v1.ReplicationControllerSpec{}.OpenAPIModelName()), + }, + }, + "status": { + SchemaProps: spec.SchemaProps{ + Description: "Status is the most recently observed status of the replication controller. This data may be out of date by some window of time. Populated by the system. Read-only. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status", + Default: map[string]interface{}{}, + Ref: ref(v1.ReplicationControllerStatus{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + Dependencies: []string{ + v1.ReplicationControllerSpec{}.OpenAPIModelName(), v1.ReplicationControllerStatus{}.OpenAPIModelName(), metav1.ObjectMeta{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_ReplicationControllerCondition(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "ReplicationControllerCondition describes the state of a replication controller at a certain point.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "type": { + SchemaProps: spec.SchemaProps{ + Description: "Type of replication controller condition.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "status": { + SchemaProps: spec.SchemaProps{ + Description: "Status of the condition, one of True, False, Unknown.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "lastTransitionTime": { + SchemaProps: spec.SchemaProps{ + Description: "The last time the condition transitioned from one status to another.", + Ref: ref(metav1.Time{}.OpenAPIModelName()), + }, + }, + "reason": { + SchemaProps: spec.SchemaProps{ + Description: "The reason for the condition's last transition.", + Type: []string{"string"}, + Format: "", + }, + }, + "message": { + SchemaProps: spec.SchemaProps{ + Description: "A human readable message indicating details about the transition.", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"type", "status"}, + }, + }, + Dependencies: []string{ + metav1.Time{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_ReplicationControllerList(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "ReplicationControllerList is a collection of replication controllers.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "metadata": { + SchemaProps: spec.SchemaProps{ + Description: "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Default: map[string]interface{}{}, + Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), + }, + }, + "items": { + SchemaProps: spec.SchemaProps{ + Description: "List of replication controllers. More info: https://kubernetes.io/docs/concepts/workloads/controllers/replicationcontroller", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.ReplicationController{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + }, + Required: []string{"items"}, + }, + }, + Dependencies: []string{ + v1.ReplicationController{}.OpenAPIModelName(), metav1.ListMeta{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_ReplicationControllerSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "ReplicationControllerSpec is the specification of a replication controller.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "replicas": { + SchemaProps: spec.SchemaProps{ + Description: "Replicas is the number of desired replicas. This is a pointer to distinguish between explicit zero and unspecified. Defaults to 1. More info: https://kubernetes.io/docs/concepts/workloads/controllers/replicationcontroller#what-is-a-replicationcontroller", + Default: 1, + Type: []string{"integer"}, + Format: "int32", + }, + }, + "minReadySeconds": { + SchemaProps: spec.SchemaProps{ + Description: "Minimum number of seconds for which a newly created pod should be ready without any of its container crashing, for it to be considered available. Defaults to 0 (pod will be considered available as soon as it is ready)", + Default: 0, + Type: []string{"integer"}, + Format: "int32", + }, + }, + "selector": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-map-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "Selector is a label query over pods that should match the Replicas count. If Selector is empty, it is defaulted to the labels present on the Pod template. Label keys and values that must match in order to be controlled by this replication controller, if empty defaulted to labels on Pod template. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/#label-selectors", + Type: []string{"object"}, + AdditionalProperties: &spec.SchemaOrBool{ + Allows: true, + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + "template": { + SchemaProps: spec.SchemaProps{ + Description: "Template is the object that describes the pod that will be created if insufficient replicas are detected. This takes precedence over a TemplateRef. The only allowed template.spec.restartPolicy value is \"Always\". More info: https://kubernetes.io/docs/concepts/workloads/controllers/replicationcontroller#pod-template", + Ref: ref(v1.PodTemplateSpec{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + Dependencies: []string{ + v1.PodTemplateSpec{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_ReplicationControllerStatus(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "ReplicationControllerStatus represents the current status of a replication controller.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "replicas": { + SchemaProps: spec.SchemaProps{ + Description: "Replicas is the most recently observed number of replicas. More info: https://kubernetes.io/docs/concepts/workloads/controllers/replicationcontroller#what-is-a-replicationcontroller", + Default: 0, + Type: []string{"integer"}, + Format: "int32", + }, + }, + "fullyLabeledReplicas": { + SchemaProps: spec.SchemaProps{ + Description: "The number of pods that have labels matching the labels of the pod template of the replication controller.", + Type: []string{"integer"}, + Format: "int32", + }, + }, + "readyReplicas": { + SchemaProps: spec.SchemaProps{ + Description: "The number of ready replicas for this replication controller.", + Type: []string{"integer"}, + Format: "int32", + }, + }, + "availableReplicas": { + SchemaProps: spec.SchemaProps{ + Description: "The number of available replicas (ready for at least minReadySeconds) for this replication controller.", + Type: []string{"integer"}, + Format: "int32", + }, + }, + "observedGeneration": { + SchemaProps: spec.SchemaProps{ + Description: "ObservedGeneration reflects the generation of the most recently observed replication controller.", + Type: []string{"integer"}, + Format: "int64", + }, + }, + "conditions": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-map-keys": []interface{}{ + "type", + }, + "x-kubernetes-list-type": "map", + "x-kubernetes-patch-merge-key": "type", + "x-kubernetes-patch-strategy": "merge", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "Represents the latest available observations of a replication controller's current state.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.ReplicationControllerCondition{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + }, + Required: []string{"replicas"}, + }, + }, + Dependencies: []string{ + v1.ReplicationControllerCondition{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_ResourceClaim(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "ResourceClaim references one entry in PodSpec.ResourceClaims.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "name": { + SchemaProps: spec.SchemaProps{ + Description: "Name must match the name of one entry in pod.spec.resourceClaims of the Pod where this field is used. It makes that resource available inside a container.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "request": { + SchemaProps: spec.SchemaProps{ + Description: "Request is the name chosen for a request in the referenced claim. If empty, everything from the claim is made available, otherwise only the result of this request.", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"name"}, + }, + }, + } +} + +func schema_k8sio_api_core_v1_ResourceFieldSelector(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "ResourceFieldSelector represents container resources (cpu, memory) and their output format", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "containerName": { + SchemaProps: spec.SchemaProps{ + Description: "Container name: required for volumes, optional for env vars", + Type: []string{"string"}, + Format: "", + }, + }, + "resource": { + SchemaProps: spec.SchemaProps{ + Description: "Required: resource to select", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "divisor": { + SchemaProps: spec.SchemaProps{ + Description: "Specifies the output format of the exposed resources, defaults to \"1\"", + Ref: ref(resource.Quantity{}.OpenAPIModelName()), + }, + }, + }, + Required: []string{"resource"}, + }, + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-map-type": "atomic", + }, + }, + }, + Dependencies: []string{ + resource.Quantity{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_ResourceHealth(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "ResourceHealth represents the health of a resource. It has the latest device health information. This is a part of KEP https://kep.k8s.io/4680.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "resourceID": { + SchemaProps: spec.SchemaProps{ + Description: "ResourceID is the unique identifier of the resource. See the ResourceID type for more information.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "health": { + SchemaProps: spec.SchemaProps{ + Description: "Health of the resource. can be one of:\n - Healthy: operates as normal\n - Unhealthy: reported unhealthy. We consider this a temporary health issue\n since we do not have a mechanism today to distinguish\n temporary and permanent issues.\n - Unknown: The status cannot be determined.\n For example, Device Plugin got unregistered and hasn't been re-registered since.\n\nIn future we may want to introduce the PermanentlyUnhealthy Status.", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"resourceID"}, + }, + }, + } +} + +func schema_k8sio_api_core_v1_ResourceQuota(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "ResourceQuota sets aggregate quota restrictions enforced per namespace", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "metadata": { + SchemaProps: spec.SchemaProps{ + Description: "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata", + Default: map[string]interface{}{}, + Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), + }, + }, + "spec": { + SchemaProps: spec.SchemaProps{ + Description: "Spec defines the desired quota. https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status", + Default: map[string]interface{}{}, + Ref: ref(v1.ResourceQuotaSpec{}.OpenAPIModelName()), + }, + }, + "status": { + SchemaProps: spec.SchemaProps{ + Description: "Status defines the actual enforced quota and its current usage. https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status", + Default: map[string]interface{}{}, + Ref: ref(v1.ResourceQuotaStatus{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + Dependencies: []string{ + v1.ResourceQuotaSpec{}.OpenAPIModelName(), v1.ResourceQuotaStatus{}.OpenAPIModelName(), metav1.ObjectMeta{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_ResourceQuotaList(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "ResourceQuotaList is a list of ResourceQuota items.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "metadata": { + SchemaProps: spec.SchemaProps{ + Description: "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Default: map[string]interface{}{}, + Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), + }, + }, + "items": { + SchemaProps: spec.SchemaProps{ + Description: "Items is a list of ResourceQuota objects. More info: https://kubernetes.io/docs/concepts/policy/resource-quotas/", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.ResourceQuota{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + }, + Required: []string{"items"}, + }, + }, + Dependencies: []string{ + v1.ResourceQuota{}.OpenAPIModelName(), metav1.ListMeta{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_ResourceQuotaSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "ResourceQuotaSpec defines the desired hard limits to enforce for Quota.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "hard": { + SchemaProps: spec.SchemaProps{ + Description: "hard is the set of desired hard limits for each named resource. More info: https://kubernetes.io/docs/concepts/policy/resource-quotas/", + Type: []string{"object"}, + AdditionalProperties: &spec.SchemaOrBool{ + Allows: true, + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Ref: ref(resource.Quantity{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "scopes": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "A collection of filters that must match each object tracked by a quota. If not specified, the quota matches all objects.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + Enum: []interface{}{"BestEffort", "CrossNamespacePodAffinity", "NotBestEffort", "NotTerminating", "PriorityClass", "Terminating", "VolumeAttributesClass"}, + }, + }, + }, + }, + }, + "scopeSelector": { + SchemaProps: spec.SchemaProps{ + Description: "scopeSelector is also a collection of filters like scopes that must match each object tracked by a quota but expressed using ScopeSelectorOperator in combination with possible values. For a resource to match, both scopes AND scopeSelector (if specified in spec), must be matched.", + Ref: ref(v1.ScopeSelector{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + Dependencies: []string{ + v1.ScopeSelector{}.OpenAPIModelName(), resource.Quantity{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_ResourceQuotaStatus(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "ResourceQuotaStatus defines the enforced hard limits and observed use.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "hard": { + SchemaProps: spec.SchemaProps{ + Description: "Hard is the set of enforced hard limits for each named resource. More info: https://kubernetes.io/docs/concepts/policy/resource-quotas/", + Type: []string{"object"}, + AdditionalProperties: &spec.SchemaOrBool{ + Allows: true, + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Ref: ref(resource.Quantity{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "used": { + SchemaProps: spec.SchemaProps{ + Description: "Used is the current observed total usage of the resource in the namespace.", + Type: []string{"object"}, + AdditionalProperties: &spec.SchemaOrBool{ + Allows: true, + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Ref: ref(resource.Quantity{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + }, + }, + }, + Dependencies: []string{ + resource.Quantity{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_ResourceRequirements(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "ResourceRequirements describes the compute resource requirements.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "limits": { + SchemaProps: spec.SchemaProps{ + Description: "Limits describes the maximum amount of compute resources allowed. More info: https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/", + Type: []string{"object"}, + AdditionalProperties: &spec.SchemaOrBool{ + Allows: true, + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Ref: ref(resource.Quantity{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "requests": { + SchemaProps: spec.SchemaProps{ + Description: "Requests describes the minimum amount of compute resources required. If Requests is omitted for a container, it defaults to Limits if that is explicitly specified, otherwise to an implementation-defined value. Requests cannot exceed Limits. More info: https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/", + Type: []string{"object"}, + AdditionalProperties: &spec.SchemaOrBool{ + Allows: true, + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Ref: ref(resource.Quantity{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "claims": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-map-keys": []interface{}{ + "name", + }, + "x-kubernetes-list-type": "map", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "Claims lists the names of resources, defined in spec.resourceClaims, that are used by this container.\n\nThis field depends on the DynamicResourceAllocation feature gate.\n\nThis field is immutable. It can only be set for containers.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.ResourceClaim{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + }, + }, + }, + Dependencies: []string{ + v1.ResourceClaim{}.OpenAPIModelName(), resource.Quantity{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_ResourceStatus(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "ResourceStatus represents the status of a single resource allocated to a Pod.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "name": { + SchemaProps: spec.SchemaProps{ + Description: "Name of the resource. Must be unique within the pod and in case of non-DRA resource, match one of the resources from the pod spec. For DRA resources, the value must be \"claim:/\". When this status is reported about a container, the \"claim_name\" and \"request\" must match one of the claims of this container.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "resources": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-map-keys": []interface{}{ + "resourceID", + }, + "x-kubernetes-list-type": "map", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "List of unique resources health. Each element in the list contains an unique resource ID and its health. At a minimum, for the lifetime of a Pod, resource ID must uniquely identify the resource allocated to the Pod on the Node. If other Pod on the same Node reports the status with the same resource ID, it must be the same resource they share. See ResourceID type definition for a specific format it has in various use cases.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.ResourceHealth{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + }, + Required: []string{"name"}, + }, + }, + Dependencies: []string{ + v1.ResourceHealth{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_SELinuxOptions(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "SELinuxOptions are the labels to be applied to the container", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "user": { + SchemaProps: spec.SchemaProps{ + Description: "User is a SELinux user label that applies to the container.", + Type: []string{"string"}, + Format: "", + }, + }, + "role": { + SchemaProps: spec.SchemaProps{ + Description: "Role is a SELinux role label that applies to the container.", + Type: []string{"string"}, + Format: "", + }, + }, + "type": { + SchemaProps: spec.SchemaProps{ + Description: "Type is a SELinux type label that applies to the container.", + Type: []string{"string"}, + Format: "", + }, + }, + "level": { + SchemaProps: spec.SchemaProps{ + Description: "Level is SELinux level label that applies to the container.", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + } +} + +func schema_k8sio_api_core_v1_ScaleIOPersistentVolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "ScaleIOPersistentVolumeSource represents a persistent ScaleIO volume", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "gateway": { + SchemaProps: spec.SchemaProps{ + Description: "gateway is the host address of the ScaleIO API Gateway.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "system": { + SchemaProps: spec.SchemaProps{ + Description: "system is the name of the storage system as configured in ScaleIO.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "secretRef": { + SchemaProps: spec.SchemaProps{ + Description: "secretRef references to the secret for ScaleIO user and other sensitive information. If this is not provided, Login operation will fail.", + Ref: ref(v1.SecretReference{}.OpenAPIModelName()), + }, + }, + "sslEnabled": { + SchemaProps: spec.SchemaProps{ + Description: "sslEnabled is the flag to enable/disable SSL communication with Gateway, default false", + Type: []string{"boolean"}, + Format: "", + }, + }, + "protectionDomain": { + SchemaProps: spec.SchemaProps{ + Description: "protectionDomain is the name of the ScaleIO Protection Domain for the configured storage.", + Type: []string{"string"}, + Format: "", + }, + }, + "storagePool": { + SchemaProps: spec.SchemaProps{ + Description: "storagePool is the ScaleIO Storage Pool associated with the protection domain.", + Type: []string{"string"}, + Format: "", + }, + }, + "storageMode": { + SchemaProps: spec.SchemaProps{ + Description: "storageMode indicates whether the storage for a volume should be ThickProvisioned or ThinProvisioned. Default is ThinProvisioned.", + Default: "ThinProvisioned", + Type: []string{"string"}, + Format: "", + }, + }, + "volumeName": { + SchemaProps: spec.SchemaProps{ + Description: "volumeName is the name of a volume already created in the ScaleIO system that is associated with this volume source.", + Type: []string{"string"}, + Format: "", + }, + }, + "fsType": { + SchemaProps: spec.SchemaProps{ + Description: "fsType is the filesystem type to mount. Must be a filesystem type supported by the host operating system. Ex. \"ext4\", \"xfs\", \"ntfs\". Default is \"xfs\"", + Default: "xfs", + Type: []string{"string"}, + Format: "", + }, + }, + "readOnly": { + SchemaProps: spec.SchemaProps{ + Description: "readOnly defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts.", + Type: []string{"boolean"}, + Format: "", + }, + }, + }, + Required: []string{"gateway", "system", "secretRef"}, + }, + }, + Dependencies: []string{ + v1.SecretReference{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_ScaleIOVolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "ScaleIOVolumeSource represents a persistent ScaleIO volume", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "gateway": { + SchemaProps: spec.SchemaProps{ + Description: "gateway is the host address of the ScaleIO API Gateway.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "system": { + SchemaProps: spec.SchemaProps{ + Description: "system is the name of the storage system as configured in ScaleIO.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "secretRef": { + SchemaProps: spec.SchemaProps{ + Description: "secretRef references to the secret for ScaleIO user and other sensitive information. If this is not provided, Login operation will fail.", + Ref: ref(v1.LocalObjectReference{}.OpenAPIModelName()), + }, + }, + "sslEnabled": { + SchemaProps: spec.SchemaProps{ + Description: "sslEnabled Flag enable/disable SSL communication with Gateway, default false", + Type: []string{"boolean"}, + Format: "", + }, + }, + "protectionDomain": { + SchemaProps: spec.SchemaProps{ + Description: "protectionDomain is the name of the ScaleIO Protection Domain for the configured storage.", + Type: []string{"string"}, + Format: "", + }, + }, + "storagePool": { + SchemaProps: spec.SchemaProps{ + Description: "storagePool is the ScaleIO Storage Pool associated with the protection domain.", + Type: []string{"string"}, + Format: "", + }, + }, + "storageMode": { + SchemaProps: spec.SchemaProps{ + Description: "storageMode indicates whether the storage for a volume should be ThickProvisioned or ThinProvisioned. Default is ThinProvisioned.", + Default: "ThinProvisioned", + Type: []string{"string"}, + Format: "", + }, + }, + "volumeName": { + SchemaProps: spec.SchemaProps{ + Description: "volumeName is the name of a volume already created in the ScaleIO system that is associated with this volume source.", + Type: []string{"string"}, + Format: "", + }, + }, + "fsType": { + SchemaProps: spec.SchemaProps{ + Description: "fsType is the filesystem type to mount. Must be a filesystem type supported by the host operating system. Ex. \"ext4\", \"xfs\", \"ntfs\". Default is \"xfs\".", + Default: "xfs", + Type: []string{"string"}, + Format: "", + }, + }, + "readOnly": { + SchemaProps: spec.SchemaProps{ + Description: "readOnly Defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts.", + Type: []string{"boolean"}, + Format: "", + }, + }, + }, + Required: []string{"gateway", "system", "secretRef"}, + }, + }, + Dependencies: []string{ + v1.LocalObjectReference{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_ScopeSelector(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "A scope selector represents the AND of the selectors represented by the scoped-resource selector requirements.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "matchExpressions": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "A list of scope selector requirements by scope of the resources.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.ScopedResourceSelectorRequirement{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + }, + }, + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-map-type": "atomic", + }, + }, + }, + Dependencies: []string{ + v1.ScopedResourceSelectorRequirement{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_ScopedResourceSelectorRequirement(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "A scoped-resource selector requirement is a selector that contains values, a scope name, and an operator that relates the scope name and values.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "scopeName": { + SchemaProps: spec.SchemaProps{ + Description: "The name of the scope that the selector applies to.\n\nPossible enum values:\n - `\"BestEffort\"` Match all pod objects that have best effort quality of service\n - `\"CrossNamespacePodAffinity\"` Match all pod objects that have cross-namespace pod (anti)affinity mentioned.\n - `\"NotBestEffort\"` Match all pod objects that do not have best effort quality of service\n - `\"NotTerminating\"` Match all pod objects where spec.activeDeadlineSeconds is nil\n - `\"PriorityClass\"` Match all pod objects that have priority class mentioned\n - `\"Terminating\"` Match all pod objects where spec.activeDeadlineSeconds >=0\n - `\"VolumeAttributesClass\"` Match all pvc objects that have volume attributes class mentioned.", + Default: "", + Type: []string{"string"}, + Format: "", + Enum: []interface{}{"BestEffort", "CrossNamespacePodAffinity", "NotBestEffort", "NotTerminating", "PriorityClass", "Terminating", "VolumeAttributesClass"}, + }, + }, + "operator": { + SchemaProps: spec.SchemaProps{ + Description: "Represents a scope's relationship to a set of values. Valid operators are In, NotIn, Exists, DoesNotExist.\n\nPossible enum values:\n - `\"DoesNotExist\"`\n - `\"Exists\"`\n - `\"In\"`\n - `\"NotIn\"`", + Default: "", + Type: []string{"string"}, + Format: "", + Enum: []interface{}{"DoesNotExist", "Exists", "In", "NotIn"}, + }, + }, + "values": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "An array of string values. If the operator is In or NotIn, the values array must be non-empty. If the operator is Exists or DoesNotExist, the values array must be empty. This array is replaced during a strategic merge patch.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + }, + Required: []string{"scopeName", "operator"}, + }, + }, + } +} + +func schema_k8sio_api_core_v1_SeccompProfile(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "SeccompProfile defines a pod/container's seccomp profile settings. Only one profile source may be set.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "type": { + SchemaProps: spec.SchemaProps{ + Description: "type indicates which kind of seccomp profile will be applied. Valid options are:\n\nLocalhost - a profile defined in a file on the node should be used. RuntimeDefault - the container runtime default profile should be used. Unconfined - no profile should be applied.\n\nPossible enum values:\n - `\"Localhost\"` indicates a profile defined in a file on the node should be used. The file's location relative to /seccomp.\n - `\"RuntimeDefault\"` represents the default container runtime seccomp profile.\n - `\"Unconfined\"` indicates no seccomp profile is applied (A.K.A. unconfined).", + Default: "", + Type: []string{"string"}, + Format: "", + Enum: []interface{}{"Localhost", "RuntimeDefault", "Unconfined"}, + }, + }, + "localhostProfile": { + SchemaProps: spec.SchemaProps{ + Description: "localhostProfile indicates a profile defined in a file on the node should be used. The profile must be preconfigured on the node to work. Must be a descending path, relative to the kubelet's configured seccomp profile location. Must be set if type is \"Localhost\". Must NOT be set for any other type.", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"type"}, + }, + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-unions": []interface{}{ + map[string]interface{}{ + "discriminator": "type", + "fields-to-discriminateBy": map[string]interface{}{ + "localhostProfile": "LocalhostProfile", + }, + }, + }, + }, + }, + }, + } +} + +func schema_k8sio_api_core_v1_Secret(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "Secret holds secret data of a certain type. The total bytes of the values in the Data field must be less than MaxSecretSize bytes.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "metadata": { + SchemaProps: spec.SchemaProps{ + Description: "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata", + Default: map[string]interface{}{}, + Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), + }, + }, + "immutable": { + SchemaProps: spec.SchemaProps{ + Description: "Immutable, if set to true, ensures that data stored in the Secret cannot be updated (only object metadata can be modified). If not set to true, the field can be modified at any time. Defaulted to nil.", + Type: []string{"boolean"}, + Format: "", + }, + }, + "data": { + SchemaProps: spec.SchemaProps{ + Description: "Data contains the secret data. Each key must consist of alphanumeric characters, '-', '_' or '.'. The serialized form of the secret data is a base64 encoded string, representing the arbitrary (possibly non-string) data value here. Described in https://tools.ietf.org/html/rfc4648#section-4", + Type: []string{"object"}, + AdditionalProperties: &spec.SchemaOrBool{ + Allows: true, + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"string"}, + Format: "byte", + }, + }, + }, + }, + }, + "stringData": { + SchemaProps: spec.SchemaProps{ + Description: "stringData allows specifying non-binary secret data in string form. It is provided as a write-only input field for convenience. All keys and values are merged into the data field on write, overwriting any existing values. The stringData field is never output when reading from the API.", + Type: []string{"object"}, + AdditionalProperties: &spec.SchemaOrBool{ + Allows: true, + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + "type": { + SchemaProps: spec.SchemaProps{ + Description: "Used to facilitate programmatic handling of secret data. More info: https://kubernetes.io/docs/concepts/configuration/secret/#secret-types", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + Dependencies: []string{ + metav1.ObjectMeta{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_SecretEnvSource(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "SecretEnvSource selects a Secret to populate the environment variables with.\n\nThe contents of the target Secret's Data field will represent the key-value pairs as environment variables.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "name": { + SchemaProps: spec.SchemaProps{ + Description: "Name of the referent. This field is effectively required, but due to backwards compatibility is allowed to be empty. Instances of this type with an empty value here are almost certainly wrong. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "optional": { + SchemaProps: spec.SchemaProps{ + Description: "Specify whether the Secret must be defined", + Type: []string{"boolean"}, + Format: "", + }, + }, + }, + }, + }, + } +} + +func schema_k8sio_api_core_v1_SecretKeySelector(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "SecretKeySelector selects a key of a Secret.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "name": { + SchemaProps: spec.SchemaProps{ + Description: "Name of the referent. This field is effectively required, but due to backwards compatibility is allowed to be empty. Instances of this type with an empty value here are almost certainly wrong. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "key": { + SchemaProps: spec.SchemaProps{ + Description: "The key of the secret to select from. Must be a valid secret key.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "optional": { + SchemaProps: spec.SchemaProps{ + Description: "Specify whether the Secret or its key must be defined", + Type: []string{"boolean"}, + Format: "", + }, + }, + }, + Required: []string{"key"}, + }, + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-map-type": "atomic", + }, + }, + }, + } +} + +func schema_k8sio_api_core_v1_SecretList(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "SecretList is a list of Secret.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "metadata": { + SchemaProps: spec.SchemaProps{ + Description: "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Default: map[string]interface{}{}, + Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), + }, + }, + "items": { + SchemaProps: spec.SchemaProps{ + Description: "Items is a list of secret objects. More info: https://kubernetes.io/docs/concepts/configuration/secret", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.Secret{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + }, + Required: []string{"items"}, + }, + }, + Dependencies: []string{ + v1.Secret{}.OpenAPIModelName(), metav1.ListMeta{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_SecretProjection(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "Adapts a secret into a projected volume.\n\nThe contents of the target Secret's Data field will be presented in a projected volume as files using the keys in the Data field as the file names. Note that this is identical to a secret volume source without the default mode.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "name": { + SchemaProps: spec.SchemaProps{ + Description: "Name of the referent. This field is effectively required, but due to backwards compatibility is allowed to be empty. Instances of this type with an empty value here are almost certainly wrong. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "items": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "items if unspecified, each key-value pair in the Data field of the referenced Secret will be projected into the volume as a file whose name is the key and content is the value. If specified, the listed keys will be projected into the specified paths, and unlisted keys will not be present. If a key is specified which is not present in the Secret, the volume setup will error unless it is marked optional. Paths must be relative and may not contain the '..' path or start with '..'.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.KeyToPath{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "optional": { + SchemaProps: spec.SchemaProps{ + Description: "optional field specify whether the Secret or its key must be defined", + Type: []string{"boolean"}, + Format: "", + }, + }, + }, + }, + }, + Dependencies: []string{ + v1.KeyToPath{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_SecretReference(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "SecretReference represents a Secret Reference. It has enough information to retrieve secret in any namespace", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "name": { + SchemaProps: spec.SchemaProps{ + Description: "name is unique within a namespace to reference a secret resource.", + Type: []string{"string"}, + Format: "", + }, + }, + "namespace": { + SchemaProps: spec.SchemaProps{ + Description: "namespace defines the space within which the secret name must be unique.", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-map-type": "atomic", + }, + }, + }, + } +} + +func schema_k8sio_api_core_v1_SecretVolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "Adapts a Secret into a volume.\n\nThe contents of the target Secret's Data field will be presented in a volume as files using the keys in the Data field as the file names. Secret volumes support ownership management and SELinux relabeling.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "secretName": { + SchemaProps: spec.SchemaProps{ + Description: "secretName is the name of the secret in the pod's namespace to use. More info: https://kubernetes.io/docs/concepts/storage/volumes#secret", + Type: []string{"string"}, + Format: "", + }, + }, + "items": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "items If unspecified, each key-value pair in the Data field of the referenced Secret will be projected into the volume as a file whose name is the key and content is the value. If specified, the listed keys will be projected into the specified paths, and unlisted keys will not be present. If a key is specified which is not present in the Secret, the volume setup will error unless it is marked optional. Paths must be relative and may not contain the '..' path or start with '..'.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.KeyToPath{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "defaultMode": { + SchemaProps: spec.SchemaProps{ + Description: "defaultMode is Optional: mode bits used to set permissions on created files by default. Must be an octal value between 0000 and 0777 or a decimal value between 0 and 511. YAML accepts both octal and decimal values, JSON requires decimal values for mode bits. Defaults to 0644. Directories within the path are not affected by this setting. This might be in conflict with other options that affect the file mode, like fsGroup, and the result can be other mode bits set.", + Type: []string{"integer"}, + Format: "int32", + }, + }, + "optional": { + SchemaProps: spec.SchemaProps{ + Description: "optional field specify whether the Secret or its keys must be defined", + Type: []string{"boolean"}, + Format: "", + }, + }, + }, + }, + }, + Dependencies: []string{ + v1.KeyToPath{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_SecurityContext(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "SecurityContext holds security configuration that will be applied to a container. Some fields are present in both SecurityContext and PodSecurityContext. When both are set, the values in SecurityContext take precedence.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "capabilities": { + SchemaProps: spec.SchemaProps{ + Description: "The capabilities to add/drop when running containers. Defaults to the default set of capabilities granted by the container runtime. Note that this field cannot be set when spec.os.name is windows.", + Ref: ref(v1.Capabilities{}.OpenAPIModelName()), + }, + }, + "privileged": { + SchemaProps: spec.SchemaProps{ + Description: "Run container in privileged mode. Processes in privileged containers are essentially equivalent to root on the host. Defaults to false. Note that this field cannot be set when spec.os.name is windows.", + Type: []string{"boolean"}, + Format: "", + }, + }, + "seLinuxOptions": { + SchemaProps: spec.SchemaProps{ + Description: "The SELinux context to be applied to the container. If unspecified, the container runtime will allocate a random SELinux context for each container. May also be set in PodSecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence. Note that this field cannot be set when spec.os.name is windows.", + Ref: ref(v1.SELinuxOptions{}.OpenAPIModelName()), + }, + }, + "windowsOptions": { + SchemaProps: spec.SchemaProps{ + Description: "The Windows specific settings applied to all containers. If unspecified, the options from the PodSecurityContext will be used. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence. Note that this field cannot be set when spec.os.name is linux.", + Ref: ref(v1.WindowsSecurityContextOptions{}.OpenAPIModelName()), + }, + }, + "runAsUser": { + SchemaProps: spec.SchemaProps{ + Description: "The UID to run the entrypoint of the container process. Defaults to user specified in image metadata if unspecified. May also be set in PodSecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence. Note that this field cannot be set when spec.os.name is windows.", + Type: []string{"integer"}, + Format: "int64", + }, + }, + "runAsGroup": { + SchemaProps: spec.SchemaProps{ + Description: "The GID to run the entrypoint of the container process. Uses runtime default if unset. May also be set in PodSecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence. Note that this field cannot be set when spec.os.name is windows.", + Type: []string{"integer"}, + Format: "int64", + }, + }, + "runAsNonRoot": { + SchemaProps: spec.SchemaProps{ + Description: "Indicates that the container must run as a non-root user. If true, the Kubelet will validate the image at runtime to ensure that it does not run as UID 0 (root) and fail to start the container if it does. If unset or false, no such validation will be performed. May also be set in PodSecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence.", + Type: []string{"boolean"}, + Format: "", + }, + }, + "readOnlyRootFilesystem": { + SchemaProps: spec.SchemaProps{ + Description: "Whether this container has a read-only root filesystem. Default is false. Note that this field cannot be set when spec.os.name is windows.", + Type: []string{"boolean"}, + Format: "", + }, + }, + "allowPrivilegeEscalation": { + SchemaProps: spec.SchemaProps{ + Description: "AllowPrivilegeEscalation controls whether a process can gain more privileges than its parent process. This bool directly controls if the no_new_privs flag will be set on the container process. AllowPrivilegeEscalation is true always when the container is: 1) run as Privileged 2) has CAP_SYS_ADMIN Note that this field cannot be set when spec.os.name is windows.", + Type: []string{"boolean"}, + Format: "", + }, + }, + "procMount": { + SchemaProps: spec.SchemaProps{ + Description: "procMount denotes the type of proc mount to use for the containers. The default value is Default which uses the container runtime defaults for readonly paths and masked paths. This requires the ProcMountType feature flag to be enabled. Note that this field cannot be set when spec.os.name is windows.\n\nPossible enum values:\n - `\"Default\"` uses the container runtime defaults for readonly and masked paths for /proc. Most container runtimes mask certain paths in /proc to avoid accidental security exposure of special devices or information.\n - `\"Unmasked\"` bypasses the default masking behavior of the container runtime and ensures the newly created /proc the container stays in tact with no modifications.", + Type: []string{"string"}, + Format: "", + Enum: []interface{}{"Default", "Unmasked"}, + }, + }, + "seccompProfile": { + SchemaProps: spec.SchemaProps{ + Description: "The seccomp options to use by this container. If seccomp options are provided at both the pod & container level, the container options override the pod options. Note that this field cannot be set when spec.os.name is windows.", + Ref: ref(v1.SeccompProfile{}.OpenAPIModelName()), + }, + }, + "appArmorProfile": { + SchemaProps: spec.SchemaProps{ + Description: "appArmorProfile is the AppArmor options to use by this container. If set, this profile overrides the pod's appArmorProfile. Note that this field cannot be set when spec.os.name is windows.", + Ref: ref(v1.AppArmorProfile{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + Dependencies: []string{ + v1.AppArmorProfile{}.OpenAPIModelName(), v1.Capabilities{}.OpenAPIModelName(), v1.SELinuxOptions{}.OpenAPIModelName(), v1.SeccompProfile{}.OpenAPIModelName(), v1.WindowsSecurityContextOptions{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_SerializedReference(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "SerializedReference is a reference to serialized object.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "reference": { + SchemaProps: spec.SchemaProps{ + Description: "The reference to an object in the system.", + Default: map[string]interface{}{}, + Ref: ref(v1.ObjectReference{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + Dependencies: []string{ + v1.ObjectReference{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_Service(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "Service is a named abstraction of software service (for example, mysql) consisting of local port (for example 3306) that the proxy listens on, and the selector that determines which pods will answer requests sent through the proxy.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "metadata": { + SchemaProps: spec.SchemaProps{ + Description: "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata", + Default: map[string]interface{}{}, + Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), + }, + }, + "spec": { + SchemaProps: spec.SchemaProps{ + Description: "Spec defines the behavior of a service. https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status", + Default: map[string]interface{}{}, + Ref: ref(v1.ServiceSpec{}.OpenAPIModelName()), + }, + }, + "status": { + SchemaProps: spec.SchemaProps{ + Description: "Most recently observed status of the service. Populated by the system. Read-only. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status", + Default: map[string]interface{}{}, + Ref: ref(v1.ServiceStatus{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + Dependencies: []string{ + v1.ServiceSpec{}.OpenAPIModelName(), v1.ServiceStatus{}.OpenAPIModelName(), metav1.ObjectMeta{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_ServiceAccount(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "ServiceAccount binds together: * a name, understood by users, and perhaps by peripheral systems, for an identity * a principal that can be authenticated and authorized * a set of secrets", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "metadata": { + SchemaProps: spec.SchemaProps{ + Description: "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata", + Default: map[string]interface{}{}, + Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), + }, + }, + "secrets": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-map-keys": []interface{}{ + "name", + }, + "x-kubernetes-list-type": "map", + "x-kubernetes-patch-merge-key": "name", + "x-kubernetes-patch-strategy": "merge", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "Secrets is a list of the secrets in the same namespace that pods running using this ServiceAccount are allowed to use. Pods are only limited to this list if this service account has a \"kubernetes.io/enforce-mountable-secrets\" annotation set to \"true\". The \"kubernetes.io/enforce-mountable-secrets\" annotation is deprecated since v1.32. Prefer separate namespaces to isolate access to mounted secrets. This field should not be used to find auto-generated service account token secrets for use outside of pods. Instead, tokens can be requested directly using the TokenRequest API, or service account token secrets can be manually created. More info: https://kubernetes.io/docs/concepts/configuration/secret", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.ObjectReference{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "imagePullSecrets": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "ImagePullSecrets is a list of references to secrets in the same namespace to use for pulling any images in pods that reference this ServiceAccount. ImagePullSecrets are distinct from Secrets because Secrets can be mounted in the pod, but ImagePullSecrets are only accessed by the kubelet. More info: https://kubernetes.io/docs/concepts/containers/images/#specifying-imagepullsecrets-on-a-pod", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.LocalObjectReference{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "automountServiceAccountToken": { + SchemaProps: spec.SchemaProps{ + Description: "AutomountServiceAccountToken indicates whether pods running as this service account should have an API token automatically mounted. Can be overridden at the pod level.", + Type: []string{"boolean"}, + Format: "", + }, + }, + }, + }, + }, + Dependencies: []string{ + v1.LocalObjectReference{}.OpenAPIModelName(), v1.ObjectReference{}.OpenAPIModelName(), metav1.ObjectMeta{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_ServiceAccountList(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "ServiceAccountList is a list of ServiceAccount objects", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "metadata": { + SchemaProps: spec.SchemaProps{ + Description: "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Default: map[string]interface{}{}, + Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), + }, + }, + "items": { + SchemaProps: spec.SchemaProps{ + Description: "List of ServiceAccounts. More info: https://kubernetes.io/docs/tasks/configure-pod-container/configure-service-account/", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.ServiceAccount{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + }, + Required: []string{"items"}, + }, + }, + Dependencies: []string{ + v1.ServiceAccount{}.OpenAPIModelName(), metav1.ListMeta{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_ServiceAccountTokenProjection(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "ServiceAccountTokenProjection represents a projected service account token volume. This projection can be used to insert a service account token into the pods runtime filesystem for use against APIs (Kubernetes API Server or otherwise).", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "audience": { + SchemaProps: spec.SchemaProps{ + Description: "audience is the intended audience of the token. A recipient of a token must identify itself with an identifier specified in the audience of the token, and otherwise should reject the token. The audience defaults to the identifier of the apiserver.", + Type: []string{"string"}, + Format: "", + }, + }, + "expirationSeconds": { + SchemaProps: spec.SchemaProps{ + Description: "expirationSeconds is the requested duration of validity of the service account token. As the token approaches expiration, the kubelet volume plugin will proactively rotate the service account token. The kubelet will start trying to rotate the token if the token is older than 80 percent of its time to live or if the token is older than 24 hours.Defaults to 1 hour and must be at least 10 minutes.", + Type: []string{"integer"}, + Format: "int64", + }, + }, + "path": { + SchemaProps: spec.SchemaProps{ + Description: "path is the path relative to the mount point of the file to project the token into.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"path"}, + }, + }, + } +} + +func schema_k8sio_api_core_v1_ServiceList(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "ServiceList holds a list of services.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "metadata": { + SchemaProps: spec.SchemaProps{ + Description: "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Default: map[string]interface{}{}, + Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), + }, + }, + "items": { + SchemaProps: spec.SchemaProps{ + Description: "List of services", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.Service{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + }, + Required: []string{"items"}, + }, + }, + Dependencies: []string{ + v1.Service{}.OpenAPIModelName(), metav1.ListMeta{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_ServicePort(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "ServicePort contains information on service's port.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "name": { + SchemaProps: spec.SchemaProps{ + Description: "The name of this port within the service. This must be a DNS_LABEL. All ports within a ServiceSpec must have unique names. When considering the endpoints for a Service, this must match the 'name' field in the EndpointPort. Optional if only one ServicePort is defined on this service.", + Type: []string{"string"}, + Format: "", + }, + }, + "protocol": { + SchemaProps: spec.SchemaProps{ + Description: "The IP protocol for this port. Supports \"TCP\", \"UDP\", and \"SCTP\". Default is TCP.\n\nPossible enum values:\n - `\"SCTP\"` is the SCTP protocol.\n - `\"TCP\"` is the TCP protocol.\n - `\"UDP\"` is the UDP protocol.", + Default: "TCP", + Type: []string{"string"}, + Format: "", + Enum: []interface{}{"SCTP", "TCP", "UDP"}, + }, + }, + "appProtocol": { + SchemaProps: spec.SchemaProps{ + Description: "The application protocol for this port. This is used as a hint for implementations to offer richer behavior for protocols that they understand. This field follows standard Kubernetes label syntax. Valid values are either:\n\n* Un-prefixed protocol names - reserved for IANA standard service names (as per RFC-6335 and https://www.iana.org/assignments/service-names).\n\n* Kubernetes-defined prefixed names:\n * 'kubernetes.io/h2c' - HTTP/2 prior knowledge over cleartext as described in https://www.rfc-editor.org/rfc/rfc9113.html#name-starting-http-2-with-prior-\n * 'kubernetes.io/ws' - WebSocket over cleartext as described in https://www.rfc-editor.org/rfc/rfc6455\n * 'kubernetes.io/wss' - WebSocket over TLS as described in https://www.rfc-editor.org/rfc/rfc6455\n\n* Other protocols should use implementation-defined prefixed names such as mycompany.com/my-custom-protocol.", + Type: []string{"string"}, + Format: "", + }, + }, + "port": { + SchemaProps: spec.SchemaProps{ + Description: "The port that will be exposed by this service.", + Default: 0, + Type: []string{"integer"}, + Format: "int32", + }, + }, + "targetPort": { + SchemaProps: spec.SchemaProps{ + Description: "Number or name of the port to access on the pods targeted by the service. Number must be in the range 1 to 65535. Name must be an IANA_SVC_NAME. If this is a string, it will be looked up as a named port in the target Pod's container ports. If this is not specified, the value of the 'port' field is used (an identity map). This field is ignored for services with clusterIP=None, and should be omitted or set equal to the 'port' field. More info: https://kubernetes.io/docs/concepts/services-networking/service/#defining-a-service", + Ref: ref("k8s.io/apimachinery/pkg/util/intstr.IntOrString"), + }, + }, + "nodePort": { + SchemaProps: spec.SchemaProps{ + Description: "The port on each node on which this service is exposed when type is NodePort or LoadBalancer. Usually assigned by the system. If a value is specified, in-range, and not in use it will be used, otherwise the operation will fail. If not specified, a port will be allocated if this Service requires one. If this field is specified when creating a Service which does not need it, creation will fail. This field will be wiped when updating a Service to no longer need it (e.g. changing type from NodePort to ClusterIP). More info: https://kubernetes.io/docs/concepts/services-networking/service/#type-nodeport", + Type: []string{"integer"}, + Format: "int32", + }, + }, + }, + Required: []string{"port"}, + }, + }, + Dependencies: []string{ + "k8s.io/apimachinery/pkg/util/intstr.IntOrString"}, + } +} + +func schema_k8sio_api_core_v1_ServiceProxyOptions(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "ServiceProxyOptions is the query options to a Service's proxy call.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "path": { + SchemaProps: spec.SchemaProps{ + Description: "Path is the part of URLs that include service endpoints, suffixes, and parameters to use for the current proxy request to service. For example, the whole request URL is http://localhost/api/v1/namespaces/kube-system/services/elasticsearch-logging/_search?q=user:kimchy. Path is _search?q=user:kimchy.", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + } +} + +func schema_k8sio_api_core_v1_ServiceSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "ServiceSpec describes the attributes that a user creates on a service.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "ports": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-map-keys": []interface{}{ + "port", + "protocol", + }, + "x-kubernetes-list-type": "map", + "x-kubernetes-patch-merge-key": "port", + "x-kubernetes-patch-strategy": "merge", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "The list of ports that are exposed by this service. More info: https://kubernetes.io/docs/concepts/services-networking/service/#virtual-ips-and-service-proxies", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.ServicePort{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "selector": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-map-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "Route service traffic to pods with label keys and values matching this selector. If empty or not present, the service is assumed to have an external process managing its endpoints, which Kubernetes will not modify. Only applies to types ClusterIP, NodePort, and LoadBalancer. Ignored if type is ExternalName. More info: https://kubernetes.io/docs/concepts/services-networking/service/", + Type: []string{"object"}, + AdditionalProperties: &spec.SchemaOrBool{ + Allows: true, + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + "clusterIP": { + SchemaProps: spec.SchemaProps{ + Description: "clusterIP is the IP address of the service and is usually assigned randomly. If an address is specified manually, is in-range (as per system configuration), and is not in use, it will be allocated to the service; otherwise creation of the service will fail. This field may not be changed through updates unless the type field is also being changed to ExternalName (which requires this field to be blank) or the type field is being changed from ExternalName (in which case this field may optionally be specified, as describe above). Valid values are \"None\", empty string (\"\"), or a valid IP address. Setting this to \"None\" makes a \"headless service\" (no virtual IP), which is useful when direct endpoint connections are preferred and proxying is not required. Only applies to types ClusterIP, NodePort, and LoadBalancer. If this field is specified when creating a Service of type ExternalName, creation will fail. This field will be wiped when updating a Service to type ExternalName. More info: https://kubernetes.io/docs/concepts/services-networking/service/#virtual-ips-and-service-proxies", + Type: []string{"string"}, + Format: "", + }, + }, + "clusterIPs": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "ClusterIPs is a list of IP addresses assigned to this service, and are usually assigned randomly. If an address is specified manually, is in-range (as per system configuration), and is not in use, it will be allocated to the service; otherwise creation of the service will fail. This field may not be changed through updates unless the type field is also being changed to ExternalName (which requires this field to be empty) or the type field is being changed from ExternalName (in which case this field may optionally be specified, as describe above). Valid values are \"None\", empty string (\"\"), or a valid IP address. Setting this to \"None\" makes a \"headless service\" (no virtual IP), which is useful when direct endpoint connections are preferred and proxying is not required. Only applies to types ClusterIP, NodePort, and LoadBalancer. If this field is specified when creating a Service of type ExternalName, creation will fail. This field will be wiped when updating a Service to type ExternalName. If this field is not specified, it will be initialized from the clusterIP field. If this field is specified, clients must ensure that clusterIPs[0] and clusterIP have the same value.\n\nThis field may hold a maximum of two entries (dual-stack IPs, in either order). These IPs must correspond to the values of the ipFamilies field. Both clusterIPs and ipFamilies are governed by the ipFamilyPolicy field. More info: https://kubernetes.io/docs/concepts/services-networking/service/#virtual-ips-and-service-proxies", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + "type": { + SchemaProps: spec.SchemaProps{ + Description: "type determines how the Service is exposed. Defaults to ClusterIP. Valid options are ExternalName, ClusterIP, NodePort, and LoadBalancer. \"ClusterIP\" allocates a cluster-internal IP address for load-balancing to endpoints. Endpoints are determined by the selector or if that is not specified, by manual construction of an Endpoints object or EndpointSlice objects. If clusterIP is \"None\", no virtual IP is allocated and the endpoints are published as a set of endpoints rather than a virtual IP. \"NodePort\" builds on ClusterIP and allocates a port on every node which routes to the same endpoints as the clusterIP. \"LoadBalancer\" builds on NodePort and creates an external load-balancer (if supported in the current cloud) which routes to the same endpoints as the clusterIP. \"ExternalName\" aliases this service to the specified externalName. Several other fields do not apply to ExternalName services. More info: https://kubernetes.io/docs/concepts/services-networking/service/#publishing-services-service-types\n\nPossible enum values:\n - `\"ClusterIP\"` means a service will only be accessible inside the cluster, via the cluster IP.\n - `\"ExternalName\"` means a service consists of only a reference to an external name that kubedns or equivalent will return as a CNAME record, with no exposing or proxying of any pods involved.\n - `\"LoadBalancer\"` means a service will be exposed via an external load balancer (if the cloud provider supports it), in addition to 'NodePort' type.\n - `\"NodePort\"` means a service will be exposed on one port of every node, in addition to 'ClusterIP' type.", + Type: []string{"string"}, + Format: "", + Enum: []interface{}{"ClusterIP", "ExternalName", "LoadBalancer", "NodePort"}, + }, + }, + "externalIPs": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "externalIPs is a list of IP addresses for which nodes in the cluster will also accept traffic for this service. These IPs are not managed by Kubernetes. The user is responsible for ensuring that traffic arrives at a node with this IP. A common example is external load-balancers that are not part of the Kubernetes system.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + "sessionAffinity": { + SchemaProps: spec.SchemaProps{ + Description: "Supports \"ClientIP\" and \"None\". Used to maintain session affinity. Enable client IP based session affinity. Must be ClientIP or None. Defaults to None. More info: https://kubernetes.io/docs/concepts/services-networking/service/#virtual-ips-and-service-proxies\n\nPossible enum values:\n - `\"ClientIP\"` is the Client IP based.\n - `\"None\"` - no session affinity.", + Type: []string{"string"}, + Format: "", + Enum: []interface{}{"ClientIP", "None"}, + }, + }, + "loadBalancerIP": { + SchemaProps: spec.SchemaProps{ + Description: "Only applies to Service Type: LoadBalancer. This feature depends on whether the underlying cloud-provider supports specifying the loadBalancerIP when a load balancer is created. This field will be ignored if the cloud-provider does not support the feature. Deprecated: This field was under-specified and its meaning varies across implementations. Using it is non-portable and it may not support dual-stack. Users are encouraged to use implementation-specific annotations when available.", + Type: []string{"string"}, + Format: "", + }, + }, + "loadBalancerSourceRanges": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "If specified and supported by the platform, this will restrict traffic through the cloud-provider load-balancer will be restricted to the specified client IPs. This field will be ignored if the cloud-provider does not support the feature.\" More info: https://kubernetes.io/docs/tasks/access-application-cluster/create-external-load-balancer/", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + "externalName": { + SchemaProps: spec.SchemaProps{ + Description: "externalName is the external reference that discovery mechanisms will return as an alias for this service (e.g. a DNS CNAME record). No proxying will be involved. Must be a lowercase RFC-1123 hostname (https://tools.ietf.org/html/rfc1123) and requires `type` to be \"ExternalName\".", + Type: []string{"string"}, + Format: "", + }, + }, + "externalTrafficPolicy": { + SchemaProps: spec.SchemaProps{ + Description: "externalTrafficPolicy describes how nodes distribute service traffic they receive on one of the Service's \"externally-facing\" addresses (NodePorts, ExternalIPs, and LoadBalancer IPs). If set to \"Local\", the proxy will configure the service in a way that assumes that external load balancers will take care of balancing the service traffic between nodes, and so each node will deliver traffic only to the node-local endpoints of the service, without masquerading the client source IP. (Traffic mistakenly sent to a node with no endpoints will be dropped.) The default value, \"Cluster\", uses the standard behavior of routing to all endpoints evenly (possibly modified by topology and other features). Note that traffic sent to an External IP or LoadBalancer IP from within the cluster will always get \"Cluster\" semantics, but clients sending to a NodePort from within the cluster may need to take traffic policy into account when picking a node.\n\nPossible enum values:\n - `\"Cluster\"` routes traffic to all endpoints.\n - `\"Local\"` preserves the source IP of the traffic by routing only to endpoints on the same node as the traffic was received on (dropping the traffic if there are no local endpoints).", + Type: []string{"string"}, + Format: "", + Enum: []interface{}{"Cluster", "Local"}, + }, + }, + "healthCheckNodePort": { + SchemaProps: spec.SchemaProps{ + Description: "healthCheckNodePort specifies the healthcheck nodePort for the service. This only applies when type is set to LoadBalancer and externalTrafficPolicy is set to Local. If a value is specified, is in-range, and is not in use, it will be used. If not specified, a value will be automatically allocated. External systems (e.g. load-balancers) can use this port to determine if a given node holds endpoints for this service or not. If this field is specified when creating a Service which does not need it, creation will fail. This field will be wiped when updating a Service to no longer need it (e.g. changing type). This field cannot be updated once set.", + Type: []string{"integer"}, + Format: "int32", + }, + }, + "publishNotReadyAddresses": { + SchemaProps: spec.SchemaProps{ + Description: "publishNotReadyAddresses indicates that any agent which deals with endpoints for this Service should disregard any indications of ready/not-ready. The primary use case for setting this field is for a StatefulSet's Headless Service to propagate SRV DNS records for its Pods for the purpose of peer discovery. The Kubernetes controllers that generate Endpoints and EndpointSlice resources for Services interpret this to mean that all endpoints are considered \"ready\" even if the Pods themselves are not. Agents which consume only Kubernetes generated endpoints through the Endpoints or EndpointSlice resources can safely assume this behavior.", + Type: []string{"boolean"}, + Format: "", + }, + }, + "sessionAffinityConfig": { + SchemaProps: spec.SchemaProps{ + Description: "sessionAffinityConfig contains the configurations of session affinity.", + Ref: ref(v1.SessionAffinityConfig{}.OpenAPIModelName()), + }, + }, + "ipFamilies": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "IPFamilies is a list of IP families (e.g. IPv4, IPv6) assigned to this service. This field is usually assigned automatically based on cluster configuration and the ipFamilyPolicy field. If this field is specified manually, the requested family is available in the cluster, and ipFamilyPolicy allows it, it will be used; otherwise creation of the service will fail. This field is conditionally mutable: it allows for adding or removing a secondary IP family, but it does not allow changing the primary IP family of the Service. Valid values are \"IPv4\" and \"IPv6\". This field only applies to Services of types ClusterIP, NodePort, and LoadBalancer, and does apply to \"headless\" services. This field will be wiped when updating a Service to type ExternalName.\n\nThis field may hold a maximum of two entries (dual-stack families, in either order). These families must correspond to the values of the clusterIPs field, if specified. Both clusterIPs and ipFamilies are governed by the ipFamilyPolicy field.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + Enum: []interface{}{"", "IPv4", "IPv6"}, + }, + }, + }, + }, + }, + "ipFamilyPolicy": { + SchemaProps: spec.SchemaProps{ + Description: "IPFamilyPolicy represents the dual-stack-ness requested or required by this Service. If there is no value provided, then this field will be set to SingleStack. Services can be \"SingleStack\" (a single IP family), \"PreferDualStack\" (two IP families on dual-stack configured clusters or a single IP family on single-stack clusters), or \"RequireDualStack\" (two IP families on dual-stack configured clusters, otherwise fail). The ipFamilies and clusterIPs fields depend on the value of this field. This field will be wiped when updating a service to type ExternalName.\n\nPossible enum values:\n - `\"PreferDualStack\"` indicates that this service prefers dual-stack when the cluster is configured for dual-stack. If the cluster is not configured for dual-stack the service will be assigned a single IPFamily. If the IPFamily is not set in service.spec.ipFamilies then the service will be assigned the default IPFamily configured on the cluster\n - `\"RequireDualStack\"` indicates that this service requires dual-stack. Using IPFamilyPolicyRequireDualStack on a single stack cluster will result in validation errors. The IPFamilies (and their order) assigned to this service is based on service.spec.ipFamilies. If service.spec.ipFamilies was not provided then it will be assigned according to how they are configured on the cluster. If service.spec.ipFamilies has only one entry then the alternative IPFamily will be added by apiserver\n - `\"SingleStack\"` indicates that this service is required to have a single IPFamily. The IPFamily assigned is based on the default IPFamily used by the cluster or as identified by service.spec.ipFamilies field", + Type: []string{"string"}, + Format: "", + Enum: []interface{}{"PreferDualStack", "RequireDualStack", "SingleStack"}, + }, + }, + "allocateLoadBalancerNodePorts": { + SchemaProps: spec.SchemaProps{ + Description: "allocateLoadBalancerNodePorts defines if NodePorts will be automatically allocated for services with type LoadBalancer. Default is \"true\". It may be set to \"false\" if the cluster load-balancer does not rely on NodePorts. If the caller requests specific NodePorts (by specifying a value), those requests will be respected, regardless of this field. This field may only be set for services with type LoadBalancer and will be cleared if the type is changed to any other type.", + Type: []string{"boolean"}, + Format: "", + }, + }, + "loadBalancerClass": { + SchemaProps: spec.SchemaProps{ + Description: "loadBalancerClass is the class of the load balancer implementation this Service belongs to. If specified, the value of this field must be a label-style identifier, with an optional prefix, e.g. \"internal-vip\" or \"example.com/internal-vip\". Unprefixed names are reserved for end-users. This field can only be set when the Service type is 'LoadBalancer'. If not set, the default load balancer implementation is used, today this is typically done through the cloud provider integration, but should apply for any default implementation. If set, it is assumed that a load balancer implementation is watching for Services with a matching class. Any default load balancer implementation (e.g. cloud providers) should ignore Services that set this field. This field can only be set when creating or updating a Service to type 'LoadBalancer'. Once set, it can not be changed. This field will be wiped when a service is updated to a non 'LoadBalancer' type.", + Type: []string{"string"}, + Format: "", + }, + }, + "internalTrafficPolicy": { + SchemaProps: spec.SchemaProps{ + Description: "InternalTrafficPolicy describes how nodes distribute service traffic they receive on the ClusterIP. If set to \"Local\", the proxy will assume that pods only want to talk to endpoints of the service on the same node as the pod, dropping the traffic if there are no local endpoints. The default value, \"Cluster\", uses the standard behavior of routing to all endpoints evenly (possibly modified by topology and other features).\n\nPossible enum values:\n - `\"Cluster\"` routes traffic to all endpoints.\n - `\"Local\"` routes traffic only to endpoints on the same node as the client pod (dropping the traffic if there are no local endpoints).", + Type: []string{"string"}, + Format: "", + Enum: []interface{}{"Cluster", "Local"}, + }, + }, + "trafficDistribution": { + SchemaProps: spec.SchemaProps{ + Description: "TrafficDistribution offers a way to express preferences for how traffic is distributed to Service endpoints. Implementations can use this field as a hint, but are not required to guarantee strict adherence. If the field is not set, the implementation will apply its default routing strategy. If set to \"PreferClose\", implementations should prioritize endpoints that are in the same zone.", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + Dependencies: []string{ + v1.ServicePort{}.OpenAPIModelName(), v1.SessionAffinityConfig{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_ServiceStatus(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "ServiceStatus represents the current status of a service.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "loadBalancer": { + SchemaProps: spec.SchemaProps{ + Description: "LoadBalancer contains the current status of the load-balancer, if one is present.", + Default: map[string]interface{}{}, + Ref: ref(v1.LoadBalancerStatus{}.OpenAPIModelName()), + }, + }, + "conditions": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-map-keys": []interface{}{ + "type", + }, + "x-kubernetes-list-type": "map", + "x-kubernetes-patch-merge-key": "type", + "x-kubernetes-patch-strategy": "merge", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "Current service state", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(metav1.Condition{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + }, + }, + }, + Dependencies: []string{ + v1.LoadBalancerStatus{}.OpenAPIModelName(), metav1.Condition{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_SessionAffinityConfig(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "SessionAffinityConfig represents the configurations of session affinity.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "clientIP": { + SchemaProps: spec.SchemaProps{ + Description: "clientIP contains the configurations of Client IP based session affinity.", + Ref: ref(v1.ClientIPConfig{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + Dependencies: []string{ + v1.ClientIPConfig{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_SleepAction(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "SleepAction describes a \"sleep\" action.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "seconds": { + SchemaProps: spec.SchemaProps{ + Description: "Seconds is the number of seconds to sleep.", + Default: 0, + Type: []string{"integer"}, + Format: "int64", + }, + }, + }, + Required: []string{"seconds"}, + }, + }, + } +} + +func schema_k8sio_api_core_v1_StorageOSPersistentVolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "Represents a StorageOS persistent volume resource.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "volumeName": { + SchemaProps: spec.SchemaProps{ + Description: "volumeName is the human-readable name of the StorageOS volume. Volume names are only unique within a namespace.", + Type: []string{"string"}, + Format: "", + }, + }, + "volumeNamespace": { + SchemaProps: spec.SchemaProps{ + Description: "volumeNamespace specifies the scope of the volume within StorageOS. If no namespace is specified then the Pod's namespace will be used. This allows the Kubernetes name scoping to be mirrored within StorageOS for tighter integration. Set VolumeName to any name to override the default behaviour. Set to \"default\" if you are not using namespaces within StorageOS. Namespaces that do not pre-exist within StorageOS will be created.", + Type: []string{"string"}, + Format: "", + }, + }, + "fsType": { + SchemaProps: spec.SchemaProps{ + Description: "fsType is the filesystem type to mount. Must be a filesystem type supported by the host operating system. Ex. \"ext4\", \"xfs\", \"ntfs\". Implicitly inferred to be \"ext4\" if unspecified.", + Type: []string{"string"}, + Format: "", + }, + }, + "readOnly": { + SchemaProps: spec.SchemaProps{ + Description: "readOnly defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts.", + Type: []string{"boolean"}, + Format: "", + }, + }, + "secretRef": { + SchemaProps: spec.SchemaProps{ + Description: "secretRef specifies the secret to use for obtaining the StorageOS API credentials. If not specified, default values will be attempted.", + Ref: ref(v1.ObjectReference{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + Dependencies: []string{ + v1.ObjectReference{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_StorageOSVolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "Represents a StorageOS persistent volume resource.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "volumeName": { + SchemaProps: spec.SchemaProps{ + Description: "volumeName is the human-readable name of the StorageOS volume. Volume names are only unique within a namespace.", + Type: []string{"string"}, + Format: "", + }, + }, + "volumeNamespace": { + SchemaProps: spec.SchemaProps{ + Description: "volumeNamespace specifies the scope of the volume within StorageOS. If no namespace is specified then the Pod's namespace will be used. This allows the Kubernetes name scoping to be mirrored within StorageOS for tighter integration. Set VolumeName to any name to override the default behaviour. Set to \"default\" if you are not using namespaces within StorageOS. Namespaces that do not pre-exist within StorageOS will be created.", + Type: []string{"string"}, + Format: "", + }, + }, + "fsType": { + SchemaProps: spec.SchemaProps{ + Description: "fsType is the filesystem type to mount. Must be a filesystem type supported by the host operating system. Ex. \"ext4\", \"xfs\", \"ntfs\". Implicitly inferred to be \"ext4\" if unspecified.", + Type: []string{"string"}, + Format: "", + }, + }, + "readOnly": { + SchemaProps: spec.SchemaProps{ + Description: "readOnly defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts.", + Type: []string{"boolean"}, + Format: "", + }, + }, + "secretRef": { + SchemaProps: spec.SchemaProps{ + Description: "secretRef specifies the secret to use for obtaining the StorageOS API credentials. If not specified, default values will be attempted.", + Ref: ref(v1.LocalObjectReference{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + Dependencies: []string{ + v1.LocalObjectReference{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_Sysctl(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "Sysctl defines a kernel parameter to be set", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "name": { + SchemaProps: spec.SchemaProps{ + Description: "Name of a property to set", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "value": { + SchemaProps: spec.SchemaProps{ + Description: "Value of a property to set", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"name", "value"}, + }, + }, + } +} + +func schema_k8sio_api_core_v1_TCPSocketAction(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "TCPSocketAction describes an action based on opening a socket", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "port": { + SchemaProps: spec.SchemaProps{ + Description: "Number or name of the port to access on the container. Number must be in the range 1 to 65535. Name must be an IANA_SVC_NAME.", + Ref: ref("k8s.io/apimachinery/pkg/util/intstr.IntOrString"), + }, + }, + "host": { + SchemaProps: spec.SchemaProps{ + Description: "Optional: Host name to connect to, defaults to the pod IP.", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"port"}, + }, + }, + Dependencies: []string{ + "k8s.io/apimachinery/pkg/util/intstr.IntOrString"}, + } +} + +func schema_k8sio_api_core_v1_Taint(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "The node this Taint is attached to has the \"effect\" on any pod that does not tolerate the Taint.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "key": { + SchemaProps: spec.SchemaProps{ + Description: "Required. The taint key to be applied to a node.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "value": { + SchemaProps: spec.SchemaProps{ + Description: "The taint value corresponding to the taint key.", + Type: []string{"string"}, + Format: "", + }, + }, + "effect": { + SchemaProps: spec.SchemaProps{ + Description: "Required. The effect of the taint on pods that do not tolerate the taint. Valid effects are NoSchedule, PreferNoSchedule and NoExecute.\n\nPossible enum values:\n - `\"NoExecute\"` Evict any already-running pods that do not tolerate the taint. Currently enforced by NodeController.\n - `\"NoSchedule\"` Do not allow new pods to schedule onto the node unless they tolerate the taint, but allow all pods submitted to Kubelet without going through the scheduler to start, and allow all already-running pods to continue running. Enforced by the scheduler.\n - `\"PreferNoSchedule\"` Like TaintEffectNoSchedule, but the scheduler tries not to schedule new pods onto the node, rather than prohibiting new pods from scheduling onto the node entirely. Enforced by the scheduler.", + Default: "", + Type: []string{"string"}, + Format: "", + Enum: []interface{}{"NoExecute", "NoSchedule", "PreferNoSchedule"}, + }, + }, + "timeAdded": { + SchemaProps: spec.SchemaProps{ + Description: "TimeAdded represents the time at which the taint was added.", + Ref: ref(metav1.Time{}.OpenAPIModelName()), + }, + }, + }, + Required: []string{"key", "effect"}, + }, + }, + Dependencies: []string{ + metav1.Time{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_Toleration(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "The pod this Toleration is attached to tolerates any taint that matches the triple using the matching operator .", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "key": { + SchemaProps: spec.SchemaProps{ + Description: "Key is the taint key that the toleration applies to. Empty means match all taint keys. If the key is empty, operator must be Exists; this combination means to match all values and all keys.", + Type: []string{"string"}, + Format: "", + }, + }, + "operator": { + SchemaProps: spec.SchemaProps{ + Description: "Operator represents a key's relationship to the value. Valid operators are Exists, Equal, Lt, and Gt. Defaults to Equal. Exists is equivalent to wildcard for value, so that a pod can tolerate all taints of a particular category. Lt and Gt perform numeric comparisons (requires feature gate TaintTolerationComparisonOperators).\n\nPossible enum values:\n - `\"Equal\"`\n - `\"Exists\"`\n - `\"Gt\"`\n - `\"Lt\"`", + Type: []string{"string"}, + Format: "", + Enum: []interface{}{"Equal", "Exists", "Gt", "Lt"}, + }, + }, + "value": { + SchemaProps: spec.SchemaProps{ + Description: "Value is the taint value the toleration matches to. If the operator is Exists, the value should be empty, otherwise just a regular string.", + Type: []string{"string"}, + Format: "", + }, + }, + "effect": { + SchemaProps: spec.SchemaProps{ + Description: "Effect indicates the taint effect to match. Empty means match all taint effects. When specified, allowed values are NoSchedule, PreferNoSchedule and NoExecute.\n\nPossible enum values:\n - `\"NoExecute\"` Evict any already-running pods that do not tolerate the taint. Currently enforced by NodeController.\n - `\"NoSchedule\"` Do not allow new pods to schedule onto the node unless they tolerate the taint, but allow all pods submitted to Kubelet without going through the scheduler to start, and allow all already-running pods to continue running. Enforced by the scheduler.\n - `\"PreferNoSchedule\"` Like TaintEffectNoSchedule, but the scheduler tries not to schedule new pods onto the node, rather than prohibiting new pods from scheduling onto the node entirely. Enforced by the scheduler.", + Type: []string{"string"}, + Format: "", + Enum: []interface{}{"NoExecute", "NoSchedule", "PreferNoSchedule"}, + }, + }, + "tolerationSeconds": { + SchemaProps: spec.SchemaProps{ + Description: "TolerationSeconds represents the period of time the toleration (which must be of effect NoExecute, otherwise this field is ignored) tolerates the taint. By default, it is not set, which means tolerate the taint forever (do not evict). Zero and negative values will be treated as 0 (evict immediately) by the system.", + Type: []string{"integer"}, + Format: "int64", + }, + }, + }, + }, + }, + } +} + +func schema_k8sio_api_core_v1_TopologySelectorLabelRequirement(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "A topology selector requirement is a selector that matches given label. This is an alpha feature and may change in the future.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "key": { + SchemaProps: spec.SchemaProps{ + Description: "The label key that the selector applies to.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "values": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "An array of string values. One value must match the label to be selected. Each entry in Values is ORed.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + }, + Required: []string{"key", "values"}, + }, + }, + } +} + +func schema_k8sio_api_core_v1_TopologySelectorTerm(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "A topology selector term represents the result of label queries. A null or empty topology selector term matches no objects. The requirements of them are ANDed. It provides a subset of functionality as NodeSelectorTerm. This is an alpha feature and may change in the future.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "matchLabelExpressions": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "A list of topology selector requirements by labels.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(v1.TopologySelectorLabelRequirement{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + }, + }, + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-map-type": "atomic", + }, + }, + }, + Dependencies: []string{ + v1.TopologySelectorLabelRequirement{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_TopologySpreadConstraint(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "TopologySpreadConstraint specifies how to spread matching pods among the given topology.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "maxSkew": { + SchemaProps: spec.SchemaProps{ + Description: "MaxSkew describes the degree to which pods may be unevenly distributed. When `whenUnsatisfiable=DoNotSchedule`, it is the maximum permitted difference between the number of matching pods in the target topology and the global minimum. The global minimum is the minimum number of matching pods in an eligible domain or zero if the number of eligible domains is less than MinDomains. For example, in a 3-zone cluster, MaxSkew is set to 1, and pods with the same labelSelector spread as 2/2/1: In this case, the global minimum is 1. | zone1 | zone2 | zone3 | | P P | P P | P | - if MaxSkew is 1, incoming pod can only be scheduled to zone3 to become 2/2/2; scheduling it onto zone1(zone2) would make the ActualSkew(3-1) on zone1(zone2) violate MaxSkew(1). - if MaxSkew is 2, incoming pod can be scheduled onto any zone. When `whenUnsatisfiable=ScheduleAnyway`, it is used to give higher precedence to topologies that satisfy it. It's a required field. Default value is 1 and 0 is not allowed.", + Default: 0, + Type: []string{"integer"}, + Format: "int32", + }, + }, + "topologyKey": { + SchemaProps: spec.SchemaProps{ + Description: "TopologyKey is the key of node labels. Nodes that have a label with this key and identical values are considered to be in the same topology. We consider each as a \"bucket\", and try to put balanced number of pods into each bucket. We define a domain as a particular instance of a topology. Also, we define an eligible domain as a domain whose nodes meet the requirements of nodeAffinityPolicy and nodeTaintsPolicy. e.g. If TopologyKey is \"kubernetes.io/hostname\", each Node is a domain of that topology. And, if TopologyKey is \"topology.kubernetes.io/zone\", each zone is a domain of that topology. It's a required field.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "whenUnsatisfiable": { + SchemaProps: spec.SchemaProps{ + Description: "WhenUnsatisfiable indicates how to deal with a pod if it doesn't satisfy the spread constraint. - DoNotSchedule (default) tells the scheduler not to schedule it. - ScheduleAnyway tells the scheduler to schedule the pod in any location,\n but giving higher precedence to topologies that would help reduce the\n skew.\nA constraint is considered \"Unsatisfiable\" for an incoming pod if and only if every possible node assignment for that pod would violate \"MaxSkew\" on some topology. For example, in a 3-zone cluster, MaxSkew is set to 1, and pods with the same labelSelector spread as 3/1/1: | zone1 | zone2 | zone3 | | P P P | P | P | If WhenUnsatisfiable is set to DoNotSchedule, incoming pod can only be scheduled to zone2(zone3) to become 3/2/1(3/1/2) as ActualSkew(2-1) on zone2(zone3) satisfies MaxSkew(1). In other words, the cluster can still be imbalanced, but scheduler won't make it *more* imbalanced. It's a required field.\n\nPossible enum values:\n - `\"DoNotSchedule\"` instructs the scheduler not to schedule the pod when constraints are not satisfied.\n - `\"ScheduleAnyway\"` instructs the scheduler to schedule the pod even if constraints are not satisfied.", + Default: "", + Type: []string{"string"}, + Format: "", + Enum: []interface{}{"DoNotSchedule", "ScheduleAnyway"}, + }, + }, + "labelSelector": { + SchemaProps: spec.SchemaProps{ + Description: "LabelSelector is used to find matching pods. Pods that match this label selector are counted to determine the number of pods in their corresponding topology domain.", + Ref: ref(metav1.LabelSelector{}.OpenAPIModelName()), + }, + }, + "minDomains": { + SchemaProps: spec.SchemaProps{ + Description: "MinDomains indicates a minimum number of eligible domains. When the number of eligible domains with matching topology keys is less than minDomains, Pod Topology Spread treats \"global minimum\" as 0, and then the calculation of Skew is performed. And when the number of eligible domains with matching topology keys equals or greater than minDomains, this value has no effect on scheduling. As a result, when the number of eligible domains is less than minDomains, scheduler won't schedule more than maxSkew Pods to those domains. If value is nil, the constraint behaves as if MinDomains is equal to 1. Valid values are integers greater than 0. When value is not nil, WhenUnsatisfiable must be DoNotSchedule.\n\nFor example, in a 3-zone cluster, MaxSkew is set to 2, MinDomains is set to 5 and pods with the same labelSelector spread as 2/2/2: | zone1 | zone2 | zone3 | | P P | P P | P P | The number of domains is less than 5(MinDomains), so \"global minimum\" is treated as 0. In this situation, new pod with the same labelSelector cannot be scheduled, because computed skew will be 3(3 - 0) if new Pod is scheduled to any of the three zones, it will violate MaxSkew.", + Type: []string{"integer"}, + Format: "int32", + }, + }, + "nodeAffinityPolicy": { + SchemaProps: spec.SchemaProps{ + Description: "NodeAffinityPolicy indicates how we will treat Pod's nodeAffinity/nodeSelector when calculating pod topology spread skew. Options are: - Honor: only nodes matching nodeAffinity/nodeSelector are included in the calculations. - Ignore: nodeAffinity/nodeSelector are ignored. All nodes are included in the calculations.\n\nIf this value is nil, the behavior is equivalent to the Honor policy.\n\nPossible enum values:\n - `\"Honor\"` means use this scheduling directive when calculating pod topology spread skew.\n - `\"Ignore\"` means ignore this scheduling directive when calculating pod topology spread skew.", + Type: []string{"string"}, + Format: "", + Enum: []interface{}{"Honor", "Ignore"}, + }, + }, + "nodeTaintsPolicy": { + SchemaProps: spec.SchemaProps{ + Description: "NodeTaintsPolicy indicates how we will treat node taints when calculating pod topology spread skew. Options are: - Honor: nodes without taints, along with tainted nodes for which the incoming pod has a toleration, are included. - Ignore: node taints are ignored. All nodes are included.\n\nIf this value is nil, the behavior is equivalent to the Ignore policy.\n\nPossible enum values:\n - `\"Honor\"` means use this scheduling directive when calculating pod topology spread skew.\n - `\"Ignore\"` means ignore this scheduling directive when calculating pod topology spread skew.", + Type: []string{"string"}, + Format: "", + Enum: []interface{}{"Honor", "Ignore"}, + }, + }, + "matchLabelKeys": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "MatchLabelKeys is a set of pod label keys to select the pods over which spreading will be calculated. The keys are used to lookup values from the incoming pod labels, those key-value labels are ANDed with labelSelector to select the group of existing pods over which spreading will be calculated for the incoming pod. The same key is forbidden to exist in both MatchLabelKeys and LabelSelector. MatchLabelKeys cannot be set when LabelSelector isn't set. Keys that don't exist in the incoming pod labels will be ignored. A null or empty list means only match against labelSelector.\n\nThis is a beta field and requires the MatchLabelKeysInPodTopologySpread feature gate to be enabled (enabled by default).", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + }, + Required: []string{"maxSkew", "topologyKey", "whenUnsatisfiable"}, + }, + }, + Dependencies: []string{ + metav1.LabelSelector{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_TypedLocalObjectReference(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "TypedLocalObjectReference contains enough information to let you locate the typed referenced object inside the same namespace.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "apiGroup": { + SchemaProps: spec.SchemaProps{ + Description: "APIGroup is the group for the resource being referenced. If APIGroup is not specified, the specified Kind must be in the core API group. For any other third-party types, APIGroup is required.", + Type: []string{"string"}, + Format: "", + }, + }, + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is the type of resource being referenced", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "name": { + SchemaProps: spec.SchemaProps{ + Description: "Name is the name of resource being referenced", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"kind", "name"}, + }, + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-map-type": "atomic", + }, + }, + }, + } +} + +func schema_k8sio_api_core_v1_TypedObjectReference(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "TypedObjectReference contains enough information to let you locate the typed referenced object", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "apiGroup": { + SchemaProps: spec.SchemaProps{ + Description: "APIGroup is the group for the resource being referenced. If APIGroup is not specified, the specified Kind must be in the core API group. For any other third-party types, APIGroup is required.", + Type: []string{"string"}, + Format: "", + }, + }, + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is the type of resource being referenced", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "name": { + SchemaProps: spec.SchemaProps{ + Description: "Name is the name of resource being referenced", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "namespace": { + SchemaProps: spec.SchemaProps{ + Description: "Namespace is the namespace of resource being referenced Note that when a namespace is specified, a gateway.networking.k8s.io/ReferenceGrant object is required in the referent namespace to allow that namespace's owner to accept the reference. See the ReferenceGrant documentation for details. (Alpha) This field requires the CrossNamespaceVolumeDataSource feature gate to be enabled.", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"kind", "name"}, + }, + }, + } +} + +func schema_k8sio_api_core_v1_Volume(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "Volume represents a named volume in a pod that may be accessed by any container in the pod.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "name": { + SchemaProps: spec.SchemaProps{ + Description: "name of the volume. Must be a DNS_LABEL and unique within the pod. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "hostPath": { + SchemaProps: spec.SchemaProps{ + Description: "hostPath represents a pre-existing file or directory on the host machine that is directly exposed to the container. This is generally used for system agents or other privileged things that are allowed to see the host machine. Most containers will NOT need this. More info: https://kubernetes.io/docs/concepts/storage/volumes#hostpath", + Ref: ref(v1.HostPathVolumeSource{}.OpenAPIModelName()), + }, + }, + "emptyDir": { + SchemaProps: spec.SchemaProps{ + Description: "emptyDir represents a temporary directory that shares a pod's lifetime. More info: https://kubernetes.io/docs/concepts/storage/volumes#emptydir", + Ref: ref(v1.EmptyDirVolumeSource{}.OpenAPIModelName()), + }, + }, + "gcePersistentDisk": { + SchemaProps: spec.SchemaProps{ + Description: "gcePersistentDisk represents a GCE Disk resource that is attached to a kubelet's host machine and then exposed to the pod. Deprecated: GCEPersistentDisk is deprecated. All operations for the in-tree gcePersistentDisk type are redirected to the pd.csi.storage.gke.io CSI driver. More info: https://kubernetes.io/docs/concepts/storage/volumes#gcepersistentdisk", + Ref: ref(v1.GCEPersistentDiskVolumeSource{}.OpenAPIModelName()), + }, + }, + "awsElasticBlockStore": { + SchemaProps: spec.SchemaProps{ + Description: "awsElasticBlockStore represents an AWS Disk resource that is attached to a kubelet's host machine and then exposed to the pod. Deprecated: AWSElasticBlockStore is deprecated. All operations for the in-tree awsElasticBlockStore type are redirected to the ebs.csi.aws.com CSI driver. More info: https://kubernetes.io/docs/concepts/storage/volumes#awselasticblockstore", + Ref: ref(v1.AWSElasticBlockStoreVolumeSource{}.OpenAPIModelName()), + }, + }, + "gitRepo": { + SchemaProps: spec.SchemaProps{ + Description: "gitRepo represents a git repository at a particular revision. Deprecated: GitRepo is deprecated. To provision a container with a git repo, mount an EmptyDir into an InitContainer that clones the repo using git, then mount the EmptyDir into the Pod's container.", + Ref: ref(v1.GitRepoVolumeSource{}.OpenAPIModelName()), + }, + }, + "secret": { + SchemaProps: spec.SchemaProps{ + Description: "secret represents a secret that should populate this volume. More info: https://kubernetes.io/docs/concepts/storage/volumes#secret", + Ref: ref(v1.SecretVolumeSource{}.OpenAPIModelName()), + }, + }, + "nfs": { + SchemaProps: spec.SchemaProps{ + Description: "nfs represents an NFS mount on the host that shares a pod's lifetime More info: https://kubernetes.io/docs/concepts/storage/volumes#nfs", + Ref: ref(v1.NFSVolumeSource{}.OpenAPIModelName()), + }, + }, + "iscsi": { + SchemaProps: spec.SchemaProps{ + Description: "iscsi represents an ISCSI Disk resource that is attached to a kubelet's host machine and then exposed to the pod. More info: https://kubernetes.io/docs/concepts/storage/volumes/#iscsi", + Ref: ref(v1.ISCSIVolumeSource{}.OpenAPIModelName()), + }, + }, + "glusterfs": { + SchemaProps: spec.SchemaProps{ + Description: "glusterfs represents a Glusterfs mount on the host that shares a pod's lifetime. Deprecated: Glusterfs is deprecated and the in-tree glusterfs type is no longer supported.", + Ref: ref(v1.GlusterfsVolumeSource{}.OpenAPIModelName()), + }, + }, + "persistentVolumeClaim": { + SchemaProps: spec.SchemaProps{ + Description: "persistentVolumeClaimVolumeSource represents a reference to a PersistentVolumeClaim in the same namespace. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#persistentvolumeclaims", + Ref: ref(v1.PersistentVolumeClaimVolumeSource{}.OpenAPIModelName()), + }, + }, + "rbd": { + SchemaProps: spec.SchemaProps{ + Description: "rbd represents a Rados Block Device mount on the host that shares a pod's lifetime. Deprecated: RBD is deprecated and the in-tree rbd type is no longer supported.", + Ref: ref(v1.RBDVolumeSource{}.OpenAPIModelName()), + }, + }, + "flexVolume": { + SchemaProps: spec.SchemaProps{ + Description: "flexVolume represents a generic volume resource that is provisioned/attached using an exec based plugin. Deprecated: FlexVolume is deprecated. Consider using a CSIDriver instead.", + Ref: ref(v1.FlexVolumeSource{}.OpenAPIModelName()), + }, + }, + "cinder": { + SchemaProps: spec.SchemaProps{ + Description: "cinder represents a cinder volume attached and mounted on kubelets host machine. Deprecated: Cinder is deprecated. All operations for the in-tree cinder type are redirected to the cinder.csi.openstack.org CSI driver. More info: https://examples.k8s.io/mysql-cinder-pd/README.md", + Ref: ref(v1.CinderVolumeSource{}.OpenAPIModelName()), + }, + }, + "cephfs": { + SchemaProps: spec.SchemaProps{ + Description: "cephFS represents a Ceph FS mount on the host that shares a pod's lifetime. Deprecated: CephFS is deprecated and the in-tree cephfs type is no longer supported.", + Ref: ref(v1.CephFSVolumeSource{}.OpenAPIModelName()), + }, + }, + "flocker": { + SchemaProps: spec.SchemaProps{ + Description: "flocker represents a Flocker volume attached to a kubelet's host machine. This depends on the Flocker control service being running. Deprecated: Flocker is deprecated and the in-tree flocker type is no longer supported.", + Ref: ref(v1.FlockerVolumeSource{}.OpenAPIModelName()), + }, + }, + "downwardAPI": { + SchemaProps: spec.SchemaProps{ + Description: "downwardAPI represents downward API about the pod that should populate this volume", + Ref: ref(v1.DownwardAPIVolumeSource{}.OpenAPIModelName()), + }, + }, + "fc": { + SchemaProps: spec.SchemaProps{ + Description: "fc represents a Fibre Channel resource that is attached to a kubelet's host machine and then exposed to the pod.", + Ref: ref(v1.FCVolumeSource{}.OpenAPIModelName()), + }, + }, + "azureFile": { + SchemaProps: spec.SchemaProps{ + Description: "azureFile represents an Azure File Service mount on the host and bind mount to the pod. Deprecated: AzureFile is deprecated. All operations for the in-tree azureFile type are redirected to the file.csi.azure.com CSI driver.", + Ref: ref(v1.AzureFileVolumeSource{}.OpenAPIModelName()), + }, + }, + "configMap": { + SchemaProps: spec.SchemaProps{ + Description: "configMap represents a configMap that should populate this volume", + Ref: ref(v1.ConfigMapVolumeSource{}.OpenAPIModelName()), + }, + }, + "vsphereVolume": { + SchemaProps: spec.SchemaProps{ + Description: "vsphereVolume represents a vSphere volume attached and mounted on kubelets host machine. Deprecated: VsphereVolume is deprecated. All operations for the in-tree vsphereVolume type are redirected to the csi.vsphere.vmware.com CSI driver.", + Ref: ref(v1.VsphereVirtualDiskVolumeSource{}.OpenAPIModelName()), + }, + }, + "quobyte": { + SchemaProps: spec.SchemaProps{ + Description: "quobyte represents a Quobyte mount on the host that shares a pod's lifetime. Deprecated: Quobyte is deprecated and the in-tree quobyte type is no longer supported.", + Ref: ref(v1.QuobyteVolumeSource{}.OpenAPIModelName()), + }, + }, + "azureDisk": { + SchemaProps: spec.SchemaProps{ + Description: "azureDisk represents an Azure Data Disk mount on the host and bind mount to the pod. Deprecated: AzureDisk is deprecated. All operations for the in-tree azureDisk type are redirected to the disk.csi.azure.com CSI driver.", + Ref: ref(v1.AzureDiskVolumeSource{}.OpenAPIModelName()), + }, + }, + "photonPersistentDisk": { + SchemaProps: spec.SchemaProps{ + Description: "photonPersistentDisk represents a PhotonController persistent disk attached and mounted on kubelets host machine. Deprecated: PhotonPersistentDisk is deprecated and the in-tree photonPersistentDisk type is no longer supported.", + Ref: ref(v1.PhotonPersistentDiskVolumeSource{}.OpenAPIModelName()), + }, + }, + "projected": { + SchemaProps: spec.SchemaProps{ + Description: "projected items for all in one resources secrets, configmaps, and downward API", + Ref: ref(v1.ProjectedVolumeSource{}.OpenAPIModelName()), + }, + }, + "portworxVolume": { + SchemaProps: spec.SchemaProps{ + Description: "portworxVolume represents a portworx volume attached and mounted on kubelets host machine. Deprecated: PortworxVolume is deprecated. All operations for the in-tree portworxVolume type are redirected to the pxd.portworx.com CSI driver when the CSIMigrationPortworx feature-gate is on.", + Ref: ref(v1.PortworxVolumeSource{}.OpenAPIModelName()), + }, + }, + "scaleIO": { + SchemaProps: spec.SchemaProps{ + Description: "scaleIO represents a ScaleIO persistent volume attached and mounted on Kubernetes nodes. Deprecated: ScaleIO is deprecated and the in-tree scaleIO type is no longer supported.", + Ref: ref(v1.ScaleIOVolumeSource{}.OpenAPIModelName()), + }, + }, + "storageos": { + SchemaProps: spec.SchemaProps{ + Description: "storageOS represents a StorageOS volume attached and mounted on Kubernetes nodes. Deprecated: StorageOS is deprecated and the in-tree storageos type is no longer supported.", + Ref: ref(v1.StorageOSVolumeSource{}.OpenAPIModelName()), + }, + }, + "csi": { + SchemaProps: spec.SchemaProps{ + Description: "csi (Container Storage Interface) represents ephemeral storage that is handled by certain external CSI drivers.", + Ref: ref(v1.CSIVolumeSource{}.OpenAPIModelName()), + }, + }, + "ephemeral": { + SchemaProps: spec.SchemaProps{ + Description: "ephemeral represents a volume that is handled by a cluster storage driver. The volume's lifecycle is tied to the pod that defines it - it will be created before the pod starts, and deleted when the pod is removed.\n\nUse this if: a) the volume is only needed while the pod runs, b) features of normal volumes like restoring from snapshot or capacity\n tracking are needed,\nc) the storage driver is specified through a storage class, and d) the storage driver supports dynamic volume provisioning through\n a PersistentVolumeClaim (see EphemeralVolumeSource for more\n information on the connection between this volume type\n and PersistentVolumeClaim).\n\nUse PersistentVolumeClaim or one of the vendor-specific APIs for volumes that persist for longer than the lifecycle of an individual pod.\n\nUse CSI for light-weight local ephemeral volumes if the CSI driver is meant to be used that way - see the documentation of the driver for more information.\n\nA pod can use both types of ephemeral volumes and persistent volumes at the same time.", + Ref: ref(v1.EphemeralVolumeSource{}.OpenAPIModelName()), + }, + }, + "image": { + SchemaProps: spec.SchemaProps{ + Description: "image represents an OCI object (a container image or artifact) pulled and mounted on the kubelet's host machine. The volume is resolved at pod startup depending on which PullPolicy value is provided:\n\n- Always: the kubelet always attempts to pull the reference. Container creation will fail If the pull fails. - Never: the kubelet never pulls the reference and only uses a local image or artifact. Container creation will fail if the reference isn't present. - IfNotPresent: the kubelet pulls if the reference isn't already present on disk. Container creation will fail if the reference isn't present and the pull fails.\n\nThe volume gets re-resolved if the pod gets deleted and recreated, which means that new remote content will become available on pod recreation. A failure to resolve or pull the image during pod startup will block containers from starting and may add significant latency. Failures will be retried using normal volume backoff and will be reported on the pod reason and message. The types of objects that may be mounted by this volume are defined by the container runtime implementation on a host machine and at minimum must include all valid types supported by the container image field. The OCI object gets mounted in a single directory (spec.containers[*].volumeMounts.mountPath) by merging the manifest layers in the same way as for container images. The volume will be mounted read-only (ro) and non-executable files (noexec). Sub path mounts for containers are not supported (spec.containers[*].volumeMounts.subpath) before 1.33. The field spec.securityContext.fsGroupChangePolicy has no effect on this volume type.", + Ref: ref(v1.ImageVolumeSource{}.OpenAPIModelName()), + }, + }, + }, + Required: []string{"name"}, + }, + }, + Dependencies: []string{ + v1.AWSElasticBlockStoreVolumeSource{}.OpenAPIModelName(), v1.AzureDiskVolumeSource{}.OpenAPIModelName(), v1.AzureFileVolumeSource{}.OpenAPIModelName(), v1.CSIVolumeSource{}.OpenAPIModelName(), v1.CephFSVolumeSource{}.OpenAPIModelName(), v1.CinderVolumeSource{}.OpenAPIModelName(), v1.ConfigMapVolumeSource{}.OpenAPIModelName(), v1.DownwardAPIVolumeSource{}.OpenAPIModelName(), v1.EmptyDirVolumeSource{}.OpenAPIModelName(), v1.EphemeralVolumeSource{}.OpenAPIModelName(), v1.FCVolumeSource{}.OpenAPIModelName(), v1.FlexVolumeSource{}.OpenAPIModelName(), v1.FlockerVolumeSource{}.OpenAPIModelName(), v1.GCEPersistentDiskVolumeSource{}.OpenAPIModelName(), v1.GitRepoVolumeSource{}.OpenAPIModelName(), v1.GlusterfsVolumeSource{}.OpenAPIModelName(), v1.HostPathVolumeSource{}.OpenAPIModelName(), v1.ISCSIVolumeSource{}.OpenAPIModelName(), v1.ImageVolumeSource{}.OpenAPIModelName(), v1.NFSVolumeSource{}.OpenAPIModelName(), v1.PersistentVolumeClaimVolumeSource{}.OpenAPIModelName(), v1.PhotonPersistentDiskVolumeSource{}.OpenAPIModelName(), v1.PortworxVolumeSource{}.OpenAPIModelName(), v1.ProjectedVolumeSource{}.OpenAPIModelName(), v1.QuobyteVolumeSource{}.OpenAPIModelName(), v1.RBDVolumeSource{}.OpenAPIModelName(), v1.ScaleIOVolumeSource{}.OpenAPIModelName(), v1.SecretVolumeSource{}.OpenAPIModelName(), v1.StorageOSVolumeSource{}.OpenAPIModelName(), v1.VsphereVirtualDiskVolumeSource{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_VolumeDevice(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "volumeDevice describes a mapping of a raw block device within a container.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "name": { + SchemaProps: spec.SchemaProps{ + Description: "name must match the name of a persistentVolumeClaim in the pod", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "devicePath": { + SchemaProps: spec.SchemaProps{ + Description: "devicePath is the path inside of the container that the device will be mapped to.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"name", "devicePath"}, + }, + }, + } +} + +func schema_k8sio_api_core_v1_VolumeMount(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "VolumeMount describes a mounting of a Volume within a container.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "name": { + SchemaProps: spec.SchemaProps{ + Description: "This must match the Name of a Volume.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "readOnly": { + SchemaProps: spec.SchemaProps{ + Description: "Mounted read-only if true, read-write otherwise (false or unspecified). Defaults to false.", + Type: []string{"boolean"}, + Format: "", + }, + }, + "recursiveReadOnly": { + SchemaProps: spec.SchemaProps{ + Description: "RecursiveReadOnly specifies whether read-only mounts should be handled recursively.\n\nIf ReadOnly is false, this field has no meaning and must be unspecified.\n\nIf ReadOnly is true, and this field is set to Disabled, the mount is not made recursively read-only. If this field is set to IfPossible, the mount is made recursively read-only, if it is supported by the container runtime. If this field is set to Enabled, the mount is made recursively read-only if it is supported by the container runtime, otherwise the pod will not be started and an error will be generated to indicate the reason.\n\nIf this field is set to IfPossible or Enabled, MountPropagation must be set to None (or be unspecified, which defaults to None).\n\nIf this field is not specified, it is treated as an equivalent of Disabled.", + Type: []string{"string"}, + Format: "", + }, + }, + "mountPath": { + SchemaProps: spec.SchemaProps{ + Description: "Path within the container at which the volume should be mounted. Must not contain ':'.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "subPath": { + SchemaProps: spec.SchemaProps{ + Description: "Path within the volume from which the container's volume should be mounted. Defaults to \"\" (volume's root).", + Type: []string{"string"}, + Format: "", + }, + }, + "mountPropagation": { + SchemaProps: spec.SchemaProps{ + Description: "mountPropagation determines how mounts are propagated from the host to container and the other way around. When not set, MountPropagationNone is used. This field is beta in 1.10. When RecursiveReadOnly is set to IfPossible or to Enabled, MountPropagation must be None or unspecified (which defaults to None).\n\nPossible enum values:\n - `\"Bidirectional\"` means that the volume in a container will receive new mounts from the host or other containers, and its own mounts will be propagated from the container to the host or other containers. Note that this mode is recursively applied to all mounts in the volume (\"rshared\" in Linux terminology).\n - `\"HostToContainer\"` means that the volume in a container will receive new mounts from the host or other containers, but filesystems mounted inside the container won't be propagated to the host or other containers. Note that this mode is recursively applied to all mounts in the volume (\"rslave\" in Linux terminology).\n - `\"None\"` means that the volume in a container will not receive new mounts from the host or other containers, and filesystems mounted inside the container won't be propagated to the host or other containers. Note that this mode corresponds to \"private\" in Linux terminology.", + Type: []string{"string"}, + Format: "", + Enum: []interface{}{"Bidirectional", "HostToContainer", "None"}, + }, + }, + "subPathExpr": { + SchemaProps: spec.SchemaProps{ + Description: "Expanded path within the volume from which the container's volume should be mounted. Behaves similarly to SubPath but environment variable references $(VAR_NAME) are expanded using the container's environment. Defaults to \"\" (volume's root). SubPathExpr and SubPath are mutually exclusive.", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"name", "mountPath"}, + }, + }, + } +} + +func schema_k8sio_api_core_v1_VolumeMountStatus(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "VolumeMountStatus shows status of volume mounts.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "name": { + SchemaProps: spec.SchemaProps{ + Description: "Name corresponds to the name of the original VolumeMount.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "mountPath": { + SchemaProps: spec.SchemaProps{ + Description: "MountPath corresponds to the original VolumeMount.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "readOnly": { + SchemaProps: spec.SchemaProps{ + Description: "ReadOnly corresponds to the original VolumeMount.", + Type: []string{"boolean"}, + Format: "", + }, + }, + "recursiveReadOnly": { + SchemaProps: spec.SchemaProps{ + Description: "RecursiveReadOnly must be set to Disabled, Enabled, or unspecified (for non-readonly mounts). An IfPossible value in the original VolumeMount must be translated to Disabled or Enabled, depending on the mount result.", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"name", "mountPath"}, + }, + }, + } +} + +func schema_k8sio_api_core_v1_VolumeNodeAffinity(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "VolumeNodeAffinity defines constraints that limit what nodes this volume can be accessed from.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "required": { + SchemaProps: spec.SchemaProps{ + Description: "required specifies hard node constraints that must be met.", + Ref: ref(v1.NodeSelector{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + Dependencies: []string{ + v1.NodeSelector{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_VolumeProjection(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "Projection that may be projected along with other supported volume types. Exactly one of these fields must be set.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "secret": { + SchemaProps: spec.SchemaProps{ + Description: "secret information about the secret data to project", + Ref: ref(v1.SecretProjection{}.OpenAPIModelName()), + }, + }, + "downwardAPI": { + SchemaProps: spec.SchemaProps{ + Description: "downwardAPI information about the downwardAPI data to project", + Ref: ref(v1.DownwardAPIProjection{}.OpenAPIModelName()), + }, + }, + "configMap": { + SchemaProps: spec.SchemaProps{ + Description: "configMap information about the configMap data to project", + Ref: ref(v1.ConfigMapProjection{}.OpenAPIModelName()), + }, + }, + "serviceAccountToken": { + SchemaProps: spec.SchemaProps{ + Description: "serviceAccountToken is information about the serviceAccountToken data to project", + Ref: ref(v1.ServiceAccountTokenProjection{}.OpenAPIModelName()), + }, + }, + "clusterTrustBundle": { + SchemaProps: spec.SchemaProps{ + Description: "ClusterTrustBundle allows a pod to access the `.spec.trustBundle` field of ClusterTrustBundle objects in an auto-updating file.\n\nAlpha, gated by the ClusterTrustBundleProjection feature gate.\n\nClusterTrustBundle objects can either be selected by name, or by the combination of signer name and a label selector.\n\nKubelet performs aggressive normalization of the PEM contents written into the pod filesystem. Esoteric PEM features such as inter-block comments and block headers are stripped. Certificates are deduplicated. The ordering of certificates within the file is arbitrary, and Kubelet may change the order over time.", + Ref: ref(v1.ClusterTrustBundleProjection{}.OpenAPIModelName()), + }, + }, + "podCertificate": { + SchemaProps: spec.SchemaProps{ + Description: "Projects an auto-rotating credential bundle (private key and certificate chain) that the pod can use either as a TLS client or server.\n\nKubelet generates a private key and uses it to send a PodCertificateRequest to the named signer. Once the signer approves the request and issues a certificate chain, Kubelet writes the key and certificate chain to the pod filesystem. The pod does not start until certificates have been issued for each podCertificate projected volume source in its spec.\n\nKubelet will begin trying to rotate the certificate at the time indicated by the signer using the PodCertificateRequest.Status.BeginRefreshAt timestamp.\n\nKubelet can write a single file, indicated by the credentialBundlePath field, or separate files, indicated by the keyPath and certificateChainPath fields.\n\nThe credential bundle is a single file in PEM format. The first PEM entry is the private key (in PKCS#8 format), and the remaining PEM entries are the certificate chain issued by the signer (typically, signers will return their certificate chain in leaf-to-root order).\n\nPrefer using the credential bundle format, since your application code can read it atomically. If you use keyPath and certificateChainPath, your application must make two separate file reads. If these coincide with a certificate rotation, it is possible that the private key and leaf certificate you read may not correspond to each other. Your application will need to check for this condition, and re-read until they are consistent.\n\nThe named signer controls chooses the format of the certificate it issues; consult the signer implementation's documentation to learn how to use the certificates it issues.", + Ref: ref(v1.PodCertificateProjection{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + Dependencies: []string{ + v1.ClusterTrustBundleProjection{}.OpenAPIModelName(), v1.ConfigMapProjection{}.OpenAPIModelName(), v1.DownwardAPIProjection{}.OpenAPIModelName(), v1.PodCertificateProjection{}.OpenAPIModelName(), v1.SecretProjection{}.OpenAPIModelName(), v1.ServiceAccountTokenProjection{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_VolumeResourceRequirements(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "VolumeResourceRequirements describes the storage resource requirements for a volume.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "limits": { + SchemaProps: spec.SchemaProps{ + Description: "Limits describes the maximum amount of compute resources allowed. More info: https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/", + Type: []string{"object"}, + AdditionalProperties: &spec.SchemaOrBool{ + Allows: true, + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Ref: ref(resource.Quantity{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "requests": { + SchemaProps: spec.SchemaProps{ + Description: "Requests describes the minimum amount of compute resources required. If Requests is omitted for a container, it defaults to Limits if that is explicitly specified, otherwise to an implementation-defined value. Requests cannot exceed Limits. More info: https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/", + Type: []string{"object"}, + AdditionalProperties: &spec.SchemaOrBool{ + Allows: true, + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Ref: ref(resource.Quantity{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + }, + }, + }, + Dependencies: []string{ + resource.Quantity{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_VolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "Represents the source of a volume to mount. Only one of its members may be specified.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "hostPath": { + SchemaProps: spec.SchemaProps{ + Description: "hostPath represents a pre-existing file or directory on the host machine that is directly exposed to the container. This is generally used for system agents or other privileged things that are allowed to see the host machine. Most containers will NOT need this. More info: https://kubernetes.io/docs/concepts/storage/volumes#hostpath", + Ref: ref(v1.HostPathVolumeSource{}.OpenAPIModelName()), + }, + }, + "emptyDir": { + SchemaProps: spec.SchemaProps{ + Description: "emptyDir represents a temporary directory that shares a pod's lifetime. More info: https://kubernetes.io/docs/concepts/storage/volumes#emptydir", + Ref: ref(v1.EmptyDirVolumeSource{}.OpenAPIModelName()), + }, + }, + "gcePersistentDisk": { + SchemaProps: spec.SchemaProps{ + Description: "gcePersistentDisk represents a GCE Disk resource that is attached to a kubelet's host machine and then exposed to the pod. Deprecated: GCEPersistentDisk is deprecated. All operations for the in-tree gcePersistentDisk type are redirected to the pd.csi.storage.gke.io CSI driver. More info: https://kubernetes.io/docs/concepts/storage/volumes#gcepersistentdisk", + Ref: ref(v1.GCEPersistentDiskVolumeSource{}.OpenAPIModelName()), + }, + }, + "awsElasticBlockStore": { + SchemaProps: spec.SchemaProps{ + Description: "awsElasticBlockStore represents an AWS Disk resource that is attached to a kubelet's host machine and then exposed to the pod. Deprecated: AWSElasticBlockStore is deprecated. All operations for the in-tree awsElasticBlockStore type are redirected to the ebs.csi.aws.com CSI driver. More info: https://kubernetes.io/docs/concepts/storage/volumes#awselasticblockstore", + Ref: ref(v1.AWSElasticBlockStoreVolumeSource{}.OpenAPIModelName()), + }, + }, + "gitRepo": { + SchemaProps: spec.SchemaProps{ + Description: "gitRepo represents a git repository at a particular revision. Deprecated: GitRepo is deprecated. To provision a container with a git repo, mount an EmptyDir into an InitContainer that clones the repo using git, then mount the EmptyDir into the Pod's container.", + Ref: ref(v1.GitRepoVolumeSource{}.OpenAPIModelName()), + }, + }, + "secret": { + SchemaProps: spec.SchemaProps{ + Description: "secret represents a secret that should populate this volume. More info: https://kubernetes.io/docs/concepts/storage/volumes#secret", + Ref: ref(v1.SecretVolumeSource{}.OpenAPIModelName()), + }, + }, + "nfs": { + SchemaProps: spec.SchemaProps{ + Description: "nfs represents an NFS mount on the host that shares a pod's lifetime More info: https://kubernetes.io/docs/concepts/storage/volumes#nfs", + Ref: ref(v1.NFSVolumeSource{}.OpenAPIModelName()), + }, + }, + "iscsi": { + SchemaProps: spec.SchemaProps{ + Description: "iscsi represents an ISCSI Disk resource that is attached to a kubelet's host machine and then exposed to the pod. More info: https://kubernetes.io/docs/concepts/storage/volumes/#iscsi", + Ref: ref(v1.ISCSIVolumeSource{}.OpenAPIModelName()), + }, + }, + "glusterfs": { + SchemaProps: spec.SchemaProps{ + Description: "glusterfs represents a Glusterfs mount on the host that shares a pod's lifetime. Deprecated: Glusterfs is deprecated and the in-tree glusterfs type is no longer supported.", + Ref: ref(v1.GlusterfsVolumeSource{}.OpenAPIModelName()), + }, + }, + "persistentVolumeClaim": { + SchemaProps: spec.SchemaProps{ + Description: "persistentVolumeClaimVolumeSource represents a reference to a PersistentVolumeClaim in the same namespace. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#persistentvolumeclaims", + Ref: ref(v1.PersistentVolumeClaimVolumeSource{}.OpenAPIModelName()), + }, + }, + "rbd": { + SchemaProps: spec.SchemaProps{ + Description: "rbd represents a Rados Block Device mount on the host that shares a pod's lifetime. Deprecated: RBD is deprecated and the in-tree rbd type is no longer supported.", + Ref: ref(v1.RBDVolumeSource{}.OpenAPIModelName()), + }, + }, + "flexVolume": { + SchemaProps: spec.SchemaProps{ + Description: "flexVolume represents a generic volume resource that is provisioned/attached using an exec based plugin. Deprecated: FlexVolume is deprecated. Consider using a CSIDriver instead.", + Ref: ref(v1.FlexVolumeSource{}.OpenAPIModelName()), + }, + }, + "cinder": { + SchemaProps: spec.SchemaProps{ + Description: "cinder represents a cinder volume attached and mounted on kubelets host machine. Deprecated: Cinder is deprecated. All operations for the in-tree cinder type are redirected to the cinder.csi.openstack.org CSI driver. More info: https://examples.k8s.io/mysql-cinder-pd/README.md", + Ref: ref(v1.CinderVolumeSource{}.OpenAPIModelName()), + }, + }, + "cephfs": { + SchemaProps: spec.SchemaProps{ + Description: "cephFS represents a Ceph FS mount on the host that shares a pod's lifetime. Deprecated: CephFS is deprecated and the in-tree cephfs type is no longer supported.", + Ref: ref(v1.CephFSVolumeSource{}.OpenAPIModelName()), + }, + }, + "flocker": { + SchemaProps: spec.SchemaProps{ + Description: "flocker represents a Flocker volume attached to a kubelet's host machine. This depends on the Flocker control service being running. Deprecated: Flocker is deprecated and the in-tree flocker type is no longer supported.", + Ref: ref(v1.FlockerVolumeSource{}.OpenAPIModelName()), + }, + }, + "downwardAPI": { + SchemaProps: spec.SchemaProps{ + Description: "downwardAPI represents downward API about the pod that should populate this volume", + Ref: ref(v1.DownwardAPIVolumeSource{}.OpenAPIModelName()), + }, + }, + "fc": { + SchemaProps: spec.SchemaProps{ + Description: "fc represents a Fibre Channel resource that is attached to a kubelet's host machine and then exposed to the pod.", + Ref: ref(v1.FCVolumeSource{}.OpenAPIModelName()), + }, + }, + "azureFile": { + SchemaProps: spec.SchemaProps{ + Description: "azureFile represents an Azure File Service mount on the host and bind mount to the pod. Deprecated: AzureFile is deprecated. All operations for the in-tree azureFile type are redirected to the file.csi.azure.com CSI driver.", + Ref: ref(v1.AzureFileVolumeSource{}.OpenAPIModelName()), + }, + }, + "configMap": { + SchemaProps: spec.SchemaProps{ + Description: "configMap represents a configMap that should populate this volume", + Ref: ref(v1.ConfigMapVolumeSource{}.OpenAPIModelName()), + }, + }, + "vsphereVolume": { + SchemaProps: spec.SchemaProps{ + Description: "vsphereVolume represents a vSphere volume attached and mounted on kubelets host machine. Deprecated: VsphereVolume is deprecated. All operations for the in-tree vsphereVolume type are redirected to the csi.vsphere.vmware.com CSI driver.", + Ref: ref(v1.VsphereVirtualDiskVolumeSource{}.OpenAPIModelName()), + }, + }, + "quobyte": { + SchemaProps: spec.SchemaProps{ + Description: "quobyte represents a Quobyte mount on the host that shares a pod's lifetime. Deprecated: Quobyte is deprecated and the in-tree quobyte type is no longer supported.", + Ref: ref(v1.QuobyteVolumeSource{}.OpenAPIModelName()), + }, + }, + "azureDisk": { + SchemaProps: spec.SchemaProps{ + Description: "azureDisk represents an Azure Data Disk mount on the host and bind mount to the pod. Deprecated: AzureDisk is deprecated. All operations for the in-tree azureDisk type are redirected to the disk.csi.azure.com CSI driver.", + Ref: ref(v1.AzureDiskVolumeSource{}.OpenAPIModelName()), + }, + }, + "photonPersistentDisk": { + SchemaProps: spec.SchemaProps{ + Description: "photonPersistentDisk represents a PhotonController persistent disk attached and mounted on kubelets host machine. Deprecated: PhotonPersistentDisk is deprecated and the in-tree photonPersistentDisk type is no longer supported.", + Ref: ref(v1.PhotonPersistentDiskVolumeSource{}.OpenAPIModelName()), + }, + }, + "projected": { + SchemaProps: spec.SchemaProps{ + Description: "projected items for all in one resources secrets, configmaps, and downward API", + Ref: ref(v1.ProjectedVolumeSource{}.OpenAPIModelName()), + }, + }, + "portworxVolume": { + SchemaProps: spec.SchemaProps{ + Description: "portworxVolume represents a portworx volume attached and mounted on kubelets host machine. Deprecated: PortworxVolume is deprecated. All operations for the in-tree portworxVolume type are redirected to the pxd.portworx.com CSI driver when the CSIMigrationPortworx feature-gate is on.", + Ref: ref(v1.PortworxVolumeSource{}.OpenAPIModelName()), + }, + }, + "scaleIO": { + SchemaProps: spec.SchemaProps{ + Description: "scaleIO represents a ScaleIO persistent volume attached and mounted on Kubernetes nodes. Deprecated: ScaleIO is deprecated and the in-tree scaleIO type is no longer supported.", + Ref: ref(v1.ScaleIOVolumeSource{}.OpenAPIModelName()), + }, + }, + "storageos": { + SchemaProps: spec.SchemaProps{ + Description: "storageOS represents a StorageOS volume attached and mounted on Kubernetes nodes. Deprecated: StorageOS is deprecated and the in-tree storageos type is no longer supported.", + Ref: ref(v1.StorageOSVolumeSource{}.OpenAPIModelName()), + }, + }, + "csi": { + SchemaProps: spec.SchemaProps{ + Description: "csi (Container Storage Interface) represents ephemeral storage that is handled by certain external CSI drivers.", + Ref: ref(v1.CSIVolumeSource{}.OpenAPIModelName()), + }, + }, + "ephemeral": { + SchemaProps: spec.SchemaProps{ + Description: "ephemeral represents a volume that is handled by a cluster storage driver. The volume's lifecycle is tied to the pod that defines it - it will be created before the pod starts, and deleted when the pod is removed.\n\nUse this if: a) the volume is only needed while the pod runs, b) features of normal volumes like restoring from snapshot or capacity\n tracking are needed,\nc) the storage driver is specified through a storage class, and d) the storage driver supports dynamic volume provisioning through\n a PersistentVolumeClaim (see EphemeralVolumeSource for more\n information on the connection between this volume type\n and PersistentVolumeClaim).\n\nUse PersistentVolumeClaim or one of the vendor-specific APIs for volumes that persist for longer than the lifecycle of an individual pod.\n\nUse CSI for light-weight local ephemeral volumes if the CSI driver is meant to be used that way - see the documentation of the driver for more information.\n\nA pod can use both types of ephemeral volumes and persistent volumes at the same time.", + Ref: ref(v1.EphemeralVolumeSource{}.OpenAPIModelName()), + }, + }, + "image": { + SchemaProps: spec.SchemaProps{ + Description: "image represents an OCI object (a container image or artifact) pulled and mounted on the kubelet's host machine. The volume is resolved at pod startup depending on which PullPolicy value is provided:\n\n- Always: the kubelet always attempts to pull the reference. Container creation will fail If the pull fails. - Never: the kubelet never pulls the reference and only uses a local image or artifact. Container creation will fail if the reference isn't present. - IfNotPresent: the kubelet pulls if the reference isn't already present on disk. Container creation will fail if the reference isn't present and the pull fails.\n\nThe volume gets re-resolved if the pod gets deleted and recreated, which means that new remote content will become available on pod recreation. A failure to resolve or pull the image during pod startup will block containers from starting and may add significant latency. Failures will be retried using normal volume backoff and will be reported on the pod reason and message. The types of objects that may be mounted by this volume are defined by the container runtime implementation on a host machine and at minimum must include all valid types supported by the container image field. The OCI object gets mounted in a single directory (spec.containers[*].volumeMounts.mountPath) by merging the manifest layers in the same way as for container images. The volume will be mounted read-only (ro) and non-executable files (noexec). Sub path mounts for containers are not supported (spec.containers[*].volumeMounts.subpath) before 1.33. The field spec.securityContext.fsGroupChangePolicy has no effect on this volume type.", + Ref: ref(v1.ImageVolumeSource{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + Dependencies: []string{ + v1.AWSElasticBlockStoreVolumeSource{}.OpenAPIModelName(), v1.AzureDiskVolumeSource{}.OpenAPIModelName(), v1.AzureFileVolumeSource{}.OpenAPIModelName(), v1.CSIVolumeSource{}.OpenAPIModelName(), v1.CephFSVolumeSource{}.OpenAPIModelName(), v1.CinderVolumeSource{}.OpenAPIModelName(), v1.ConfigMapVolumeSource{}.OpenAPIModelName(), v1.DownwardAPIVolumeSource{}.OpenAPIModelName(), v1.EmptyDirVolumeSource{}.OpenAPIModelName(), v1.EphemeralVolumeSource{}.OpenAPIModelName(), v1.FCVolumeSource{}.OpenAPIModelName(), v1.FlexVolumeSource{}.OpenAPIModelName(), v1.FlockerVolumeSource{}.OpenAPIModelName(), v1.GCEPersistentDiskVolumeSource{}.OpenAPIModelName(), v1.GitRepoVolumeSource{}.OpenAPIModelName(), v1.GlusterfsVolumeSource{}.OpenAPIModelName(), v1.HostPathVolumeSource{}.OpenAPIModelName(), v1.ISCSIVolumeSource{}.OpenAPIModelName(), v1.ImageVolumeSource{}.OpenAPIModelName(), v1.NFSVolumeSource{}.OpenAPIModelName(), v1.PersistentVolumeClaimVolumeSource{}.OpenAPIModelName(), v1.PhotonPersistentDiskVolumeSource{}.OpenAPIModelName(), v1.PortworxVolumeSource{}.OpenAPIModelName(), v1.ProjectedVolumeSource{}.OpenAPIModelName(), v1.QuobyteVolumeSource{}.OpenAPIModelName(), v1.RBDVolumeSource{}.OpenAPIModelName(), v1.ScaleIOVolumeSource{}.OpenAPIModelName(), v1.SecretVolumeSource{}.OpenAPIModelName(), v1.StorageOSVolumeSource{}.OpenAPIModelName(), v1.VsphereVirtualDiskVolumeSource{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_VsphereVirtualDiskVolumeSource(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "Represents a vSphere volume resource.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "volumePath": { + SchemaProps: spec.SchemaProps{ + Description: "volumePath is the path that identifies vSphere volume vmdk", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "fsType": { + SchemaProps: spec.SchemaProps{ + Description: "fsType is filesystem type to mount. Must be a filesystem type supported by the host operating system. Ex. \"ext4\", \"xfs\", \"ntfs\". Implicitly inferred to be \"ext4\" if unspecified.", + Type: []string{"string"}, + Format: "", + }, + }, + "storagePolicyName": { + SchemaProps: spec.SchemaProps{ + Description: "storagePolicyName is the storage Policy Based Management (SPBM) profile name.", + Type: []string{"string"}, + Format: "", + }, + }, + "storagePolicyID": { + SchemaProps: spec.SchemaProps{ + Description: "storagePolicyID is the storage Policy Based Management (SPBM) profile ID associated with the StoragePolicyName.", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"volumePath"}, + }, + }, + } +} + +func schema_k8sio_api_core_v1_WeightedPodAffinityTerm(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "The weights of all of the matched WeightedPodAffinityTerm fields are added per-node to find the most preferred node(s)", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "weight": { + SchemaProps: spec.SchemaProps{ + Description: "weight associated with matching the corresponding podAffinityTerm, in the range 1-100.", + Default: 0, + Type: []string{"integer"}, + Format: "int32", + }, + }, + "podAffinityTerm": { + SchemaProps: spec.SchemaProps{ + Description: "Required. A pod affinity term, associated with the corresponding weight.", + Default: map[string]interface{}{}, + Ref: ref(v1.PodAffinityTerm{}.OpenAPIModelName()), + }, + }, + }, + Required: []string{"weight", "podAffinityTerm"}, + }, + }, + Dependencies: []string{ + v1.PodAffinityTerm{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_api_core_v1_WindowsSecurityContextOptions(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "WindowsSecurityContextOptions contain Windows-specific options and credentials.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "gmsaCredentialSpecName": { + SchemaProps: spec.SchemaProps{ + Description: "GMSACredentialSpecName is the name of the GMSA credential spec to use.", + Type: []string{"string"}, + Format: "", + }, + }, + "gmsaCredentialSpec": { + SchemaProps: spec.SchemaProps{ + Description: "GMSACredentialSpec is where the GMSA admission webhook (https://github.com/kubernetes-sigs/windows-gmsa) inlines the contents of the GMSA credential spec named by the GMSACredentialSpecName field.", + Type: []string{"string"}, + Format: "", + }, + }, + "runAsUserName": { + SchemaProps: spec.SchemaProps{ + Description: "The UserName in Windows to run the entrypoint of the container process. Defaults to the user specified in image metadata if unspecified. May also be set in PodSecurityContext. If set in both SecurityContext and PodSecurityContext, the value specified in SecurityContext takes precedence.", + Type: []string{"string"}, + Format: "", + }, + }, + "hostProcess": { + SchemaProps: spec.SchemaProps{ + Description: "HostProcess determines if a container should be run as a 'Host Process' container. All of a Pod's containers must have the same effective HostProcess value (it is not allowed to have a mix of HostProcess containers and non-HostProcess containers). In addition, if HostProcess is true then HostNetwork must also be set to true.", + Type: []string{"boolean"}, + Format: "", + }, + }, + }, + }, + }, + } +} + +func schema_k8sio_api_core_v1_WorkloadReference(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "WorkloadReference identifies the Workload object and PodGroup membership that a Pod belongs to. The scheduler uses this information to apply workload-aware scheduling semantics.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "name": { + SchemaProps: spec.SchemaProps{ + Description: "Name defines the name of the Workload object this Pod belongs to. Workload must be in the same namespace as the Pod. If it doesn't match any existing Workload, the Pod will remain unschedulable until a Workload object is created and observed by the kube-scheduler. It must be a DNS subdomain.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "podGroup": { + SchemaProps: spec.SchemaProps{ + Description: "PodGroup is the name of the PodGroup within the Workload that this Pod belongs to. If it doesn't match any existing PodGroup within the Workload, the Pod will remain unschedulable until the Workload object is recreated and observed by the kube-scheduler. It must be a DNS label.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "podGroupReplicaKey": { + SchemaProps: spec.SchemaProps{ + Description: "PodGroupReplicaKey specifies the replica key of the PodGroup to which this Pod belongs. It is used to distinguish pods belonging to different replicas of the same pod group. The pod group policy is applied separately to each replica. When set, it must be a DNS label.", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"name", "podGroup"}, + }, + }, + } +} + +func schema_apimachinery_pkg_api_resource_Quantity(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.EmbedOpenAPIDefinitionIntoV2Extension(common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "Quantity is a fixed-point representation of a number. It provides convenient marshaling/unmarshaling in JSON and YAML, in addition to String() and AsInt64() accessors.\n\nThe serialization format is:\n\n``` ::= \n\n\t(Note that may be empty, from the \"\" case in .)\n\n ::= 0 | 1 | ... | 9 ::= | ::= | . | . | . ::= \"+\" | \"-\" ::= | ::= | | ::= Ki | Mi | Gi | Ti | Pi | Ei\n\n\t(International System of units; See: http://physics.nist.gov/cuu/Units/binary.html)\n\n ::= m | \"\" | k | M | G | T | P | E\n\n\t(Note that 1024 = 1Ki but 1000 = 1k; I didn't choose the capitalization.)\n\n ::= \"e\" | \"E\" ```\n\nNo matter which of the three exponent forms is used, no quantity may represent a number greater than 2^63-1 in magnitude, nor may it have more than 3 decimal places. Numbers larger or more precise will be capped or rounded up. (E.g.: 0.1m will rounded up to 1m.) This may be extended in the future if we require larger or smaller quantities.\n\nWhen a Quantity is parsed from a string, it will remember the type of suffix it had, and will use the same type again when it is serialized.\n\nBefore serializing, Quantity will be put in \"canonical form\". This means that Exponent/suffix will be adjusted up or down (with a corresponding increase or decrease in Mantissa) such that:\n\n- No precision is lost - No fractional digits will be emitted - The exponent (or suffix) is as large as possible.\n\nThe sign will be omitted unless the number is negative.\n\nExamples:\n\n- 1.5 will be serialized as \"1500m\" - 1.5Gi will be serialized as \"1536Mi\"\n\nNote that the quantity will NEVER be internally represented by a floating point number. That is the whole point of this exercise.\n\nNon-canonical values will still parse as long as they are well formed, but will be re-emitted in their canonical form. (So always use canonical form, or don't diff.)\n\nThis format is intended to make it difficult to use these numbers without writing some sort of special handling code in the hopes that that will cause implementors to also use a fixed point implementation.", + OneOf: common.GenerateOpenAPIV3OneOfSchema(resource.Quantity{}.OpenAPIV3OneOfTypes()), + Format: resource.Quantity{}.OpenAPISchemaFormat(), + }, + }, + }, common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "Quantity is a fixed-point representation of a number. It provides convenient marshaling/unmarshaling in JSON and YAML, in addition to String() and AsInt64() accessors.\n\nThe serialization format is:\n\n``` ::= \n\n\t(Note that may be empty, from the \"\" case in .)\n\n ::= 0 | 1 | ... | 9 ::= | ::= | . | . | . ::= \"+\" | \"-\" ::= | ::= | | ::= Ki | Mi | Gi | Ti | Pi | Ei\n\n\t(International System of units; See: http://physics.nist.gov/cuu/Units/binary.html)\n\n ::= m | \"\" | k | M | G | T | P | E\n\n\t(Note that 1024 = 1Ki but 1000 = 1k; I didn't choose the capitalization.)\n\n ::= \"e\" | \"E\" ```\n\nNo matter which of the three exponent forms is used, no quantity may represent a number greater than 2^63-1 in magnitude, nor may it have more than 3 decimal places. Numbers larger or more precise will be capped or rounded up. (E.g.: 0.1m will rounded up to 1m.) This may be extended in the future if we require larger or smaller quantities.\n\nWhen a Quantity is parsed from a string, it will remember the type of suffix it had, and will use the same type again when it is serialized.\n\nBefore serializing, Quantity will be put in \"canonical form\". This means that Exponent/suffix will be adjusted up or down (with a corresponding increase or decrease in Mantissa) such that:\n\n- No precision is lost - No fractional digits will be emitted - The exponent (or suffix) is as large as possible.\n\nThe sign will be omitted unless the number is negative.\n\nExamples:\n\n- 1.5 will be serialized as \"1500m\" - 1.5Gi will be serialized as \"1536Mi\"\n\nNote that the quantity will NEVER be internally represented by a floating point number. That is the whole point of this exercise.\n\nNon-canonical values will still parse as long as they are well formed, but will be re-emitted in their canonical form. (So always use canonical form, or don't diff.)\n\nThis format is intended to make it difficult to use these numbers without writing some sort of special handling code in the hopes that that will cause implementors to also use a fixed point implementation.", + Type: resource.Quantity{}.OpenAPISchemaType(), + Format: resource.Quantity{}.OpenAPISchemaFormat(), + }, + }, + }) +} + +func schema_apimachinery_pkg_api_resource_int64Amount(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "int64Amount represents a fixed precision numerator and arbitrary scale exponent. It is faster than operations on inf.Dec for values that can be represented as int64.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "value": { + SchemaProps: spec.SchemaProps{ + Default: 0, + Type: []string{"integer"}, + Format: "int64", + }, + }, + "scale": { + SchemaProps: spec.SchemaProps{ + Default: 0, + Type: []string{"integer"}, + Format: "int32", + }, + }, + }, + Required: []string{"value", "scale"}, + }, + }, + } +} + +func schema_pkg_apis_meta_v1_APIGroup(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "APIGroup contains the name, the supported versions, and the preferred version of a group.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "name": { + SchemaProps: spec.SchemaProps{ + Description: "name is the name of the group.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "versions": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "versions are the versions supported in this group.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(metav1.GroupVersionForDiscovery{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "preferredVersion": { + SchemaProps: spec.SchemaProps{ + Description: "preferredVersion is the version preferred by the API server, which probably is the storage version.", + Default: map[string]interface{}{}, + Ref: ref(metav1.GroupVersionForDiscovery{}.OpenAPIModelName()), + }, + }, + "serverAddressByClientCIDRs": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "a map of client CIDR to server address that is serving this group. This is to help clients reach servers in the most network-efficient way possible. Clients can use the appropriate server address as per the CIDR that they match. In case of multiple matches, clients should use the longest matching CIDR. The server returns only those CIDRs that it thinks that the client can match. For example: the master will return an internal IP CIDR only, if the client reaches the server using an internal IP. Server looks at X-Forwarded-For header or X-Real-Ip header or request.RemoteAddr (in that order) to get the client IP.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(metav1.ServerAddressByClientCIDR{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + }, + Required: []string{"name", "versions"}, + }, + }, + Dependencies: []string{ + metav1.GroupVersionForDiscovery{}.OpenAPIModelName(), metav1.ServerAddressByClientCIDR{}.OpenAPIModelName()}, + } +} + +func schema_pkg_apis_meta_v1_APIGroupList(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "APIGroupList is a list of APIGroup, to allow clients to discover the API at /apis.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "groups": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "groups is a list of APIGroup.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(metav1.APIGroup{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + }, + Required: []string{"groups"}, + }, + }, + Dependencies: []string{ + metav1.APIGroup{}.OpenAPIModelName()}, + } +} + +func schema_pkg_apis_meta_v1_APIResource(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "APIResource specifies the name of a resource and whether it is namespaced.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "name": { + SchemaProps: spec.SchemaProps{ + Description: "name is the plural name of the resource.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "singularName": { + SchemaProps: spec.SchemaProps{ + Description: "singularName is the singular name of the resource. This allows clients to handle plural and singular opaquely. The singularName is more correct for reporting status on a single item and both singular and plural are allowed from the kubectl CLI interface.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "namespaced": { + SchemaProps: spec.SchemaProps{ + Description: "namespaced indicates if a resource is namespaced or not.", + Default: false, + Type: []string{"boolean"}, + Format: "", + }, + }, + "group": { + SchemaProps: spec.SchemaProps{ + Description: "group is the preferred group of the resource. Empty implies the group of the containing resource list. For subresources, this may have a different value, for example: Scale\".", + Type: []string{"string"}, + Format: "", + }, + }, + "version": { + SchemaProps: spec.SchemaProps{ + Description: "version is the preferred version of the resource. Empty implies the version of the containing resource list For subresources, this may have a different value, for example: v1 (while inside a v1beta1 version of the core resource's group)\".", + Type: []string{"string"}, + Format: "", + }, + }, + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "kind is the kind for the resource (e.g. 'Foo' is the kind for a resource 'foo')", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "verbs": { + SchemaProps: spec.SchemaProps{ + Description: "verbs is a list of supported kube verbs (this includes get, list, watch, create, update, patch, delete, deletecollection, and proxy)", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + "shortNames": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "shortNames is a list of suggested short names of the resource.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + "categories": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "categories is a list of the grouped resources this resource belongs to (e.g. 'all')", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + "storageVersionHash": { + SchemaProps: spec.SchemaProps{ + Description: "The hash value of the storage version, the version this resource is converted to when written to the data store. Value must be treated as opaque by clients. Only equality comparison on the value is valid. This is an alpha feature and may change or be removed in the future. The field is populated by the apiserver only if the StorageVersionHash feature gate is enabled. This field will remain optional even if it graduates.", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"name", "singularName", "namespaced", "kind", "verbs"}, + }, + }, + } +} + +func schema_pkg_apis_meta_v1_APIResourceList(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "APIResourceList is a list of APIResource, it is used to expose the name of the resources supported in a specific group and version, and if the resource is namespaced.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "groupVersion": { + SchemaProps: spec.SchemaProps{ + Description: "groupVersion is the group and version this APIResourceList is for.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "resources": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "resources contains the name of the resources and if they are namespaced.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(metav1.APIResource{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + }, + Required: []string{"groupVersion", "resources"}, + }, + }, + Dependencies: []string{ + metav1.APIResource{}.OpenAPIModelName()}, + } +} + +func schema_pkg_apis_meta_v1_APIVersions(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "APIVersions lists the versions that are available, to allow clients to discover the API at /api, which is the root path of the legacy v1 API.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "versions": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "versions are the api versions that are available.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + "serverAddressByClientCIDRs": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "a map of client CIDR to server address that is serving this group. This is to help clients reach servers in the most network-efficient way possible. Clients can use the appropriate server address as per the CIDR that they match. In case of multiple matches, clients should use the longest matching CIDR. The server returns only those CIDRs that it thinks that the client can match. For example: the master will return an internal IP CIDR only, if the client reaches the server using an internal IP. Server looks at X-Forwarded-For header or X-Real-Ip header or request.RemoteAddr (in that order) to get the client IP.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(metav1.ServerAddressByClientCIDR{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + }, + Required: []string{"versions", "serverAddressByClientCIDRs"}, + }, + }, + Dependencies: []string{ + metav1.ServerAddressByClientCIDR{}.OpenAPIModelName()}, + } +} + +func schema_pkg_apis_meta_v1_ApplyOptions(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "ApplyOptions may be provided when applying an API object. FieldManager is required for apply requests. ApplyOptions is equivalent to PatchOptions. It is provided as a convenience with documentation that speaks specifically to how the options fields relate to apply.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "dryRun": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + "force": { + SchemaProps: spec.SchemaProps{ + Description: "Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people.", + Default: false, + Type: []string{"boolean"}, + Format: "", + }, + }, + "fieldManager": { + SchemaProps: spec.SchemaProps{ + Description: "fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"force", "fieldManager"}, + }, + }, + } +} + +func schema_pkg_apis_meta_v1_Condition(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "Condition contains details for one aspect of the current state of this API Resource.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "type": { + SchemaProps: spec.SchemaProps{ + Description: "type of condition in CamelCase or in foo.example.com/CamelCase.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "status": { + SchemaProps: spec.SchemaProps{ + Description: "status of the condition, one of True, False, Unknown.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "observedGeneration": { + SchemaProps: spec.SchemaProps{ + Description: "observedGeneration represents the .metadata.generation that the condition was set based upon. For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date with respect to the current state of the instance.", + Type: []string{"integer"}, + Format: "int64", + }, + }, + "lastTransitionTime": { + SchemaProps: spec.SchemaProps{ + Description: "lastTransitionTime is the last time the condition transitioned from one status to another. This should be when the underlying condition changed. If that is not known, then using the time when the API field changed is acceptable.", + Ref: ref(metav1.Time{}.OpenAPIModelName()), + }, + }, + "reason": { + SchemaProps: spec.SchemaProps{ + Description: "reason contains a programmatic identifier indicating the reason for the condition's last transition. Producers of specific condition types may define expected values and meanings for this field, and whether the values are considered a guaranteed API. The value should be a CamelCase string. This field may not be empty.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "message": { + SchemaProps: spec.SchemaProps{ + Description: "message is a human readable message indicating details about the transition. This may be an empty string.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"type", "status", "lastTransitionTime", "reason", "message"}, + }, + }, + Dependencies: []string{ + metav1.Time{}.OpenAPIModelName()}, + } +} + +func schema_pkg_apis_meta_v1_CreateOptions(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "CreateOptions may be provided when creating an API object.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "dryRun": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + "fieldManager": { + SchemaProps: spec.SchemaProps{ + Description: "fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.", + Type: []string{"string"}, + Format: "", + }, + }, + "fieldValidation": { + SchemaProps: spec.SchemaProps{ + Description: "fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + } +} + +func schema_pkg_apis_meta_v1_DeleteOptions(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "DeleteOptions may be provided when deleting an API object.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "gracePeriodSeconds": { + SchemaProps: spec.SchemaProps{ + Description: "The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.", + Type: []string{"integer"}, + Format: "int64", + }, + }, + "preconditions": { + SchemaProps: spec.SchemaProps{ + Description: "Must be fulfilled before a deletion is carried out. If not possible, a 409 Conflict status will be returned.", + Ref: ref(metav1.Preconditions{}.OpenAPIModelName()), + }, + }, + "orphanDependents": { + SchemaProps: spec.SchemaProps{ + Description: "Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.", + Type: []string{"boolean"}, + Format: "", + }, + }, + "propagationPolicy": { + SchemaProps: spec.SchemaProps{ + Description: "Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.", + Type: []string{"string"}, + Format: "", + }, + }, + "dryRun": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + "ignoreStoreReadErrorWithClusterBreakingPotential": { + SchemaProps: spec.SchemaProps{ + Description: "if set to true, it will trigger an unsafe deletion of the resource in case the normal deletion flow fails with a corrupt object error. A resource is considered corrupt if it can not be retrieved from the underlying storage successfully because of a) its data can not be transformed e.g. decryption failure, or b) it fails to decode into an object. NOTE: unsafe deletion ignores finalizer constraints, skips precondition checks, and removes the object from the storage. WARNING: This may potentially break the cluster if the workload associated with the resource being unsafe-deleted relies on normal deletion flow. Use only if you REALLY know what you are doing. The default value is false, and the user must opt in to enable it", + Type: []string{"boolean"}, + Format: "", + }, + }, + }, + }, + }, + Dependencies: []string{ + metav1.Preconditions{}.OpenAPIModelName()}, + } +} + +func schema_pkg_apis_meta_v1_Duration(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "Duration is a wrapper around time.Duration which supports correct marshaling to YAML and JSON. In particular, it marshals into strings, which can be used as map keys in json.", + Type: metav1.Duration{}.OpenAPISchemaType(), + Format: metav1.Duration{}.OpenAPISchemaFormat(), + }, + }, + } +} + +func schema_pkg_apis_meta_v1_FieldSelectorRequirement(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "FieldSelectorRequirement is a selector that contains values, a key, and an operator that relates the key and values.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "key": { + SchemaProps: spec.SchemaProps{ + Description: "key is the field selector key that the requirement applies to.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "operator": { + SchemaProps: spec.SchemaProps{ + Description: "operator represents a key's relationship to a set of values. Valid operators are In, NotIn, Exists, DoesNotExist. The list of operators may grow in the future.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "values": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "values is an array of string values. If the operator is In or NotIn, the values array must be non-empty. If the operator is Exists or DoesNotExist, the values array must be empty.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + }, + Required: []string{"key", "operator"}, + }, + }, + } +} + +func schema_pkg_apis_meta_v1_FieldsV1(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "FieldsV1 stores a set of fields in a data structure like a Trie, in JSON format.\n\nEach key is either a '.' representing the field itself, and will always map to an empty set, or a string representing a sub-field or item. The string will follow one of these four formats: 'f:', where is the name of a field in a struct, or key in a map 'v:', where is the exact json formatted value of a list item 'i:', where is position of a item in a list 'k:', where is a map of a list item's key fields to their unique values If a key maps to an empty Fields value, the field that key represents is part of the set.\n\nThe exact format is defined in sigs.k8s.io/structured-merge-diff", + Type: []string{"object"}, + }, + }, + } +} + +func schema_pkg_apis_meta_v1_GetOptions(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "GetOptions is the standard query options to the standard REST get call.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "resourceVersion": { + SchemaProps: spec.SchemaProps{ + Description: "resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details.\n\nDefaults to unset", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + } +} + +func schema_pkg_apis_meta_v1_GroupKind(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "GroupKind specifies a Group and a Kind, but does not force a version. This is useful for identifying concepts during lookup stages without having partially valid types", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "group": { + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "kind": { + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"group", "kind"}, + }, + }, + } +} + +func schema_pkg_apis_meta_v1_GroupResource(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "GroupResource specifies a Group and a Resource, but does not force a version. This is useful for identifying concepts during lookup stages without having partially valid types", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "group": { + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "resource": { + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"group", "resource"}, + }, + }, + } +} + +func schema_pkg_apis_meta_v1_GroupVersion(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "GroupVersion contains the \"group\" and the \"version\", which uniquely identifies the API.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "group": { + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "version": { + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"group", "version"}, + }, + }, + } +} + +func schema_pkg_apis_meta_v1_GroupVersionForDiscovery(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "GroupVersion contains the \"group/version\" and \"version\" string of a version. It is made a struct to keep extensibility.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "groupVersion": { + SchemaProps: spec.SchemaProps{ + Description: "groupVersion specifies the API group and version in the form \"group/version\"", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "version": { + SchemaProps: spec.SchemaProps{ + Description: "version specifies the version in the form of \"version\". This is to save the clients the trouble of splitting the GroupVersion.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"groupVersion", "version"}, + }, + }, + } +} + +func schema_pkg_apis_meta_v1_GroupVersionKind(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "GroupVersionKind unambiguously identifies a kind. It doesn't anonymously include GroupVersion to avoid automatic coercion. It doesn't use a GroupVersion to avoid custom marshalling", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "group": { + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "version": { + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "kind": { + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"group", "version", "kind"}, + }, + }, + } +} + +func schema_pkg_apis_meta_v1_GroupVersionResource(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "GroupVersionResource unambiguously identifies a resource. It doesn't anonymously include GroupVersion to avoid automatic coercion. It doesn't use a GroupVersion to avoid custom marshalling", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "group": { + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "version": { + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "resource": { + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"group", "version", "resource"}, + }, + }, + } +} + +func schema_pkg_apis_meta_v1_InternalEvent(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "InternalEvent makes watch.Event versioned", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "Type": { + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "Object": { + SchemaProps: spec.SchemaProps{ + Description: "Object is:\n * If Type is Added or Modified: the new state of the object.\n * If Type is Deleted: the state of the object immediately before deletion.\n * If Type is Bookmark: the object (instance of a type being watched) where\n only ResourceVersion field is set. On successful restart of watch from a\n bookmark resourceVersion, client is guaranteed to not get repeat event\n nor miss any events.\n * If Type is Error: *api.Status is recommended; other types may make sense\n depending on context.", + }, + }, + }, + Required: []string{"Type", "Object"}, + }, + }, + } +} + +func schema_pkg_apis_meta_v1_LabelSelector(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "A label selector is a label query over a set of resources. The result of matchLabels and matchExpressions are ANDed. An empty label selector matches all objects. A null label selector matches no objects.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "matchLabels": { + SchemaProps: spec.SchemaProps{ + Description: "matchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels map is equivalent to an element of matchExpressions, whose key field is \"key\", the operator is \"In\", and the values array contains only \"value\". The requirements are ANDed.", + Type: []string{"object"}, + AdditionalProperties: &spec.SchemaOrBool{ + Allows: true, + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + "matchExpressions": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "matchExpressions is a list of label selector requirements. The requirements are ANDed.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(metav1.LabelSelectorRequirement{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + }, + }, + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-map-type": "atomic", + }, + }, + }, + Dependencies: []string{ + metav1.LabelSelectorRequirement{}.OpenAPIModelName()}, + } +} + +func schema_pkg_apis_meta_v1_LabelSelectorRequirement(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "A label selector requirement is a selector that contains values, a key, and an operator that relates the key and values.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "key": { + SchemaProps: spec.SchemaProps{ + Description: "key is the label key that the selector applies to.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "operator": { + SchemaProps: spec.SchemaProps{ + Description: "operator represents a key's relationship to a set of values. Valid operators are In, NotIn, Exists and DoesNotExist.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "values": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "values is an array of string values. If the operator is In or NotIn, the values array must be non-empty. If the operator is Exists or DoesNotExist, the values array must be empty. This array is replaced during a strategic merge patch.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + }, + Required: []string{"key", "operator"}, + }, + }, + } +} + +func schema_pkg_apis_meta_v1_List(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "List holds a list of objects, which may not be known by the server.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "metadata": { + SchemaProps: spec.SchemaProps{ + Description: "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Default: map[string]interface{}{}, + Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), + }, + }, + "items": { + SchemaProps: spec.SchemaProps{ + Description: "List of objects", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Ref: ref(runtime.RawExtension{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + }, + Required: []string{"items"}, + }, + }, + Dependencies: []string{ + metav1.ListMeta{}.OpenAPIModelName(), runtime.RawExtension{}.OpenAPIModelName()}, + } +} + +func schema_pkg_apis_meta_v1_ListMeta(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "ListMeta describes metadata that synthetic resources must have, including lists and various status objects. A resource may have only one of {ObjectMeta, ListMeta}.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "selfLink": { + SchemaProps: spec.SchemaProps{ + Description: "Deprecated: selfLink is a legacy read-only field that is no longer populated by the system.", + Type: []string{"string"}, + Format: "", + }, + }, + "resourceVersion": { + SchemaProps: spec.SchemaProps{ + Description: "String that identifies the server's internal version of this object that can be used by clients to determine when objects have changed. Value must be treated as opaque by clients and passed unmodified back to the server. Populated by the system. Read-only. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#concurrency-control-and-consistency", + Type: []string{"string"}, + Format: "", + }, + }, + "continue": { + SchemaProps: spec.SchemaProps{ + Description: "continue may be set if the user set a limit on the number of items returned, and indicates that the server has more data available. The value is opaque and may be used to issue another request to the endpoint that served this list to retrieve the next set of available objects. Continuing a consistent list may not be possible if the server configuration has changed or more than a few minutes have passed. The resourceVersion field returned when using this continue value will be identical to the value in the first response, unless you have received this token from an error message.", + Type: []string{"string"}, + Format: "", + }, + }, + "remainingItemCount": { + SchemaProps: spec.SchemaProps{ + Description: "remainingItemCount is the number of subsequent items in the list which are not included in this list response. If the list request contained label or field selectors, then the number of remaining items is unknown and the field will be left unset and omitted during serialization. If the list is complete (either because it is not chunking or because this is the last chunk), then there are no more remaining items and this field will be left unset and omitted during serialization. Servers older than v1.15 do not set this field. The intended use of the remainingItemCount is *estimating* the size of a collection. Clients should not rely on the remainingItemCount to be set or to be exact.", + Type: []string{"integer"}, + Format: "int64", + }, + }, + }, + }, + }, + } +} + +func schema_pkg_apis_meta_v1_ListOptions(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "ListOptions is the query options to a standard REST list call.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "labelSelector": { + SchemaProps: spec.SchemaProps{ + Description: "A selector to restrict the list of returned objects by their labels. Defaults to everything.", + Type: []string{"string"}, + Format: "", + }, + }, + "fieldSelector": { + SchemaProps: spec.SchemaProps{ + Description: "A selector to restrict the list of returned objects by their fields. Defaults to everything.", + Type: []string{"string"}, + Format: "", + }, + }, + "watch": { + SchemaProps: spec.SchemaProps{ + Description: "Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.", + Type: []string{"boolean"}, + Format: "", + }, + }, + "allowWatchBookmarks": { + SchemaProps: spec.SchemaProps{ + Description: "allowWatchBookmarks requests watch events with type \"BOOKMARK\". Servers that do not implement bookmarks may ignore this flag and bookmarks are sent at the server's discretion. Clients should not assume bookmarks are returned at any specific interval, nor may they assume the server will send any BOOKMARK event during a session. If this is not a watch, this field is ignored.", + Type: []string{"boolean"}, + Format: "", + }, + }, + "resourceVersion": { + SchemaProps: spec.SchemaProps{ + Description: "resourceVersion sets a constraint on what resource versions a request may be served from. See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details.\n\nDefaults to unset", + Type: []string{"string"}, + Format: "", + }, + }, + "resourceVersionMatch": { + SchemaProps: spec.SchemaProps{ + Description: "resourceVersionMatch determines how resourceVersion is applied to list calls. It is highly recommended that resourceVersionMatch be set for list calls where resourceVersion is set See https://kubernetes.io/docs/reference/using-api/api-concepts/#resource-versions for details.\n\nDefaults to unset", + Type: []string{"string"}, + Format: "", + }, + }, + "timeoutSeconds": { + SchemaProps: spec.SchemaProps{ + Description: "Timeout for the list/watch call. This limits the duration of the call, regardless of any activity or inactivity.", + Type: []string{"integer"}, + Format: "int64", + }, + }, + "limit": { + SchemaProps: spec.SchemaProps{ + Description: "limit is a maximum number of responses to return for a list call. If more items exist, the server will set the `continue` field on the list metadata to a value that can be used with the same initial query to retrieve the next set of results. Setting a limit may return fewer than the requested amount of items (up to zero items) in the event all requested objects are filtered out and clients should only use the presence of the continue field to determine whether more results are available. Servers may choose not to support the limit argument and will return all of the available results. If limit is specified and the continue field is empty, clients may assume that no more results are available. This field is not supported if watch is true.\n\nThe server guarantees that the objects returned when using continue will be identical to issuing a single list call without a limit - that is, no objects created, modified, or deleted after the first request is issued will be included in any subsequent continued requests. This is sometimes referred to as a consistent snapshot, and ensures that a client that is using limit to receive smaller chunks of a very large result can ensure they see all possible objects. If objects are updated during a chunked list the version of the object that was present at the time the first list result was calculated is returned.", + Type: []string{"integer"}, + Format: "int64", + }, + }, + "continue": { + SchemaProps: spec.SchemaProps{ + Description: "The continue option should be set when retrieving more results from the server. Since this value is server defined, clients may only use the continue value from a previous query result with identical query parameters (except for the value of continue) and the server may reject a continue value it does not recognize. If the specified continue value is no longer valid whether due to expiration (generally five to fifteen minutes) or a configuration change on the server, the server will respond with a 410 ResourceExpired error together with a continue token. If the client needs a consistent list, it must restart their list without the continue field. Otherwise, the client may send another list request with the token received with the 410 error, the server will respond with a list starting from the next key, but from the latest snapshot, which is inconsistent from the previous list results - objects that are created, modified, or deleted after the first list request will be included in the response, as long as their keys are after the \"next key\".\n\nThis field is not supported when watch is true. Clients may start a watch from the last resourceVersion value returned by the server and not miss any modifications.", + Type: []string{"string"}, + Format: "", + }, + }, + "sendInitialEvents": { + SchemaProps: spec.SchemaProps{ + Description: "`sendInitialEvents=true` may be set together with `watch=true`. In that case, the watch stream will begin with synthetic events to produce the current state of objects in the collection. Once all such events have been sent, a synthetic \"Bookmark\" event will be sent. The bookmark will report the ResourceVersion (RV) corresponding to the set of objects, and be marked with `\"k8s.io/initial-events-end\": \"true\"` annotation. Afterwards, the watch stream will proceed as usual, sending watch events corresponding to changes (subsequent to the RV) to objects watched.\n\nWhen `sendInitialEvents` option is set, we require `resourceVersionMatch` option to also be set. The semantic of the watch request is as following: - `resourceVersionMatch` = NotOlderThan\n is interpreted as \"data at least as new as the provided `resourceVersion`\"\n and the bookmark event is send when the state is synced\n to a `resourceVersion` at least as fresh as the one provided by the ListOptions.\n If `resourceVersion` is unset, this is interpreted as \"consistent read\" and the\n bookmark event is send when the state is synced at least to the moment\n when request started being processed.\n- `resourceVersionMatch` set to any other value or unset\n Invalid error is returned.\n\nDefaults to true if `resourceVersion=\"\"` or `resourceVersion=\"0\"` (for backward compatibility reasons) and to false otherwise.", + Type: []string{"boolean"}, + Format: "", + }, + }, + }, + }, + }, + } +} + +func schema_pkg_apis_meta_v1_ManagedFieldsEntry(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "ManagedFieldsEntry is a workflow-id, a FieldSet and the group version of the resource that the fieldset applies to.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "manager": { + SchemaProps: spec.SchemaProps{ + Description: "Manager is an identifier of the workflow managing these fields.", + Type: []string{"string"}, + Format: "", + }, + }, + "operation": { + SchemaProps: spec.SchemaProps{ + Description: "Operation is the type of operation which lead to this ManagedFieldsEntry being created. The only valid values for this field are 'Apply' and 'Update'.", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the version of this resource that this field set applies to. The format is \"group/version\" just like the top-level APIVersion field. It is necessary to track the version of a field set because it cannot be automatically converted.", + Type: []string{"string"}, + Format: "", + }, + }, + "time": { + SchemaProps: spec.SchemaProps{ + Description: "Time is the timestamp of when the ManagedFields entry was added. The timestamp will also be updated if a field is added, the manager changes any of the owned fields value or removes a field. The timestamp does not update when a field is removed from the entry because another manager took it over.", + Ref: ref(metav1.Time{}.OpenAPIModelName()), + }, + }, + "fieldsType": { + SchemaProps: spec.SchemaProps{ + Description: "FieldsType is the discriminator for the different fields format and version. There is currently only one possible value: \"FieldsV1\"", + Type: []string{"string"}, + Format: "", + }, + }, + "fieldsV1": { + SchemaProps: spec.SchemaProps{ + Description: "FieldsV1 holds the first JSON version format as described in the \"FieldsV1\" type.", + Ref: ref(metav1.FieldsV1{}.OpenAPIModelName()), + }, + }, + "subresource": { + SchemaProps: spec.SchemaProps{ + Description: "Subresource is the name of the subresource used to update that object, or empty string if the object was updated through the main resource. The value of this field is used to distinguish between managers, even if they share the same name. For example, a status update will be distinct from a regular update using the same manager name. Note that the APIVersion field is not related to the Subresource field and it always corresponds to the version of the main resource.", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + Dependencies: []string{ + metav1.FieldsV1{}.OpenAPIModelName(), metav1.Time{}.OpenAPIModelName()}, + } +} + +func schema_pkg_apis_meta_v1_MicroTime(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "MicroTime is version of Time with microsecond level precision.", + Type: metav1.MicroTime{}.OpenAPISchemaType(), + Format: metav1.MicroTime{}.OpenAPISchemaFormat(), + }, + }, + } +} + +func schema_pkg_apis_meta_v1_ObjectMeta(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "ObjectMeta is metadata that all persisted resources must have, which includes all objects users must create.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "name": { + SchemaProps: spec.SchemaProps{ + Description: "Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names#names", + Type: []string{"string"}, + Format: "", + }, + }, + "generateName": { + SchemaProps: spec.SchemaProps{ + Description: "GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server.\n\nIf this field is specified and the generated name exists, the server will return a 409.\n\nApplied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#idempotency", + Type: []string{"string"}, + Format: "", + }, + }, + "namespace": { + SchemaProps: spec.SchemaProps{ + Description: "Namespace defines the space within which each name must be unique. An empty namespace is equivalent to the \"default\" namespace, but \"default\" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty.\n\nMust be a DNS_LABEL. Cannot be updated. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/namespaces", + Type: []string{"string"}, + Format: "", + }, + }, + "selfLink": { + SchemaProps: spec.SchemaProps{ + Description: "Deprecated: selfLink is a legacy read-only field that is no longer populated by the system.", + Type: []string{"string"}, + Format: "", + }, + }, + "uid": { + SchemaProps: spec.SchemaProps{ + Description: "UID is the unique in time and space value for this object. It is typically generated by the server on successful creation of a resource and is not allowed to change on PUT operations.\n\nPopulated by the system. Read-only. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names#uids", + Type: []string{"string"}, + Format: "", + }, + }, + "resourceVersion": { + SchemaProps: spec.SchemaProps{ + Description: "An opaque value that represents the internal version of this object that can be used by clients to determine when objects have changed. May be used for optimistic concurrency, change detection, and the watch operation on a resource or set of resources. Clients must treat these values as opaque and passed unmodified back to the server. They may only be valid for a particular resource or set of resources.\n\nPopulated by the system. Read-only. Value must be treated as opaque by clients and . More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#concurrency-control-and-consistency", + Type: []string{"string"}, + Format: "", + }, + }, + "generation": { + SchemaProps: spec.SchemaProps{ + Description: "A sequence number representing a specific generation of the desired state. Populated by the system. Read-only.", + Type: []string{"integer"}, + Format: "int64", + }, + }, + "creationTimestamp": { + SchemaProps: spec.SchemaProps{ + Description: "CreationTimestamp is a timestamp representing the server time when this object was created. It is not guaranteed to be set in happens-before order across separate operations. Clients may not set this value. It is represented in RFC3339 form and is in UTC.\n\nPopulated by the system. Read-only. Null for lists. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata", + Ref: ref(metav1.Time{}.OpenAPIModelName()), + }, + }, + "deletionTimestamp": { + SchemaProps: spec.SchemaProps{ + Description: "DeletionTimestamp is RFC 3339 date and time at which this resource will be deleted. This field is set by the server when a graceful deletion is requested by the user, and is not directly settable by a client. The resource is expected to be deleted (no longer visible from resource lists, and not reachable by name) after the time in this field, once the finalizers list is empty. As long as the finalizers list contains items, deletion is blocked. Once the deletionTimestamp is set, this value may not be unset or be set further into the future, although it may be shortened or the resource may be deleted prior to this time. For example, a user may request that a pod is deleted in 30 seconds. The Kubelet will react by sending a graceful termination signal to the containers in the pod. After that 30 seconds, the Kubelet will send a hard termination signal (SIGKILL) to the container and after cleanup, remove the pod from the API. In the presence of network partitions, this object may still exist after this timestamp, until an administrator or automated process can determine the resource is fully terminated. If not set, graceful deletion of the object has not been requested.\n\nPopulated by the system when a graceful deletion is requested. Read-only. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata", + Ref: ref(metav1.Time{}.OpenAPIModelName()), + }, + }, + "deletionGracePeriodSeconds": { + SchemaProps: spec.SchemaProps{ + Description: "Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only.", + Type: []string{"integer"}, + Format: "int64", + }, + }, + "labels": { + SchemaProps: spec.SchemaProps{ + Description: "Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/labels", + Type: []string{"object"}, + AdditionalProperties: &spec.SchemaOrBool{ + Allows: true, + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + "annotations": { + SchemaProps: spec.SchemaProps{ + Description: "Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/annotations", + Type: []string{"object"}, + AdditionalProperties: &spec.SchemaOrBool{ + Allows: true, + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + "ownerReferences": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-map-keys": []interface{}{ + "uid", + }, + "x-kubernetes-list-type": "map", + "x-kubernetes-patch-merge-key": "uid", + "x-kubernetes-patch-strategy": "merge", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "List of objects depended by this object. If ALL objects in the list have been deleted, this object will be garbage collected. If this object is managed by a controller, then an entry in this list will point to this controller, with the controller field set to true. There cannot be more than one managing controller.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(metav1.OwnerReference{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "finalizers": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "set", + "x-kubernetes-patch-strategy": "merge", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed. Finalizers may be processed and removed in any order. Order is NOT enforced because it introduces significant risk of stuck finalizers. finalizers is a shared field, any actor with permission can reorder it. If the finalizer list is processed in order, then this can lead to a situation in which the component responsible for the first finalizer in the list is waiting for a signal (field value, external system, or other) produced by a component responsible for a finalizer later in the list, resulting in a deadlock. Without enforced ordering finalizers are free to order amongst themselves and are not vulnerable to ordering changes in the list.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + "managedFields": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "ManagedFields maps workflow-id and version to the set of fields that are managed by that workflow. This is mostly for internal housekeeping, and users typically shouldn't need to set or understand this field. A workflow can be the user's name, a controller's name, or the name of a specific apply path like \"ci-cd\". The set of fields is always in the version that the workflow used when modifying the object.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(metav1.ManagedFieldsEntry{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + }, + }, + }, + Dependencies: []string{ + metav1.ManagedFieldsEntry{}.OpenAPIModelName(), metav1.OwnerReference{}.OpenAPIModelName(), metav1.Time{}.OpenAPIModelName()}, + } +} + +func schema_pkg_apis_meta_v1_OwnerReference(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "OwnerReference contains enough information to let you identify an owning object. An owning object must be in the same namespace as the dependent, or be cluster-scoped, so there is no namespace field.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "API version of the referent.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind of the referent. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "name": { + SchemaProps: spec.SchemaProps{ + Description: "Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names#names", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "uid": { + SchemaProps: spec.SchemaProps{ + Description: "UID of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names#uids", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "controller": { + SchemaProps: spec.SchemaProps{ + Description: "If true, this reference points to the managing controller.", + Type: []string{"boolean"}, + Format: "", + }, + }, + "blockOwnerDeletion": { + SchemaProps: spec.SchemaProps{ + Description: "If true, AND if the owner has the \"foregroundDeletion\" finalizer, then the owner cannot be deleted from the key-value store until this reference is removed. See https://kubernetes.io/docs/concepts/architecture/garbage-collection/#foreground-deletion for how the garbage collector interacts with this field and enforces the foreground deletion. Defaults to false. To set this field, a user needs \"delete\" permission of the owner, otherwise 422 (Unprocessable Entity) will be returned.", + Type: []string{"boolean"}, + Format: "", + }, + }, + }, + Required: []string{"apiVersion", "kind", "name", "uid"}, + }, + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-map-type": "atomic", + }, + }, + }, + } +} + +func schema_pkg_apis_meta_v1_PartialObjectMetadata(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "PartialObjectMetadata is a generic representation of any object with ObjectMeta. It allows clients to get access to a particular ObjectMeta schema without knowing the details of the version.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "metadata": { + SchemaProps: spec.SchemaProps{ + Description: "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata", + Default: map[string]interface{}{}, + Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + Dependencies: []string{ + metav1.ObjectMeta{}.OpenAPIModelName()}, + } +} + +func schema_pkg_apis_meta_v1_PartialObjectMetadataList(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "PartialObjectMetadataList contains a list of objects containing only their metadata", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "metadata": { + SchemaProps: spec.SchemaProps{ + Description: "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Default: map[string]interface{}{}, + Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), + }, + }, + "items": { + SchemaProps: spec.SchemaProps{ + Description: "items contains each of the included items.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(metav1.PartialObjectMetadata{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + }, + Required: []string{"items"}, + }, + }, + Dependencies: []string{ + metav1.ListMeta{}.OpenAPIModelName(), metav1.PartialObjectMetadata{}.OpenAPIModelName()}, + } +} + +func schema_pkg_apis_meta_v1_Patch(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "Patch is provided to give a concrete name and type to the Kubernetes PATCH request body.", + Type: []string{"object"}, + }, + }, + } +} + +func schema_pkg_apis_meta_v1_PatchOptions(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "PatchOptions may be provided when patching an API object. PatchOptions is meant to be a superset of UpdateOptions.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "dryRun": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + "force": { + SchemaProps: spec.SchemaProps{ + Description: "Force is going to \"force\" Apply requests. It means user will re-acquire conflicting fields owned by other people. Force flag must be unset for non-apply patch requests.", + Type: []string{"boolean"}, + Format: "", + }, + }, + "fieldManager": { + SchemaProps: spec.SchemaProps{ + Description: "fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint. This field is required for apply requests (application/apply-patch) but optional for non-apply patch types (JsonPatch, MergePatch, StrategicMergePatch).", + Type: []string{"string"}, + Format: "", + }, + }, + "fieldValidation": { + SchemaProps: spec.SchemaProps{ + Description: "fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + } +} + +func schema_pkg_apis_meta_v1_Preconditions(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "Preconditions must be fulfilled before an operation (update, delete, etc.) is carried out.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "uid": { + SchemaProps: spec.SchemaProps{ + Description: "Specifies the target UID.", + Type: []string{"string"}, + Format: "", + }, + }, + "resourceVersion": { + SchemaProps: spec.SchemaProps{ + Description: "Specifies the target ResourceVersion", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + } +} + +func schema_pkg_apis_meta_v1_RootPaths(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "RootPaths lists the paths available at root. For example: \"/healthz\", \"/apis\".", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "paths": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "paths are the paths available at root.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + }, + Required: []string{"paths"}, + }, + }, + } +} + +func schema_pkg_apis_meta_v1_ServerAddressByClientCIDR(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "ServerAddressByClientCIDR helps the client to determine the server address that they should use, depending on the clientCIDR that they match.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "clientCIDR": { + SchemaProps: spec.SchemaProps{ + Description: "The CIDR with which clients can match their IP to figure out the server address that they should use.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "serverAddress": { + SchemaProps: spec.SchemaProps{ + Description: "Address of this server, suitable for a client that matches the above CIDR. This can be a hostname, hostname:port, IP or IP:port.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"clientCIDR", "serverAddress"}, + }, + }, + } +} + +func schema_pkg_apis_meta_v1_Status(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "Status is a return value for calls that don't return other objects.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "metadata": { + SchemaProps: spec.SchemaProps{ + Description: "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Default: map[string]interface{}{}, + Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), + }, + }, + "status": { + SchemaProps: spec.SchemaProps{ + Description: "Status of the operation. One of: \"Success\" or \"Failure\". More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status", + Type: []string{"string"}, + Format: "", + }, + }, + "message": { + SchemaProps: spec.SchemaProps{ + Description: "A human-readable description of the status of this operation.", + Type: []string{"string"}, + Format: "", + }, + }, + "reason": { + SchemaProps: spec.SchemaProps{ + Description: "A machine-readable description of why this operation is in the \"Failure\" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it.", + Type: []string{"string"}, + Format: "", + }, + }, + "details": { + SchemaProps: spec.SchemaProps{ + Description: "Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type.", + Ref: ref(metav1.StatusDetails{}.OpenAPIModelName()), + }, + }, + "code": { + SchemaProps: spec.SchemaProps{ + Description: "Suggested HTTP return code for this status, 0 if not set.", + Type: []string{"integer"}, + Format: "int32", + }, + }, + }, + }, + }, + Dependencies: []string{ + metav1.ListMeta{}.OpenAPIModelName(), metav1.StatusDetails{}.OpenAPIModelName()}, + } +} + +func schema_pkg_apis_meta_v1_StatusCause(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "StatusCause provides more information about an api.Status failure, including cases when multiple errors are encountered.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "reason": { + SchemaProps: spec.SchemaProps{ + Description: "A machine-readable description of the cause of the error. If this value is empty there is no information available.", + Type: []string{"string"}, + Format: "", + }, + }, + "message": { + SchemaProps: spec.SchemaProps{ + Description: "A human-readable description of the cause of the error. This field may be presented as-is to a reader.", + Type: []string{"string"}, + Format: "", + }, + }, + "field": { + SchemaProps: spec.SchemaProps{ + Description: "The field of the resource that has caused this error, as named by its JSON serialization. May include dot and postfix notation for nested attributes. Arrays are zero-indexed. Fields may appear more than once in an array of causes due to fields having multiple errors. Optional.\n\nExamples:\n \"name\" - the field \"name\" on the current resource\n \"items[0].name\" - the field \"name\" on the first array entry in \"items\"", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + } +} + +func schema_pkg_apis_meta_v1_StatusDetails(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "StatusDetails is a set of additional properties that MAY be set by the server to provide additional information about a response. The Reason field of a Status object defines what attributes will be set. Clients must ignore fields that do not match the defined type of each attribute, and should assume that any attribute may be empty, invalid, or under defined.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "name": { + SchemaProps: spec.SchemaProps{ + Description: "The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described).", + Type: []string{"string"}, + Format: "", + }, + }, + "group": { + SchemaProps: spec.SchemaProps{ + Description: "The group attribute of the resource associated with the status StatusReason.", + Type: []string{"string"}, + Format: "", + }, + }, + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "The kind attribute of the resource associated with the status StatusReason. On some operations may differ from the requested resource Kind. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "uid": { + SchemaProps: spec.SchemaProps{ + Description: "UID of the resource. (when there is a single resource which can be described). More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names#uids", + Type: []string{"string"}, + Format: "", + }, + }, + "causes": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(metav1.StatusCause{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "retryAfterSeconds": { + SchemaProps: spec.SchemaProps{ + Description: "If specified, the time in seconds before the operation should be retried. Some errors may indicate the client must take an alternate action - for those errors this field may indicate how long to wait before taking the alternate action.", + Type: []string{"integer"}, + Format: "int32", + }, + }, + }, + }, + }, + Dependencies: []string{ + metav1.StatusCause{}.OpenAPIModelName()}, + } +} + +func schema_pkg_apis_meta_v1_Table(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "Table is a tabular representation of a set of API resources. The server transforms the object into a set of preferred columns for quickly reviewing the objects.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "metadata": { + SchemaProps: spec.SchemaProps{ + Description: "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Default: map[string]interface{}{}, + Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), + }, + }, + "columnDefinitions": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "columnDefinitions describes each column in the returned items array. The number of cells per row will always match the number of column definitions.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(metav1.TableColumnDefinition{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "rows": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "rows is the list of items in the table.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(metav1.TableRow{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + }, + Required: []string{"columnDefinitions", "rows"}, + }, + }, + Dependencies: []string{ + metav1.ListMeta{}.OpenAPIModelName(), metav1.TableColumnDefinition{}.OpenAPIModelName(), metav1.TableRow{}.OpenAPIModelName()}, + } +} + +func schema_pkg_apis_meta_v1_TableColumnDefinition(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "TableColumnDefinition contains information about a column returned in the Table.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "name": { + SchemaProps: spec.SchemaProps{ + Description: "name is a human readable name for the column.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "type": { + SchemaProps: spec.SchemaProps{ + Description: "type is an OpenAPI type definition for this column, such as number, integer, string, or array. See https://github.com/OAI/OpenAPI-Specification/blob/master/versions/2.0.md#data-types for more.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "format": { + SchemaProps: spec.SchemaProps{ + Description: "format is an optional OpenAPI type modifier for this column. A format modifies the type and imposes additional rules, like date or time formatting for a string. The 'name' format is applied to the primary identifier column which has type 'string' to assist in clients identifying column is the resource name. See https://github.com/OAI/OpenAPI-Specification/blob/master/versions/2.0.md#data-types for more.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "description": { + SchemaProps: spec.SchemaProps{ + Description: "description is a human readable description of this column.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "priority": { + SchemaProps: spec.SchemaProps{ + Description: "priority is an integer defining the relative importance of this column compared to others. Lower numbers are considered higher priority. Columns that may be omitted in limited space scenarios should be given a higher priority.", + Default: 0, + Type: []string{"integer"}, + Format: "int32", + }, + }, + }, + Required: []string{"name", "type", "format", "description", "priority"}, + }, + }, + } +} + +func schema_pkg_apis_meta_v1_TableOptions(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "TableOptions are used when a Table is requested by the caller.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "includeObject": { + SchemaProps: spec.SchemaProps{ + Description: "includeObject decides whether to include each object along with its columnar information. Specifying \"None\" will return no object, specifying \"Object\" will return the full object contents, and specifying \"Metadata\" (the default) will return the object's metadata in the PartialObjectMetadata kind in version v1beta1 of the meta.k8s.io API group.", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + } +} + +func schema_pkg_apis_meta_v1_TableRow(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "TableRow is an individual row in a table.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "cells": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "cells will be as wide as the column definitions array and may contain strings, numbers (float64 or int64), booleans, simple maps, lists, or null. See the type field of the column definition for a more detailed description.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Format: "", + }, + }, + }, + }, + }, + "conditions": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "conditions describe additional status of a row that are relevant for a human user. These conditions apply to the row, not to the object, and will be specific to table output. The only defined condition type is 'Completed', for a row that indicates a resource that has run to completion and can be given less visual priority.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(metav1.TableRowCondition{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + "object": { + SchemaProps: spec.SchemaProps{ + Description: "This field contains the requested additional information about each object based on the includeObject policy when requesting the Table. If \"None\", this field is empty, if \"Object\" this will be the default serialization of the object for the current API version, and if \"Metadata\" (the default) will contain the object metadata. Check the returned kind and apiVersion of the object before parsing. The media type of the object will always match the enclosing list - if this as a JSON table, these will be JSON encoded objects.", + Ref: ref(runtime.RawExtension{}.OpenAPIModelName()), + }, + }, + }, + Required: []string{"cells"}, + }, + }, + Dependencies: []string{ + metav1.TableRowCondition{}.OpenAPIModelName(), runtime.RawExtension{}.OpenAPIModelName()}, + } +} + +func schema_pkg_apis_meta_v1_TableRowCondition(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "TableRowCondition allows a row to be marked with additional information.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "type": { + SchemaProps: spec.SchemaProps{ + Description: "Type of row condition. The only defined value is 'Completed' indicating that the object this row represents has reached a completed state and may be given less visual priority than other rows. Clients are not required to honor any conditions but should be consistent where possible about handling the conditions.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "status": { + SchemaProps: spec.SchemaProps{ + Description: "Status of the condition, one of True, False, Unknown.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "reason": { + SchemaProps: spec.SchemaProps{ + Description: "(brief) machine readable reason for the condition's last transition.", + Type: []string{"string"}, + Format: "", + }, + }, + "message": { + SchemaProps: spec.SchemaProps{ + Description: "Human readable message indicating details about last transition.", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"type", "status"}, + }, + }, + } +} + +func schema_pkg_apis_meta_v1_Time(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "Time is a wrapper around time.Time which supports correct marshaling to YAML and JSON. Wrappers are provided for many of the factory methods that the time package offers.", + Type: metav1.Time{}.OpenAPISchemaType(), + Format: metav1.Time{}.OpenAPISchemaFormat(), + }, + }, + } +} + +func schema_pkg_apis_meta_v1_Timestamp(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "Timestamp is a struct that is equivalent to Time, but intended for protobuf marshalling/unmarshalling. It is generated into a serialization that matches Time. Do not use in Go structs.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "seconds": { + SchemaProps: spec.SchemaProps{ + Description: "Represents seconds of UTC time since Unix epoch 1970-01-01T00:00:00Z. Must be from 0001-01-01T00:00:00Z to 9999-12-31T23:59:59Z inclusive.", + Default: 0, + Type: []string{"integer"}, + Format: "int64", + }, + }, + "nanos": { + SchemaProps: spec.SchemaProps{ + Description: "Non-negative fractions of a second at nanosecond resolution. Negative second values with fractions must still have non-negative nanos values that count forward in time. Must be from 0 to 999,999,999 inclusive. This field may be limited in precision depending on context.", + Default: 0, + Type: []string{"integer"}, + Format: "int32", + }, + }, + }, + Required: []string{"seconds", "nanos"}, + }, + }, + } +} + +func schema_pkg_apis_meta_v1_TypeMeta(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "TypeMeta describes an individual object in an API response or request with strings representing the type of the object and its API schema version. Structures that are versioned or persisted should inline TypeMeta.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + } +} + +func schema_pkg_apis_meta_v1_UpdateOptions(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "UpdateOptions may be provided when updating an API object. All fields in UpdateOptions should also be present in PatchOptions.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "dryRun": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + "fieldManager": { + SchemaProps: spec.SchemaProps{ + Description: "fieldManager is a name associated with the actor or entity that is making these changes. The value must be less than or 128 characters long, and only contain printable characters, as defined by https://golang.org/pkg/unicode/#IsPrint.", + Type: []string{"string"}, + Format: "", + }, + }, + "fieldValidation": { + SchemaProps: spec.SchemaProps{ + Description: "fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + } +} + +func schema_pkg_apis_meta_v1_WatchEvent(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "Event represents a single event to a watched resource.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "type": { + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "object": { + SchemaProps: spec.SchemaProps{ + Description: "Object is:\n * If Type is Added or Modified: the new state of the object.\n * If Type is Deleted: the state of the object immediately before deletion.\n * If Type is Error: *Status is recommended; other types may make sense\n depending on context.", + Ref: ref(runtime.RawExtension{}.OpenAPIModelName()), + }, + }, + }, + Required: []string{"type", "object"}, + }, + }, + Dependencies: []string{ + runtime.RawExtension{}.OpenAPIModelName()}, + } +} + +func schema_k8sio_apimachinery_pkg_runtime_RawExtension(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "RawExtension is used to hold extensions in external versions.\n\nTo use this, make a field which has RawExtension as its type in your external, versioned struct, and Object in your internal struct. You also need to register your various plugin types.\n\n// Internal package:\n\n\ttype MyAPIObject struct {\n\t\truntime.TypeMeta `json:\",inline\"`\n\t\tMyPlugin runtime.Object `json:\"myPlugin\"`\n\t}\n\n\ttype PluginA struct {\n\t\tAOption string `json:\"aOption\"`\n\t}\n\n// External package:\n\n\ttype MyAPIObject struct {\n\t\truntime.TypeMeta `json:\",inline\"`\n\t\tMyPlugin runtime.RawExtension `json:\"myPlugin\"`\n\t}\n\n\ttype PluginA struct {\n\t\tAOption string `json:\"aOption\"`\n\t}\n\n// On the wire, the JSON will look something like this:\n\n\t{\n\t\t\"kind\":\"MyAPIObject\",\n\t\t\"apiVersion\":\"v1\",\n\t\t\"myPlugin\": {\n\t\t\t\"kind\":\"PluginA\",\n\t\t\t\"aOption\":\"foo\",\n\t\t},\n\t}\n\nSo what happens? Decode first uses json or yaml to unmarshal the serialized data into your external MyAPIObject. That causes the raw JSON to be stored, but not unpacked. The next step is to copy (using pkg/conversion) into the internal struct. The runtime package's DefaultScheme has conversion functions installed which will unpack the JSON stored in RawExtension, turning it into the correct object type, and storing it in the Object. (TODO: In the case where the object is of an unknown type, a runtime.Unknown object will be created and stored.)", + Type: []string{"object"}, + }, + }, + } +} + +func schema_k8sio_apimachinery_pkg_runtime_TypeMeta(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "TypeMeta is shared by all top level objects. The proper way to use it is to inline it in your type, like this:\n\n\ttype MyAwesomeAPIObject struct {\n\t runtime.TypeMeta `json:\",inline\"`\n\t ... // other fields\n\t}\n\nfunc (obj *MyAwesomeAPIObject) SetGroupVersionKind(gvk *metav1.GroupVersionKind) { metav1.UpdateTypeMeta(obj,gvk) }; GroupVersionKind() *GroupVersionKind\n\nTypeMeta is provided here for convenience. You may use it directly from this package or define your own with the same fields.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Type: []string{"string"}, + Format: "", + }, + }, + "kind": { + SchemaProps: spec.SchemaProps{ + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + } +} + +func schema_k8sio_apimachinery_pkg_runtime_Unknown(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "Unknown allows api objects with unknown types to be passed-through. This can be used to deal with the API objects from a plug-in. Unknown objects still have functioning TypeMeta features-- kind, version, etc. metadata and field mutatation.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Type: []string{"string"}, + Format: "", + }, + }, + "kind": { + SchemaProps: spec.SchemaProps{ + Type: []string{"string"}, + Format: "", + }, + }, + "ContentEncoding": { + SchemaProps: spec.SchemaProps{ + Description: "ContentEncoding is encoding used to encode 'Raw' data. Unspecified means no encoding.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "ContentType": { + SchemaProps: spec.SchemaProps{ + Description: "ContentType is serialization method used to serialize 'Raw'. Unspecified means ContentTypeJSON.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"ContentEncoding", "ContentType"}, + }, + }, + } +} + +func schema_k8sio_apimachinery_pkg_version_Info(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "Info contains versioning information. how we'll want to distribute that information.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "major": { + SchemaProps: spec.SchemaProps{ + Description: "Major is the major version of the binary version", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "minor": { + SchemaProps: spec.SchemaProps{ + Description: "Minor is the minor version of the binary version", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "emulationMajor": { + SchemaProps: spec.SchemaProps{ + Description: "EmulationMajor is the major version of the emulation version", + Type: []string{"string"}, + Format: "", + }, + }, + "emulationMinor": { + SchemaProps: spec.SchemaProps{ + Description: "EmulationMinor is the minor version of the emulation version", + Type: []string{"string"}, + Format: "", + }, + }, + "minCompatibilityMajor": { + SchemaProps: spec.SchemaProps{ + Description: "MinCompatibilityMajor is the major version of the minimum compatibility version", + Type: []string{"string"}, + Format: "", + }, + }, + "minCompatibilityMinor": { + SchemaProps: spec.SchemaProps{ + Description: "MinCompatibilityMinor is the minor version of the minimum compatibility version", + Type: []string{"string"}, + Format: "", + }, + }, + "gitVersion": { + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "gitCommit": { + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "gitTreeState": { + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "buildDate": { + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "goVersion": { + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "compiler": { + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "platform": { + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"major", "minor", "gitVersion", "gitCommit", "gitTreeState", "buildDate", "goVersion", "compiler", "platform"}, + }, + }, } } diff --git a/pkg/reconcilers/target/reconciler.go b/pkg/reconcilers/target/reconciler.go index 4405dc99..b319f027 100644 --- a/pkg/reconcilers/target/reconciler.go +++ b/pkg/reconcilers/target/reconciler.go @@ -24,6 +24,7 @@ import ( pkgerrors "github.com/pkg/errors" condv1alpha1 "github.com/sdcio/config-server/apis/condition/v1alpha1" invv1alpha1 "github.com/sdcio/config-server/apis/inv/v1alpha1" + invv1alpha1apply "github.com/sdcio/config-server/pkg/generated/applyconfiguration/inv/v1alpha1" "github.com/sdcio/config-server/pkg/reconcilers" "github.com/sdcio/config-server/pkg/reconcilers/ctrlconfig" "github.com/sdcio/config-server/pkg/reconcilers/resource" @@ -34,7 +35,7 @@ import ( "sigs.k8s.io/controller-runtime/pkg/client" "sigs.k8s.io/controller-runtime/pkg/event" - invv1alpha1apply "github.com/sdcio/config-server/pkg/generated/applyconfiguration/inv/v1alpha1" + ) func init() { diff --git a/pkg/schema/gitdownloader.go b/pkg/schema/gitdownloader.go index 52f0767c..8d7ee447 100644 --- a/pkg/schema/gitdownloader.go +++ b/pkg/schema/gitdownloader.go @@ -45,7 +45,7 @@ func newGitDownloader(destDir, namespace string, schemaRepo *invv1alpha1.SchemaS func (l *gitDownloader) Download(ctx context.Context) (string, error) { log := log.FromContext(ctx) - repo, err := git.NewRepo(l.schemaRepo.RepositoryURL) + repo, err := git.NewRepo(l.schemaRepo.RepoURL) if err != nil { return "", err } diff --git a/pkg/schema/loader.go b/pkg/schema/loader.go index 6bd3ba50..0ca1f57f 100644 --- a/pkg/schema/loader.go +++ b/pkg/schema/loader.go @@ -144,7 +144,7 @@ func (r *Loader) Load(ctx context.Context, key string) ([]invv1alpha1.SchemaRepo if err != nil { errs = append(errs, err) } - repoStatuses = append(repoStatuses, invv1alpha1.SchemaRepositoryStatus{RepoURL: schemaRepo.RepositoryURL, Reference: reference}) + repoStatuses = append(repoStatuses, invv1alpha1.SchemaRepositoryStatus{RepoURL: schemaRepo.RepoURL, Reference: reference}) } err = errors.Join(errs...) @@ -160,10 +160,10 @@ func (r *Loader) download(ctx context.Context, schema *invv1alpha1.Schema, schem // for now we only use git, but in the future we can extend this to use other downloaders e.g. OCI/... downloader := newGitDownloader(r.tmpDir, schema.Namespace, schemaRepo, r.credentialResolver) - sem := r.repoMgr.GetOrAdd(schemaRepo.RepositoryURL) + sem := r.repoMgr.GetOrAdd(schemaRepo.RepoURL) // Attempt to acquire the semaphore if err := sem.Acquire(ctx, 1); err != nil { - return "", fmt.Errorf("failed to acquire semaphore for %s: %w", schemaRepo.RepositoryURL, err) + return "", fmt.Errorf("failed to acquire semaphore for %s: %w", schemaRepo.RepoURL, err) } defer sem.Release(1) @@ -172,7 +172,7 @@ func (r *Loader) download(ctx context.Context, schema *invv1alpha1.Schema, schem return "", err } - localPath, err := downloader.LocalPath(schemaRepo.RepositoryURL) + localPath, err := downloader.LocalPath(schemaRepo.RepoURL) if err != nil { return "", err } diff --git a/pkg/sdc/target/manager/deviation_watcher.go b/pkg/sdc/target/manager/deviation_watcher.go index 0d9eed26..72526992 100644 --- a/pkg/sdc/target/manager/deviation_watcher.go +++ b/pkg/sdc/target/manager/deviation_watcher.go @@ -40,27 +40,27 @@ import ( const ( unManagedConfigDeviation = "__" - fieldManagerDeviation = "ConfigController" + fieldManagerDeviation = "ConfigController" ) type DeviationWatcher struct { - key storebackend.Key // target key - client client.Client // k8 client - dsclient dsclient.Client // datastore client + key storebackend.Key // target key + client client.Client // k8 client + dsclient dsclient.Client // datastore client m sync.RWMutex cancel context.CancelFunc } func NewDeviationWatcher( - key storebackend.Key, - client client.Client, + key storebackend.Key, + client client.Client, dsclient dsclient.Client, ) *DeviationWatcher { return &DeviationWatcher{ - key: key, - client: client, - dsclient: dsclient, + key: key, + client: client, + dsclient: dsclient, } } @@ -138,11 +138,11 @@ func (r *DeviationWatcher) start(ctx context.Context) { if started { log.Error("protocol violation start on start") /* - if err := stream.CloseSend(); err != nil { - log.Error("stream failed", "err", err) - } // to check if this works on the client side to inform the server to stop sending - stream = nil - time.Sleep(time.Second * 1) //- resilience for server crash + if err := stream.CloseSend(); err != nil { + log.Error("stream failed", "err", err) + } // to check if this works on the client side to inform the server to stop sending + stream = nil + time.Sleep(time.Second * 1) //- resilience for server crash */ continue } @@ -155,11 +155,11 @@ func (r *DeviationWatcher) start(ctx context.Context) { if !started { log.Error("protocol violation update without start") /* - if err := stream.CloseSend(); err != nil { - log.Error("stream failed", "err", err) - } // to check if this works on the client side to inform the server to stop sending - stream = nil - time.Sleep(time.Second * 1) //- resilience for server crash + if err := stream.CloseSend(); err != nil { + log.Error("stream failed", "err", err) + } // to check if this works on the client side to inform the server to stop sending + stream = nil + time.Sleep(time.Second * 1) //- resilience for server crash */ continue } @@ -183,11 +183,11 @@ func (r *DeviationWatcher) start(ctx context.Context) { log.Error("protocol violation end without start") /* - if err := stream.CloseSend(); err != nil { - log.Error("stream failed", "err", err) - } // to check if this works on the client side to inform the server to stop sending - stream = nil - time.Sleep(time.Second * 1) //- resilience for server crash + if err := stream.CloseSend(); err != nil { + log.Error("stream failed", "err", err) + } // to check if this works on the client side to inform the server to stop sending + stream = nil + time.Sleep(time.Second * 1) //- resilience for server crash */ continue } @@ -257,7 +257,6 @@ func (r *DeviationWatcher) processConfigDeviations( } } - func (r *DeviationWatcher) clearTargetDeviation( ctx context.Context, ) { @@ -270,9 +269,9 @@ func (r *DeviationWatcher) clearTargetDeviation( return } // If already clear, do nothing (avoids useless writes) - if len(deviation.Spec.Deviations) == 0 { - return - } + if len(deviation.Spec.Deviations) == 0 { + return + } log.Info("clear deviations", "nsn", nsn) @@ -305,7 +304,7 @@ func ConvertSdcpbDeviations2ConfigDeviations(ctx context.Context, devs []*sdcpb. deviations = append(deviations, configv1alpha1.ConfigDeviation{ Path: dev.GetPath().ToXPath(false), DesiredValue: desiredValue, - CurrentValue: currentValue, + ActualValue: currentValue, Reason: dev.GetReason().String(), }) @@ -325,7 +324,6 @@ func getDeviationString(val *sdcpb.TypedValue) (*string, error) { return v, nil } - func configDeviationsToApply(devs []configv1alpha1.ConfigDeviation) []*configv1alpha1apply.ConfigDeviationApplyConfiguration { result := make([]*configv1alpha1apply.ConfigDeviationApplyConfiguration, 0, len(devs)) for _, d := range devs { @@ -335,10 +333,10 @@ func configDeviationsToApply(devs []configv1alpha1.ConfigDeviation) []*configv1a if d.DesiredValue != nil { a = a.WithDesiredValue(*d.DesiredValue) } - if d.CurrentValue != nil { - a = a.WithCurrentValue(*d.CurrentValue) + if d.ActualValue != nil { + a = a.WithActualValue(*d.ActualValue) } result = append(result, a) } return result -} \ No newline at end of file +} diff --git a/pkg/sdc/target/manager/runtime.go b/pkg/sdc/target/manager/runtime.go index 3f943972..4fd98295 100644 --- a/pkg/sdc/target/manager/runtime.go +++ b/pkg/sdc/target/manager/runtime.go @@ -23,7 +23,6 @@ import ( "sync" "time" - //"github.com/henderiw/logger/log" "github.com/henderiw/apiserver-store/pkg/storebackend" "github.com/henderiw/logger/log" condv1alpha1 "github.com/sdcio/config-server/apis/condition/v1alpha1" diff --git a/pkg/workspace/loader.go b/pkg/workspace/loader.go index 01fe62b1..2ca78314 100644 --- a/pkg/workspace/loader.go +++ b/pkg/workspace/loader.go @@ -48,7 +48,7 @@ func NewLoader(workspaceDir string, credentialResolver auth.CredentialResolver) func (r *Loader) EnsureCommit(ctx context.Context, workspace *invv1alpha1.Workspace) (string, error) { log := log.FromContext(ctx) - repo, err := git.NewRepo(workspace.Spec.RepositoryURL) + repo, err := git.NewRepo(workspace.Spec.RepoURL) if err != nil { return "", err } diff --git a/pkg/workspace/reader.go b/pkg/workspace/reader.go index 4d861a5e..b1724bba 100644 --- a/pkg/workspace/reader.go +++ b/pkg/workspace/reader.go @@ -50,7 +50,7 @@ func NewReader(workspaceDir string, credentialResolver auth.CredentialResolver) func (r *Reader) GetConfigs(ctx context.Context, rollout *invv1alpha1.Rollout) (storebackend.Storer[storebackend.Storer[*config.Config]], error) { log := log.FromContext(ctx) - repo, err := git.NewRepo(rollout.Spec.RepositoryURL) + repo, err := git.NewRepo(rollout.Spec.RepoURL) if err != nil { return nil, err } From 7131c6763b35a55e20954364d2006d299dfab084 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Wed, 18 Feb 2026 18:38:14 +0100 Subject: [PATCH 021/135] updated builder --- go.mod | 2 +- go.sum | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/go.mod b/go.mod index 1cab44df..2b3cc9a2 100644 --- a/go.mod +++ b/go.mod @@ -8,7 +8,7 @@ require ( github.com/gogo/protobuf v1.3.2 github.com/google/go-cmp v0.7.0 github.com/google/uuid v1.6.0 - github.com/henderiw/apiserver-builder v0.0.6-0.20260218145442-77ce7b3713a9 + github.com/henderiw/apiserver-builder v0.0.6-0.20260218173622-b3b6eb894826 github.com/henderiw/apiserver-store v0.0.3 github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c github.com/henderiw/logger v0.0.0-20230911123436-8655829b1abe diff --git a/go.sum b/go.sum index 6f5be312..b948f6a8 100644 --- a/go.sum +++ b/go.sum @@ -171,6 +171,8 @@ github.com/grpc-ecosystem/grpc-gateway/v2 v2.27.3 h1:NmZ1PKzSTQbuGHw9DGPFomqkkLW github.com/grpc-ecosystem/grpc-gateway/v2 v2.27.3/go.mod h1:zQrxl1YP88HQlA6i9c63DSVPFklWpGX4OWAc9bFuaH4= github.com/henderiw/apiserver-builder v0.0.6-0.20260218145442-77ce7b3713a9 h1:sFdegJDnvir5IbpVm5cWEHIKq25JfKk3JqAeW3kMmKU= github.com/henderiw/apiserver-builder v0.0.6-0.20260218145442-77ce7b3713a9/go.mod h1:n5ApsFfaK3h5B1WVEnZ29erGuMV0ovPA0/ErcXeQet0= +github.com/henderiw/apiserver-builder v0.0.6-0.20260218173622-b3b6eb894826 h1:YED7ifaxzOetKDElzsOm+EUucMWfhZ6Oye4qcr6oe6U= +github.com/henderiw/apiserver-builder v0.0.6-0.20260218173622-b3b6eb894826/go.mod h1:n5ApsFfaK3h5B1WVEnZ29erGuMV0ovPA0/ErcXeQet0= github.com/henderiw/apiserver-store v0.0.3 h1:cUNzimOvxVKsw+/kj+7IkI/GnRuFlziwCc3AsfYo9zM= github.com/henderiw/apiserver-store v0.0.3/go.mod h1:RuXLMHJwszn6LXgL6fO9fxMC7AW5wAc4zOddnnZpkKI= github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c h1:nFnCNyRV1Ej/zqV/gn8UnFESkoPUXhwpUCZyhSYGSYA= From d6c8d462e512e2e595256032664686b47d7d3359 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Wed, 18 Feb 2026 18:51:42 +0100 Subject: [PATCH 022/135] added new builder --- go.mod | 2 +- go.sum | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/go.mod b/go.mod index 2b3cc9a2..b9670046 100644 --- a/go.mod +++ b/go.mod @@ -8,7 +8,7 @@ require ( github.com/gogo/protobuf v1.3.2 github.com/google/go-cmp v0.7.0 github.com/google/uuid v1.6.0 - github.com/henderiw/apiserver-builder v0.0.6-0.20260218173622-b3b6eb894826 + github.com/henderiw/apiserver-builder v0.0.6-0.20260218174843-63e42f865431 github.com/henderiw/apiserver-store v0.0.3 github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c github.com/henderiw/logger v0.0.0-20230911123436-8655829b1abe diff --git a/go.sum b/go.sum index b948f6a8..9c8ba031 100644 --- a/go.sum +++ b/go.sum @@ -173,6 +173,8 @@ github.com/henderiw/apiserver-builder v0.0.6-0.20260218145442-77ce7b3713a9 h1:sF github.com/henderiw/apiserver-builder v0.0.6-0.20260218145442-77ce7b3713a9/go.mod h1:n5ApsFfaK3h5B1WVEnZ29erGuMV0ovPA0/ErcXeQet0= github.com/henderiw/apiserver-builder v0.0.6-0.20260218173622-b3b6eb894826 h1:YED7ifaxzOetKDElzsOm+EUucMWfhZ6Oye4qcr6oe6U= github.com/henderiw/apiserver-builder v0.0.6-0.20260218173622-b3b6eb894826/go.mod h1:n5ApsFfaK3h5B1WVEnZ29erGuMV0ovPA0/ErcXeQet0= +github.com/henderiw/apiserver-builder v0.0.6-0.20260218174843-63e42f865431 h1:lb5oSbI3hb3qLzqfAMUP/kN5EHBfgq+h6EKsEyYZlQk= +github.com/henderiw/apiserver-builder v0.0.6-0.20260218174843-63e42f865431/go.mod h1:n5ApsFfaK3h5B1WVEnZ29erGuMV0ovPA0/ErcXeQet0= github.com/henderiw/apiserver-store v0.0.3 h1:cUNzimOvxVKsw+/kj+7IkI/GnRuFlziwCc3AsfYo9zM= github.com/henderiw/apiserver-store v0.0.3/go.mod h1:RuXLMHJwszn6LXgL6fO9fxMC7AW5wAc4zOddnnZpkKI= github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c h1:nFnCNyRV1Ej/zqV/gn8UnFESkoPUXhwpUCZyhSYGSYA= From 48491ca8f664cafdae46b78fb46a2df01b2b2f64 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Wed, 18 Feb 2026 19:11:40 +0100 Subject: [PATCH 023/135] added new builder --- go.mod | 2 +- go.sum | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/go.mod b/go.mod index b9670046..3a5cc90a 100644 --- a/go.mod +++ b/go.mod @@ -8,7 +8,7 @@ require ( github.com/gogo/protobuf v1.3.2 github.com/google/go-cmp v0.7.0 github.com/google/uuid v1.6.0 - github.com/henderiw/apiserver-builder v0.0.6-0.20260218174843-63e42f865431 + github.com/henderiw/apiserver-builder v0.0.6-0.20260218181021-8c6f185f97b7 github.com/henderiw/apiserver-store v0.0.3 github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c github.com/henderiw/logger v0.0.0-20230911123436-8655829b1abe diff --git a/go.sum b/go.sum index 9c8ba031..bc4395d9 100644 --- a/go.sum +++ b/go.sum @@ -175,6 +175,8 @@ github.com/henderiw/apiserver-builder v0.0.6-0.20260218173622-b3b6eb894826 h1:YE github.com/henderiw/apiserver-builder v0.0.6-0.20260218173622-b3b6eb894826/go.mod h1:n5ApsFfaK3h5B1WVEnZ29erGuMV0ovPA0/ErcXeQet0= github.com/henderiw/apiserver-builder v0.0.6-0.20260218174843-63e42f865431 h1:lb5oSbI3hb3qLzqfAMUP/kN5EHBfgq+h6EKsEyYZlQk= github.com/henderiw/apiserver-builder v0.0.6-0.20260218174843-63e42f865431/go.mod h1:n5ApsFfaK3h5B1WVEnZ29erGuMV0ovPA0/ErcXeQet0= +github.com/henderiw/apiserver-builder v0.0.6-0.20260218181021-8c6f185f97b7 h1:lV+r00Ydcp60oiuxzoSQLMsGv4AsP4tj11+4gfm5isk= +github.com/henderiw/apiserver-builder v0.0.6-0.20260218181021-8c6f185f97b7/go.mod h1:n5ApsFfaK3h5B1WVEnZ29erGuMV0ovPA0/ErcXeQet0= github.com/henderiw/apiserver-store v0.0.3 h1:cUNzimOvxVKsw+/kj+7IkI/GnRuFlziwCc3AsfYo9zM= github.com/henderiw/apiserver-store v0.0.3/go.mod h1:RuXLMHJwszn6LXgL6fO9fxMC7AW5wAc4zOddnnZpkKI= github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c h1:nFnCNyRV1Ej/zqV/gn8UnFESkoPUXhwpUCZyhSYGSYA= From 180083d48dd6e04f81dfa82cad7d667d83a3f2c4 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Wed, 18 Feb 2026 19:27:45 +0100 Subject: [PATCH 024/135] added new builder --- go.mod | 2 +- go.sum | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/go.mod b/go.mod index 3a5cc90a..76efb091 100644 --- a/go.mod +++ b/go.mod @@ -8,7 +8,7 @@ require ( github.com/gogo/protobuf v1.3.2 github.com/google/go-cmp v0.7.0 github.com/google/uuid v1.6.0 - github.com/henderiw/apiserver-builder v0.0.6-0.20260218181021-8c6f185f97b7 + github.com/henderiw/apiserver-builder v0.0.6-0.20260218182703-f5e7d2224819 github.com/henderiw/apiserver-store v0.0.3 github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c github.com/henderiw/logger v0.0.0-20230911123436-8655829b1abe diff --git a/go.sum b/go.sum index bc4395d9..d67afe91 100644 --- a/go.sum +++ b/go.sum @@ -177,6 +177,8 @@ github.com/henderiw/apiserver-builder v0.0.6-0.20260218174843-63e42f865431 h1:lb github.com/henderiw/apiserver-builder v0.0.6-0.20260218174843-63e42f865431/go.mod h1:n5ApsFfaK3h5B1WVEnZ29erGuMV0ovPA0/ErcXeQet0= github.com/henderiw/apiserver-builder v0.0.6-0.20260218181021-8c6f185f97b7 h1:lV+r00Ydcp60oiuxzoSQLMsGv4AsP4tj11+4gfm5isk= github.com/henderiw/apiserver-builder v0.0.6-0.20260218181021-8c6f185f97b7/go.mod h1:n5ApsFfaK3h5B1WVEnZ29erGuMV0ovPA0/ErcXeQet0= +github.com/henderiw/apiserver-builder v0.0.6-0.20260218182703-f5e7d2224819 h1:dQt2/p4v/i0RYPvAn4GLZwbWHSgqOW7eH9pPWKf6H50= +github.com/henderiw/apiserver-builder v0.0.6-0.20260218182703-f5e7d2224819/go.mod h1:n5ApsFfaK3h5B1WVEnZ29erGuMV0ovPA0/ErcXeQet0= github.com/henderiw/apiserver-store v0.0.3 h1:cUNzimOvxVKsw+/kj+7IkI/GnRuFlziwCc3AsfYo9zM= github.com/henderiw/apiserver-store v0.0.3/go.mod h1:RuXLMHJwszn6LXgL6fO9fxMC7AW5wAc4zOddnnZpkKI= github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c h1:nFnCNyRV1Ej/zqV/gn8UnFESkoPUXhwpUCZyhSYGSYA= From d6bf135c4621a11dffcb94795e759b01ae05873a Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Wed, 18 Feb 2026 19:50:51 +0100 Subject: [PATCH 025/135] updated openapigen --- pkg/generated/openapi/zz_generated.openapi.go | 63 ++++++++++++++++--- 1 file changed, 55 insertions(+), 8 deletions(-) diff --git a/pkg/generated/openapi/zz_generated.openapi.go b/pkg/generated/openapi/zz_generated.openapi.go index 1d6cba6f..5537c321 100644 --- a/pkg/generated/openapi/zz_generated.openapi.go +++ b/pkg/generated/openapi/zz_generated.openapi.go @@ -579,10 +579,17 @@ func schema_config_server_apis_config_v1alpha1_Config(ref common.ReferenceCallba }, }, }, + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-group-version-kind": []interface{}{ + map[string]interface{}{"group": "config.sdcio.dev", "kind": "Config", "version": "v1alpha1"}, + }, + }, + }, }, Dependencies: []string{ - "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigSpec", "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigStatus", metav1.ObjectMeta{}.OpenAPIModelName()}, - } + "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigSpec", "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigStatus", metav1.ObjectMeta{}.OpenAPIModelName()}, + } } func schema_config_server_apis_config_v1alpha1_ConfigBlame(ref common.ReferenceCallback) common.OpenAPIDefinition { @@ -626,8 +633,16 @@ func schema_config_server_apis_config_v1alpha1_ConfigBlame(ref common.ReferenceC }, }, }, + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-group-version-kind": []interface{}{ + map[string]interface{}{"group": "config.sdcio.dev", "kind": "ConfigBlame", "version": "v1alpha1"}, + }, + }, + }, }, - Dependencies: []string{ + + Dependencies: []string{ "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigBlameSpec", "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigBlameStatus", metav1.ObjectMeta{}.OpenAPIModelName()}, } } @@ -870,8 +885,17 @@ func schema_config_server_apis_config_v1alpha1_ConfigSet(ref common.ReferenceCal }, }, }, + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-group-version-kind": []interface{}{ + map[string]interface{}{"group": "config.sdcio.dev", "kind": "ConfigSet", "version": "v1alpha1"}, + }, + }, + }, }, - Dependencies: []string{ + + + Dependencies: []string{ "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigSetSpec", "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigSetStatus", metav1.ObjectMeta{}.OpenAPIModelName()}, } } @@ -1228,10 +1252,17 @@ func schema_config_server_apis_config_v1alpha1_Deviation(ref common.ReferenceCal }, }, }, + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-group-version-kind": []interface{}{ + map[string]interface{}{"group": "config.sdcio.dev", "kind": "Deviation", "version": "v1alpha1"}, + }, + }, + }, }, Dependencies: []string{ - "github.com/sdcio/config-server/apis/config/v1alpha1.DeviationSpec", "github.com/sdcio/config-server/apis/config/v1alpha1.DeviationStatus", metav1.ObjectMeta{}.OpenAPIModelName()}, - } + "github.com/sdcio/config-server/apis/config/v1alpha1.DeviationSpec", "github.com/sdcio/config-server/apis/config/v1alpha1.DeviationStatus", metav1.ObjectMeta{}.OpenAPIModelName()}, + } } func schema_config_server_apis_config_v1alpha1_DeviationList(ref common.ReferenceCallback) common.OpenAPIDefinition { @@ -1420,8 +1451,16 @@ func schema_config_server_apis_config_v1alpha1_RunningConfig(ref common.Referenc }, }, }, + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-group-version-kind": []interface{}{ + map[string]interface{}{"group": "config.sdcio.dev", "kind": "RunningConfig", "version": "v1alpha1"}, + }, + }, + }, }, - Dependencies: []string{ + + Dependencies: []string{ "github.com/sdcio/config-server/apis/config/v1alpha1.RunningConfigSpec", "github.com/sdcio/config-server/apis/config/v1alpha1.RunningConfigStatus", metav1.ObjectMeta{}.OpenAPIModelName()}, } } @@ -1548,8 +1587,16 @@ func schema_config_server_apis_config_v1alpha1_SensitiveConfig(ref common.Refere }, }, }, + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-group-version-kind": []interface{}{ + map[string]interface{}{"group": "config.sdcio.dev", "kind": "SensitiveConfig", "version": "v1alpha1"}, + }, + }, + }, }, - Dependencies: []string{ + + Dependencies: []string{ "github.com/sdcio/config-server/apis/config/v1alpha1.SensitiveConfigSpec", "github.com/sdcio/config-server/apis/config/v1alpha1.SensitiveConfigStatus", metav1.ObjectMeta{}.OpenAPIModelName()}, } } From 22cf424730d114288bfca0862c890567c35519f9 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Wed, 18 Feb 2026 20:10:20 +0100 Subject: [PATCH 026/135] updated builder --- go.mod | 2 +- go.sum | 2 ++ tools/apiserver-runtime-gen/main.go | 2 +- 3 files changed, 4 insertions(+), 2 deletions(-) diff --git a/go.mod b/go.mod index 76efb091..43056b28 100644 --- a/go.mod +++ b/go.mod @@ -8,7 +8,7 @@ require ( github.com/gogo/protobuf v1.3.2 github.com/google/go-cmp v0.7.0 github.com/google/uuid v1.6.0 - github.com/henderiw/apiserver-builder v0.0.6-0.20260218182703-f5e7d2224819 + github.com/henderiw/apiserver-builder v0.0.6-0.20260218190858-04a143226229 github.com/henderiw/apiserver-store v0.0.3 github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c github.com/henderiw/logger v0.0.0-20230911123436-8655829b1abe diff --git a/go.sum b/go.sum index d67afe91..f6fca245 100644 --- a/go.sum +++ b/go.sum @@ -179,6 +179,8 @@ github.com/henderiw/apiserver-builder v0.0.6-0.20260218181021-8c6f185f97b7 h1:lV github.com/henderiw/apiserver-builder v0.0.6-0.20260218181021-8c6f185f97b7/go.mod h1:n5ApsFfaK3h5B1WVEnZ29erGuMV0ovPA0/ErcXeQet0= github.com/henderiw/apiserver-builder v0.0.6-0.20260218182703-f5e7d2224819 h1:dQt2/p4v/i0RYPvAn4GLZwbWHSgqOW7eH9pPWKf6H50= github.com/henderiw/apiserver-builder v0.0.6-0.20260218182703-f5e7d2224819/go.mod h1:n5ApsFfaK3h5B1WVEnZ29erGuMV0ovPA0/ErcXeQet0= +github.com/henderiw/apiserver-builder v0.0.6-0.20260218190858-04a143226229 h1:GKxfCwGcRPhYuQs4wic1xyCMxYIu1QkqOVKVdsa+kpk= +github.com/henderiw/apiserver-builder v0.0.6-0.20260218190858-04a143226229/go.mod h1:n5ApsFfaK3h5B1WVEnZ29erGuMV0ovPA0/ErcXeQet0= github.com/henderiw/apiserver-store v0.0.3 h1:cUNzimOvxVKsw+/kj+7IkI/GnRuFlziwCc3AsfYo9zM= github.com/henderiw/apiserver-store v0.0.3/go.mod h1:RuXLMHJwszn6LXgL6fO9fxMC7AW5wAc4zOddnnZpkKI= github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c h1:nFnCNyRV1Ej/zqV/gn8UnFESkoPUXhwpUCZyhSYGSYA= diff --git a/tools/apiserver-runtime-gen/main.go b/tools/apiserver-runtime-gen/main.go index 46b0460d..6341d52e 100644 --- a/tools/apiserver-runtime-gen/main.go +++ b/tools/apiserver-runtime-gen/main.go @@ -164,7 +164,7 @@ func doGen() error { "k8s.io/apimachinery/pkg/version", } cmdArgs = append(cmdArgs, typeVersions...) - err := run(getCmdSimple("openapi-gen", cmdArgs...)) + err := run(getCmdSimple("bin/openapi-gen", cmdArgs...)) if err != nil { return err From 9906c7a711780ff44c34269669f2de3de9743528 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Wed, 18 Feb 2026 20:35:05 +0100 Subject: [PATCH 027/135] updated builder --- go.mod | 2 +- go.sum | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/go.mod b/go.mod index 43056b28..277ba20f 100644 --- a/go.mod +++ b/go.mod @@ -8,7 +8,7 @@ require ( github.com/gogo/protobuf v1.3.2 github.com/google/go-cmp v0.7.0 github.com/google/uuid v1.6.0 - github.com/henderiw/apiserver-builder v0.0.6-0.20260218190858-04a143226229 + github.com/henderiw/apiserver-builder v0.0.6-0.20260218193424-e94ea827dec5 github.com/henderiw/apiserver-store v0.0.3 github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c github.com/henderiw/logger v0.0.0-20230911123436-8655829b1abe diff --git a/go.sum b/go.sum index f6fca245..0ae3a7b8 100644 --- a/go.sum +++ b/go.sum @@ -181,6 +181,8 @@ github.com/henderiw/apiserver-builder v0.0.6-0.20260218182703-f5e7d2224819 h1:dQ github.com/henderiw/apiserver-builder v0.0.6-0.20260218182703-f5e7d2224819/go.mod h1:n5ApsFfaK3h5B1WVEnZ29erGuMV0ovPA0/ErcXeQet0= github.com/henderiw/apiserver-builder v0.0.6-0.20260218190858-04a143226229 h1:GKxfCwGcRPhYuQs4wic1xyCMxYIu1QkqOVKVdsa+kpk= github.com/henderiw/apiserver-builder v0.0.6-0.20260218190858-04a143226229/go.mod h1:n5ApsFfaK3h5B1WVEnZ29erGuMV0ovPA0/ErcXeQet0= +github.com/henderiw/apiserver-builder v0.0.6-0.20260218193424-e94ea827dec5 h1:fFhkkPdMUFc9z8bP93UrdT+Uz2WtuG9bZFGz5fOEIyI= +github.com/henderiw/apiserver-builder v0.0.6-0.20260218193424-e94ea827dec5/go.mod h1:n5ApsFfaK3h5B1WVEnZ29erGuMV0ovPA0/ErcXeQet0= github.com/henderiw/apiserver-store v0.0.3 h1:cUNzimOvxVKsw+/kj+7IkI/GnRuFlziwCc3AsfYo9zM= github.com/henderiw/apiserver-store v0.0.3/go.mod h1:RuXLMHJwszn6LXgL6fO9fxMC7AW5wAc4zOddnnZpkKI= github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c h1:nFnCNyRV1Ej/zqV/gn8UnFESkoPUXhwpUCZyhSYGSYA= From a1cad500ef5d72c77e20cf66eb0b47ef4e482b15 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Wed, 18 Feb 2026 20:46:42 +0100 Subject: [PATCH 028/135] updated builder --- go.mod | 2 +- go.sum | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/go.mod b/go.mod index 277ba20f..20caa1b7 100644 --- a/go.mod +++ b/go.mod @@ -8,7 +8,7 @@ require ( github.com/gogo/protobuf v1.3.2 github.com/google/go-cmp v0.7.0 github.com/google/uuid v1.6.0 - github.com/henderiw/apiserver-builder v0.0.6-0.20260218193424-e94ea827dec5 + github.com/henderiw/apiserver-builder v0.0.6-0.20260218194554-006b0fd68e94 github.com/henderiw/apiserver-store v0.0.3 github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c github.com/henderiw/logger v0.0.0-20230911123436-8655829b1abe diff --git a/go.sum b/go.sum index 0ae3a7b8..46dfb0ec 100644 --- a/go.sum +++ b/go.sum @@ -183,6 +183,8 @@ github.com/henderiw/apiserver-builder v0.0.6-0.20260218190858-04a143226229 h1:GK github.com/henderiw/apiserver-builder v0.0.6-0.20260218190858-04a143226229/go.mod h1:n5ApsFfaK3h5B1WVEnZ29erGuMV0ovPA0/ErcXeQet0= github.com/henderiw/apiserver-builder v0.0.6-0.20260218193424-e94ea827dec5 h1:fFhkkPdMUFc9z8bP93UrdT+Uz2WtuG9bZFGz5fOEIyI= github.com/henderiw/apiserver-builder v0.0.6-0.20260218193424-e94ea827dec5/go.mod h1:n5ApsFfaK3h5B1WVEnZ29erGuMV0ovPA0/ErcXeQet0= +github.com/henderiw/apiserver-builder v0.0.6-0.20260218194554-006b0fd68e94 h1:8fFkUYhrqamV1KxC59XwzpxH0hsZv2Fs0MU1L9VfnIE= +github.com/henderiw/apiserver-builder v0.0.6-0.20260218194554-006b0fd68e94/go.mod h1:n5ApsFfaK3h5B1WVEnZ29erGuMV0ovPA0/ErcXeQet0= github.com/henderiw/apiserver-store v0.0.3 h1:cUNzimOvxVKsw+/kj+7IkI/GnRuFlziwCc3AsfYo9zM= github.com/henderiw/apiserver-store v0.0.3/go.mod h1:RuXLMHJwszn6LXgL6fO9fxMC7AW5wAc4zOddnnZpkKI= github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c h1:nFnCNyRV1Ej/zqV/gn8UnFESkoPUXhwpUCZyhSYGSYA= From 6438ac483f45718bef5a03547692dd961daaf38f Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Wed, 18 Feb 2026 21:00:08 +0100 Subject: [PATCH 029/135] updated builder --- go.mod | 2 +- go.sum | 18 ++---------------- 2 files changed, 3 insertions(+), 17 deletions(-) diff --git a/go.mod b/go.mod index 20caa1b7..8ff99765 100644 --- a/go.mod +++ b/go.mod @@ -8,7 +8,7 @@ require ( github.com/gogo/protobuf v1.3.2 github.com/google/go-cmp v0.7.0 github.com/google/uuid v1.6.0 - github.com/henderiw/apiserver-builder v0.0.6-0.20260218194554-006b0fd68e94 + github.com/henderiw/apiserver-builder v0.0.6-0.20260218195914-109e6a1935cb github.com/henderiw/apiserver-store v0.0.3 github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c github.com/henderiw/logger v0.0.0-20230911123436-8655829b1abe diff --git a/go.sum b/go.sum index 46dfb0ec..be38dd02 100644 --- a/go.sum +++ b/go.sum @@ -169,22 +169,8 @@ github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0 h1:Ovs26xHkKqVztRpIrF/92Bcuy github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0/go.mod h1:8NvIoxWQoOIhqOTXgfV/d3M/q6VIi02HzZEHgUlZvzk= github.com/grpc-ecosystem/grpc-gateway/v2 v2.27.3 h1:NmZ1PKzSTQbuGHw9DGPFomqkkLWMC+vZCkfs+FHv1Vg= github.com/grpc-ecosystem/grpc-gateway/v2 v2.27.3/go.mod h1:zQrxl1YP88HQlA6i9c63DSVPFklWpGX4OWAc9bFuaH4= -github.com/henderiw/apiserver-builder v0.0.6-0.20260218145442-77ce7b3713a9 h1:sFdegJDnvir5IbpVm5cWEHIKq25JfKk3JqAeW3kMmKU= -github.com/henderiw/apiserver-builder v0.0.6-0.20260218145442-77ce7b3713a9/go.mod h1:n5ApsFfaK3h5B1WVEnZ29erGuMV0ovPA0/ErcXeQet0= -github.com/henderiw/apiserver-builder v0.0.6-0.20260218173622-b3b6eb894826 h1:YED7ifaxzOetKDElzsOm+EUucMWfhZ6Oye4qcr6oe6U= -github.com/henderiw/apiserver-builder v0.0.6-0.20260218173622-b3b6eb894826/go.mod h1:n5ApsFfaK3h5B1WVEnZ29erGuMV0ovPA0/ErcXeQet0= -github.com/henderiw/apiserver-builder v0.0.6-0.20260218174843-63e42f865431 h1:lb5oSbI3hb3qLzqfAMUP/kN5EHBfgq+h6EKsEyYZlQk= -github.com/henderiw/apiserver-builder v0.0.6-0.20260218174843-63e42f865431/go.mod h1:n5ApsFfaK3h5B1WVEnZ29erGuMV0ovPA0/ErcXeQet0= -github.com/henderiw/apiserver-builder v0.0.6-0.20260218181021-8c6f185f97b7 h1:lV+r00Ydcp60oiuxzoSQLMsGv4AsP4tj11+4gfm5isk= -github.com/henderiw/apiserver-builder v0.0.6-0.20260218181021-8c6f185f97b7/go.mod h1:n5ApsFfaK3h5B1WVEnZ29erGuMV0ovPA0/ErcXeQet0= -github.com/henderiw/apiserver-builder v0.0.6-0.20260218182703-f5e7d2224819 h1:dQt2/p4v/i0RYPvAn4GLZwbWHSgqOW7eH9pPWKf6H50= -github.com/henderiw/apiserver-builder v0.0.6-0.20260218182703-f5e7d2224819/go.mod h1:n5ApsFfaK3h5B1WVEnZ29erGuMV0ovPA0/ErcXeQet0= -github.com/henderiw/apiserver-builder v0.0.6-0.20260218190858-04a143226229 h1:GKxfCwGcRPhYuQs4wic1xyCMxYIu1QkqOVKVdsa+kpk= -github.com/henderiw/apiserver-builder v0.0.6-0.20260218190858-04a143226229/go.mod h1:n5ApsFfaK3h5B1WVEnZ29erGuMV0ovPA0/ErcXeQet0= -github.com/henderiw/apiserver-builder v0.0.6-0.20260218193424-e94ea827dec5 h1:fFhkkPdMUFc9z8bP93UrdT+Uz2WtuG9bZFGz5fOEIyI= -github.com/henderiw/apiserver-builder v0.0.6-0.20260218193424-e94ea827dec5/go.mod h1:n5ApsFfaK3h5B1WVEnZ29erGuMV0ovPA0/ErcXeQet0= -github.com/henderiw/apiserver-builder v0.0.6-0.20260218194554-006b0fd68e94 h1:8fFkUYhrqamV1KxC59XwzpxH0hsZv2Fs0MU1L9VfnIE= -github.com/henderiw/apiserver-builder v0.0.6-0.20260218194554-006b0fd68e94/go.mod h1:n5ApsFfaK3h5B1WVEnZ29erGuMV0ovPA0/ErcXeQet0= +github.com/henderiw/apiserver-builder v0.0.6-0.20260218195914-109e6a1935cb h1:lw97lhe8rxEMR8ZNQA1dPHMt88I9LdYUgBwiqi4QdQo= +github.com/henderiw/apiserver-builder v0.0.6-0.20260218195914-109e6a1935cb/go.mod h1:n5ApsFfaK3h5B1WVEnZ29erGuMV0ovPA0/ErcXeQet0= github.com/henderiw/apiserver-store v0.0.3 h1:cUNzimOvxVKsw+/kj+7IkI/GnRuFlziwCc3AsfYo9zM= github.com/henderiw/apiserver-store v0.0.3/go.mod h1:RuXLMHJwszn6LXgL6fO9fxMC7AW5wAc4zOddnnZpkKI= github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c h1:nFnCNyRV1Ej/zqV/gn8UnFESkoPUXhwpUCZyhSYGSYA= From a8d177e9d680a4c18a7b5d7d9b34196e20b62c8a Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Wed, 18 Feb 2026 21:19:36 +0100 Subject: [PATCH 030/135] updated builder --- go.mod | 2 +- go.sum | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/go.mod b/go.mod index 8ff99765..19f3f563 100644 --- a/go.mod +++ b/go.mod @@ -8,7 +8,7 @@ require ( github.com/gogo/protobuf v1.3.2 github.com/google/go-cmp v0.7.0 github.com/google/uuid v1.6.0 - github.com/henderiw/apiserver-builder v0.0.6-0.20260218195914-109e6a1935cb + github.com/henderiw/apiserver-builder v0.0.6-0.20260218201828-653d0f7e4042 github.com/henderiw/apiserver-store v0.0.3 github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c github.com/henderiw/logger v0.0.0-20230911123436-8655829b1abe diff --git a/go.sum b/go.sum index be38dd02..17afbc18 100644 --- a/go.sum +++ b/go.sum @@ -169,8 +169,8 @@ github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0 h1:Ovs26xHkKqVztRpIrF/92Bcuy github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0/go.mod h1:8NvIoxWQoOIhqOTXgfV/d3M/q6VIi02HzZEHgUlZvzk= github.com/grpc-ecosystem/grpc-gateway/v2 v2.27.3 h1:NmZ1PKzSTQbuGHw9DGPFomqkkLWMC+vZCkfs+FHv1Vg= github.com/grpc-ecosystem/grpc-gateway/v2 v2.27.3/go.mod h1:zQrxl1YP88HQlA6i9c63DSVPFklWpGX4OWAc9bFuaH4= -github.com/henderiw/apiserver-builder v0.0.6-0.20260218195914-109e6a1935cb h1:lw97lhe8rxEMR8ZNQA1dPHMt88I9LdYUgBwiqi4QdQo= -github.com/henderiw/apiserver-builder v0.0.6-0.20260218195914-109e6a1935cb/go.mod h1:n5ApsFfaK3h5B1WVEnZ29erGuMV0ovPA0/ErcXeQet0= +github.com/henderiw/apiserver-builder v0.0.6-0.20260218201828-653d0f7e4042 h1:pyTApXvz9r/euWoFZoqzKMybafQlAjo9IDAk2uu8V0I= +github.com/henderiw/apiserver-builder v0.0.6-0.20260218201828-653d0f7e4042/go.mod h1:n5ApsFfaK3h5B1WVEnZ29erGuMV0ovPA0/ErcXeQet0= github.com/henderiw/apiserver-store v0.0.3 h1:cUNzimOvxVKsw+/kj+7IkI/GnRuFlziwCc3AsfYo9zM= github.com/henderiw/apiserver-store v0.0.3/go.mod h1:RuXLMHJwszn6LXgL6fO9fxMC7AW5wAc4zOddnnZpkKI= github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c h1:nFnCNyRV1Ej/zqV/gn8UnFESkoPUXhwpUCZyhSYGSYA= From a5d773593f4b8fb53d54cb885a8f6d38f367695e Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Wed, 18 Feb 2026 21:31:48 +0100 Subject: [PATCH 031/135] updated builder --- go.mod | 2 +- go.sum | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/go.mod b/go.mod index 19f3f563..73983f8f 100644 --- a/go.mod +++ b/go.mod @@ -8,7 +8,7 @@ require ( github.com/gogo/protobuf v1.3.2 github.com/google/go-cmp v0.7.0 github.com/google/uuid v1.6.0 - github.com/henderiw/apiserver-builder v0.0.6-0.20260218201828-653d0f7e4042 + github.com/henderiw/apiserver-builder v0.0.6-0.20260218203055-86c6dd0d1193 github.com/henderiw/apiserver-store v0.0.3 github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c github.com/henderiw/logger v0.0.0-20230911123436-8655829b1abe diff --git a/go.sum b/go.sum index 17afbc18..ae2c32a9 100644 --- a/go.sum +++ b/go.sum @@ -171,6 +171,8 @@ github.com/grpc-ecosystem/grpc-gateway/v2 v2.27.3 h1:NmZ1PKzSTQbuGHw9DGPFomqkkLW github.com/grpc-ecosystem/grpc-gateway/v2 v2.27.3/go.mod h1:zQrxl1YP88HQlA6i9c63DSVPFklWpGX4OWAc9bFuaH4= github.com/henderiw/apiserver-builder v0.0.6-0.20260218201828-653d0f7e4042 h1:pyTApXvz9r/euWoFZoqzKMybafQlAjo9IDAk2uu8V0I= github.com/henderiw/apiserver-builder v0.0.6-0.20260218201828-653d0f7e4042/go.mod h1:n5ApsFfaK3h5B1WVEnZ29erGuMV0ovPA0/ErcXeQet0= +github.com/henderiw/apiserver-builder v0.0.6-0.20260218203055-86c6dd0d1193 h1:hRlPgwRlb4i8fbAu2yfeVxw99BaaSxbEU9OdDrBm5bE= +github.com/henderiw/apiserver-builder v0.0.6-0.20260218203055-86c6dd0d1193/go.mod h1:n5ApsFfaK3h5B1WVEnZ29erGuMV0ovPA0/ErcXeQet0= github.com/henderiw/apiserver-store v0.0.3 h1:cUNzimOvxVKsw+/kj+7IkI/GnRuFlziwCc3AsfYo9zM= github.com/henderiw/apiserver-store v0.0.3/go.mod h1:RuXLMHJwszn6LXgL6fO9fxMC7AW5wAc4zOddnnZpkKI= github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c h1:nFnCNyRV1Ej/zqV/gn8UnFESkoPUXhwpUCZyhSYGSYA= From e338ec70f3cc8a7eeda49e88df54330e8fd56043 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Wed, 18 Feb 2026 21:58:00 +0100 Subject: [PATCH 032/135] updated builder --- go.mod | 2 +- go.sum | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/go.mod b/go.mod index 73983f8f..86e72b9d 100644 --- a/go.mod +++ b/go.mod @@ -8,7 +8,7 @@ require ( github.com/gogo/protobuf v1.3.2 github.com/google/go-cmp v0.7.0 github.com/google/uuid v1.6.0 - github.com/henderiw/apiserver-builder v0.0.6-0.20260218203055-86c6dd0d1193 + github.com/henderiw/apiserver-builder v0.0.6-0.20260218205721-520ac97264d3 github.com/henderiw/apiserver-store v0.0.3 github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c github.com/henderiw/logger v0.0.0-20230911123436-8655829b1abe diff --git a/go.sum b/go.sum index ae2c32a9..d60f6cd0 100644 --- a/go.sum +++ b/go.sum @@ -173,6 +173,8 @@ github.com/henderiw/apiserver-builder v0.0.6-0.20260218201828-653d0f7e4042 h1:py github.com/henderiw/apiserver-builder v0.0.6-0.20260218201828-653d0f7e4042/go.mod h1:n5ApsFfaK3h5B1WVEnZ29erGuMV0ovPA0/ErcXeQet0= github.com/henderiw/apiserver-builder v0.0.6-0.20260218203055-86c6dd0d1193 h1:hRlPgwRlb4i8fbAu2yfeVxw99BaaSxbEU9OdDrBm5bE= github.com/henderiw/apiserver-builder v0.0.6-0.20260218203055-86c6dd0d1193/go.mod h1:n5ApsFfaK3h5B1WVEnZ29erGuMV0ovPA0/ErcXeQet0= +github.com/henderiw/apiserver-builder v0.0.6-0.20260218205721-520ac97264d3 h1:F8c215zVwkM1vPtLJMRnWohqOK9e0DwYCAiHSBJwzCw= +github.com/henderiw/apiserver-builder v0.0.6-0.20260218205721-520ac97264d3/go.mod h1:n5ApsFfaK3h5B1WVEnZ29erGuMV0ovPA0/ErcXeQet0= github.com/henderiw/apiserver-store v0.0.3 h1:cUNzimOvxVKsw+/kj+7IkI/GnRuFlziwCc3AsfYo9zM= github.com/henderiw/apiserver-store v0.0.3/go.mod h1:RuXLMHJwszn6LXgL6fO9fxMC7AW5wAc4zOddnnZpkKI= github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c h1:nFnCNyRV1Ej/zqV/gn8UnFESkoPUXhwpUCZyhSYGSYA= From 97fb11e7f8863fb3077892bfec27bbf41a8c7656 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Wed, 18 Feb 2026 22:26:41 +0100 Subject: [PATCH 033/135] updated builder --- go.mod | 2 +- go.sum | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/go.mod b/go.mod index 86e72b9d..8aaa8d6d 100644 --- a/go.mod +++ b/go.mod @@ -8,7 +8,7 @@ require ( github.com/gogo/protobuf v1.3.2 github.com/google/go-cmp v0.7.0 github.com/google/uuid v1.6.0 - github.com/henderiw/apiserver-builder v0.0.6-0.20260218205721-520ac97264d3 + github.com/henderiw/apiserver-builder v0.0.6-0.20260218212602-406f5fc7bbaa github.com/henderiw/apiserver-store v0.0.3 github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c github.com/henderiw/logger v0.0.0-20230911123436-8655829b1abe diff --git a/go.sum b/go.sum index d60f6cd0..95aa10e2 100644 --- a/go.sum +++ b/go.sum @@ -175,6 +175,8 @@ github.com/henderiw/apiserver-builder v0.0.6-0.20260218203055-86c6dd0d1193 h1:hR github.com/henderiw/apiserver-builder v0.0.6-0.20260218203055-86c6dd0d1193/go.mod h1:n5ApsFfaK3h5B1WVEnZ29erGuMV0ovPA0/ErcXeQet0= github.com/henderiw/apiserver-builder v0.0.6-0.20260218205721-520ac97264d3 h1:F8c215zVwkM1vPtLJMRnWohqOK9e0DwYCAiHSBJwzCw= github.com/henderiw/apiserver-builder v0.0.6-0.20260218205721-520ac97264d3/go.mod h1:n5ApsFfaK3h5B1WVEnZ29erGuMV0ovPA0/ErcXeQet0= +github.com/henderiw/apiserver-builder v0.0.6-0.20260218212602-406f5fc7bbaa h1:9yUs5bIDtz2n95CQ8C8+bsarwpgYsqW3YIYLUqdkgrc= +github.com/henderiw/apiserver-builder v0.0.6-0.20260218212602-406f5fc7bbaa/go.mod h1:n5ApsFfaK3h5B1WVEnZ29erGuMV0ovPA0/ErcXeQet0= github.com/henderiw/apiserver-store v0.0.3 h1:cUNzimOvxVKsw+/kj+7IkI/GnRuFlziwCc3AsfYo9zM= github.com/henderiw/apiserver-store v0.0.3/go.mod h1:RuXLMHJwszn6LXgL6fO9fxMC7AW5wAc4zOddnnZpkKI= github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c h1:nFnCNyRV1Ej/zqV/gn8UnFESkoPUXhwpUCZyhSYGSYA= From fa6f6bae746c73045a70be1719a9eb0573866bbb Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Thu, 19 Feb 2026 05:06:30 +0100 Subject: [PATCH 034/135] updated debug --- go.mod | 2 +- go.sum | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/go.mod b/go.mod index 8aaa8d6d..23bb37df 100644 --- a/go.mod +++ b/go.mod @@ -8,7 +8,7 @@ require ( github.com/gogo/protobuf v1.3.2 github.com/google/go-cmp v0.7.0 github.com/google/uuid v1.6.0 - github.com/henderiw/apiserver-builder v0.0.6-0.20260218212602-406f5fc7bbaa + github.com/henderiw/apiserver-builder v0.0.6-0.20260219040518-f1e69f8ea9a3 github.com/henderiw/apiserver-store v0.0.3 github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c github.com/henderiw/logger v0.0.0-20230911123436-8655829b1abe diff --git a/go.sum b/go.sum index 95aa10e2..b8ee7f1e 100644 --- a/go.sum +++ b/go.sum @@ -177,6 +177,8 @@ github.com/henderiw/apiserver-builder v0.0.6-0.20260218205721-520ac97264d3 h1:F8 github.com/henderiw/apiserver-builder v0.0.6-0.20260218205721-520ac97264d3/go.mod h1:n5ApsFfaK3h5B1WVEnZ29erGuMV0ovPA0/ErcXeQet0= github.com/henderiw/apiserver-builder v0.0.6-0.20260218212602-406f5fc7bbaa h1:9yUs5bIDtz2n95CQ8C8+bsarwpgYsqW3YIYLUqdkgrc= github.com/henderiw/apiserver-builder v0.0.6-0.20260218212602-406f5fc7bbaa/go.mod h1:n5ApsFfaK3h5B1WVEnZ29erGuMV0ovPA0/ErcXeQet0= +github.com/henderiw/apiserver-builder v0.0.6-0.20260219040518-f1e69f8ea9a3 h1:S6TzLhse6enhZzVqj72qy+H3GzuKD4tukWs84+QOsH8= +github.com/henderiw/apiserver-builder v0.0.6-0.20260219040518-f1e69f8ea9a3/go.mod h1:n5ApsFfaK3h5B1WVEnZ29erGuMV0ovPA0/ErcXeQet0= github.com/henderiw/apiserver-store v0.0.3 h1:cUNzimOvxVKsw+/kj+7IkI/GnRuFlziwCc3AsfYo9zM= github.com/henderiw/apiserver-store v0.0.3/go.mod h1:RuXLMHJwszn6LXgL6fO9fxMC7AW5wAc4zOddnnZpkKI= github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c h1:nFnCNyRV1Ej/zqV/gn8UnFESkoPUXhwpUCZyhSYGSYA= From d7bbe0e2e3acb005e05a43d1112252fcf0b453da Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Thu, 19 Feb 2026 05:27:22 +0100 Subject: [PATCH 035/135] updated debug --- go.mod | 2 +- go.sum | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/go.mod b/go.mod index 23bb37df..a24f69d0 100644 --- a/go.mod +++ b/go.mod @@ -8,7 +8,7 @@ require ( github.com/gogo/protobuf v1.3.2 github.com/google/go-cmp v0.7.0 github.com/google/uuid v1.6.0 - github.com/henderiw/apiserver-builder v0.0.6-0.20260219040518-f1e69f8ea9a3 + github.com/henderiw/apiserver-builder v0.0.6-0.20260219042604-0940a62b5ab6 github.com/henderiw/apiserver-store v0.0.3 github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c github.com/henderiw/logger v0.0.0-20230911123436-8655829b1abe diff --git a/go.sum b/go.sum index b8ee7f1e..99cc3bc6 100644 --- a/go.sum +++ b/go.sum @@ -179,6 +179,8 @@ github.com/henderiw/apiserver-builder v0.0.6-0.20260218212602-406f5fc7bbaa h1:9y github.com/henderiw/apiserver-builder v0.0.6-0.20260218212602-406f5fc7bbaa/go.mod h1:n5ApsFfaK3h5B1WVEnZ29erGuMV0ovPA0/ErcXeQet0= github.com/henderiw/apiserver-builder v0.0.6-0.20260219040518-f1e69f8ea9a3 h1:S6TzLhse6enhZzVqj72qy+H3GzuKD4tukWs84+QOsH8= github.com/henderiw/apiserver-builder v0.0.6-0.20260219040518-f1e69f8ea9a3/go.mod h1:n5ApsFfaK3h5B1WVEnZ29erGuMV0ovPA0/ErcXeQet0= +github.com/henderiw/apiserver-builder v0.0.6-0.20260219042604-0940a62b5ab6 h1:0BzTdbW5/oJDQ5qdWKFoOkgMPSakLmFWYGcoUAhkUZc= +github.com/henderiw/apiserver-builder v0.0.6-0.20260219042604-0940a62b5ab6/go.mod h1:n5ApsFfaK3h5B1WVEnZ29erGuMV0ovPA0/ErcXeQet0= github.com/henderiw/apiserver-store v0.0.3 h1:cUNzimOvxVKsw+/kj+7IkI/GnRuFlziwCc3AsfYo9zM= github.com/henderiw/apiserver-store v0.0.3/go.mod h1:RuXLMHJwszn6LXgL6fO9fxMC7AW5wAc4zOddnnZpkKI= github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c h1:nFnCNyRV1Ej/zqV/gn8UnFESkoPUXhwpUCZyhSYGSYA= From 03a2eb7be7ea5d639b3c39259a60d3ceea172e58 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Thu, 19 Feb 2026 05:38:57 +0100 Subject: [PATCH 036/135] updated debug --- go.mod | 2 +- go.sum | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/go.mod b/go.mod index a24f69d0..c349e438 100644 --- a/go.mod +++ b/go.mod @@ -8,7 +8,7 @@ require ( github.com/gogo/protobuf v1.3.2 github.com/google/go-cmp v0.7.0 github.com/google/uuid v1.6.0 - github.com/henderiw/apiserver-builder v0.0.6-0.20260219042604-0940a62b5ab6 + github.com/henderiw/apiserver-builder v0.0.6-0.20260219043804-e86807fd6ce5 github.com/henderiw/apiserver-store v0.0.3 github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c github.com/henderiw/logger v0.0.0-20230911123436-8655829b1abe diff --git a/go.sum b/go.sum index 99cc3bc6..66975253 100644 --- a/go.sum +++ b/go.sum @@ -181,6 +181,8 @@ github.com/henderiw/apiserver-builder v0.0.6-0.20260219040518-f1e69f8ea9a3 h1:S6 github.com/henderiw/apiserver-builder v0.0.6-0.20260219040518-f1e69f8ea9a3/go.mod h1:n5ApsFfaK3h5B1WVEnZ29erGuMV0ovPA0/ErcXeQet0= github.com/henderiw/apiserver-builder v0.0.6-0.20260219042604-0940a62b5ab6 h1:0BzTdbW5/oJDQ5qdWKFoOkgMPSakLmFWYGcoUAhkUZc= github.com/henderiw/apiserver-builder v0.0.6-0.20260219042604-0940a62b5ab6/go.mod h1:n5ApsFfaK3h5B1WVEnZ29erGuMV0ovPA0/ErcXeQet0= +github.com/henderiw/apiserver-builder v0.0.6-0.20260219043804-e86807fd6ce5 h1:Wh5LNxgoCEnP3mvEdA5JiPV9LLbrq3KRScv4dV+fMY8= +github.com/henderiw/apiserver-builder v0.0.6-0.20260219043804-e86807fd6ce5/go.mod h1:n5ApsFfaK3h5B1WVEnZ29erGuMV0ovPA0/ErcXeQet0= github.com/henderiw/apiserver-store v0.0.3 h1:cUNzimOvxVKsw+/kj+7IkI/GnRuFlziwCc3AsfYo9zM= github.com/henderiw/apiserver-store v0.0.3/go.mod h1:RuXLMHJwszn6LXgL6fO9fxMC7AW5wAc4zOddnnZpkKI= github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c h1:nFnCNyRV1Ej/zqV/gn8UnFESkoPUXhwpUCZyhSYGSYA= From ad197508947520e238ef2ae8f52168aa7ad1d55e Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Thu, 19 Feb 2026 05:50:07 +0100 Subject: [PATCH 037/135] updated debug --- go.mod | 2 +- go.sum | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/go.mod b/go.mod index c349e438..2ac96b88 100644 --- a/go.mod +++ b/go.mod @@ -8,7 +8,7 @@ require ( github.com/gogo/protobuf v1.3.2 github.com/google/go-cmp v0.7.0 github.com/google/uuid v1.6.0 - github.com/henderiw/apiserver-builder v0.0.6-0.20260219043804-e86807fd6ce5 + github.com/henderiw/apiserver-builder v0.0.6-0.20260219044914-498b0bc2e82b github.com/henderiw/apiserver-store v0.0.3 github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c github.com/henderiw/logger v0.0.0-20230911123436-8655829b1abe diff --git a/go.sum b/go.sum index 66975253..9058ad61 100644 --- a/go.sum +++ b/go.sum @@ -183,6 +183,8 @@ github.com/henderiw/apiserver-builder v0.0.6-0.20260219042604-0940a62b5ab6 h1:0B github.com/henderiw/apiserver-builder v0.0.6-0.20260219042604-0940a62b5ab6/go.mod h1:n5ApsFfaK3h5B1WVEnZ29erGuMV0ovPA0/ErcXeQet0= github.com/henderiw/apiserver-builder v0.0.6-0.20260219043804-e86807fd6ce5 h1:Wh5LNxgoCEnP3mvEdA5JiPV9LLbrq3KRScv4dV+fMY8= github.com/henderiw/apiserver-builder v0.0.6-0.20260219043804-e86807fd6ce5/go.mod h1:n5ApsFfaK3h5B1WVEnZ29erGuMV0ovPA0/ErcXeQet0= +github.com/henderiw/apiserver-builder v0.0.6-0.20260219044914-498b0bc2e82b h1:NMPa8cchw2y66ymBTjTBhpK/69LDnelUDf6FJaS09Zg= +github.com/henderiw/apiserver-builder v0.0.6-0.20260219044914-498b0bc2e82b/go.mod h1:Py2AD4oB1McoYpz4chBNAFo9bYeZ9N9cKPijzkMxk2U= github.com/henderiw/apiserver-store v0.0.3 h1:cUNzimOvxVKsw+/kj+7IkI/GnRuFlziwCc3AsfYo9zM= github.com/henderiw/apiserver-store v0.0.3/go.mod h1:RuXLMHJwszn6LXgL6fO9fxMC7AW5wAc4zOddnnZpkKI= github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c h1:nFnCNyRV1Ej/zqV/gn8UnFESkoPUXhwpUCZyhSYGSYA= From 9b01afe4e545626df861a52c2903787a90bfeb79 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Thu, 19 Feb 2026 06:17:05 +0100 Subject: [PATCH 038/135] updated debug --- go.mod | 2 +- go.sum | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/go.mod b/go.mod index 2ac96b88..1c2458a6 100644 --- a/go.mod +++ b/go.mod @@ -8,7 +8,7 @@ require ( github.com/gogo/protobuf v1.3.2 github.com/google/go-cmp v0.7.0 github.com/google/uuid v1.6.0 - github.com/henderiw/apiserver-builder v0.0.6-0.20260219044914-498b0bc2e82b + github.com/henderiw/apiserver-builder v0.0.6-0.20260219051624-595e0ea22ab4 github.com/henderiw/apiserver-store v0.0.3 github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c github.com/henderiw/logger v0.0.0-20230911123436-8655829b1abe diff --git a/go.sum b/go.sum index 9058ad61..4f74d221 100644 --- a/go.sum +++ b/go.sum @@ -185,6 +185,8 @@ github.com/henderiw/apiserver-builder v0.0.6-0.20260219043804-e86807fd6ce5 h1:Wh github.com/henderiw/apiserver-builder v0.0.6-0.20260219043804-e86807fd6ce5/go.mod h1:n5ApsFfaK3h5B1WVEnZ29erGuMV0ovPA0/ErcXeQet0= github.com/henderiw/apiserver-builder v0.0.6-0.20260219044914-498b0bc2e82b h1:NMPa8cchw2y66ymBTjTBhpK/69LDnelUDf6FJaS09Zg= github.com/henderiw/apiserver-builder v0.0.6-0.20260219044914-498b0bc2e82b/go.mod h1:Py2AD4oB1McoYpz4chBNAFo9bYeZ9N9cKPijzkMxk2U= +github.com/henderiw/apiserver-builder v0.0.6-0.20260219051624-595e0ea22ab4 h1:dfa+4LWwmk0EZAr+iO+GwUm0fbUxrOtJ9znND8M4Vc4= +github.com/henderiw/apiserver-builder v0.0.6-0.20260219051624-595e0ea22ab4/go.mod h1:Py2AD4oB1McoYpz4chBNAFo9bYeZ9N9cKPijzkMxk2U= github.com/henderiw/apiserver-store v0.0.3 h1:cUNzimOvxVKsw+/kj+7IkI/GnRuFlziwCc3AsfYo9zM= github.com/henderiw/apiserver-store v0.0.3/go.mod h1:RuXLMHJwszn6LXgL6fO9fxMC7AW5wAc4zOddnnZpkKI= github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c h1:nFnCNyRV1Ej/zqV/gn8UnFESkoPUXhwpUCZyhSYGSYA= From df956475693c80b42f56d019c5a68c87fab38016 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Thu, 19 Feb 2026 06:38:12 +0100 Subject: [PATCH 039/135] updated debug --- go.mod | 2 +- go.sum | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/go.mod b/go.mod index 1c2458a6..05233a9c 100644 --- a/go.mod +++ b/go.mod @@ -8,7 +8,7 @@ require ( github.com/gogo/protobuf v1.3.2 github.com/google/go-cmp v0.7.0 github.com/google/uuid v1.6.0 - github.com/henderiw/apiserver-builder v0.0.6-0.20260219051624-595e0ea22ab4 + github.com/henderiw/apiserver-builder v0.0.6-0.20260219053658-5ad076035844 github.com/henderiw/apiserver-store v0.0.3 github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c github.com/henderiw/logger v0.0.0-20230911123436-8655829b1abe diff --git a/go.sum b/go.sum index 4f74d221..5f0a0492 100644 --- a/go.sum +++ b/go.sum @@ -187,6 +187,8 @@ github.com/henderiw/apiserver-builder v0.0.6-0.20260219044914-498b0bc2e82b h1:NM github.com/henderiw/apiserver-builder v0.0.6-0.20260219044914-498b0bc2e82b/go.mod h1:Py2AD4oB1McoYpz4chBNAFo9bYeZ9N9cKPijzkMxk2U= github.com/henderiw/apiserver-builder v0.0.6-0.20260219051624-595e0ea22ab4 h1:dfa+4LWwmk0EZAr+iO+GwUm0fbUxrOtJ9znND8M4Vc4= github.com/henderiw/apiserver-builder v0.0.6-0.20260219051624-595e0ea22ab4/go.mod h1:Py2AD4oB1McoYpz4chBNAFo9bYeZ9N9cKPijzkMxk2U= +github.com/henderiw/apiserver-builder v0.0.6-0.20260219053658-5ad076035844 h1:w3Bf1/AMhbZwzTjtUiWNrsq5+yBPuPTXfP7yIorbGrQ= +github.com/henderiw/apiserver-builder v0.0.6-0.20260219053658-5ad076035844/go.mod h1:Py2AD4oB1McoYpz4chBNAFo9bYeZ9N9cKPijzkMxk2U= github.com/henderiw/apiserver-store v0.0.3 h1:cUNzimOvxVKsw+/kj+7IkI/GnRuFlziwCc3AsfYo9zM= github.com/henderiw/apiserver-store v0.0.3/go.mod h1:RuXLMHJwszn6LXgL6fO9fxMC7AW5wAc4zOddnnZpkKI= github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c h1:nFnCNyRV1Ej/zqV/gn8UnFESkoPUXhwpUCZyhSYGSYA= From 59b6d358245484f27078fe1cd4617e17bba3fdad Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Thu, 19 Feb 2026 07:00:00 +0100 Subject: [PATCH 040/135] updated debug --- go.mod | 2 +- go.sum | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/go.mod b/go.mod index 05233a9c..b1e33e61 100644 --- a/go.mod +++ b/go.mod @@ -8,7 +8,7 @@ require ( github.com/gogo/protobuf v1.3.2 github.com/google/go-cmp v0.7.0 github.com/google/uuid v1.6.0 - github.com/henderiw/apiserver-builder v0.0.6-0.20260219053658-5ad076035844 + github.com/henderiw/apiserver-builder v0.0.6-0.20260219055920-ca124837d848 github.com/henderiw/apiserver-store v0.0.3 github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c github.com/henderiw/logger v0.0.0-20230911123436-8655829b1abe diff --git a/go.sum b/go.sum index 5f0a0492..384af3e5 100644 --- a/go.sum +++ b/go.sum @@ -189,6 +189,8 @@ github.com/henderiw/apiserver-builder v0.0.6-0.20260219051624-595e0ea22ab4 h1:df github.com/henderiw/apiserver-builder v0.0.6-0.20260219051624-595e0ea22ab4/go.mod h1:Py2AD4oB1McoYpz4chBNAFo9bYeZ9N9cKPijzkMxk2U= github.com/henderiw/apiserver-builder v0.0.6-0.20260219053658-5ad076035844 h1:w3Bf1/AMhbZwzTjtUiWNrsq5+yBPuPTXfP7yIorbGrQ= github.com/henderiw/apiserver-builder v0.0.6-0.20260219053658-5ad076035844/go.mod h1:Py2AD4oB1McoYpz4chBNAFo9bYeZ9N9cKPijzkMxk2U= +github.com/henderiw/apiserver-builder v0.0.6-0.20260219055920-ca124837d848 h1:yAa6+4uqiVwGD1nzD1R5xjop2TYetOE6RcPPYrNpH4A= +github.com/henderiw/apiserver-builder v0.0.6-0.20260219055920-ca124837d848/go.mod h1:Py2AD4oB1McoYpz4chBNAFo9bYeZ9N9cKPijzkMxk2U= github.com/henderiw/apiserver-store v0.0.3 h1:cUNzimOvxVKsw+/kj+7IkI/GnRuFlziwCc3AsfYo9zM= github.com/henderiw/apiserver-store v0.0.3/go.mod h1:RuXLMHJwszn6LXgL6fO9fxMC7AW5wAc4zOddnnZpkKI= github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c h1:nFnCNyRV1Ej/zqV/gn8UnFESkoPUXhwpUCZyhSYGSYA= From 5b6bf671a6b0489f28b98945851f836111620499 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Thu, 19 Feb 2026 07:13:16 +0100 Subject: [PATCH 041/135] updated debug --- go.mod | 2 +- go.sum | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/go.mod b/go.mod index b1e33e61..20d192ba 100644 --- a/go.mod +++ b/go.mod @@ -8,7 +8,7 @@ require ( github.com/gogo/protobuf v1.3.2 github.com/google/go-cmp v0.7.0 github.com/google/uuid v1.6.0 - github.com/henderiw/apiserver-builder v0.0.6-0.20260219055920-ca124837d848 + github.com/henderiw/apiserver-builder v0.0.6-0.20260219061223-2be11c1e38bf github.com/henderiw/apiserver-store v0.0.3 github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c github.com/henderiw/logger v0.0.0-20230911123436-8655829b1abe diff --git a/go.sum b/go.sum index 384af3e5..bd083045 100644 --- a/go.sum +++ b/go.sum @@ -191,6 +191,8 @@ github.com/henderiw/apiserver-builder v0.0.6-0.20260219053658-5ad076035844 h1:w3 github.com/henderiw/apiserver-builder v0.0.6-0.20260219053658-5ad076035844/go.mod h1:Py2AD4oB1McoYpz4chBNAFo9bYeZ9N9cKPijzkMxk2U= github.com/henderiw/apiserver-builder v0.0.6-0.20260219055920-ca124837d848 h1:yAa6+4uqiVwGD1nzD1R5xjop2TYetOE6RcPPYrNpH4A= github.com/henderiw/apiserver-builder v0.0.6-0.20260219055920-ca124837d848/go.mod h1:Py2AD4oB1McoYpz4chBNAFo9bYeZ9N9cKPijzkMxk2U= +github.com/henderiw/apiserver-builder v0.0.6-0.20260219061223-2be11c1e38bf h1:yM/+zMp1HhCkIAsTgSvsgzBs3UY00l14wwZV9f+dmIM= +github.com/henderiw/apiserver-builder v0.0.6-0.20260219061223-2be11c1e38bf/go.mod h1:Py2AD4oB1McoYpz4chBNAFo9bYeZ9N9cKPijzkMxk2U= github.com/henderiw/apiserver-store v0.0.3 h1:cUNzimOvxVKsw+/kj+7IkI/GnRuFlziwCc3AsfYo9zM= github.com/henderiw/apiserver-store v0.0.3/go.mod h1:RuXLMHJwszn6LXgL6fO9fxMC7AW5wAc4zOddnnZpkKI= github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c h1:nFnCNyRV1Ej/zqV/gn8UnFESkoPUXhwpUCZyhSYGSYA= From 8a8ec0d94a25f9fefd19ca1736f2e67903ddaa1e Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Thu, 19 Feb 2026 07:25:08 +0100 Subject: [PATCH 042/135] updated debug --- go.mod | 2 +- go.sum | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/go.mod b/go.mod index 20d192ba..000ed8b2 100644 --- a/go.mod +++ b/go.mod @@ -8,7 +8,7 @@ require ( github.com/gogo/protobuf v1.3.2 github.com/google/go-cmp v0.7.0 github.com/google/uuid v1.6.0 - github.com/henderiw/apiserver-builder v0.0.6-0.20260219061223-2be11c1e38bf + github.com/henderiw/apiserver-builder v0.0.6-0.20260219062429-c5918967e841 github.com/henderiw/apiserver-store v0.0.3 github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c github.com/henderiw/logger v0.0.0-20230911123436-8655829b1abe diff --git a/go.sum b/go.sum index bd083045..332a1207 100644 --- a/go.sum +++ b/go.sum @@ -193,6 +193,8 @@ github.com/henderiw/apiserver-builder v0.0.6-0.20260219055920-ca124837d848 h1:yA github.com/henderiw/apiserver-builder v0.0.6-0.20260219055920-ca124837d848/go.mod h1:Py2AD4oB1McoYpz4chBNAFo9bYeZ9N9cKPijzkMxk2U= github.com/henderiw/apiserver-builder v0.0.6-0.20260219061223-2be11c1e38bf h1:yM/+zMp1HhCkIAsTgSvsgzBs3UY00l14wwZV9f+dmIM= github.com/henderiw/apiserver-builder v0.0.6-0.20260219061223-2be11c1e38bf/go.mod h1:Py2AD4oB1McoYpz4chBNAFo9bYeZ9N9cKPijzkMxk2U= +github.com/henderiw/apiserver-builder v0.0.6-0.20260219062429-c5918967e841 h1:7JmaObLyDIG6jwclB/ruQvucVPbck1HhSvPNFagkg4E= +github.com/henderiw/apiserver-builder v0.0.6-0.20260219062429-c5918967e841/go.mod h1:Py2AD4oB1McoYpz4chBNAFo9bYeZ9N9cKPijzkMxk2U= github.com/henderiw/apiserver-store v0.0.3 h1:cUNzimOvxVKsw+/kj+7IkI/GnRuFlziwCc3AsfYo9zM= github.com/henderiw/apiserver-store v0.0.3/go.mod h1:RuXLMHJwszn6LXgL6fO9fxMC7AW5wAc4zOddnnZpkKI= github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c h1:nFnCNyRV1Ej/zqV/gn8UnFESkoPUXhwpUCZyhSYGSYA= From dd65a40d4d526bf74efe8bdccde353dbe0cd1e03 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Thu, 19 Feb 2026 07:38:16 +0100 Subject: [PATCH 043/135] updated debug --- go.mod | 2 +- go.sum | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/go.mod b/go.mod index 000ed8b2..126a92f1 100644 --- a/go.mod +++ b/go.mod @@ -8,7 +8,7 @@ require ( github.com/gogo/protobuf v1.3.2 github.com/google/go-cmp v0.7.0 github.com/google/uuid v1.6.0 - github.com/henderiw/apiserver-builder v0.0.6-0.20260219062429-c5918967e841 + github.com/henderiw/apiserver-builder v0.0.6-0.20260219063725-ed5e767ba219 github.com/henderiw/apiserver-store v0.0.3 github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c github.com/henderiw/logger v0.0.0-20230911123436-8655829b1abe diff --git a/go.sum b/go.sum index 332a1207..538076df 100644 --- a/go.sum +++ b/go.sum @@ -195,6 +195,8 @@ github.com/henderiw/apiserver-builder v0.0.6-0.20260219061223-2be11c1e38bf h1:yM github.com/henderiw/apiserver-builder v0.0.6-0.20260219061223-2be11c1e38bf/go.mod h1:Py2AD4oB1McoYpz4chBNAFo9bYeZ9N9cKPijzkMxk2U= github.com/henderiw/apiserver-builder v0.0.6-0.20260219062429-c5918967e841 h1:7JmaObLyDIG6jwclB/ruQvucVPbck1HhSvPNFagkg4E= github.com/henderiw/apiserver-builder v0.0.6-0.20260219062429-c5918967e841/go.mod h1:Py2AD4oB1McoYpz4chBNAFo9bYeZ9N9cKPijzkMxk2U= +github.com/henderiw/apiserver-builder v0.0.6-0.20260219063725-ed5e767ba219 h1:/F/CNb4e2ta0P9LfRLUFFSfTNJCi/Qtif3tXyhztdg8= +github.com/henderiw/apiserver-builder v0.0.6-0.20260219063725-ed5e767ba219/go.mod h1:Py2AD4oB1McoYpz4chBNAFo9bYeZ9N9cKPijzkMxk2U= github.com/henderiw/apiserver-store v0.0.3 h1:cUNzimOvxVKsw+/kj+7IkI/GnRuFlziwCc3AsfYo9zM= github.com/henderiw/apiserver-store v0.0.3/go.mod h1:RuXLMHJwszn6LXgL6fO9fxMC7AW5wAc4zOddnnZpkKI= github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c h1:nFnCNyRV1Ej/zqV/gn8UnFESkoPUXhwpUCZyhSYGSYA= From fb6129adc555763613af4791b0a972e7494056a1 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Thu, 19 Feb 2026 07:57:05 +0100 Subject: [PATCH 044/135] updated debug --- go.mod | 2 +- go.sum | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/go.mod b/go.mod index 126a92f1..cef180cb 100644 --- a/go.mod +++ b/go.mod @@ -8,7 +8,7 @@ require ( github.com/gogo/protobuf v1.3.2 github.com/google/go-cmp v0.7.0 github.com/google/uuid v1.6.0 - github.com/henderiw/apiserver-builder v0.0.6-0.20260219063725-ed5e767ba219 + github.com/henderiw/apiserver-builder v0.0.6-0.20260219065618-6d7685c0d18c github.com/henderiw/apiserver-store v0.0.3 github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c github.com/henderiw/logger v0.0.0-20230911123436-8655829b1abe diff --git a/go.sum b/go.sum index 538076df..225e3ad6 100644 --- a/go.sum +++ b/go.sum @@ -197,6 +197,8 @@ github.com/henderiw/apiserver-builder v0.0.6-0.20260219062429-c5918967e841 h1:7J github.com/henderiw/apiserver-builder v0.0.6-0.20260219062429-c5918967e841/go.mod h1:Py2AD4oB1McoYpz4chBNAFo9bYeZ9N9cKPijzkMxk2U= github.com/henderiw/apiserver-builder v0.0.6-0.20260219063725-ed5e767ba219 h1:/F/CNb4e2ta0P9LfRLUFFSfTNJCi/Qtif3tXyhztdg8= github.com/henderiw/apiserver-builder v0.0.6-0.20260219063725-ed5e767ba219/go.mod h1:Py2AD4oB1McoYpz4chBNAFo9bYeZ9N9cKPijzkMxk2U= +github.com/henderiw/apiserver-builder v0.0.6-0.20260219065618-6d7685c0d18c h1:Cma9idG+MkgzwoGCi9mKKz29V9zhKUhdvxAQ8NmEpEU= +github.com/henderiw/apiserver-builder v0.0.6-0.20260219065618-6d7685c0d18c/go.mod h1:Py2AD4oB1McoYpz4chBNAFo9bYeZ9N9cKPijzkMxk2U= github.com/henderiw/apiserver-store v0.0.3 h1:cUNzimOvxVKsw+/kj+7IkI/GnRuFlziwCc3AsfYo9zM= github.com/henderiw/apiserver-store v0.0.3/go.mod h1:RuXLMHJwszn6LXgL6fO9fxMC7AW5wAc4zOddnnZpkKI= github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c h1:nFnCNyRV1Ej/zqV/gn8UnFESkoPUXhwpUCZyhSYGSYA= From 9a29958e26647f20a4891d0c225761dd653c45fd Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Thu, 19 Feb 2026 08:09:31 +0100 Subject: [PATCH 045/135] updated debug --- go.mod | 2 +- go.sum | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/go.mod b/go.mod index cef180cb..2491afca 100644 --- a/go.mod +++ b/go.mod @@ -8,7 +8,7 @@ require ( github.com/gogo/protobuf v1.3.2 github.com/google/go-cmp v0.7.0 github.com/google/uuid v1.6.0 - github.com/henderiw/apiserver-builder v0.0.6-0.20260219065618-6d7685c0d18c + github.com/henderiw/apiserver-builder v0.0.6-0.20260219070848-d085ab8ef21e github.com/henderiw/apiserver-store v0.0.3 github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c github.com/henderiw/logger v0.0.0-20230911123436-8655829b1abe diff --git a/go.sum b/go.sum index 225e3ad6..4e36f09d 100644 --- a/go.sum +++ b/go.sum @@ -199,6 +199,8 @@ github.com/henderiw/apiserver-builder v0.0.6-0.20260219063725-ed5e767ba219 h1:/F github.com/henderiw/apiserver-builder v0.0.6-0.20260219063725-ed5e767ba219/go.mod h1:Py2AD4oB1McoYpz4chBNAFo9bYeZ9N9cKPijzkMxk2U= github.com/henderiw/apiserver-builder v0.0.6-0.20260219065618-6d7685c0d18c h1:Cma9idG+MkgzwoGCi9mKKz29V9zhKUhdvxAQ8NmEpEU= github.com/henderiw/apiserver-builder v0.0.6-0.20260219065618-6d7685c0d18c/go.mod h1:Py2AD4oB1McoYpz4chBNAFo9bYeZ9N9cKPijzkMxk2U= +github.com/henderiw/apiserver-builder v0.0.6-0.20260219070848-d085ab8ef21e h1:BfwL4amzHrSUw+0uGuneYhsPjaSBkHMM7Tt5wo1Jtf0= +github.com/henderiw/apiserver-builder v0.0.6-0.20260219070848-d085ab8ef21e/go.mod h1:Py2AD4oB1McoYpz4chBNAFo9bYeZ9N9cKPijzkMxk2U= github.com/henderiw/apiserver-store v0.0.3 h1:cUNzimOvxVKsw+/kj+7IkI/GnRuFlziwCc3AsfYo9zM= github.com/henderiw/apiserver-store v0.0.3/go.mod h1:RuXLMHJwszn6LXgL6fO9fxMC7AW5wAc4zOddnnZpkKI= github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c h1:nFnCNyRV1Ej/zqV/gn8UnFESkoPUXhwpUCZyhSYGSYA= From c520001fe089444c2f4a8230eb6b2ed0c6d3061d Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Thu, 19 Feb 2026 08:23:53 +0100 Subject: [PATCH 046/135] updated debug --- go.mod | 2 +- go.sum | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/go.mod b/go.mod index 2491afca..a448bddd 100644 --- a/go.mod +++ b/go.mod @@ -8,7 +8,7 @@ require ( github.com/gogo/protobuf v1.3.2 github.com/google/go-cmp v0.7.0 github.com/google/uuid v1.6.0 - github.com/henderiw/apiserver-builder v0.0.6-0.20260219070848-d085ab8ef21e + github.com/henderiw/apiserver-builder v0.0.6-0.20260219072317-078f99edf64e github.com/henderiw/apiserver-store v0.0.3 github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c github.com/henderiw/logger v0.0.0-20230911123436-8655829b1abe diff --git a/go.sum b/go.sum index 4e36f09d..f88d02b2 100644 --- a/go.sum +++ b/go.sum @@ -201,6 +201,8 @@ github.com/henderiw/apiserver-builder v0.0.6-0.20260219065618-6d7685c0d18c h1:Cm github.com/henderiw/apiserver-builder v0.0.6-0.20260219065618-6d7685c0d18c/go.mod h1:Py2AD4oB1McoYpz4chBNAFo9bYeZ9N9cKPijzkMxk2U= github.com/henderiw/apiserver-builder v0.0.6-0.20260219070848-d085ab8ef21e h1:BfwL4amzHrSUw+0uGuneYhsPjaSBkHMM7Tt5wo1Jtf0= github.com/henderiw/apiserver-builder v0.0.6-0.20260219070848-d085ab8ef21e/go.mod h1:Py2AD4oB1McoYpz4chBNAFo9bYeZ9N9cKPijzkMxk2U= +github.com/henderiw/apiserver-builder v0.0.6-0.20260219072317-078f99edf64e h1:KudoxkO9dQZAmH9SS37TynFv2JH0VGWKNllKd9RXfh4= +github.com/henderiw/apiserver-builder v0.0.6-0.20260219072317-078f99edf64e/go.mod h1:Py2AD4oB1McoYpz4chBNAFo9bYeZ9N9cKPijzkMxk2U= github.com/henderiw/apiserver-store v0.0.3 h1:cUNzimOvxVKsw+/kj+7IkI/GnRuFlziwCc3AsfYo9zM= github.com/henderiw/apiserver-store v0.0.3/go.mod h1:RuXLMHJwszn6LXgL6fO9fxMC7AW5wAc4zOddnnZpkKI= github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c h1:nFnCNyRV1Ej/zqV/gn8UnFESkoPUXhwpUCZyhSYGSYA= From 6c65488173d9d5d33059450ddcfc6524edd52982 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Thu, 19 Feb 2026 08:52:24 +0100 Subject: [PATCH 047/135] updated debug --- go.mod | 2 +- go.sum | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/go.mod b/go.mod index a448bddd..2d4557ec 100644 --- a/go.mod +++ b/go.mod @@ -8,7 +8,7 @@ require ( github.com/gogo/protobuf v1.3.2 github.com/google/go-cmp v0.7.0 github.com/google/uuid v1.6.0 - github.com/henderiw/apiserver-builder v0.0.6-0.20260219072317-078f99edf64e + github.com/henderiw/apiserver-builder v0.0.6-0.20260219075034-98a7e4574ec1 github.com/henderiw/apiserver-store v0.0.3 github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c github.com/henderiw/logger v0.0.0-20230911123436-8655829b1abe diff --git a/go.sum b/go.sum index f88d02b2..c0a40959 100644 --- a/go.sum +++ b/go.sum @@ -203,6 +203,8 @@ github.com/henderiw/apiserver-builder v0.0.6-0.20260219070848-d085ab8ef21e h1:Bf github.com/henderiw/apiserver-builder v0.0.6-0.20260219070848-d085ab8ef21e/go.mod h1:Py2AD4oB1McoYpz4chBNAFo9bYeZ9N9cKPijzkMxk2U= github.com/henderiw/apiserver-builder v0.0.6-0.20260219072317-078f99edf64e h1:KudoxkO9dQZAmH9SS37TynFv2JH0VGWKNllKd9RXfh4= github.com/henderiw/apiserver-builder v0.0.6-0.20260219072317-078f99edf64e/go.mod h1:Py2AD4oB1McoYpz4chBNAFo9bYeZ9N9cKPijzkMxk2U= +github.com/henderiw/apiserver-builder v0.0.6-0.20260219075034-98a7e4574ec1 h1:6d/HpbDzZyaZZuep+qVFRLHmf4RQznUymYWm/LralFQ= +github.com/henderiw/apiserver-builder v0.0.6-0.20260219075034-98a7e4574ec1/go.mod h1:Py2AD4oB1McoYpz4chBNAFo9bYeZ9N9cKPijzkMxk2U= github.com/henderiw/apiserver-store v0.0.3 h1:cUNzimOvxVKsw+/kj+7IkI/GnRuFlziwCc3AsfYo9zM= github.com/henderiw/apiserver-store v0.0.3/go.mod h1:RuXLMHJwszn6LXgL6fO9fxMC7AW5wAc4zOddnnZpkKI= github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c h1:nFnCNyRV1Ej/zqV/gn8UnFESkoPUXhwpUCZyhSYGSYA= From 5e72099d3f9af6796b99e80450793b84da3acdf0 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Thu, 19 Feb 2026 09:19:51 +0100 Subject: [PATCH 048/135] updated debug --- go.mod | 2 +- go.sum | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/go.mod b/go.mod index 2d4557ec..3c7f8909 100644 --- a/go.mod +++ b/go.mod @@ -8,7 +8,7 @@ require ( github.com/gogo/protobuf v1.3.2 github.com/google/go-cmp v0.7.0 github.com/google/uuid v1.6.0 - github.com/henderiw/apiserver-builder v0.0.6-0.20260219075034-98a7e4574ec1 + github.com/henderiw/apiserver-builder v0.0.6-0.20260219081909-1727866bcd67 github.com/henderiw/apiserver-store v0.0.3 github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c github.com/henderiw/logger v0.0.0-20230911123436-8655829b1abe diff --git a/go.sum b/go.sum index c0a40959..c93811e0 100644 --- a/go.sum +++ b/go.sum @@ -205,6 +205,8 @@ github.com/henderiw/apiserver-builder v0.0.6-0.20260219072317-078f99edf64e h1:Ku github.com/henderiw/apiserver-builder v0.0.6-0.20260219072317-078f99edf64e/go.mod h1:Py2AD4oB1McoYpz4chBNAFo9bYeZ9N9cKPijzkMxk2U= github.com/henderiw/apiserver-builder v0.0.6-0.20260219075034-98a7e4574ec1 h1:6d/HpbDzZyaZZuep+qVFRLHmf4RQznUymYWm/LralFQ= github.com/henderiw/apiserver-builder v0.0.6-0.20260219075034-98a7e4574ec1/go.mod h1:Py2AD4oB1McoYpz4chBNAFo9bYeZ9N9cKPijzkMxk2U= +github.com/henderiw/apiserver-builder v0.0.6-0.20260219081909-1727866bcd67 h1:bYrPn572ma328A5yrwA3ihirIzgICXhQ7ojGPOE+Y54= +github.com/henderiw/apiserver-builder v0.0.6-0.20260219081909-1727866bcd67/go.mod h1:Py2AD4oB1McoYpz4chBNAFo9bYeZ9N9cKPijzkMxk2U= github.com/henderiw/apiserver-store v0.0.3 h1:cUNzimOvxVKsw+/kj+7IkI/GnRuFlziwCc3AsfYo9zM= github.com/henderiw/apiserver-store v0.0.3/go.mod h1:RuXLMHJwszn6LXgL6fO9fxMC7AW5wAc4zOddnnZpkKI= github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c h1:nFnCNyRV1Ej/zqV/gn8UnFESkoPUXhwpUCZyhSYGSYA= From 4164f2faf3d75e8dc8f05d80320d3f0486e1f0ea Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Thu, 19 Feb 2026 09:47:40 +0100 Subject: [PATCH 049/135] updated debug --- go.mod | 2 +- go.sum | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/go.mod b/go.mod index 3c7f8909..2f4a0a52 100644 --- a/go.mod +++ b/go.mod @@ -8,7 +8,7 @@ require ( github.com/gogo/protobuf v1.3.2 github.com/google/go-cmp v0.7.0 github.com/google/uuid v1.6.0 - github.com/henderiw/apiserver-builder v0.0.6-0.20260219081909-1727866bcd67 + github.com/henderiw/apiserver-builder v0.0.6-0.20260219084651-b0a801b267e4 github.com/henderiw/apiserver-store v0.0.3 github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c github.com/henderiw/logger v0.0.0-20230911123436-8655829b1abe diff --git a/go.sum b/go.sum index c93811e0..868ba9c0 100644 --- a/go.sum +++ b/go.sum @@ -207,6 +207,8 @@ github.com/henderiw/apiserver-builder v0.0.6-0.20260219075034-98a7e4574ec1 h1:6d github.com/henderiw/apiserver-builder v0.0.6-0.20260219075034-98a7e4574ec1/go.mod h1:Py2AD4oB1McoYpz4chBNAFo9bYeZ9N9cKPijzkMxk2U= github.com/henderiw/apiserver-builder v0.0.6-0.20260219081909-1727866bcd67 h1:bYrPn572ma328A5yrwA3ihirIzgICXhQ7ojGPOE+Y54= github.com/henderiw/apiserver-builder v0.0.6-0.20260219081909-1727866bcd67/go.mod h1:Py2AD4oB1McoYpz4chBNAFo9bYeZ9N9cKPijzkMxk2U= +github.com/henderiw/apiserver-builder v0.0.6-0.20260219084651-b0a801b267e4 h1:ptAf3qtBchU5ATFxBWwZ3j05SP/RChQoYuzFs6npmlM= +github.com/henderiw/apiserver-builder v0.0.6-0.20260219084651-b0a801b267e4/go.mod h1:Py2AD4oB1McoYpz4chBNAFo9bYeZ9N9cKPijzkMxk2U= github.com/henderiw/apiserver-store v0.0.3 h1:cUNzimOvxVKsw+/kj+7IkI/GnRuFlziwCc3AsfYo9zM= github.com/henderiw/apiserver-store v0.0.3/go.mod h1:RuXLMHJwszn6LXgL6fO9fxMC7AW5wAc4zOddnnZpkKI= github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c h1:nFnCNyRV1Ej/zqV/gn8UnFESkoPUXhwpUCZyhSYGSYA= From cdfc6eefc9258381e603f9be92f5f2a2a0fd8629 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Thu, 19 Feb 2026 10:05:04 +0100 Subject: [PATCH 050/135] updated debug --- go.mod | 2 +- go.sum | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/go.mod b/go.mod index 2f4a0a52..9ae38174 100644 --- a/go.mod +++ b/go.mod @@ -8,7 +8,7 @@ require ( github.com/gogo/protobuf v1.3.2 github.com/google/go-cmp v0.7.0 github.com/google/uuid v1.6.0 - github.com/henderiw/apiserver-builder v0.0.6-0.20260219084651-b0a801b267e4 + github.com/henderiw/apiserver-builder v0.0.6-0.20260219090415-d2a64fe241f7 github.com/henderiw/apiserver-store v0.0.3 github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c github.com/henderiw/logger v0.0.0-20230911123436-8655829b1abe diff --git a/go.sum b/go.sum index 868ba9c0..6ddb567c 100644 --- a/go.sum +++ b/go.sum @@ -209,6 +209,8 @@ github.com/henderiw/apiserver-builder v0.0.6-0.20260219081909-1727866bcd67 h1:bY github.com/henderiw/apiserver-builder v0.0.6-0.20260219081909-1727866bcd67/go.mod h1:Py2AD4oB1McoYpz4chBNAFo9bYeZ9N9cKPijzkMxk2U= github.com/henderiw/apiserver-builder v0.0.6-0.20260219084651-b0a801b267e4 h1:ptAf3qtBchU5ATFxBWwZ3j05SP/RChQoYuzFs6npmlM= github.com/henderiw/apiserver-builder v0.0.6-0.20260219084651-b0a801b267e4/go.mod h1:Py2AD4oB1McoYpz4chBNAFo9bYeZ9N9cKPijzkMxk2U= +github.com/henderiw/apiserver-builder v0.0.6-0.20260219090415-d2a64fe241f7 h1:FuH321LNd0/A7chR9PplOUYOiPdbsl/8Gx3KkAK+m60= +github.com/henderiw/apiserver-builder v0.0.6-0.20260219090415-d2a64fe241f7/go.mod h1:Py2AD4oB1McoYpz4chBNAFo9bYeZ9N9cKPijzkMxk2U= github.com/henderiw/apiserver-store v0.0.3 h1:cUNzimOvxVKsw+/kj+7IkI/GnRuFlziwCc3AsfYo9zM= github.com/henderiw/apiserver-store v0.0.3/go.mod h1:RuXLMHJwszn6LXgL6fO9fxMC7AW5wAc4zOddnnZpkKI= github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c h1:nFnCNyRV1Ej/zqV/gn8UnFESkoPUXhwpUCZyhSYGSYA= From cd0afcfb64b0f4b488856e24a917a9b14b49e287 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Thu, 19 Feb 2026 10:38:45 +0100 Subject: [PATCH 051/135] updated apibuilder for SSA --- go.mod | 2 +- go.sum | 44 ++------------------------------------------ 2 files changed, 3 insertions(+), 43 deletions(-) diff --git a/go.mod b/go.mod index 9ae38174..968c8669 100644 --- a/go.mod +++ b/go.mod @@ -8,7 +8,7 @@ require ( github.com/gogo/protobuf v1.3.2 github.com/google/go-cmp v0.7.0 github.com/google/uuid v1.6.0 - github.com/henderiw/apiserver-builder v0.0.6-0.20260219090415-d2a64fe241f7 + github.com/henderiw/apiserver-builder v0.0.6 github.com/henderiw/apiserver-store v0.0.3 github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c github.com/henderiw/logger v0.0.0-20230911123436-8655829b1abe diff --git a/go.sum b/go.sum index 6ddb567c..7e6ca08b 100644 --- a/go.sum +++ b/go.sum @@ -169,48 +169,8 @@ github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0 h1:Ovs26xHkKqVztRpIrF/92Bcuy github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0/go.mod h1:8NvIoxWQoOIhqOTXgfV/d3M/q6VIi02HzZEHgUlZvzk= github.com/grpc-ecosystem/grpc-gateway/v2 v2.27.3 h1:NmZ1PKzSTQbuGHw9DGPFomqkkLWMC+vZCkfs+FHv1Vg= github.com/grpc-ecosystem/grpc-gateway/v2 v2.27.3/go.mod h1:zQrxl1YP88HQlA6i9c63DSVPFklWpGX4OWAc9bFuaH4= -github.com/henderiw/apiserver-builder v0.0.6-0.20260218201828-653d0f7e4042 h1:pyTApXvz9r/euWoFZoqzKMybafQlAjo9IDAk2uu8V0I= -github.com/henderiw/apiserver-builder v0.0.6-0.20260218201828-653d0f7e4042/go.mod h1:n5ApsFfaK3h5B1WVEnZ29erGuMV0ovPA0/ErcXeQet0= -github.com/henderiw/apiserver-builder v0.0.6-0.20260218203055-86c6dd0d1193 h1:hRlPgwRlb4i8fbAu2yfeVxw99BaaSxbEU9OdDrBm5bE= -github.com/henderiw/apiserver-builder v0.0.6-0.20260218203055-86c6dd0d1193/go.mod h1:n5ApsFfaK3h5B1WVEnZ29erGuMV0ovPA0/ErcXeQet0= -github.com/henderiw/apiserver-builder v0.0.6-0.20260218205721-520ac97264d3 h1:F8c215zVwkM1vPtLJMRnWohqOK9e0DwYCAiHSBJwzCw= -github.com/henderiw/apiserver-builder v0.0.6-0.20260218205721-520ac97264d3/go.mod h1:n5ApsFfaK3h5B1WVEnZ29erGuMV0ovPA0/ErcXeQet0= -github.com/henderiw/apiserver-builder v0.0.6-0.20260218212602-406f5fc7bbaa h1:9yUs5bIDtz2n95CQ8C8+bsarwpgYsqW3YIYLUqdkgrc= -github.com/henderiw/apiserver-builder v0.0.6-0.20260218212602-406f5fc7bbaa/go.mod h1:n5ApsFfaK3h5B1WVEnZ29erGuMV0ovPA0/ErcXeQet0= -github.com/henderiw/apiserver-builder v0.0.6-0.20260219040518-f1e69f8ea9a3 h1:S6TzLhse6enhZzVqj72qy+H3GzuKD4tukWs84+QOsH8= -github.com/henderiw/apiserver-builder v0.0.6-0.20260219040518-f1e69f8ea9a3/go.mod h1:n5ApsFfaK3h5B1WVEnZ29erGuMV0ovPA0/ErcXeQet0= -github.com/henderiw/apiserver-builder v0.0.6-0.20260219042604-0940a62b5ab6 h1:0BzTdbW5/oJDQ5qdWKFoOkgMPSakLmFWYGcoUAhkUZc= -github.com/henderiw/apiserver-builder v0.0.6-0.20260219042604-0940a62b5ab6/go.mod h1:n5ApsFfaK3h5B1WVEnZ29erGuMV0ovPA0/ErcXeQet0= -github.com/henderiw/apiserver-builder v0.0.6-0.20260219043804-e86807fd6ce5 h1:Wh5LNxgoCEnP3mvEdA5JiPV9LLbrq3KRScv4dV+fMY8= -github.com/henderiw/apiserver-builder v0.0.6-0.20260219043804-e86807fd6ce5/go.mod h1:n5ApsFfaK3h5B1WVEnZ29erGuMV0ovPA0/ErcXeQet0= -github.com/henderiw/apiserver-builder v0.0.6-0.20260219044914-498b0bc2e82b h1:NMPa8cchw2y66ymBTjTBhpK/69LDnelUDf6FJaS09Zg= -github.com/henderiw/apiserver-builder v0.0.6-0.20260219044914-498b0bc2e82b/go.mod h1:Py2AD4oB1McoYpz4chBNAFo9bYeZ9N9cKPijzkMxk2U= -github.com/henderiw/apiserver-builder v0.0.6-0.20260219051624-595e0ea22ab4 h1:dfa+4LWwmk0EZAr+iO+GwUm0fbUxrOtJ9znND8M4Vc4= -github.com/henderiw/apiserver-builder v0.0.6-0.20260219051624-595e0ea22ab4/go.mod h1:Py2AD4oB1McoYpz4chBNAFo9bYeZ9N9cKPijzkMxk2U= -github.com/henderiw/apiserver-builder v0.0.6-0.20260219053658-5ad076035844 h1:w3Bf1/AMhbZwzTjtUiWNrsq5+yBPuPTXfP7yIorbGrQ= -github.com/henderiw/apiserver-builder v0.0.6-0.20260219053658-5ad076035844/go.mod h1:Py2AD4oB1McoYpz4chBNAFo9bYeZ9N9cKPijzkMxk2U= -github.com/henderiw/apiserver-builder v0.0.6-0.20260219055920-ca124837d848 h1:yAa6+4uqiVwGD1nzD1R5xjop2TYetOE6RcPPYrNpH4A= -github.com/henderiw/apiserver-builder v0.0.6-0.20260219055920-ca124837d848/go.mod h1:Py2AD4oB1McoYpz4chBNAFo9bYeZ9N9cKPijzkMxk2U= -github.com/henderiw/apiserver-builder v0.0.6-0.20260219061223-2be11c1e38bf h1:yM/+zMp1HhCkIAsTgSvsgzBs3UY00l14wwZV9f+dmIM= -github.com/henderiw/apiserver-builder v0.0.6-0.20260219061223-2be11c1e38bf/go.mod h1:Py2AD4oB1McoYpz4chBNAFo9bYeZ9N9cKPijzkMxk2U= -github.com/henderiw/apiserver-builder v0.0.6-0.20260219062429-c5918967e841 h1:7JmaObLyDIG6jwclB/ruQvucVPbck1HhSvPNFagkg4E= -github.com/henderiw/apiserver-builder v0.0.6-0.20260219062429-c5918967e841/go.mod h1:Py2AD4oB1McoYpz4chBNAFo9bYeZ9N9cKPijzkMxk2U= -github.com/henderiw/apiserver-builder v0.0.6-0.20260219063725-ed5e767ba219 h1:/F/CNb4e2ta0P9LfRLUFFSfTNJCi/Qtif3tXyhztdg8= -github.com/henderiw/apiserver-builder v0.0.6-0.20260219063725-ed5e767ba219/go.mod h1:Py2AD4oB1McoYpz4chBNAFo9bYeZ9N9cKPijzkMxk2U= -github.com/henderiw/apiserver-builder v0.0.6-0.20260219065618-6d7685c0d18c h1:Cma9idG+MkgzwoGCi9mKKz29V9zhKUhdvxAQ8NmEpEU= -github.com/henderiw/apiserver-builder v0.0.6-0.20260219065618-6d7685c0d18c/go.mod h1:Py2AD4oB1McoYpz4chBNAFo9bYeZ9N9cKPijzkMxk2U= -github.com/henderiw/apiserver-builder v0.0.6-0.20260219070848-d085ab8ef21e h1:BfwL4amzHrSUw+0uGuneYhsPjaSBkHMM7Tt5wo1Jtf0= -github.com/henderiw/apiserver-builder v0.0.6-0.20260219070848-d085ab8ef21e/go.mod h1:Py2AD4oB1McoYpz4chBNAFo9bYeZ9N9cKPijzkMxk2U= -github.com/henderiw/apiserver-builder v0.0.6-0.20260219072317-078f99edf64e h1:KudoxkO9dQZAmH9SS37TynFv2JH0VGWKNllKd9RXfh4= -github.com/henderiw/apiserver-builder v0.0.6-0.20260219072317-078f99edf64e/go.mod h1:Py2AD4oB1McoYpz4chBNAFo9bYeZ9N9cKPijzkMxk2U= -github.com/henderiw/apiserver-builder v0.0.6-0.20260219075034-98a7e4574ec1 h1:6d/HpbDzZyaZZuep+qVFRLHmf4RQznUymYWm/LralFQ= -github.com/henderiw/apiserver-builder v0.0.6-0.20260219075034-98a7e4574ec1/go.mod h1:Py2AD4oB1McoYpz4chBNAFo9bYeZ9N9cKPijzkMxk2U= -github.com/henderiw/apiserver-builder v0.0.6-0.20260219081909-1727866bcd67 h1:bYrPn572ma328A5yrwA3ihirIzgICXhQ7ojGPOE+Y54= -github.com/henderiw/apiserver-builder v0.0.6-0.20260219081909-1727866bcd67/go.mod h1:Py2AD4oB1McoYpz4chBNAFo9bYeZ9N9cKPijzkMxk2U= -github.com/henderiw/apiserver-builder v0.0.6-0.20260219084651-b0a801b267e4 h1:ptAf3qtBchU5ATFxBWwZ3j05SP/RChQoYuzFs6npmlM= -github.com/henderiw/apiserver-builder v0.0.6-0.20260219084651-b0a801b267e4/go.mod h1:Py2AD4oB1McoYpz4chBNAFo9bYeZ9N9cKPijzkMxk2U= -github.com/henderiw/apiserver-builder v0.0.6-0.20260219090415-d2a64fe241f7 h1:FuH321LNd0/A7chR9PplOUYOiPdbsl/8Gx3KkAK+m60= -github.com/henderiw/apiserver-builder v0.0.6-0.20260219090415-d2a64fe241f7/go.mod h1:Py2AD4oB1McoYpz4chBNAFo9bYeZ9N9cKPijzkMxk2U= +github.com/henderiw/apiserver-builder v0.0.6 h1:8vlnpGmQsIgSCVNNSQKaBeHtbAtgCvKoKQii7Vx3YLk= +github.com/henderiw/apiserver-builder v0.0.6/go.mod h1:Py2AD4oB1McoYpz4chBNAFo9bYeZ9N9cKPijzkMxk2U= github.com/henderiw/apiserver-store v0.0.3 h1:cUNzimOvxVKsw+/kj+7IkI/GnRuFlziwCc3AsfYo9zM= github.com/henderiw/apiserver-store v0.0.3/go.mod h1:RuXLMHJwszn6LXgL6fO9fxMC7AW5wAc4zOddnnZpkKI= github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c h1:nFnCNyRV1Ej/zqV/gn8UnFESkoPUXhwpUCZyhSYGSYA= From 19cc872f4e7a760fb224b85917374f33ed5f626d Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Thu, 19 Feb 2026 13:07:49 +0100 Subject: [PATCH 052/135] go fmt --- Makefile | 7 + apis/condition/doc.go | 2 +- apis/config/config_types.go | 4 +- apis/config/configblame_helpers.go | 4 +- apis/config/configblame_types.go | 2 +- apis/config/configset_helpers.go | 2 +- apis/config/configset_types.go | 3 +- apis/config/deviation_clear_types.go | 16 +- apis/config/deviation_helper.go | 2 +- apis/config/deviation_types.go | 9 +- apis/config/handlers/confighandler.go | 10 +- apis/config/running_config_helpers.go | 4 +- apis/config/running_config_types.go | 2 +- apis/config/sensitive_config_types.go | 6 +- apis/config/v1alpha1/condition.go | 4 +- apis/config/v1alpha1/config_helpers.go | 5 +- .../v1alpha1/zz_generated.conversion.go | 10 + apis/inv/doc.go | 2 +- apis/inv/v1alpha1/target_helpers.go | 5 +- cmd/api-server/main.go | 17 +- pkg/discovery/discoveryrule/deviation.go | 6 +- .../discover_gnmi_discoverer_test.go | 10 +- .../discover_gnmi_transform_test.go | 6 +- pkg/discovery/discoveryrule/rule.go | 16 +- pkg/generated/openapi/zz_generated.openapi.go | 21 +- pkg/git/git.go | 2 +- pkg/git/refs.go | 1 - .../prometheusserver/handler_prometheus.go | 6 +- pkg/output/prometheusserver/server.go | 1 - pkg/reconcilers/all/all.go | 6 +- pkg/reconcilers/configset/reconciler.go | 6 +- pkg/reconcilers/ctrlconfig/config.go | 8 +- .../discoveryrule/profiles_test.go | 2 +- pkg/reconcilers/discoveryrule/reconciler.go | 10 +- .../eventhandler/watch_config_for_target.go | 1 - .../watch_deviation_for_config.go | 3 +- .../watch_deviation_for_target.go | 1 - .../watch_targetconnprofile_for_dr.go | 4 +- pkg/reconcilers/resource/fake.go | 2 +- pkg/reconcilers/rollout/reconciler.go | 8 +- pkg/reconcilers/rollout/transaction.go | 31 +-- pkg/reconcilers/rollout/transaction_test.go | 2 +- pkg/reconcilers/schema/reconciler.go | 16 +- pkg/reconcilers/subscription/reconciler.go | 15 +- pkg/reconcilers/target/reconciler.go | 2 - pkg/reconcilers/targetdatastore/reconciler.go | 56 ++-- pkg/reconcilers/workspace/reconciler.go | 4 +- pkg/registry/configblame/strategy_resource.go | 9 +- pkg/registry/options/options.go | 2 +- pkg/registry/store/store.go | 8 +- pkg/sdc/dataserver/client/fake_client.go | 10 +- pkg/sdc/schemaserver/client/client.go | 5 +- pkg/sdc/target/manager/collector.go | 206 +++++++-------- pkg/sdc/target/manager/error.go | 2 +- pkg/sdc/target/manager/exports.go | 1 - pkg/sdc/target/manager/manager.go | 74 +++--- pkg/sdc/target/manager/runtime.go | 2 +- pkg/sdc/target/manager/transactor.go | 42 ++- pkg/sdc/target/manager/utils.go | 8 +- pkg/sdc/target/runtimeview/runtimeview.go | 16 +- .../subscriptionview/subscriptionview.go | 11 +- tools/apiserver-runtime-gen/main.go | 8 +- tools/fix-openapi-gvk/main.go | 250 ++++++++++++++++++ 63 files changed, 624 insertions(+), 392 deletions(-) create mode 100644 tools/fix-openapi-gvk/main.go diff --git a/Makefile b/Makefile index 127e2e29..c51d005a 100644 --- a/Makefile +++ b/Makefile @@ -72,6 +72,13 @@ genproto: -g go-to-protobuf \ --module $(REPO) \ +.PHONY: fix-openapi-gvk +fix-openapi-gvk: + go run ./tools/fix-openapi-gvk/main.go \ + --file pkg/generated/openapi/zz_generated.openapi.go \ + --group config.sdcio.dev \ + --prefix config_server_apis_config_v1alpha1 + .PHONY: generate generate: controller-gen $(CONTROLLER_GEN) object:headerFile="hack/boilerplate.go.txt" paths="./apis/inv/..." diff --git a/apis/condition/doc.go b/apis/condition/doc.go index 88e1f97a..8d621281 100644 --- a/apis/condition/doc.go +++ b/apis/condition/doc.go @@ -17,4 +17,4 @@ limitations under the License. // +k8s:deepcopy-gen=package,register // condition defines the condition api -package condition +package condition diff --git a/apis/config/config_types.go b/apis/config/config_types.go index db2a6855..5524b55a 100644 --- a/apis/config/config_types.go +++ b/apis/config/config_types.go @@ -78,8 +78,8 @@ type Config struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` - Spec ConfigSpec `json:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"` - Status ConfigStatus `json:"status,omitempty" protobuf:"bytes,3,opt,name=status"` + Spec ConfigSpec `json:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"` + Status ConfigStatus `json:"status,omitempty" protobuf:"bytes,3,opt,name=status"` } // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object diff --git a/apis/config/configblame_helpers.go b/apis/config/configblame_helpers.go index b6e22c31..c0a14d96 100644 --- a/apis/config/configblame_helpers.go +++ b/apis/config/configblame_helpers.go @@ -23,7 +23,7 @@ func BuildConfigBlame(meta metav1.ObjectMeta, spec ConfigBlameSpec, status Confi return &ConfigBlame{ TypeMeta: metav1.TypeMeta{ APIVersion: SchemeGroupVersion.Identifier(), - Kind: ConfigBlameKind, + Kind: ConfigBlameKind, }, ObjectMeta: meta, Spec: spec, @@ -38,4 +38,4 @@ func BuildEmptyConfigBlame() *ConfigBlame { Kind: ConfigBlameKind, }, } -} \ No newline at end of file +} diff --git a/apis/config/configblame_types.go b/apis/config/configblame_types.go index 2c5d080c..ffe93fc2 100644 --- a/apis/config/configblame_types.go +++ b/apis/config/configblame_types.go @@ -39,7 +39,7 @@ type ConfigBlameStatus struct { // +kubebuilder:subresource:status // +kubebuilder:resource:categories={sdc} -// ConfigBlame defines the Schema for the ConfigBlame API +// ConfigBlame defines the Schema for the ConfigBlame API type ConfigBlame struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` diff --git a/apis/config/configset_helpers.go b/apis/config/configset_helpers.go index e808b953..66abe023 100644 --- a/apis/config/configset_helpers.go +++ b/apis/config/configset_helpers.go @@ -39,4 +39,4 @@ func BuildEmptyConfigSet() *ConfigSet { Kind: ConfigSetKind, }, } -} \ No newline at end of file +} diff --git a/apis/config/configset_types.go b/apis/config/configset_types.go index 1235010d..20ec0444 100644 --- a/apis/config/configset_types.go +++ b/apis/config/configset_types.go @@ -19,8 +19,8 @@ package config import ( "reflect" - metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "github.com/sdcio/config-server/apis/condition" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" ) // ConfigSetSpec defines the desired state of Config @@ -76,7 +76,6 @@ type ConfigSet struct { Status ConfigSetStatus `json:"status,omitempty" protobuf:"bytes,3,opt,name=status"` } - // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object // +kubebuilder:object:root=true diff --git a/apis/config/deviation_clear_types.go b/apis/config/deviation_clear_types.go index 61636f4f..dadb51a3 100644 --- a/apis/config/deviation_clear_types.go +++ b/apis/config/deviation_clear_types.go @@ -19,17 +19,17 @@ package config import ( "reflect" - metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "github.com/sdcio/config-server/apis/condition" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" ) type DeviationClearType string const ( - DeviationClearType_TARGET DeviationClearType = "target" - DeviationClearType_CONFIG DeviationClearType = "config" - DeviationClearType_ALL_CONFIG DeviationClearType = "allConfig" - DeviationClearType_ALL DeviationClearType = "all" + DeviationClearType_TARGET DeviationClearType = "target" + DeviationClearType_CONFIG DeviationClearType = "config" + DeviationClearType_ALL_CONFIG DeviationClearType = "allConfig" + DeviationClearType_ALL DeviationClearType = "all" ) func (r DeviationClearType) String() string { @@ -53,9 +53,9 @@ type DeviationClearSpec struct { } type DeviationClearItem struct { - Type DeviationClearType `json:"type" protobuf:"bytes,1,opt,name=type"` + Type DeviationClearType `json:"type" protobuf:"bytes,1,opt,name=type"` // Name of the config - mandatory if the type is config - not applicable for the other types - ConfigName *string `json:"configName,omitempty" protobuf:"bytes,2,opt,name=configName"` + ConfigName *string `json:"configName,omitempty" protobuf:"bytes,2,opt,name=configName"` // Paths of the respective type that should be cleared Paths []string `json:"paths" protobuf:"bytes,3,rep,name=paths"` } @@ -74,7 +74,7 @@ type DeviationClearStatus struct { // +kubebuilder:subresource:status // +kubebuilder:resource:categories={sdc} -// DeviationClear is the Schema for the DeviationClear API +// DeviationClear is the Schema for the DeviationClear API type DeviationClear struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` diff --git a/apis/config/deviation_helper.go b/apis/config/deviation_helper.go index 5beaef86..62b30cbb 100644 --- a/apis/config/deviation_helper.go +++ b/apis/config/deviation_helper.go @@ -102,4 +102,4 @@ func BuildEmptyDeviation() *Deviation { Kind: DeviationKind, }, } -} \ No newline at end of file +} diff --git a/apis/config/deviation_types.go b/apis/config/deviation_types.go index 3dee158f..f71c9004 100644 --- a/apis/config/deviation_types.go +++ b/apis/config/deviation_types.go @@ -19,8 +19,8 @@ package config import ( "reflect" - metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "github.com/sdcio/config-server/apis/condition" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" ) // DeviationSpec defines the desired state of Deviation @@ -33,8 +33,8 @@ type DeviationSpec struct { type DeviationType string const ( - DeviationType_TARGET DeviationType = "target" - DeviationType_CONFIG DeviationType = "config" + DeviationType_TARGET DeviationType = "target" + DeviationType_CONFIG DeviationType = "config" ) func (r DeviationType) String() string { @@ -73,7 +73,7 @@ type DeviationStatus struct { // +kubebuilder:subresource:status // +kubebuilder:resource:categories={sdc} -// Deviation is the Schema for the Deviation API +// Deviation is the Schema for the Deviation API type Deviation struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` @@ -82,7 +82,6 @@ type Deviation struct { Status DeviationStatus `json:"status,omitempty" protobuf:"bytes,3,opt,name=status"` } - // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object // +kubebuilder:object:root=true diff --git a/apis/config/handlers/confighandler.go b/apis/config/handlers/confighandler.go index 3c7f945b..55dbcd64 100644 --- a/apis/config/handlers/confighandler.go +++ b/apis/config/handlers/confighandler.go @@ -7,17 +7,16 @@ import ( "github.com/henderiw/apiserver-store/pkg/storebackend" "github.com/sdcio/config-server/apis/config" invv1alpha1 "github.com/sdcio/config-server/apis/inv/v1alpha1" + targetmanager "github.com/sdcio/config-server/pkg/sdc/target/manager" sdcpb "github.com/sdcio/sdc-protos/sdcpb" "k8s.io/apimachinery/pkg/api/meta" "k8s.io/apimachinery/pkg/runtime" "k8s.io/apimachinery/pkg/types" "sigs.k8s.io/controller-runtime/pkg/client" - targetmanager "github.com/sdcio/config-server/pkg/sdc/target/manager" ) - type ConfigStoreHandler struct { - Client client.Client + Client client.Client } func (r *ConfigStoreHandler) DryRunCreateFn(ctx context.Context, key types.NamespacedName, obj runtime.Object, dryrun bool) (runtime.Object, error) { @@ -25,7 +24,7 @@ func (r *ConfigStoreHandler) DryRunCreateFn(ctx context.Context, key types.Names if err != nil { return obj, err } - + updates, err := targetmanager.GetIntentUpdate(ctx, storebackend.KeyFromNSN(key), c, true) if err != nil { return nil, err @@ -78,7 +77,6 @@ func (r *ConfigStoreHandler) DryRunDeleteFn(ctx context.Context, key types.Names return targetmanager.RunDryRunTransaction(ctx, key, c, target, intents, dryrun) } - // prepareConfigAndTarget validates labels, casts the object, fetches the Target // and ensures it's ready. func (r *ConfigStoreHandler) prepareConfigAndTarget( @@ -110,4 +108,4 @@ func (r *ConfigStoreHandler) prepareConfigAndTarget( } return c, target, nil -} \ No newline at end of file +} diff --git a/apis/config/running_config_helpers.go b/apis/config/running_config_helpers.go index 479ff6d3..2c38f41f 100644 --- a/apis/config/running_config_helpers.go +++ b/apis/config/running_config_helpers.go @@ -23,7 +23,7 @@ func BuildRunningConfig(meta metav1.ObjectMeta, spec RunningConfigSpec, status R return &RunningConfig{ TypeMeta: metav1.TypeMeta{ APIVersion: SchemeGroupVersion.Identifier(), - Kind: RunningConfigKind, + Kind: RunningConfigKind, }, ObjectMeta: meta, Spec: spec, @@ -38,4 +38,4 @@ func BuildEmptyRunningConfig() *RunningConfig { Kind: RunningConfigKind, }, } -} \ No newline at end of file +} diff --git a/apis/config/running_config_types.go b/apis/config/running_config_types.go index 7f02947c..59310021 100644 --- a/apis/config/running_config_types.go +++ b/apis/config/running_config_types.go @@ -39,7 +39,7 @@ type RunningConfigStatus struct { // +kubebuilder:subresource:status // +kubebuilder:resource:categories={sdc} -// RunningConfig defines the Schema for the RunningConfig API +// RunningConfig defines the Schema for the RunningConfig API type RunningConfig struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` diff --git a/apis/config/sensitive_config_types.go b/apis/config/sensitive_config_types.go index 78cf316f..ec2b79f1 100644 --- a/apis/config/sensitive_config_types.go +++ b/apis/config/sensitive_config_types.go @@ -19,9 +19,9 @@ package config import ( "reflect" - metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" - corev1 "k8s.io/api/core/v1" "github.com/sdcio/config-server/apis/condition" + corev1 "k8s.io/api/core/v1" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" ) // SensitiveConfigSpec defines the desired state of SensitiveConfig @@ -63,7 +63,7 @@ type SensitiveConfigStatus struct { // +kubebuilder:subresource:status // +kubebuilder:resource:categories={sdc} -// SensitiveConfig defines the Schema for the SensitiveConfig API +// SensitiveConfig defines the Schema for the SensitiveConfig API type SensitiveConfig struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` diff --git a/apis/config/v1alpha1/condition.go b/apis/config/v1alpha1/condition.go index de0a5de1..54579088 100644 --- a/apis/config/v1alpha1/condition.go +++ b/apis/config/v1alpha1/condition.go @@ -61,7 +61,6 @@ func Updating() condv1alpha1.Condition { }} } - // ConfigReady return a condition that indicates the config // get re-applied when the target became ready func ConfigReady(msg string) condv1alpha1.Condition { @@ -86,7 +85,6 @@ func ConfigFailed(msg string) condv1alpha1.Condition { }} } - // TargetReady return a condition that indicates // the target became ready func TargetReady(msg string) condv1alpha1.Condition { @@ -109,4 +107,4 @@ func TargetFailed(msg string) condv1alpha1.Condition { Reason: string(condv1alpha1.ConditionReasonFailed), Message: msg, }} -} \ No newline at end of file +} diff --git a/apis/config/v1alpha1/config_helpers.go b/apis/config/v1alpha1/config_helpers.go index f69e85a9..5f992b35 100644 --- a/apis/config/v1alpha1/config_helpers.go +++ b/apis/config/v1alpha1/config_helpers.go @@ -307,8 +307,7 @@ func (r *Config) SetOverallStatus() { r.Status.SetConditions(condv1alpha1.Failed(msg)) } - -func GetOverallCondition(r *Config) condv1alpha1.Condition { +func GetOverallCondition(r *Config) condv1alpha1.Condition { cfgC := r.GetCondition(ConditionTypeConfigReady) tgtC := r.GetCondition(ConditionTypeTargetReady) @@ -338,4 +337,4 @@ func GetOverallCondition(r *Config) condv1alpha1.Condition { } return condv1alpha1.Failed(msg) -} \ No newline at end of file +} diff --git a/apis/config/v1alpha1/zz_generated.conversion.go b/apis/config/v1alpha1/zz_generated.conversion.go index aa359115..f0cedc83 100644 --- a/apis/config/v1alpha1/zz_generated.conversion.go +++ b/apis/config/v1alpha1/zz_generated.conversion.go @@ -98,6 +98,16 @@ func RegisterConversions(s *runtime.Scheme) error { }); err != nil { return err } + if err := s.AddGeneratedConversionFunc((*ConfigDeviation)(nil), (*config.ConfigDeviation)(nil), func(a, b interface{}, scope conversion.Scope) error { + return Convert_v1alpha1_ConfigDeviation_To_config_ConfigDeviation(a.(*ConfigDeviation), b.(*config.ConfigDeviation), scope) + }); err != nil { + return err + } + if err := s.AddGeneratedConversionFunc((*config.ConfigDeviation)(nil), (*ConfigDeviation)(nil), func(a, b interface{}, scope conversion.Scope) error { + return Convert_config_ConfigDeviation_To_v1alpha1_ConfigDeviation(a.(*config.ConfigDeviation), b.(*ConfigDeviation), scope) + }); err != nil { + return err + } if err := s.AddGeneratedConversionFunc((*ConfigList)(nil), (*config.ConfigList)(nil), func(a, b interface{}, scope conversion.Scope) error { return Convert_v1alpha1_ConfigList_To_config_ConfigList(a.(*ConfigList), b.(*config.ConfigList), scope) }); err != nil { diff --git a/apis/inv/doc.go b/apis/inv/doc.go index a4f1bbfb..44805679 100644 --- a/apis/inv/doc.go +++ b/apis/inv/doc.go @@ -17,4 +17,4 @@ limitations under the License. // +k8s:deepcopy-gen=package,register // condition defines the condition api -package inv +package inv diff --git a/apis/inv/v1alpha1/target_helpers.go b/apis/inv/v1alpha1/target_helpers.go index aef722e7..e9dff6a6 100644 --- a/apis/inv/v1alpha1/target_helpers.go +++ b/apis/inv/v1alpha1/target_helpers.go @@ -67,7 +67,6 @@ func (r *Target) SetOverallStatus(target *Target) { } } - func GetOverallStatus(target *Target) condv1alpha1.Condition { ready := true msg := "target ready" @@ -89,8 +88,8 @@ func GetOverallStatus(target *Target) condv1alpha1.Condition { } if !ready { return condv1alpha1.Failed(msg) - } - return condv1alpha1.Ready() + } + return condv1alpha1.Ready() } func (r *Target) IsDatastoreReady() bool { diff --git a/cmd/api-server/main.go b/cmd/api-server/main.go index 27f53591..6b003e12 100644 --- a/cmd/api-server/main.go +++ b/cmd/api-server/main.go @@ -45,14 +45,14 @@ import ( "k8s.io/component-base/logs" "k8s.io/utils/ptr" ctrl "sigs.k8s.io/controller-runtime" - "sigs.k8s.io/controller-runtime/pkg/log/zap" "sigs.k8s.io/controller-runtime/pkg/healthz" + "sigs.k8s.io/controller-runtime/pkg/log/zap" "sigs.k8s.io/controller-runtime/pkg/metrics/filters" metricsserver "sigs.k8s.io/controller-runtime/pkg/metrics/server" ) var ( - configDir = "/config" + configDir = "/config" ) func main() { @@ -84,7 +84,6 @@ func main() { } } - var tlsOpts []func(*tls.Config) metricsServerOptions := metricsserver.Options{ BindAddress: MetricBindAddress(), @@ -99,7 +98,6 @@ func main() { // this setup is not recommended for production. TLSOpts: tlsOpts, } - mgr_options := ctrl.Options{ Scheme: runScheme, @@ -133,7 +131,7 @@ func main() { } configHandler := handlers.ConfigStoreHandler{ - Client: mgr.GetClient(), + Client: mgr.GetClient(), } configregistryOptions := *registryOptions @@ -149,15 +147,15 @@ func main() { deviationStorageProvider := genericregistry.NewStorageProvider(ctx, sdcconfig.BuildEmptyDeviation(), registryOptions) // no storage required since the targetStore is acting as the storage for the running config resource runningConfigStorageProvider := runningconfigregistry.NewStorageProvider(ctx, sdcconfig.BuildEmptyRunningConfig(), &options.Options{ - Client: mgr.GetClient(), + Client: mgr.GetClient(), //TargetStore: targetStore, }) // no storage required since the targetStore is acting as the storage for the running config resource configBlameStorageProvider := configblameregistry.NewStorageProvider(ctx, sdcconfig.BuildEmptyConfigBlame(), &options.Options{ - Client: mgr.GetClient(), + Client: mgr.GetClient(), //TargetStore: targetStore, }) - + go func() { if err := builder.APIServer. WithServerName("config-server"). @@ -207,10 +205,9 @@ func IsPProfEnabled() *string { return nil } - func MetricBindAddress() string { if val, found := os.LookupEnv("METRIC_PORT"); found { return fmt.Sprintf(":%s", val) } return ":8443" -} \ No newline at end of file +} diff --git a/pkg/discovery/discoveryrule/deviation.go b/pkg/discovery/discoveryrule/deviation.go index 6251d316..e3eb8f19 100644 --- a/pkg/discovery/discoveryrule/deviation.go +++ b/pkg/discovery/discoveryrule/deviation.go @@ -20,14 +20,14 @@ import ( "context" "github.com/henderiw/logger/log" - configv1alpha1 "github.com/sdcio/config-server/apis/config/v1alpha1" "github.com/sdcio/config-server/apis/config" + configv1alpha1 "github.com/sdcio/config-server/apis/config/v1alpha1" + invv1alpha1 "github.com/sdcio/config-server/apis/inv/v1alpha1" "github.com/sdcio/config-server/pkg/reconcilers/resource" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/apimachinery/pkg/runtime/schema" "k8s.io/apimachinery/pkg/types" "k8s.io/utils/ptr" - invv1alpha1 "github.com/sdcio/config-server/apis/inv/v1alpha1" ) func (r *dr) applyTargetDeviationCR(ctx context.Context, target *invv1alpha1.Target) error { @@ -86,7 +86,7 @@ func (r *dr) newDeviationCR(_ context.Context, target *invv1alpha1.Target) (*con }, Spec: configv1alpha1.DeviationSpec{ DeviationType: ptr.To(configv1alpha1.DeviationType_TARGET), - Deviations: []configv1alpha1.ConfigDeviation{}, + Deviations: []configv1alpha1.ConfigDeviation{}, }, Status: configv1alpha1.DeviationStatus{}, }, nil diff --git a/pkg/discovery/discoveryrule/discover_gnmi_discoverer_test.go b/pkg/discovery/discoveryrule/discover_gnmi_discoverer_test.go index 494b5779..c125300c 100644 --- a/pkg/discovery/discoveryrule/discover_gnmi_discoverer_test.go +++ b/pkg/discovery/discoveryrule/discover_gnmi_discoverer_test.go @@ -35,24 +35,24 @@ const ( func TestGetDiscovererGNMI(t *testing.T) { cases := map[string]struct { - capabilityFile string + capabilityFile string expectedProvider string expectError bool }{ "NokiaSROS": { - capabilityFile: "data/nokia-sros-capabilities.json", + capabilityFile: "data/nokia-sros-capabilities.json", expectedProvider: "sros.nokia.sdcio.dev", }, "NokiaSRL": { - capabilityFile: "data/nokia-srl-capabilities.json", + capabilityFile: "data/nokia-srl-capabilities.json", expectedProvider: "srl.nokia.sdcio.dev", }, "Arista": { - capabilityFile: "data/arista-capabilities.json", + capabilityFile: "data/arista-capabilities.json", expectedProvider: "eos.arista.sdcio.dev", }, "Unknown": { - capabilityFile: "data/unknown-capabilities.json", + capabilityFile: "data/unknown-capabilities.json", expectedProvider: "eos.arista.sdcio.dev", expectError: true, }, diff --git a/pkg/discovery/discoveryrule/discover_gnmi_transform_test.go b/pkg/discovery/discoveryrule/discover_gnmi_transform_test.go index 11edecb6..d514d4f3 100644 --- a/pkg/discovery/discoveryrule/discover_gnmi_transform_test.go +++ b/pkg/discovery/discoveryrule/discover_gnmi_transform_test.go @@ -62,9 +62,9 @@ func TestApplyRegex(t *testing.T) { shouldError: true, }, { - name: "Version", - pattern: `^v?(\d+\.\d+\.\d+)`, - value: "v24.3.2-118-g706b4f0d99", + name: "Version", + pattern: `^v?(\d+\.\d+\.\d+)`, + value: "v24.3.2-118-g706b4f0d99", expected: "24.3.2", }, } diff --git a/pkg/discovery/discoveryrule/rule.go b/pkg/discovery/discoveryrule/rule.go index 46f50e97..b86b77b1 100644 --- a/pkg/discovery/discoveryrule/rule.go +++ b/pkg/discovery/discoveryrule/rule.go @@ -26,9 +26,9 @@ import ( "github.com/henderiw/apiserver-store/pkg/storebackend" "github.com/henderiw/apiserver-store/pkg/storebackend/memory" "github.com/henderiw/logger/log" + invv1alpha1 "github.com/sdcio/config-server/apis/inv/v1alpha1" "golang.org/x/sync/semaphore" "sigs.k8s.io/controller-runtime/pkg/client" - invv1alpha1 "github.com/sdcio/config-server/apis/inv/v1alpha1" ) type DiscoveryRule interface { @@ -46,14 +46,13 @@ func New(client client.Client, cfg *DiscoveryRuleConfig) DiscoveryRule { } type dr struct { - client client.Client - cfg *DiscoveryRuleConfig - protocols *protocols - children storebackend.Storer[string] - + client client.Client + cfg *DiscoveryRuleConfig + protocols *protocols + children storebackend.Storer[string] gnmiDiscoveryProfiles map[string]invv1alpha1.GnmiDiscoveryVendorProfileParameters - cancel context.CancelFunc + cancel context.CancelFunc } func (r *dr) Stop(ctx context.Context) { @@ -143,7 +142,6 @@ func (r *dr) run(ctx context.Context) error { return nil } - func (r *dr) getVendorDiscoveryProfiles(ctx context.Context) error { discoveryVendorProfiles := &invv1alpha1.DiscoveryVendorProfileList{} if err := r.client.List(ctx, discoveryVendorProfiles); err != nil { @@ -155,4 +153,4 @@ func (r *dr) getVendorDiscoveryProfiles(ctx context.Context) error { r.gnmiDiscoveryProfiles[discoveryProfile.Name] = discoveryProfile.Spec.Gnmi } return nil -} \ No newline at end of file +} diff --git a/pkg/generated/openapi/zz_generated.openapi.go b/pkg/generated/openapi/zz_generated.openapi.go index 5537c321..46591b55 100644 --- a/pkg/generated/openapi/zz_generated.openapi.go +++ b/pkg/generated/openapi/zz_generated.openapi.go @@ -588,8 +588,8 @@ func schema_config_server_apis_config_v1alpha1_Config(ref common.ReferenceCallba }, }, Dependencies: []string{ - "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigSpec", "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigStatus", metav1.ObjectMeta{}.OpenAPIModelName()}, - } + "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigSpec", "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigStatus", metav1.ObjectMeta{}.OpenAPIModelName()}, + } } func schema_config_server_apis_config_v1alpha1_ConfigBlame(ref common.ReferenceCallback) common.OpenAPIDefinition { @@ -641,8 +641,7 @@ func schema_config_server_apis_config_v1alpha1_ConfigBlame(ref common.ReferenceC }, }, }, - - Dependencies: []string{ + Dependencies: []string{ "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigBlameSpec", "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigBlameStatus", metav1.ObjectMeta{}.OpenAPIModelName()}, } } @@ -893,9 +892,7 @@ func schema_config_server_apis_config_v1alpha1_ConfigSet(ref common.ReferenceCal }, }, }, - - - Dependencies: []string{ + Dependencies: []string{ "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigSetSpec", "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigSetStatus", metav1.ObjectMeta{}.OpenAPIModelName()}, } } @@ -1261,8 +1258,8 @@ func schema_config_server_apis_config_v1alpha1_Deviation(ref common.ReferenceCal }, }, Dependencies: []string{ - "github.com/sdcio/config-server/apis/config/v1alpha1.DeviationSpec", "github.com/sdcio/config-server/apis/config/v1alpha1.DeviationStatus", metav1.ObjectMeta{}.OpenAPIModelName()}, - } + "github.com/sdcio/config-server/apis/config/v1alpha1.DeviationSpec", "github.com/sdcio/config-server/apis/config/v1alpha1.DeviationStatus", metav1.ObjectMeta{}.OpenAPIModelName()}, + } } func schema_config_server_apis_config_v1alpha1_DeviationList(ref common.ReferenceCallback) common.OpenAPIDefinition { @@ -1459,8 +1456,7 @@ func schema_config_server_apis_config_v1alpha1_RunningConfig(ref common.Referenc }, }, }, - - Dependencies: []string{ + Dependencies: []string{ "github.com/sdcio/config-server/apis/config/v1alpha1.RunningConfigSpec", "github.com/sdcio/config-server/apis/config/v1alpha1.RunningConfigStatus", metav1.ObjectMeta{}.OpenAPIModelName()}, } } @@ -1595,8 +1591,7 @@ func schema_config_server_apis_config_v1alpha1_SensitiveConfig(ref common.Refere }, }, }, - - Dependencies: []string{ + Dependencies: []string{ "github.com/sdcio/config-server/apis/config/v1alpha1.SensitiveConfigSpec", "github.com/sdcio/config-server/apis/config/v1alpha1.SensitiveConfigStatus", metav1.ObjectMeta{}.OpenAPIModelName()}, } } diff --git a/pkg/git/git.go b/pkg/git/git.go index 6b324c84..47f62649 100644 --- a/pkg/git/git.go +++ b/pkg/git/git.go @@ -575,4 +575,4 @@ func (g *GoGit) CurrentReference() (string, error) { return "", fmt.Errorf("could not get git HEAD: %w", err) } return h.Hash().String(), nil -} \ No newline at end of file +} diff --git a/pkg/git/refs.go b/pkg/git/refs.go index 2ba0effe..80f56903 100644 --- a/pkg/git/refs.go +++ b/pkg/git/refs.go @@ -29,7 +29,6 @@ const ( BranchPrefixInLocalRepo = "refs/heads/" TagsPrefixInLocalRepo = "refs/tags/" TagsPrefixInRemoteRepo = "refs/tags/" - ) var ( diff --git a/pkg/output/prometheusserver/handler_prometheus.go b/pkg/output/prometheusserver/handler_prometheus.go index 6a0a6156..4b486b53 100644 --- a/pkg/output/prometheusserver/handler_prometheus.go +++ b/pkg/output/prometheusserver/handler_prometheus.go @@ -36,9 +36,9 @@ func (r *PrometheusServer) Collect(ch chan<- prometheus.Metric) { log := log.FromContext(ctx) runtimes := make([]targetruntimeview.TargetRuntimeView, 0) - r.targetManager.ForEachRuntime(func(rt targetruntimeview.TargetRuntimeView) { - runtimes = append(runtimes, rt) - }) + r.targetManager.ForEachRuntime(func(rt targetruntimeview.TargetRuntimeView) { + runtimes = append(runtimes, rt) + }) log.Info("prometheus collect", "targets", len(runtimes)) wg1 := new(sync.WaitGroup) diff --git a/pkg/output/prometheusserver/server.go b/pkg/output/prometheusserver/server.go index f912e76e..9ef33114 100644 --- a/pkg/output/prometheusserver/server.go +++ b/pkg/output/prometheusserver/server.go @@ -29,7 +29,6 @@ import ( "github.com/prometheus/client_golang/prometheus/promhttp" targetruntimeview "github.com/sdcio/config-server/pkg/sdc/target/runtimeview" certutil "k8s.io/client-go/util/cert" - ) type Config struct { diff --git a/pkg/reconcilers/all/all.go b/pkg/reconcilers/all/all.go index ed606c30..15be5299 100644 --- a/pkg/reconcilers/all/all.go +++ b/pkg/reconcilers/all/all.go @@ -19,12 +19,12 @@ package all import ( _ "github.com/sdcio/config-server/pkg/reconcilers/configset" _ "github.com/sdcio/config-server/pkg/reconcilers/discoveryrule" + _ "github.com/sdcio/config-server/pkg/reconcilers/rollout" _ "github.com/sdcio/config-server/pkg/reconcilers/schema" + _ "github.com/sdcio/config-server/pkg/reconcilers/subscription" _ "github.com/sdcio/config-server/pkg/reconcilers/target" - _ "github.com/sdcio/config-server/pkg/reconcilers/targetrecovery" _ "github.com/sdcio/config-server/pkg/reconcilers/targetconfig" _ "github.com/sdcio/config-server/pkg/reconcilers/targetdatastore" - _ "github.com/sdcio/config-server/pkg/reconcilers/subscription" + _ "github.com/sdcio/config-server/pkg/reconcilers/targetrecovery" _ "github.com/sdcio/config-server/pkg/reconcilers/workspace" - _ "github.com/sdcio/config-server/pkg/reconcilers/rollout" ) diff --git a/pkg/reconcilers/configset/reconciler.go b/pkg/reconcilers/configset/reconciler.go index 865ca503..ca0965e0 100644 --- a/pkg/reconcilers/configset/reconciler.go +++ b/pkg/reconcilers/configset/reconciler.go @@ -20,17 +20,17 @@ import ( "context" merrors "errors" "fmt" + "reflect" "sort" "strings" - "reflect" "github.com/henderiw/logger/log" "github.com/pkg/errors" condv1alpha1 "github.com/sdcio/config-server/apis/condition/v1alpha1" - configv1alpha1apply "github.com/sdcio/config-server/pkg/generated/applyconfiguration/config/v1alpha1" "github.com/sdcio/config-server/apis/config" configv1alpha1 "github.com/sdcio/config-server/apis/config/v1alpha1" invv1alpha1 "github.com/sdcio/config-server/apis/inv/v1alpha1" + configv1alpha1apply "github.com/sdcio/config-server/pkg/generated/applyconfiguration/config/v1alpha1" "github.com/sdcio/config-server/pkg/reconcilers" "github.com/sdcio/config-server/pkg/reconcilers/ctrlconfig" "github.com/sdcio/config-server/pkg/reconcilers/eventhandler" @@ -410,4 +410,4 @@ func targetStatusToApply(targets []configv1alpha1.TargetStatus) []*configv1alpha ) } return result -} \ No newline at end of file +} diff --git a/pkg/reconcilers/ctrlconfig/config.go b/pkg/reconcilers/ctrlconfig/config.go index 1e196380..ecd86a99 100644 --- a/pkg/reconcilers/ctrlconfig/config.go +++ b/pkg/reconcilers/ctrlconfig/config.go @@ -20,11 +20,11 @@ import ( "context" "github.com/henderiw/logger/log" + dsmanager "github.com/sdcio/config-server/pkg/sdc/dataserver/manager" + targetmanager "github.com/sdcio/config-server/pkg/sdc/target/manager" "k8s.io/apimachinery/pkg/types" "k8s.io/client-go/discovery" "sigs.k8s.io/controller-runtime/pkg/manager" - dsmanager "github.com/sdcio/config-server/pkg/sdc/dataserver/manager" - targetmanager "github.com/sdcio/config-server/pkg/sdc/target/manager" ) type ControllerConfig struct { @@ -32,8 +32,8 @@ type ControllerConfig struct { //DataServerStore storebackend.Storer[sdcctx.DSContext] SchemaDir string WorkspaceDir string - DataServerManager *dsmanager.DSConnManager - TargetManager *targetmanager.TargetManager + DataServerManager *dsmanager.DSConnManager + TargetManager *targetmanager.TargetManager } func InitContext(ctx context.Context, controllerName string, req types.NamespacedName) context.Context { diff --git a/pkg/reconcilers/discoveryrule/profiles_test.go b/pkg/reconcilers/discoveryrule/profiles_test.go index 651a5b83..b4b8f734 100644 --- a/pkg/reconcilers/discoveryrule/profiles_test.go +++ b/pkg/reconcilers/discoveryrule/profiles_test.go @@ -42,7 +42,7 @@ func createFakeClient(secret, targetConnProfile, targetSyncProfile string) clien if err := clientgoscheme.AddToScheme(runScheme); err != nil { log.Error("cannot add scheme", "err", err) } - if err := invv1alpha1.AddToScheme(runScheme) ; err != nil { + if err := invv1alpha1.AddToScheme(runScheme); err != nil { log.Error("cannot add scheme", "err", err) } client := fake.NewClientBuilder().WithScheme(runScheme).Build() diff --git a/pkg/reconcilers/discoveryrule/reconciler.go b/pkg/reconcilers/discoveryrule/reconciler.go index 504879e4..7dd5ed54 100644 --- a/pkg/reconcilers/discoveryrule/reconciler.go +++ b/pkg/reconcilers/discoveryrule/reconciler.go @@ -27,8 +27,8 @@ import ( errors "github.com/pkg/errors" condv1alpha1 "github.com/sdcio/config-server/apis/condition/v1alpha1" invv1alpha1 "github.com/sdcio/config-server/apis/inv/v1alpha1" - invv1alpha1apply "github.com/sdcio/config-server/pkg/generated/applyconfiguration/inv/v1alpha1" "github.com/sdcio/config-server/pkg/discovery/discoveryrule" + invv1alpha1apply "github.com/sdcio/config-server/pkg/generated/applyconfiguration/inv/v1alpha1" "github.com/sdcio/config-server/pkg/reconcilers" "github.com/sdcio/config-server/pkg/reconcilers/ctrlconfig" "github.com/sdcio/config-server/pkg/reconcilers/eventhandler" @@ -77,7 +77,7 @@ func (r *reconciler) SetupWithManager(ctx context.Context, mgr ctrl.Manager, c i } type reconciler struct { - client client.Client + client client.Client finalizer *resource.APIFinalizer discoveryStore storebackend.Storer[discoveryrule.DiscoveryRule] @@ -175,7 +175,7 @@ func (r *reconciler) Reconcile(ctx context.Context, req ctrl.Request) (ctrl.Resu // new discovery initialization -> create or update (we deleted the DRConfig before) if err := r.discoveryStore.Create(ctx, key, dr); err != nil { // given this is a ummutable field this means the CR will have to be deleted/recreated - return ctrl.Result{Requeue: true}, + return ctrl.Result{Requeue: true}, errors.Wrap(r.handleError(ctx, discoveryRuleOrig, "cannot get normalized discoveryRule", err), errUpdateStatus) } @@ -258,7 +258,7 @@ func (r *reconciler) HasChanged(ctx context.Context, newDRConfig, currentDRConfi func (r *reconciler) handleSuccess(ctx context.Context, discoveryRule *invv1alpha1.DiscoveryRule, changed bool) error { log := log.FromContext(ctx) log.Debug("handleSuccess", "key", discoveryRule.GetNamespacedName(), "status old", discoveryRule.DeepCopy().Status) - + newCond := condv1alpha1.Ready() oldCond := discoveryRule.GetCondition(condv1alpha1.ConditionTypeReady) @@ -287,7 +287,7 @@ func (r *reconciler) handleSuccess(ctx context.Context, discoveryRule *invv1alph func (r *reconciler) handleError(ctx context.Context, discoveryRule *invv1alpha1.DiscoveryRule, msg string, err error) error { log := log.FromContext(ctx) - + if err != nil { msg = fmt.Sprintf("%s err %s", msg, err.Error()) } diff --git a/pkg/reconcilers/eventhandler/watch_config_for_target.go b/pkg/reconcilers/eventhandler/watch_config_for_target.go index eac14eb5..fa95d69c 100644 --- a/pkg/reconcilers/eventhandler/watch_config_for_target.go +++ b/pkg/reconcilers/eventhandler/watch_config_for_target.go @@ -64,7 +64,6 @@ func (r *ConfigForTargetEventHandler) add(ctx context.Context, obj runtime.Objec ctx = ctrlconfig.InitContext(ctx, r.ControllerName, types.NamespacedName{Namespace: "config-event", Name: config.GetName()}) log := log.FromContext(ctx) - targetKey, err := config.GetTargetNamespaceName() if err != nil { log.Error(err.Error()) diff --git a/pkg/reconcilers/eventhandler/watch_deviation_for_config.go b/pkg/reconcilers/eventhandler/watch_deviation_for_config.go index f6c873cd..03b470c3 100644 --- a/pkg/reconcilers/eventhandler/watch_deviation_for_config.go +++ b/pkg/reconcilers/eventhandler/watch_deviation_for_config.go @@ -64,13 +64,12 @@ func (r *DeviationForConfigEventHandler) add(ctx context.Context, obj runtime.Ob ctx = ctrlconfig.InitContext(ctx, r.ControllerName, types.NamespacedName{Namespace: "deviation-event", Name: deviation.GetName()}) log := log.FromContext(ctx) - for _, owner := range deviation.OwnerReferences { if owner.APIVersion == configv1alpha1.SchemeGroupVersion.String() && owner.Kind == configv1alpha1.ConfigKind { key := types.NamespacedName{ Namespace: deviation.Namespace, Name: deviation.Name, - } + } log.Info("event requeue config from deviation", "key", key.String()) queue.Add(reconcile.Request{NamespacedName: key}) } diff --git a/pkg/reconcilers/eventhandler/watch_deviation_for_target.go b/pkg/reconcilers/eventhandler/watch_deviation_for_target.go index 8104d1c3..73cc865f 100644 --- a/pkg/reconcilers/eventhandler/watch_deviation_for_target.go +++ b/pkg/reconcilers/eventhandler/watch_deviation_for_target.go @@ -64,7 +64,6 @@ func (r *DeviationForTargetEventHandler) add(ctx context.Context, obj runtime.Ob ctx = ctrlconfig.InitContext(ctx, r.ControllerName, types.NamespacedName{Namespace: "deviation-event", Name: deviation.GetName()}) log := log.FromContext(ctx) - targetKey, err := deviation.GetTargetNamespaceName() if err != nil { log.Error(err.Error()) diff --git a/pkg/reconcilers/eventhandler/watch_targetconnprofile_for_dr.go b/pkg/reconcilers/eventhandler/watch_targetconnprofile_for_dr.go index 43dc3d57..3c1a9beb 100644 --- a/pkg/reconcilers/eventhandler/watch_targetconnprofile_for_dr.go +++ b/pkg/reconcilers/eventhandler/watch_targetconnprofile_for_dr.go @@ -30,7 +30,7 @@ import ( ) type TargetConnProfileForDiscoveryRuleEventHandler struct { - Client client.Client + Client client.Client } // Create enqueues a request @@ -68,7 +68,7 @@ func (r *TargetConnProfileForDiscoveryRuleEventHandler) add(ctx context.Context, opts := []client.ListOption{ client.InNamespace(cr.Namespace), } - drs := &invv1alpha1.DiscoveryRuleList{} + drs := &invv1alpha1.DiscoveryRuleList{} if err := r.Client.List(ctx, drs, opts...); err != nil { log.Error("cannot list discovery rules", "error", err) return diff --git a/pkg/reconcilers/resource/fake.go b/pkg/reconcilers/resource/fake.go index d0049e63..5c584d06 100644 --- a/pkg/reconcilers/resource/fake.go +++ b/pkg/reconcilers/resource/fake.go @@ -401,4 +401,4 @@ func (m *MockSubResourceClient) Patch(ctx context.Context, obj client.Object, pa // Apply a sub-resource func (m *MockSubResourceClient) Apply(ctx context.Context, cfg runtime.ApplyConfiguration, opts ...client.SubResourceApplyOption) error { return m.MockApply(ctx, cfg, opts...) -} \ No newline at end of file +} diff --git a/pkg/reconcilers/rollout/reconciler.go b/pkg/reconcilers/rollout/reconciler.go index 711c3a3d..00734887 100644 --- a/pkg/reconcilers/rollout/reconciler.go +++ b/pkg/reconcilers/rollout/reconciler.go @@ -59,8 +59,8 @@ const ( reconcilerName = "RolloutController" finalizer = "rollout.inv.sdcio.dev/finalizer" // errors - errGetCr = "cannot get cr" - errUpdateStatus = "cannot update status" + errGetCr = "cannot get cr" + errUpdateStatus = "cannot update status" ) // SetupWithManager sets up the controller with the Manager. @@ -92,7 +92,7 @@ func (r *reconciler) SetupWithManager(ctx context.Context, mgr ctrl.Manager, c i } type reconciler struct { - client client.Client + client client.Client finalizer *resource.APIFinalizer workspaceReader *workspacereader.Reader recorder events.EventRecorder @@ -326,7 +326,7 @@ func (r *reconciler) handleStatus( err error, ) (ctrl.Result, error) { log := log.FromContext(ctx).With("ref", rollout.Spec.Ref) - + if err != nil { condition.Message = fmt.Sprintf("%s err %s", condition.Message, err.Error()) } diff --git a/pkg/reconcilers/rollout/transaction.go b/pkg/reconcilers/rollout/transaction.go index dea142cb..c13e8930 100644 --- a/pkg/reconcilers/rollout/transaction.go +++ b/pkg/reconcilers/rollout/transaction.go @@ -28,22 +28,22 @@ import ( "github.com/henderiw/logger/log" "github.com/sdcio/config-server/apis/config" invv1alpha1 "github.com/sdcio/config-server/apis/inv/v1alpha1" + dsclient "github.com/sdcio/config-server/pkg/sdc/dataserver/client" + sdcpb "github.com/sdcio/sdc-protos/sdcpb" v1 "k8s.io/api/flowcontrol/v1" "k8s.io/apimachinery/pkg/types" "k8s.io/apimachinery/pkg/util/sets" "sigs.k8s.io/controller-runtime/pkg/client" - dsclient "github.com/sdcio/config-server/pkg/sdc/dataserver/client" - sdcpb "github.com/sdcio/sdc-protos/sdcpb" ) type transactionManager struct { newTargetUpdateConfigStore storebackend.Storer[storebackend.Storer[*config.Config]] newTargetDeleteConfigStore storebackend.Storer[storebackend.Storer[*config.Config]] //targetHandler target.TargetHandler - client client.Client - globalTimeout time.Duration - targetTimeout time.Duration - skipUnavailableTarget bool + client client.Client + globalTimeout time.Duration + targetTimeout time.Duration + skipUnavailableTarget bool // derived targets sets.Set[types.NamespacedName] targetStatus storebackend.Storer[invv1alpha1.RolloutTargetStatus] @@ -59,7 +59,7 @@ func NewTransactionManager( tm := &transactionManager{ newTargetUpdateConfigStore: newTargetUpdateConfigStore, newTargetDeleteConfigStore: newTargetDeleteConfigStore, - client: client, + client: client, globalTimeout: globalTimeout, targetTimeout: targetTimeout, targetStatus: memstore.NewStore[invv1alpha1.RolloutTargetStatus](), @@ -96,16 +96,14 @@ func (r *transactionManager) TransactToAllTargets(ctx context.Context, transacti errChan := make(chan error, r.targets.Len()) done := make(chan struct{}) - - for _, targetKey := range r.targets.UnsortedList() { t := &invv1alpha1.Target{} - if err := r.client.Get(ctx, targetKey, t); err != nil { + if err := r.client.Get(ctx, targetKey, t); err != nil { // target unavailable -> we continue for now targetStatus := invv1alpha1.RolloutTargetStatus{Name: targetKey.String()} targetStatus.SetConditions(invv1alpha1.ConfigApplyUnavailable(fmt.Sprintf("target unavailable %s", err.Error()))) _ = r.targetStatus.Update(ctx, storebackend.KeyFromNSN(targetKey), targetStatus) - if r.skipUnavailableTarget { + if r.skipUnavailableTarget { globalCancel() return r.targetStatus, fmt.Errorf("transaction aborted: target %s is unavailable", targetKey.String()) } @@ -116,14 +114,13 @@ func (r *transactionManager) TransactToAllTargets(ctx context.Context, transacti targetStatus := invv1alpha1.RolloutTargetStatus{Name: targetKey.String()} targetStatus.SetConditions(invv1alpha1.ConfigApplyUnavailable("target not ready")) _ = r.targetStatus.Update(ctx, storebackend.KeyFromNSN(targetKey), targetStatus) - if r.skipUnavailableTarget { + if r.skipUnavailableTarget { globalCancel() return r.targetStatus, fmt.Errorf("transaction aborted: target %s is not ready", targetKey.String()) } continue } - wg.Add(1) go func(targetKey types.NamespacedName) { targetStatus := invv1alpha1.RolloutTargetStatus{Name: targetKey.String()} @@ -200,7 +197,7 @@ func (r *transactionManager) RollbackTargets(ctx context.Context, transactionID } else { targetStatus.SetConditions(invv1alpha1.ConfigCancelReady()) } - if err := r.targetStatus.Update(ctx, storebackend.KeyFromNSN(targetKey), targetStatus); err != nil { + if err := r.targetStatus.Update(ctx, storebackend.KeyFromNSN(targetKey), targetStatus); err != nil { log.Error("target status update failed", "err", err) } }(targetKey) @@ -273,7 +270,7 @@ func (r *transactionManager) cancel(ctx context.Context, targetKey types.Namespa return err } return nil - }) + }) close(done) }() @@ -315,7 +312,7 @@ func (r *transactionManager) confirm(ctx context.Context, targetKey types.Namesp return err } return nil - }) + }) close(done) }() @@ -378,7 +375,7 @@ func (r *transactionManager) applyConfigToTarget(ctx context.Context, targetKey return err } return nil - }) + }) close(done) }() diff --git a/pkg/reconcilers/rollout/transaction_test.go b/pkg/reconcilers/rollout/transaction_test.go index 0024e5f4..8102cafb 100644 --- a/pkg/reconcilers/rollout/transaction_test.go +++ b/pkg/reconcilers/rollout/transaction_test.go @@ -195,4 +195,4 @@ func getTransctionManager(targets map[string]*target.MockContext, updates, delet return NewTransactionManager(updateStore, deleteStore, nil, 5*time.Second, 2*time.Second, true) } -*/ \ No newline at end of file +*/ diff --git a/pkg/reconcilers/schema/reconciler.go b/pkg/reconcilers/schema/reconciler.go index f5fbb9fe..ef109ec8 100644 --- a/pkg/reconcilers/schema/reconciler.go +++ b/pkg/reconcilers/schema/reconciler.go @@ -27,8 +27,8 @@ import ( pkgerrors "github.com/pkg/errors" condv1alpha1 "github.com/sdcio/config-server/apis/condition/v1alpha1" invv1alpha1 "github.com/sdcio/config-server/apis/inv/v1alpha1" - invv1alpha1apply "github.com/sdcio/config-server/pkg/generated/applyconfiguration/inv/v1alpha1" sdcerrors "github.com/sdcio/config-server/pkg/errors" + invv1alpha1apply "github.com/sdcio/config-server/pkg/generated/applyconfiguration/inv/v1alpha1" "github.com/sdcio/config-server/pkg/git/auth/secret" "github.com/sdcio/config-server/pkg/reconcilers" "github.com/sdcio/config-server/pkg/reconcilers/ctrlconfig" @@ -57,12 +57,10 @@ const ( reconcilerName = "SchemaController" finalizer = "schema.inv.sdcio.dev/finalizer" // errors - errGetCr = "cannot get cr" - errUpdateStatus = "cannot update status" + errGetCr = "cannot get cr" + errUpdateStatus = "cannot update status" ) - - // SetupWithManager sets up the controller with the Manager. func (r *reconciler) SetupWithManager(ctx context.Context, mgr ctrl.Manager, c interface{}) (map[schema.GroupVersionKind]chan event.GenericEvent, error) { var err error @@ -95,7 +93,7 @@ func (r *reconciler) SetupWithManager(ctx context.Context, mgr ctrl.Manager, c i } type reconciler struct { - client client.Client + client client.Client finalizer *resource.APIFinalizer schemaLoader *schemaloader.Loader @@ -139,7 +137,6 @@ func (r *reconciler) Reconcile(ctx context.Context, req ctrl.Request) (ctrl.Resu } }() - // check if the schema exists; this is == nil check; in case of err it does not exist if _, err := schemaclient.GetSchemaDetails(ctx, &sdcpb.GetSchemaDetailsRequest{ Schema: spec.GetSchema(), @@ -256,7 +253,7 @@ func (r *reconciler) Reconcile(ctx context.Context, req ctrl.Request) (ctrl.Resu func (r *reconciler) handleSuccess(ctx context.Context, schema *invv1alpha1.Schema, updatedStatus *invv1alpha1.SchemaStatus) (ctrl.Result, error) { log := log.FromContext(ctx) log.Debug("handleSuccess", "key", schema.GetNamespacedName(), "status old", schema.DeepCopy().Status) - + newCond := condv1alpha1.Ready() oldCond := schema.GetCondition(condv1alpha1.ConditionTypeReady) @@ -322,7 +319,6 @@ func (r *reconciler) handleError(ctx context.Context, schema *invv1alpha1.Schema }), errUpdateStatus) } - func repoStatusToApply(repos []invv1alpha1.SchemaRepositoryStatus) []*invv1alpha1apply.SchemaRepositoryStatusApplyConfiguration { result := make([]*invv1alpha1apply.SchemaRepositoryStatusApplyConfiguration, 0, len(repos)) for _, r := range repos { @@ -336,4 +332,4 @@ func repoStatusToApply(repos []invv1alpha1.SchemaRepositoryStatus) []*invv1alpha result = append(result, a) } return result -} \ No newline at end of file +} diff --git a/pkg/reconcilers/subscription/reconciler.go b/pkg/reconcilers/subscription/reconciler.go index 3748b372..908502f7 100644 --- a/pkg/reconcilers/subscription/reconciler.go +++ b/pkg/reconcilers/subscription/reconciler.go @@ -30,13 +30,13 @@ import ( "github.com/sdcio/config-server/pkg/reconcilers/ctrlconfig" "github.com/sdcio/config-server/pkg/reconcilers/eventhandler" "github.com/sdcio/config-server/pkg/reconcilers/resource" + targetmanager "github.com/sdcio/config-server/pkg/sdc/target/manager" corev1 "k8s.io/api/core/v1" "k8s.io/apimachinery/pkg/runtime/schema" "k8s.io/client-go/tools/events" ctrl "sigs.k8s.io/controller-runtime" "sigs.k8s.io/controller-runtime/pkg/client" "sigs.k8s.io/controller-runtime/pkg/event" - targetmanager "github.com/sdcio/config-server/pkg/sdc/target/manager" ) func init() { @@ -73,10 +73,10 @@ func (r *reconciler) SetupWithManager(ctx context.Context, mgr ctrl.Manager, c i } type reconciler struct { - client client.Client - finalizer *resource.APIFinalizer - targetMgr *targetmanager.TargetManager - recorder events.EventRecorder + client client.Client + finalizer *resource.APIFinalizer + targetMgr *targetmanager.TargetManager + recorder events.EventRecorder } func (r *reconciler) Reconcile(ctx context.Context, req ctrl.Request) (ctrl.Result, error) { @@ -96,9 +96,8 @@ func (r *reconciler) Reconcile(ctx context.Context, req ctrl.Request) (ctrl.Resu subscriptionOrig := subscription.DeepCopy() - if !subscription.GetDeletionTimestamp().IsZero() { - + if err := r.targetMgr.RemoveSubscription(ctx, subscription); err != nil { return r.handleError(ctx, subscription, "cannot delete state from target collector", err) } @@ -126,7 +125,7 @@ func (r *reconciler) Reconcile(ctx context.Context, req ctrl.Request) (ctrl.Resu func (r *reconciler) handleSuccess(ctx context.Context, state *invv1alpha1.Subscription, targets []string) (ctrl.Result, error) { log := log.FromContext(ctx) log.Debug("handleSuccess", "key", state.GetNamespacedName(), "status old", state.DeepCopy().Status) - + newCond := condv1alpha1.Ready() oldCond := state.GetCondition(condv1alpha1.ConditionTypeReady) diff --git a/pkg/reconcilers/target/reconciler.go b/pkg/reconcilers/target/reconciler.go index b319f027..deac07ce 100644 --- a/pkg/reconcilers/target/reconciler.go +++ b/pkg/reconcilers/target/reconciler.go @@ -34,8 +34,6 @@ import ( ctrl "sigs.k8s.io/controller-runtime" "sigs.k8s.io/controller-runtime/pkg/client" "sigs.k8s.io/controller-runtime/pkg/event" - - ) func init() { diff --git a/pkg/reconcilers/targetdatastore/reconciler.go b/pkg/reconcilers/targetdatastore/reconciler.go index f4d1d9b4..1d3ba55a 100644 --- a/pkg/reconcilers/targetdatastore/reconciler.go +++ b/pkg/reconcilers/targetdatastore/reconciler.go @@ -89,10 +89,10 @@ func (r *reconciler) SetupWithManager(ctx context.Context, mgr ctrl.Manager, c i } type reconciler struct { - client client.Client - finalizer *resource.APIFinalizer - targetMgr *targetmanager.TargetManager - recorder events.EventRecorder + client client.Client + finalizer *resource.APIFinalizer + targetMgr *targetmanager.TargetManager + recorder events.EventRecorder } func (r *reconciler) Reconcile(ctx context.Context, req ctrl.Request) (ctrl.Result, error) { @@ -123,7 +123,7 @@ func (r *reconciler) Reconcile(ctx context.Context, req ctrl.Request) (ctrl.Resu } log.Debug("deleting targetstore...") // check if this is the last one -> if so stop the client to the dataserver - + if r.targetMgr != nil { r.targetMgr.ClearDesired(ctx, targetKey) r.targetMgr.Delete(ctx, targetKey) @@ -176,39 +176,38 @@ func (r *reconciler) Reconcile(ctx context.Context, req ctrl.Request) (ctrl.Resu } // Compute desired hash (must be stable) - hash := targetmanager.ComputeCreateDSHash(dsReq, usedRefs) + hash := targetmanager.ComputeCreateDSHash(dsReq, usedRefs) // Drive runtime r.targetMgr.ApplyDesired(ctx, targetKey, dsReq, usedRefs, hash) - + // Read runtime status rt := r.targetMgr.GetOrCreate(targetKey) st := rt.Status() switch st.Phase { - case targetmanager.PhaseRunning: - return ctrl.Result{}, errors.Wrap(r.handleSuccess(ctx, targetOrig, usedRefs), errUpdateStatus) + case targetmanager.PhaseRunning: + return ctrl.Result{}, errors.Wrap(r.handleSuccess(ctx, targetOrig, usedRefs), errUpdateStatus) - case targetmanager.PhaseWaitingForDS, targetmanager.PhaseEnsuringDatastore, targetmanager.PhasePending: - // not ready yet; update status as failed/degraded but requeue soon - msg := fmt.Sprintf("runtime phase=%s dsReady=%t dsStoreReady=%t err=%s", - st.Phase, st.DSReady, st.DSStoreReady, st.LastError) + case targetmanager.PhaseWaitingForDS, targetmanager.PhaseEnsuringDatastore, targetmanager.PhasePending: + // not ready yet; update status as failed/degraded but requeue soon + msg := fmt.Sprintf("runtime phase=%s dsReady=%t dsStoreReady=%t err=%s", + st.Phase, st.DSReady, st.DSStoreReady, st.LastError) - _ = r.handleError(ctx, targetOrig, msg, nil, false) - return ctrl.Result{RequeueAfter: 5 * time.Second}, nil + _ = r.handleError(ctx, targetOrig, msg, nil, false) + return ctrl.Result{RequeueAfter: 5 * time.Second}, nil - case targetmanager.PhaseDegraded: - msg := fmt.Sprintf("runtime degraded: %s", st.LastError) - _ = r.handleError(ctx, targetOrig, msg, nil, false) - return ctrl.Result{RequeueAfter: 5 * time.Second}, nil + case targetmanager.PhaseDegraded: + msg := fmt.Sprintf("runtime degraded: %s", st.LastError) + _ = r.handleError(ctx, targetOrig, msg, nil, false) + return ctrl.Result{RequeueAfter: 5 * time.Second}, nil - default: - _ = r.handleError(ctx, targetOrig, "runtime unknown phase", nil, false) - return ctrl.Result{RequeueAfter: 5 * time.Second}, nil - } + default: + _ = r.handleError(ctx, targetOrig, "runtime unknown phase", nil, false) + return ctrl.Result{RequeueAfter: 5 * time.Second}, nil + } } - func (r *reconciler) handleSuccess(ctx context.Context, target *invv1alpha1.Target, usedRefs *invv1alpha1.TargetStatusUsedReferences) error { log := log.FromContext(ctx) //log.Info("handleSuccess", "key", target.GetNamespacedName(), "status old", target.DeepCopy().Status) @@ -262,7 +261,7 @@ func (r *reconciler) handleError(ctx context.Context, target *invv1alpha1.Target log.Info("handleError -> no change") return nil } - + log.Info("handleError", "condition change", !newCond.Equal(oldCond), "usedRefs change", !equality.Semantic.DeepEqual(newUsedRefs, target.Status.UsedReferences), @@ -405,13 +404,13 @@ func (r *reconciler) getCreateDataStoreRequest(ctx context.Context, target *invv } if connProfile.Spec.Protocol == invv1alpha1.Protocol_GNMI { - targetName:= "" + targetName := "" if connProfile.Spec.TargetName != nil { targetName = *connProfile.Spec.TargetName } req.Target.ProtocolOptions = &sdcpb.Target_GnmiOpts{ GnmiOpts: &sdcpb.GnmiOptions{ - Encoding: string(connProfile.Encoding()), + Encoding: string(connProfile.Encoding()), TargetName: targetName, }, } @@ -436,7 +435,6 @@ func (r *reconciler) getCreateDataStoreRequest(ctx context.Context, target *invv return req, usedReferences, nil } - func usedRefsToApply(refs *invv1alpha1.TargetStatusUsedReferences) *invv1alpha1apply.TargetStatusUsedReferencesApplyConfiguration { if refs == nil { return nil @@ -455,4 +453,4 @@ func usedRefsToApply(refs *invv1alpha1.TargetStatusUsedReferences) *invv1alpha1a a.WithSyncProfileResourceVersion(refs.SyncProfileResourceVersion) } return a -} \ No newline at end of file +} diff --git a/pkg/reconcilers/workspace/reconciler.go b/pkg/reconcilers/workspace/reconciler.go index 0decb50c..2669bb06 100644 --- a/pkg/reconcilers/workspace/reconciler.go +++ b/pkg/reconcilers/workspace/reconciler.go @@ -88,7 +88,7 @@ func (r *reconciler) SetupWithManager(ctx context.Context, mgr ctrl.Manager, c i } type reconciler struct { - client client.Client + client client.Client finalizer *resource.APIFinalizer workspaceLoader *workspaceloader.Loader @@ -205,4 +205,4 @@ func (r *reconciler) handleStatus( FieldManager: reconcilerName, }, }), errUpdateStatus) -} \ No newline at end of file +} diff --git a/pkg/registry/configblame/strategy_resource.go b/pkg/registry/configblame/strategy_resource.go index c09594f0..fc036f28 100644 --- a/pkg/registry/configblame/strategy_resource.go +++ b/pkg/registry/configblame/strategy_resource.go @@ -29,8 +29,12 @@ import ( "github.com/sdcio/config-server/apis/config" invv1alpha1 "github.com/sdcio/config-server/apis/inv/v1alpha1" "github.com/sdcio/config-server/pkg/registry/options" + dsclient "github.com/sdcio/config-server/pkg/sdc/dataserver/client" + sdcpb "github.com/sdcio/sdc-protos/sdcpb" + "google.golang.org/protobuf/encoding/protojson" apierrors "k8s.io/apimachinery/pkg/api/errors" metainternalversion "k8s.io/apimachinery/pkg/apis/meta/internalversion" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/apimachinery/pkg/runtime" "k8s.io/apimachinery/pkg/runtime/schema" "k8s.io/apimachinery/pkg/types" @@ -40,10 +44,6 @@ import ( "k8s.io/apiserver/pkg/storage/names" "sigs.k8s.io/controller-runtime/pkg/client" "sigs.k8s.io/structured-merge-diff/v6/fieldpath" - dsclient "github.com/sdcio/config-server/pkg/sdc/dataserver/client" - sdcpb "github.com/sdcio/sdc-protos/sdcpb" - "google.golang.org/protobuf/encoding/protojson" - metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" ) // NewStrategy creates and returns a strategy instance @@ -171,7 +171,6 @@ func (r *strategy) getConfigBlame(ctx context.Context, target *invv1alpha1.Targe } }() - // check if the schema exists; this is == nil check; in case of err it does not exist rsp, err := dsclient.BlameConfig(ctx, &sdcpb.BlameConfigRequest{ DatastoreName: storebackend.KeyFromNSN(key).String(), diff --git a/pkg/registry/options/options.go b/pkg/registry/options/options.go index 19934007..a68afb3f 100644 --- a/pkg/registry/options/options.go +++ b/pkg/registry/options/options.go @@ -39,7 +39,7 @@ type Options struct { Type StorageType DB *badger.DB // Target - Client client.Client + Client client.Client // specific functions DryRunCreateFn func(ctx context.Context, key types.NamespacedName, obj runtime.Object, dryrun bool) (runtime.Object, error) DryRunUpdateFn func(ctx context.Context, key types.NamespacedName, obj, old runtime.Object, dryrun bool) (runtime.Object, error) diff --git a/pkg/registry/store/store.go b/pkg/registry/store/store.go index 2f005204..4696f42d 100644 --- a/pkg/registry/store/store.go +++ b/pkg/registry/store/store.go @@ -57,10 +57,10 @@ func CreateFileStore(scheme *runtime.Scheme, obj resource.Object, prefix string) } return file.NewStore[runtime.Object](&storebackend.Config{ - GroupResource: gr, - Prefix: prefix, - Codec: codec, - NewFunc: obj.New, + GroupResource: gr, + Prefix: prefix, + Codec: codec, + NewFunc: obj.New, }) } diff --git a/pkg/sdc/dataserver/client/fake_client.go b/pkg/sdc/dataserver/client/fake_client.go index f5306dc7..16fb7377 100644 --- a/pkg/sdc/dataserver/client/fake_client.go +++ b/pkg/sdc/dataserver/client/fake_client.go @@ -30,16 +30,16 @@ func NewFakeClient() Client { type fakeclient struct{} -func (r *fakeclient) IsConnectionReady() bool {return true} +func (r *fakeclient) IsConnectionReady() bool { return true } -func (r *fakeclient) IsConnected() bool {return true} +func (r *fakeclient) IsConnected() bool { return true } func (r *fakeclient) ConnState() connectivity.State { - return connectivity.Ready + return connectivity.Ready } func (r *fakeclient) WaitForStateChange(ctx context.Context, s connectivity.State) bool { - return true + return true } func (r *fakeclient) Connect() {} @@ -91,4 +91,4 @@ func (r *fakeclient) WatchDeviations(ctx context.Context, in *sdcpb.WatchDeviati func (r *fakeclient) BlameConfig(ctx context.Context, in *sdcpb.BlameConfigRequest, opts ...grpc.CallOption) (*sdcpb.BlameConfigResponse, error) { return &sdcpb.BlameConfigResponse{}, nil -} \ No newline at end of file +} diff --git a/pkg/sdc/schemaserver/client/client.go b/pkg/sdc/schemaserver/client/client.go index c1402a94..e45673b5 100644 --- a/pkg/sdc/schemaserver/client/client.go +++ b/pkg/sdc/schemaserver/client/client.go @@ -19,8 +19,8 @@ package client import ( "context" "fmt" - "time" "os" + "time" "github.com/henderiw/logger/log" sdcpb "github.com/sdcio/sdc-protos/sdcpb" @@ -159,7 +159,6 @@ type Client interface { sdcpb.SchemaServerClient } - func New(cfg *Config) (Client, error) { defaultConfig(cfg) // default cancel is a no-op so Stop() is always safe @@ -311,4 +310,4 @@ func (r *client) ExpandPath(ctx context.Context, in *sdcpb.ExpandPathRequest, op // GetSchemaElements returns the schema of each path element func (r *client) GetSchemaElements(ctx context.Context, in *sdcpb.GetSchemaRequest, opts ...grpc.CallOption) (sdcpb.SchemaServer_GetSchemaElementsClient, error) { return r.schemaclient.GetSchemaElements(ctx, in, opts...) -} \ No newline at end of file +} diff --git a/pkg/sdc/target/manager/collector.go b/pkg/sdc/target/manager/collector.go index 6731f336..7ca417ee 100644 --- a/pkg/sdc/target/manager/collector.go +++ b/pkg/sdc/target/manager/collector.go @@ -39,7 +39,7 @@ type Collector struct { targetKey storebackend.Key subChan chan struct{} subscriptions *Subscriptions - cache cache.Cache + cache cache.Cache m sync.RWMutex target *target.Target @@ -47,9 +47,9 @@ type Collector struct { paths map[invv1alpha1.Encoding][]Path // collector lifetime - cancel context.CancelFunc + cancel context.CancelFunc - // subscription lifetime (ONLY for curr + // subscription lifetime (ONLY for curr subscriptionCancel context.CancelFunc } @@ -59,15 +59,15 @@ func NewCollector(targetKey storebackend.Key, subscriptions *Subscriptions) *Col targetKey: targetKey, subscriptions: subscriptions, subChan: make(chan struct{}), - cache: cache, + cache: cache, } } func (r *Collector) NotifySubscriptionChanged() { - select { - case r.subChan <- struct{}{}: - default: - } + select { + case r.subChan <- struct{}{}: + default: + } } func (r *Collector) SetPort(port uint) { @@ -109,81 +109,80 @@ func (r *Collector) Stop(ctx context.Context) { r.target.StopSubscriptions() if err := r.target.Close(); err != nil { log.Error("close error", "err", err) - } + } r.target = nil } r.paths = nil } - func (r *Collector) Start(ctx context.Context, req *sdcpb.CreateDataStoreRequest) error { - // stop existing (safe) - r.Stop(ctx) - - r.m.Lock() - // start collector lifetime - runCtx, cancel := context.WithCancel(ctx) - r.cancel = cancel - - log := log.FromContext(ctx).With("name", "targetCollector", "target", r.targetKey.String()) - - // build target (needs port) - tOpts := []gapi.TargetOption{ - gapi.Name(r.targetKey.String()), - gapi.Address(fmt.Sprintf("%s:%d", req.Target.Address, req.Target.Port)), - gapi.Username(string(req.Target.Credentials.Username)), - gapi.Password(string(req.Target.Credentials.Password)), - gapi.Timeout(5 * time.Second), - } - if req.Target.Tls == nil { - tOpts = append(tOpts, gapi.Insecure(true)) - } else { - tOpts = append(tOpts, gapi.SkipVerify(req.Target.Tls.SkipVerify)) - tOpts = append(tOpts, gapi.TLSCA(req.Target.Tls.Ca)) - tOpts = append(tOpts, gapi.TLSCert(req.Target.Tls.Cert)) - tOpts = append(tOpts, gapi.TLSKey(req.Target.Tls.Key)) - } - - var err error - r.target, err = gapi.NewTarget(tOpts...) - if err != nil { - r.cancel = nil - r.m.Unlock() - log.Error("cannot create gnmi target", "err", err) - return err - } - if err := r.target.CreateGNMIClient(runCtx); err != nil { - _ = r.target.Close() - r.target = nil - r.cancel = nil - r.m.Unlock() - log.Error("cannot create gnmi client", "err", err) - return err - } - - // reset path snapshot so first update triggers - r.paths = nil - r.m.Unlock() - - go r.start(runCtx) - return nil + // stop existing (safe) + r.Stop(ctx) + + r.m.Lock() + // start collector lifetime + runCtx, cancel := context.WithCancel(ctx) + r.cancel = cancel + + log := log.FromContext(ctx).With("name", "targetCollector", "target", r.targetKey.String()) + + // build target (needs port) + tOpts := []gapi.TargetOption{ + gapi.Name(r.targetKey.String()), + gapi.Address(fmt.Sprintf("%s:%d", req.Target.Address, req.Target.Port)), + gapi.Username(string(req.Target.Credentials.Username)), + gapi.Password(string(req.Target.Credentials.Password)), + gapi.Timeout(5 * time.Second), + } + if req.Target.Tls == nil { + tOpts = append(tOpts, gapi.Insecure(true)) + } else { + tOpts = append(tOpts, gapi.SkipVerify(req.Target.Tls.SkipVerify)) + tOpts = append(tOpts, gapi.TLSCA(req.Target.Tls.Ca)) + tOpts = append(tOpts, gapi.TLSCert(req.Target.Tls.Cert)) + tOpts = append(tOpts, gapi.TLSKey(req.Target.Tls.Key)) + } + + var err error + r.target, err = gapi.NewTarget(tOpts...) + if err != nil { + r.cancel = nil + r.m.Unlock() + log.Error("cannot create gnmi target", "err", err) + return err + } + if err := r.target.CreateGNMIClient(runCtx); err != nil { + _ = r.target.Close() + r.target = nil + r.cancel = nil + r.m.Unlock() + log.Error("cannot create gnmi client", "err", err) + return err + } + + // reset path snapshot so first update triggers + r.paths = nil + r.m.Unlock() + + go r.start(runCtx) + return nil } func (r *Collector) start(ctx context.Context) { - log := log.FromContext(ctx).With("name", "targetCollector", "target", r.targetKey.String()) - log.Info("start collector") - - // initial apply - r.update(ctx) - - for { - select { - case <-ctx.Done(): - return - case <-r.subChan: - r.update(ctx) - } - } + log := log.FromContext(ctx).With("name", "targetCollector", "target", r.targetKey.String()) + log.Info("start collector") + + // initial apply + r.update(ctx) + + for { + select { + case <-ctx.Done(): + return + case <-r.subChan: + r.update(ctx) + } + } } func (r *Collector) update(ctx context.Context) { @@ -194,20 +193,20 @@ func (r *Collector) update(ctx context.Context) { if r.subscriptions == nil { log.Debug("no subscriptions") - r.stopSubscriptionLocked() - r.paths = nil - return + r.stopSubscriptionLocked() + r.paths = nil + return } - + newPaths := r.subscriptions.GetPaths() log.Debug("subscription update received", "newPaths", newPaths) - + if !r.hasPathsChanged(newPaths) { log.Debug("subscription did not change") return } log.Debug("subscription changed", "newPaths", newPaths, "existingPaths", r.paths) - + // stop current subscription loop r.stopSubscriptionLocked() @@ -237,38 +236,37 @@ func (r *Collector) stopSubscriptionLocked() { } } - func (r *Collector) hasPathsChanged(newPaths map[invv1alpha1.Encoding][]Path) bool { // IMPORTANT: caller holds r.m.Lock() old := r.paths - if old == nil && len(newPaths) == 0 { - return false - } - if len(old) != len(newPaths) { - return true - } - for enc, np := range newPaths { - op, ok := old[enc] - if !ok { - return true - } - if len(op) != len(np) { - return true - } - // If order is not guaranteed, you should sort; see section 4 below. - for i := range op { - if op[i].Path != np[i].Path || op[i].Interval != np[i].Interval { - return true - } - } - } - return false + if old == nil && len(newPaths) == 0 { + return false + } + if len(old) != len(newPaths) { + return true + } + for enc, np := range newPaths { + op, ok := old[enc] + if !ok { + return true + } + if len(op) != len(np) { + return true + } + // If order is not guaranteed, you should sort; see section 4 below. + for i := range op { + if op[i].Path != np[i].Path || op[i].Interval != np[i].Interval { + return true + } + } + } + return false } func (r *Collector) StopSubscription(ctx context.Context) { log := log.FromContext(ctx).With("name", "targetCollector", "target", r.targetKey.String()) log.Info("stop subscription") - + r.m.Lock() defer r.m.Unlock() diff --git a/pkg/sdc/target/manager/error.go b/pkg/sdc/target/manager/error.go index c5d26f95..77ca9e07 100644 --- a/pkg/sdc/target/manager/error.go +++ b/pkg/sdc/target/manager/error.go @@ -57,4 +57,4 @@ func (e *LookupError) Error() string { func (e *LookupError) Unwrap() error { return e.WrappedError -} \ No newline at end of file +} diff --git a/pkg/sdc/target/manager/exports.go b/pkg/sdc/target/manager/exports.go index ba065be8..60c1b8f4 100644 --- a/pkg/sdc/target/manager/exports.go +++ b/pkg/sdc/target/manager/exports.go @@ -50,4 +50,3 @@ func (t *TargetRuntime) PromLabels() []prompb.Label { } return labels } - diff --git a/pkg/sdc/target/manager/manager.go b/pkg/sdc/target/manager/manager.go index a5327ae3..f51377f0 100644 --- a/pkg/sdc/target/manager/manager.go +++ b/pkg/sdc/target/manager/manager.go @@ -20,10 +20,10 @@ import ( "context" "crypto/sha256" "encoding/hex" - "sync" + "errors" "fmt" "sort" - "errors" + "sync" "github.com/henderiw/apiserver-store/pkg/storebackend" configv1alpha1 "github.com/sdcio/config-server/apis/config/v1alpha1" @@ -34,8 +34,8 @@ import ( sdcpb "github.com/sdcio/sdc-protos/sdcpb" "google.golang.org/protobuf/encoding/protojson" "google.golang.org/protobuf/proto" - "sigs.k8s.io/controller-runtime/pkg/client" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "sigs.k8s.io/controller-runtime/pkg/client" ) type TargetManager struct { @@ -208,41 +208,49 @@ func (m *TargetManager) listRuntimes() []*TargetRuntime { } func (m *TargetManager) ForEachRuntime(fn func(runtimeview.TargetRuntimeView)) { - for _, rt := range m.listRuntimes() { - fn(rt) - } + for _, rt := range m.listRuntimes() { + fn(rt) + } } func (m *TargetManager) ApplySubscription(ctx context.Context, sub *invv1alpha1.Subscription) ([]string, error) { - targets, err := m.getDownstreamTargets(ctx, sub) // optional helper - if err != nil { return nil, err } - - var errs error - for _, tn := range targets { - key := storebackend.KeyFromNSN(client.ObjectKey{Namespace: sub.Namespace, Name: tn}) - rt := m.GetRuntimeForTarget(ctx, key) - if rt == nil { continue } - if err := rt.UpsertSubscription(ctx, sub); err != nil { - errs = errors.Join(errs, err) - } - } - return targets, errs + targets, err := m.getDownstreamTargets(ctx, sub) // optional helper + if err != nil { + return nil, err + } + + var errs error + for _, tn := range targets { + key := storebackend.KeyFromNSN(client.ObjectKey{Namespace: sub.Namespace, Name: tn}) + rt := m.GetRuntimeForTarget(ctx, key) + if rt == nil { + continue + } + if err := rt.UpsertSubscription(ctx, sub); err != nil { + errs = errors.Join(errs, err) + } + } + return targets, errs } func (m *TargetManager) RemoveSubscription(ctx context.Context, sub *invv1alpha1.Subscription) error { - targets, err := m.getDownstreamTargets(ctx, sub) - if err != nil { return err } - - var errs error - for _, tn := range targets { - key := storebackend.KeyFromNSN(client.ObjectKey{Namespace: sub.Namespace, Name: tn}) - rt := m.GetRuntimeForTarget(ctx, key) - if rt == nil { continue } - if err := rt.DeleteSubscription(ctx, sub); err != nil { - errs = errors.Join(errs, err) - } - } - return errs + targets, err := m.getDownstreamTargets(ctx, sub) + if err != nil { + return err + } + + var errs error + for _, tn := range targets { + key := storebackend.KeyFromNSN(client.ObjectKey{Namespace: sub.Namespace, Name: tn}) + rt := m.GetRuntimeForTarget(ctx, key) + if rt == nil { + continue + } + if err := rt.DeleteSubscription(ctx, sub); err != nil { + errs = errors.Join(errs, err) + } + } + return errs } // getDownstreamTargets list the targets @@ -269,4 +277,4 @@ func (r *TargetManager) getDownstreamTargets(ctx context.Context, sub *invv1alph } sort.Strings(targets) return targets, nil -} \ No newline at end of file +} diff --git a/pkg/sdc/target/manager/runtime.go b/pkg/sdc/target/manager/runtime.go index 4fd98295..89c4edc9 100644 --- a/pkg/sdc/target/manager/runtime.go +++ b/pkg/sdc/target/manager/runtime.go @@ -28,9 +28,9 @@ import ( condv1alpha1 "github.com/sdcio/config-server/apis/condition/v1alpha1" configv1alpha1 "github.com/sdcio/config-server/apis/config/v1alpha1" invv1alpha1 "github.com/sdcio/config-server/apis/inv/v1alpha1" + invv1alpha1apply "github.com/sdcio/config-server/pkg/generated/applyconfiguration/inv/v1alpha1" dsclient "github.com/sdcio/config-server/pkg/sdc/dataserver/client" dsmanager "github.com/sdcio/config-server/pkg/sdc/dataserver/manager" - invv1alpha1apply "github.com/sdcio/config-server/pkg/generated/applyconfiguration/inv/v1alpha1" sdcpb "github.com/sdcio/sdc-protos/sdcpb" "google.golang.org/grpc/codes" "google.golang.org/grpc/status" diff --git a/pkg/sdc/target/manager/transactor.go b/pkg/sdc/target/manager/transactor.go index e06703e6..20eb0453 100644 --- a/pkg/sdc/target/manager/transactor.go +++ b/pkg/sdc/target/manager/transactor.go @@ -30,8 +30,8 @@ import ( condv1alpha1 "github.com/sdcio/config-server/apis/condition/v1alpha1" "github.com/sdcio/config-server/apis/config" configv1alpha1 "github.com/sdcio/config-server/apis/config/v1alpha1" - configv1alpha1apply "github.com/sdcio/config-server/pkg/generated/applyconfiguration/config/v1alpha1" invv1alpha1 "github.com/sdcio/config-server/apis/inv/v1alpha1" + configv1alpha1apply "github.com/sdcio/config-server/pkg/generated/applyconfiguration/config/v1alpha1" "github.com/sdcio/config-server/pkg/reconcilers/resource" sdcpb "github.com/sdcio/sdc-protos/sdcpb" "google.golang.org/grpc/codes" @@ -101,13 +101,13 @@ func (r *Transactor) RecoverConfigs(ctx context.Context, target *invv1alpha1.Tar log.Debug("recovered configs", "count", len(configs)) if err := r.SetConfigsTargetConditionForTarget( - ctx, - target, - configv1alpha1.ConfigReady("target recovered"), - ); err != nil { - // recovery succeeded but we failed to patch status -> surface it - return ptr.To("recovered, but failed to update config status"), err - } + ctx, + target, + configv1alpha1.ConfigReady("target recovered"), + ); err != nil { + // recovery succeeded but we failed to patch status -> surface it + return ptr.To("recovered, but failed to update config status"), err + } return nil, nil } @@ -130,10 +130,10 @@ func (r *Transactor) recoverIntents( return "", err } intents = append(intents, &sdcpb.TransactionIntent{ - Intent: GetGVKNSN(config), - Priority: int32(config.Spec.Priority), - Update: update, - NonRevertive: !config.IsRevertive(), + Intent: GetGVKNSN(config), + Priority: int32(config.Spec.Priority), + Update: update, + NonRevertive: !config.IsRevertive(), PreviouslyApplied: true, }) } @@ -293,9 +293,9 @@ func (r *Transactor) setIntents( return nil, err } intents = append(intents, &sdcpb.TransactionIntent{ - Intent: GetGVKNSN(config), - Priority: int32(config.Spec.Priority), - Update: update, + Intent: GetGVKNSN(config), + Priority: int32(config.Spec.Priority), + Update: update, NonRevertive: !config.IsRevertive(), }) } @@ -400,7 +400,7 @@ func (r *Transactor) updateConfigWithSuccess( log.Debug("updateConfigWithSuccess", "config", cfg.GetName()) cond := configv1alpha1.ConfigReady(msg) - overallCond := configv1alpha1.GetOverallCondition(cfg) + overallCond := configv1alpha1.GetOverallCondition(cfg) if cond.Equal(cfg.GetCondition(condv1alpha1.ConditionType(cond.Type))) && reflect.DeepEqual(schema, cfg.Status.LastKnownGoodSchema) && @@ -481,7 +481,6 @@ func toV1Alpha1Config(cfg *config.Config) (*configv1alpha1.Config, error) { return out, nil } - func (r *Transactor) patchMetadata( ctx context.Context, obj client.Object, @@ -761,7 +760,6 @@ func (r *Transactor) SetConfigsTargetConditionForTarget( return nil } - func schemaToApply(s *configv1alpha1.ConfigStatusLastKnownGoodSchema) *configv1alpha1apply.ConfigStatusLastKnownGoodSchemaApplyConfiguration { if s == nil { return nil @@ -784,8 +782,8 @@ func configSpecToApply(s *configv1alpha1.ConfigSpec) *configv1alpha1apply.Config return nil } revertive := false - if (s.Revertive != nil) { - revertive= *s.Revertive + if s.Revertive != nil { + revertive = *s.Revertive } a := configv1alpha1apply.ConfigSpec(). @@ -808,7 +806,7 @@ func lifecycleToApply(l *configv1alpha1.Lifecycle) *configv1alpha1apply.Lifecycl } a := configv1alpha1apply.Lifecycle() a.WithDeletionPolicy(l.DeletionPolicy) - + return a } @@ -822,4 +820,4 @@ func configBlobToApply(b *configv1alpha1.ConfigBlob) *configv1alpha1apply.Config } a.WithValue(b.Value) return a -} \ No newline at end of file +} diff --git a/pkg/sdc/target/manager/utils.go b/pkg/sdc/target/manager/utils.go index dc167d5b..cf4f39de 100644 --- a/pkg/sdc/target/manager/utils.go +++ b/pkg/sdc/target/manager/utils.go @@ -18,18 +18,18 @@ package targetmanager import ( "context" - "fmt" "errors" + "fmt" "strings" "github.com/henderiw/apiserver-store/pkg/storebackend" "github.com/henderiw/logger/log" "github.com/sdcio/config-server/apis/config" sdcpb "github.com/sdcio/sdc-protos/sdcpb" - "sigs.k8s.io/controller-runtime/pkg/client" - "google.golang.org/protobuf/encoding/prototext" "google.golang.org/grpc/codes" "google.golang.org/grpc/status" + "google.golang.org/protobuf/encoding/prototext" + "sigs.k8s.io/controller-runtime/pkg/client" ) func GetGVKNSN(obj client.Object) string { @@ -107,4 +107,4 @@ func processTransactionResponse(ctx context.Context, rsp *sdcpb.TransactionSetRe } log.Debug("transaction response", "rsp", prototext.Format(rsp), "msg", msg, "error", err) return msg, err -} \ No newline at end of file +} diff --git a/pkg/sdc/target/runtimeview/runtimeview.go b/pkg/sdc/target/runtimeview/runtimeview.go index 3e7b870e..33dd5738 100644 --- a/pkg/sdc/target/runtimeview/runtimeview.go +++ b/pkg/sdc/target/runtimeview/runtimeview.go @@ -17,17 +17,17 @@ limitations under the License. package runtimeview import ( - "github.com/henderiw/apiserver-store/pkg/storebackend" - "github.com/openconfig/gnmic/pkg/cache" - "github.com/prometheus/prometheus/prompb" + "github.com/henderiw/apiserver-store/pkg/storebackend" + "github.com/openconfig/gnmic/pkg/cache" + "github.com/prometheus/prometheus/prompb" ) type TargetRuntimeView interface { - Key() storebackend.Key - Cache() cache.Cache - PromLabels() []prompb.Label + Key() storebackend.Key + Cache() cache.Cache + PromLabels() []prompb.Label } type TargetManager interface { - ForEachRuntime(func(TargetRuntimeView)) -} \ No newline at end of file + ForEachRuntime(func(TargetRuntimeView)) +} diff --git a/pkg/sdc/target/subscriptionview/subscriptionview.go b/pkg/sdc/target/subscriptionview/subscriptionview.go index 1bbc6aad..f9bbb8b3 100644 --- a/pkg/sdc/target/subscriptionview/subscriptionview.go +++ b/pkg/sdc/target/subscriptionview/subscriptionview.go @@ -16,15 +16,14 @@ limitations under the License. package subscriptionview - import ( - "context" + "context" - invv1alpha1 "github.com/sdcio/config-server/apis/inv/v1alpha1" + invv1alpha1 "github.com/sdcio/config-server/apis/inv/v1alpha1" ) // Only what the reconciler needs. type TargetSubscriptionManager interface { - ApplySubscription(ctx context.Context, sub *invv1alpha1.Subscription) error - RemoveSubscription(ctx context.Context, sub *invv1alpha1.Subscription) error -} \ No newline at end of file + ApplySubscription(ctx context.Context, sub *invv1alpha1.Subscription) error + RemoveSubscription(ctx context.Context, sub *invv1alpha1.Subscription) error +} diff --git a/tools/apiserver-runtime-gen/main.go b/tools/apiserver-runtime-gen/main.go index 6341d52e..366682fa 100644 --- a/tools/apiserver-runtime-gen/main.go +++ b/tools/apiserver-runtime-gen/main.go @@ -260,10 +260,10 @@ func doGen() error { } var ( - generators []string - header string - module string - versions []string + generators []string + header string + module string + versions []string //rawVersions []string clean, install bool ) diff --git a/tools/fix-openapi-gvk/main.go b/tools/fix-openapi-gvk/main.go new file mode 100644 index 00000000..5f5d66a9 --- /dev/null +++ b/tools/fix-openapi-gvk/main.go @@ -0,0 +1,250 @@ +/* +Copyright 2026 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +// fix-openapi-gvk injects x-kubernetes-group-version-kind extensions into +// zz_generated.openapi.go for top-level resource types. openapi-gen omits +// these extensions, but NewTypeConverter requires them to register types by GVK. +// +// VendorExtensible is an embedded field of spec.Schema, so it must be injected +// INSIDE spec.Schema{} before its closing brace, not at the OpenAPIDefinition level. +// +// Only types whose properties include "kind", "apiVersion" and "metadata" are +// considered top-level resources and get the extension injected. +// List types (names ending in "List") are excluded. +// Only functions matching --prefix are processed, so types from other API groups +// are left untouched. The API version is derived from the prefix automatically. +// +// Usage: +// +// go run ./tools/fix-openapi-gvk/main.go \ +// --file pkg/generated/openapi/zz_generated.openapi.go \ +// --group config.sdcio.dev \ +// --prefix config_server_apis_config_v1alpha1 +package main + +import ( + "flag" + "fmt" + "os" + "regexp" + "strings" +) + +var ( + filePath = flag.String("file", "", "path to zz_generated.openapi.go") + group = flag.String("group", "", "API group, e.g. config.sdcio.dev") + prefix = flag.String("prefix", "", "underscore-delimited package prefix from function names, e.g. config_server_apis_config_v1alpha1") +) + +// versionRe matches Kubernetes-style API versions like v1, v1alpha1, v1beta2. +var versionRe = regexp.MustCompile(`^v\d+(?:(?:alpha|beta)\d+)?$`) + +// extractVersion returns the API version from the prefix by finding the last +// segment that matches a k8s version pattern (e.g. v1alpha1, v1beta1, v1). +func extractVersion(pfx string) (string, error) { + parts := strings.Split(pfx, "_") + for i := len(parts) - 1; i >= 0; i-- { + if versionRe.MatchString(parts[i]) { + return parts[i], nil + } + } + return "", fmt.Errorf("no API version found in prefix %q (expected segment like v1, v1alpha1, v1beta2)", pfx) +} + +func vendorBlock(g, k, v string) string { + return fmt.Sprintf( + "\t\t\tVendorExtensible: spec.VendorExtensible{\n"+ + "\t\t\t\tExtensions: spec.Extensions{\n"+ + "\t\t\t\t\t\"x-kubernetes-group-version-kind\": []interface{}{\n"+ + "\t\t\t\t\t\tmap[string]interface{}{\"group\": %q, \"kind\": %q, \"version\": %q},\n"+ + "\t\t\t\t\t},\n"+ + "\t\t\t\t},\n"+ + "\t\t\t},", + g, k, v) +} + +// isRootType returns true if the function body contains "kind", "apiVersion" +// and "metadata" as property keys — the hallmark of a top-level k8s resource. +func isRootType(funcBody string) bool { + return strings.Contains(funcBody, `"kind"`) && + strings.Contains(funcBody, `"apiVersion"`) && + strings.Contains(funcBody, `"metadata"`) +} + +func main() { + flag.Parse() + if *filePath == "" || *group == "" || *prefix == "" { + fmt.Fprintln(os.Stderr, "usage: fix-openapi-gvk --file --group --prefix ") + fmt.Fprintln(os.Stderr, "") + fmt.Fprintln(os.Stderr, " --prefix underscore-delimited package path from function names") + fmt.Fprintln(os.Stderr, " e.g. config_server_apis_config_v1alpha1") + fmt.Fprintln(os.Stderr, " the API version (v1alpha1) is derived automatically") + os.Exit(1) + } + + version, err := extractVersion(*prefix) + if err != nil { + fmt.Fprintf(os.Stderr, "error: %v\n", err) + os.Exit(1) + } + fmt.Printf("derived API version: %s\n", version) + + src, err := os.ReadFile(*filePath) + if err != nil { + fmt.Fprintf(os.Stderr, "error reading %s: %v\n", *filePath, err) + os.Exit(1) + } + + // Match schema function definitions. + funcRe := regexp.MustCompile(`(?m)^func (schema_[a-zA-Z0-9_]+)\(ref `) + + schemaOpenRe := regexp.MustCompile(`^\t\tSchema:\s+spec\.Schema\{`) + + // Build the expected function name prefix: "schema_" + user-supplied prefix + "_" + funcPrefix := "schema_" + *prefix + "_" + + lines := strings.Split(string(src), "\n") + out := make([]string, 0, len(lines)+50) + injected := 0 + skippedList := 0 + skippedPrefix := 0 + + i := 0 + for i < len(lines) { + line := lines[i] + m := funcRe.FindStringSubmatch(line) + if m == nil { + out = append(out, line) + i++ + continue + } + + funcName := m[1] + + // Kind = last underscore-delimited segment + parts := strings.Split(funcName, "_") + kind := parts[len(parts)-1] + + // Collect entire function body + funcLines := []string{line} + depth := 0 + i++ + for i < len(lines) { + fl := lines[i] + funcLines = append(funcLines, fl) + for _, ch := range fl { + if ch == '{' { + depth++ + } else if ch == '}' { + depth-- + } + } + i++ + if depth == 0 { + break + } + } + + funcBody := strings.Join(funcLines, "\n") + + // --- Filter: only process functions matching the prefix --- + if !strings.HasPrefix(funcName, funcPrefix) { + out = append(out, funcLines...) + skippedPrefix++ + continue + } + + // --- Filter: skip List types --- + if strings.HasSuffix(kind, "List") { + out = append(out, funcLines...) + skippedList++ + fmt.Printf("skipped List type: %s\n", kind) + continue + } + + // Already patched? + if strings.Contains(funcBody, "x-kubernetes-group-version-kind") { + out = append(out, funcLines...) + continue + } + + // Only inject for root types (have kind/apiVersion/metadata properties) + if !isRootType(funcBody) { + out = append(out, funcLines...) + continue + } + + // Find the Schema: spec.Schema{ line, then find its matching closing }, + // and insert VendorExtensible just before that closing line. + schemaLineIdx := -1 + for j, fl := range funcLines { + if schemaOpenRe.MatchString(fl) { + schemaLineIdx = j + break + } + } + + if schemaLineIdx < 0 { + fmt.Fprintf(os.Stderr, "WARNING: no Schema: spec.Schema{ found in %s, skipping\n", kind) + out = append(out, funcLines...) + continue + } + + // Track brace depth from the Schema line to find its closing }, + schemaDepth := 0 + schemaCloseIdx := -1 + for j := schemaLineIdx; j < len(funcLines); j++ { + fl := funcLines[j] + for _, ch := range fl { + if ch == '{' { + schemaDepth++ + } else if ch == '}' { + schemaDepth-- + } + } + if schemaDepth == 0 { + schemaCloseIdx = j + break + } + } + + if schemaCloseIdx < 0 { + fmt.Fprintf(os.Stderr, "WARNING: could not find closing of Schema{} in %s, skipping\n", kind) + out = append(out, funcLines...) + continue + } + + // Insert VendorExtensible before the closing line of Schema{} + var patchedLines []string + for j, fl := range funcLines { + if j == schemaCloseIdx { + patchedLines = append(patchedLines, vendorBlock(*group, kind, version)) + } + patchedLines = append(patchedLines, fl) + } + + out = append(out, patchedLines...) + injected++ + fmt.Printf("injected GVK extension: %s\n", kind) + } + + if err := os.WriteFile(*filePath, []byte(strings.Join(out, "\n")), 0644); err != nil { + fmt.Fprintf(os.Stderr, "error writing %s: %v\n", *filePath, err) + os.Exit(1) + } + + fmt.Printf("done: injected %d, skipped %d List types, skipped %d non-matching prefix\n", injected, skippedList, skippedPrefix) +} From 75fdb55be82d2bb3efa2e5a9c395ad166b3cf9b0 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Thu, 19 Feb 2026 13:23:43 +0100 Subject: [PATCH 053/135] split field manager --- pkg/sdc/target/manager/transactor.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkg/sdc/target/manager/transactor.go b/pkg/sdc/target/manager/transactor.go index 20eb0453..0276a85b 100644 --- a/pkg/sdc/target/manager/transactor.go +++ b/pkg/sdc/target/manager/transactor.go @@ -751,7 +751,7 @@ func (r *Transactor) SetConfigsTargetConditionForTarget( if err := r.client.Status().Apply(ctx, applyConfig, &client.SubResourceApplyOptions{ ApplyOptions: client.ApplyOptions{ - FieldManager: r.fieldManager, + FieldManager: r.fieldManager + "-target", }, }); err != nil { return err From 9d904060acffbe77aa6e2d69b49309a774a530d6 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Thu, 19 Feb 2026 13:27:22 +0100 Subject: [PATCH 054/135] fix conversion --- apis/config/v1alpha1/zz_generated.conversion.go | 10 ---------- 1 file changed, 10 deletions(-) diff --git a/apis/config/v1alpha1/zz_generated.conversion.go b/apis/config/v1alpha1/zz_generated.conversion.go index f0cedc83..aa359115 100644 --- a/apis/config/v1alpha1/zz_generated.conversion.go +++ b/apis/config/v1alpha1/zz_generated.conversion.go @@ -98,16 +98,6 @@ func RegisterConversions(s *runtime.Scheme) error { }); err != nil { return err } - if err := s.AddGeneratedConversionFunc((*ConfigDeviation)(nil), (*config.ConfigDeviation)(nil), func(a, b interface{}, scope conversion.Scope) error { - return Convert_v1alpha1_ConfigDeviation_To_config_ConfigDeviation(a.(*ConfigDeviation), b.(*config.ConfigDeviation), scope) - }); err != nil { - return err - } - if err := s.AddGeneratedConversionFunc((*config.ConfigDeviation)(nil), (*ConfigDeviation)(nil), func(a, b interface{}, scope conversion.Scope) error { - return Convert_config_ConfigDeviation_To_v1alpha1_ConfigDeviation(a.(*config.ConfigDeviation), b.(*ConfigDeviation), scope) - }); err != nil { - return err - } if err := s.AddGeneratedConversionFunc((*ConfigList)(nil), (*config.ConfigList)(nil), func(a, b interface{}, scope conversion.Scope) error { return Convert_v1alpha1_ConfigList_To_config_ConfigList(a.(*ConfigList), b.(*config.ConfigList), scope) }); err != nil { From b5cb7fa2bb7e1d7c9d6f44efc94da2a8b3e6b29d Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Thu, 19 Feb 2026 16:55:25 +0100 Subject: [PATCH 055/135] updated ssa handling on config --- pkg/reconcilers/targetconfig/reconciler.go | 2 +- pkg/sdc/target/manager/transactor.go | 54 +++++++++++++++++----- 2 files changed, 44 insertions(+), 12 deletions(-) diff --git a/pkg/reconcilers/targetconfig/reconciler.go b/pkg/reconcilers/targetconfig/reconciler.go index b4f9cbbf..56e58f95 100644 --- a/pkg/reconcilers/targetconfig/reconciler.go +++ b/pkg/reconcilers/targetconfig/reconciler.go @@ -193,7 +193,7 @@ func (r *reconciler) Reconcile(ctx context.Context, req ctrl.Request) (ctrl.Resu return ctrl.Result{}, err } - retry, err := r.transactor.Transact(ctx, target, dsctx) + retry, err := r.transactor.Transact(ctx, target, dsctx, configv1alpha1.TargetReady("target ready")) if err != nil { log.Warn("config transaction failed", "retry", retry, "err", err) if retry { diff --git a/pkg/sdc/target/manager/transactor.go b/pkg/sdc/target/manager/transactor.go index 0276a85b..c72513a9 100644 --- a/pkg/sdc/target/manager/transactor.go +++ b/pkg/sdc/target/manager/transactor.go @@ -176,7 +176,12 @@ func (r *Transactor) TransactionSet( return msg, nil } -func (r *Transactor) Transact(ctx context.Context, target *invv1alpha1.Target, dsctx *DatastoreHandle) (bool, error) { +func (r *Transactor) Transact( + ctx context.Context, + target *invv1alpha1.Target, + dsctx *DatastoreHandle, + targetCond condv1alpha1.Condition, +) (bool, error) { log := log.FromContext(ctx) log.Debug("Transact") // get all configs for the target @@ -252,7 +257,7 @@ func (r *Transactor) Transact(ctx context.Context, target *invv1alpha1.Target, d return true, err } - if err := r.updateConfigWithSuccess(ctx, config, dsctx.Schema, ""); err != nil { + if err := r.updateConfigWithSuccess(ctx, config, dsctx.Schema, targetCond, ""); err != nil { return true, err } } @@ -358,7 +363,6 @@ func (r *Transactor) updateConfigWithError(ctx context.Context, config *configv1 WithConditions(cond) if !recoverable { - // clear DeviationGeneration statusApply = statusApply.WithDeviationGeneration(0) } @@ -394,22 +398,34 @@ func (r *Transactor) updateConfigWithSuccess( ctx context.Context, cfg *configv1alpha1.Config, schema *configv1alpha1.ConfigStatusLastKnownGoodSchema, + targetCond condv1alpha1.Condition, msg string, ) error { log := log.FromContext(ctx) log.Debug("updateConfigWithSuccess", "config", cfg.GetName()) - cond := configv1alpha1.ConfigReady(msg) - overallCond := configv1alpha1.GetOverallCondition(cfg) + configCond := configv1alpha1.ConfigReady(msg) + + // capture + oldConfigCond := cfg.GetCondition(condv1alpha1.ConditionType(configCond.Type)) + oldTargetCond := cfg.GetCondition(condv1alpha1.ConditionType(targetCond.Type)) + + // compute overall from both conditions + cfg.SetConditions(configCond, targetCond) + cfg.SetOverallStatus() + overallCond := cfg.GetCondition(condv1alpha1.ConditionTypeReady) - if cond.Equal(cfg.GetCondition(condv1alpha1.ConditionType(cond.Type))) && + + // check against OLD state + if configCond.Equal(oldConfigCond) && + targetCond.Equal(oldTargetCond) && reflect.DeepEqual(schema, cfg.Status.LastKnownGoodSchema) && reflect.DeepEqual(&cfg.Spec, cfg.Status.AppliedConfig) { return nil } statusApply := configv1alpha1apply.ConfigStatus(). - WithConditions(cond, overallCond). + WithConditions(configCond, targetCond, overallCond). WithLastKnownGoodSchema(schemaToApply(schema)). WithAppliedConfig(configSpecToApply(&cfg.Spec)) @@ -744,14 +760,30 @@ func (r *Transactor) SetConfigsTargetConditionForTarget( continue } + // Preserve ALL existing status fields to avoid stripping them + configCond := v1cfg.GetCondition(condv1alpha1.ConditionType( + configv1alpha1.ConfigReady("").Type, + )) + + statusApply := configv1alpha1apply.ConfigStatus(). + WithConditions(targetCond, configCond, newReadyCond) + + // preserve schema + appliedConfig so SSA doesn't strip them + if v1cfg.Status.LastKnownGoodSchema != nil { + statusApply = statusApply.WithLastKnownGoodSchema( + schemaToApply(v1cfg.Status.LastKnownGoodSchema)) + } + if v1cfg.Status.AppliedConfig != nil { + statusApply = statusApply.WithAppliedConfig( + configSpecToApply(v1cfg.Status.AppliedConfig)) + } + applyConfig := configv1alpha1apply.Config(v1cfg.Name, v1cfg.Namespace). - WithStatus(configv1alpha1apply.ConfigStatus(). - WithConditions(targetCond, newReadyCond), - ) + WithStatus(statusApply) if err := r.client.Status().Apply(ctx, applyConfig, &client.SubResourceApplyOptions{ ApplyOptions: client.ApplyOptions{ - FieldManager: r.fieldManager + "-target", + FieldManager: r.fieldManager, }, }); err != nil { return err From 2600923b8c3c9236c218951e46cb0be29255a69f Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Thu, 19 Feb 2026 17:04:47 +0100 Subject: [PATCH 056/135] updated ready message --- apis/config/v1alpha1/config_helpers.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/apis/config/v1alpha1/config_helpers.go b/apis/config/v1alpha1/config_helpers.go index 5f992b35..292d3577 100644 --- a/apis/config/v1alpha1/config_helpers.go +++ b/apis/config/v1alpha1/config_helpers.go @@ -281,7 +281,7 @@ func (r *Config) SetOverallStatus() { if ready { // important: only set overall Ready type, do not drop other conditions - r.Status.SetConditions(condv1alpha1.ReadyWithMsg("config applied and target ready")) + r.Status.SetConditions(condv1alpha1.ReadyWithMsg("")) return } From f73294fc6c73b06d2bb354fd261d853878aa6cf1 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Thu, 19 Feb 2026 17:12:03 +0100 Subject: [PATCH 057/135] fix lint issue --- tools/fix-openapi-gvk/main.go | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/tools/fix-openapi-gvk/main.go b/tools/fix-openapi-gvk/main.go index 5f5d66a9..1c3a4bc3 100644 --- a/tools/fix-openapi-gvk/main.go +++ b/tools/fix-openapi-gvk/main.go @@ -146,9 +146,10 @@ func main() { fl := lines[i] funcLines = append(funcLines, fl) for _, ch := range fl { - if ch == '{' { + switch ch { + case '{': depth++ - } else if ch == '}' { + case '}': depth-- } } From 22bc82a092bfc9068b40ce0dc37bacec58d7f075 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Sat, 28 Feb 2026 19:41:03 +0100 Subject: [PATCH 058/135] updated lint issue --- tools/fix-openapi-gvk/main.go | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/tools/fix-openapi-gvk/main.go b/tools/fix-openapi-gvk/main.go index 1c3a4bc3..80c4936b 100644 --- a/tools/fix-openapi-gvk/main.go +++ b/tools/fix-openapi-gvk/main.go @@ -210,9 +210,10 @@ func main() { for j := schemaLineIdx; j < len(funcLines); j++ { fl := funcLines[j] for _, ch := range fl { - if ch == '{' { + switch ch { + case '{': schemaDepth++ - } else if ch == '}' { + case '}': schemaDepth-- } } From d71a493860eaf47a0c9af5661acd08c439ab7582 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Sat, 28 Feb 2026 19:50:50 +0100 Subject: [PATCH 059/135] fix makefile comment --- Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Makefile b/Makefile index c51d005a..0eb9444f 100644 --- a/Makefile +++ b/Makefile @@ -141,7 +141,7 @@ $(KFORM): $(LOCALBIN) test -s $(LOCALBIN)/kform || GOBIN=$(LOCALBIN) go install github.com/kform-dev/kform/cmd/kform@$(KFORM_VERSION) .PHONY: golangci-lint -golangci-lint: $(GOLANGCILINT) ## Download kform locally if necessary. +golangci-lint: $(GOLANGCILINT) ## Download golangci locally if necessary. $(GOLANGCILINT): $(LOCALBIN) test -s $(LOCALBIN)/golangci-lint || GOBIN=$(LOCALBIN) go install github.com/golangci/golangci-lint/cmd/golangci-lint@$(GOLANGCILINT_VERSION) From 9611f0e1eb436c8495ec3894aea22ff106957c18 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Sat, 28 Feb 2026 21:03:07 +0100 Subject: [PATCH 060/135] update namespace list handling --- apis/config/config_resource.go | 25 ++---- apis/config/configblame_resource.go | 27 ++---- apis/config/configset_resource.go | 27 ++---- apis/config/deviation_resource.go | 25 ++---- apis/config/running_config_resource.go | 27 ++---- apis/config/sensitive_config_resource.go | 25 ++---- pkg/registry/configblame/strategy_resource.go | 18 +--- pkg/registry/generic/strategy_resource.go | 9 ++ .../{configblame => options}/fieldselector.go | 31 ++++++- pkg/registry/runningconfig/fieldselector.go | 82 ------------------- .../runningconfig/strategy_resource.go | 18 +--- 11 files changed, 95 insertions(+), 219 deletions(-) rename pkg/registry/{configblame => options}/fieldselector.go (71%) delete mode 100644 pkg/registry/runningconfig/fieldselector.go diff --git a/apis/config/config_resource.go b/apis/config/config_resource.go index bc7fad0b..a2a345b6 100644 --- a/apis/config/config_resource.go +++ b/apis/config/config_resource.go @@ -262,26 +262,17 @@ type ConfigFilter struct { } func (r *ConfigFilter) Filter(ctx context.Context, obj runtime.Object) bool { - f := false // result of the previous filter o, ok := obj.(*Config) if !ok { - return f + return true } - if r.Name != "" { - if o.GetName() == r.Name { - f = false - } else { - f = true - } - } - if r.Namespace != "" { - if o.GetNamespace() == r.Namespace { - f = false - } else { - f = true - } - } - return f + if r.Name != "" && o.GetName() != r.Name { + return true + } + if r.Namespace != "" && o.GetNamespace() != r.Namespace { + return true + } + return false } func (r *Config) PrepareForCreate(ctx context.Context, obj runtime.Object) { diff --git a/apis/config/configblame_resource.go b/apis/config/configblame_resource.go index e7ab4341..3af53f7d 100644 --- a/apis/config/configblame_resource.go +++ b/apis/config/configblame_resource.go @@ -201,26 +201,17 @@ type ConfigBlameFilter struct { } func (r *ConfigBlameFilter) Filter(ctx context.Context, obj runtime.Object) bool { - f := false // result of the previous filter - o, ok := obj.(*Config) + o, ok := obj.(*ConfigBlame) if !ok { - return f + return true } - if r.Name != "" { - if o.GetName() == r.Name { - f = false - } else { - f = true - } - } - if r.Namespace != "" { - if o.GetNamespace() == r.Namespace { - f = false - } else { - f = true - } - } - return f + if r.Name != "" && o.GetName() != r.Name { + return true + } + if r.Namespace != "" && o.GetNamespace() != r.Namespace { + return true + } + return false } func (r *ConfigBlame) PrepareForCreate(ctx context.Context, obj runtime.Object) { diff --git a/apis/config/configset_resource.go b/apis/config/configset_resource.go index 6c9ee821..65eb28cc 100644 --- a/apis/config/configset_resource.go +++ b/apis/config/configset_resource.go @@ -254,26 +254,17 @@ type ConfigSetFilter struct { } func (r *ConfigSetFilter) Filter(ctx context.Context, obj runtime.Object) bool { - f := false // result of the previous filter - o, ok := obj.(*Config) + o, ok := obj.(*ConfigSet) if !ok { - return f + return true } - if r.Name != "" { - if o.GetName() == r.Name { - f = false - } else { - f = true - } - } - if r.Namespace != "" { - if o.GetNamespace() == r.Namespace { - f = false - } else { - f = true - } - } - return f + if r.Name != "" && o.GetName() != r.Name { + return true + } + if r.Namespace != "" && o.GetNamespace() != r.Namespace { + return true + } + return false } func (r *ConfigSet) PrepareForCreate(ctx context.Context, obj runtime.Object) { diff --git a/apis/config/deviation_resource.go b/apis/config/deviation_resource.go index 6c5d7183..ad52ab60 100644 --- a/apis/config/deviation_resource.go +++ b/apis/config/deviation_resource.go @@ -256,26 +256,17 @@ type DeviationFilter struct { } func (r *DeviationFilter) Filter(ctx context.Context, obj runtime.Object) bool { - f := false // result of the previous filter o, ok := obj.(*Deviation) if !ok { - return f + return true } - if r.Name != "" { - if o.GetName() == r.Name { - f = false - } else { - f = true - } - } - if r.Namespace != "" { - if o.GetNamespace() == r.Namespace { - f = false - } else { - f = true - } - } - return f + if r.Name != "" && o.GetName() != r.Name { + return true + } + if r.Namespace != "" && o.GetNamespace() != r.Namespace { + return true + } + return false } func (r *Deviation) PrepareForCreate(ctx context.Context, obj runtime.Object) { diff --git a/apis/config/running_config_resource.go b/apis/config/running_config_resource.go index 45424af3..d02f6a62 100644 --- a/apis/config/running_config_resource.go +++ b/apis/config/running_config_resource.go @@ -201,26 +201,17 @@ type RunningConfigFilter struct { } func (r *RunningConfigFilter) Filter(ctx context.Context, obj runtime.Object) bool { - f := false // result of the previous filter - o, ok := obj.(*Config) + o, ok := obj.(*RunningConfig) if !ok { - return f + return true } - if r.Name != "" { - if o.GetName() == r.Name { - f = false - } else { - f = true - } - } - if r.Namespace != "" { - if o.GetNamespace() == r.Namespace { - f = false - } else { - f = true - } - } - return f + if r.Name != "" && o.GetName() != r.Name { + return true + } + if r.Namespace != "" && o.GetNamespace() != r.Namespace { + return true + } + return false } func (r *RunningConfig) PrepareForCreate(ctx context.Context, obj runtime.Object) { diff --git a/apis/config/sensitive_config_resource.go b/apis/config/sensitive_config_resource.go index cb7fb616..e58eaff2 100644 --- a/apis/config/sensitive_config_resource.go +++ b/apis/config/sensitive_config_resource.go @@ -262,26 +262,17 @@ type SensitiveConfigFilter struct { } func (r *SensitiveConfigFilter) Filter(ctx context.Context, obj runtime.Object) bool { - f := false // result of the previous filter o, ok := obj.(*SensitiveConfig) if !ok { - return f + return true } - if r.Name != "" { - if o.GetName() == r.Name { - f = false - } else { - f = true - } - } - if r.Namespace != "" { - if o.GetNamespace() == r.Namespace { - f = false - } else { - f = true - } - } - return f + if r.Name != "" && o.GetName() != r.Name { + return true + } + if r.Namespace != "" && o.GetNamespace() != r.Namespace { + return true + } + return false } func (r *SensitiveConfig) PrepareForCreate(ctx context.Context, obj runtime.Object) { diff --git a/pkg/registry/configblame/strategy_resource.go b/pkg/registry/configblame/strategy_resource.go index fc036f28..0f01bb42 100644 --- a/pkg/registry/configblame/strategy_resource.go +++ b/pkg/registry/configblame/strategy_resource.go @@ -40,7 +40,6 @@ import ( "k8s.io/apimachinery/pkg/types" "k8s.io/apimachinery/pkg/util/validation/field" "k8s.io/apimachinery/pkg/watch" - genericapirequest "k8s.io/apiserver/pkg/endpoints/request" "k8s.io/apiserver/pkg/storage/names" "sigs.k8s.io/controller-runtime/pkg/client" "sigs.k8s.io/structured-merge-diff/v6/fieldpath" @@ -234,25 +233,14 @@ func (r *strategy) Get(ctx context.Context, key types.NamespacedName) (runtime.O return r.getConfigBlame(ctx, target, key) } -func (r *strategy) List(ctx context.Context, options *metainternalversion.ListOptions) (runtime.Object, error) { +func (r *strategy) List(ctx context.Context, opts *metainternalversion.ListOptions) (runtime.Object, error) { log := log.FromContext(ctx) - filter, err := parseFieldSelector(ctx, options.FieldSelector) + filter, err := options.ParseFieldSelector(ctx, opts.FieldSelector) if err != nil { return nil, err } - namespace, ok := genericapirequest.NamespaceFrom(ctx) - if ok { - if filter != nil { - filter.Namespace = namespace - } else { - filter = &Filter{ - Namespace: namespace, - } - } - } - newListObj := r.obj.NewList() v, err := utils.GetListPrt(newListObj) if err != nil { @@ -260,7 +248,7 @@ func (r *strategy) List(ctx context.Context, options *metainternalversion.ListOp } targets := &invv1alpha1.TargetList{} - if err := r.client.List(ctx, targets); err != nil { + if err := r.client.List(ctx, targets, options.ListOptsFromInternal(filter, opts)...); err != nil { return nil, err } diff --git a/pkg/registry/generic/strategy_resource.go b/pkg/registry/generic/strategy_resource.go index 04526560..a10b5185 100644 --- a/pkg/registry/generic/strategy_resource.go +++ b/pkg/registry/generic/strategy_resource.go @@ -37,6 +37,7 @@ import ( "k8s.io/apimachinery/pkg/watch" "k8s.io/apiserver/pkg/storage/names" "sigs.k8s.io/structured-merge-diff/v6/fieldpath" + genericapirequest "k8s.io/apiserver/pkg/endpoints/request" ) // NewStrategy creates and returns a strategy instance @@ -232,6 +233,14 @@ func (r *strategy) List(ctx context.Context, options *metainternalversion.ListOp return } + // Always enforce namespace scoping for namespace-scoped resources + if r.obj.NamespaceScoped() { + ns, ok := genericapirequest.NamespaceFrom(ctx) + if ok && ns != "" && accessor.GetNamespace() != ns { + return + } + } + if options.LabelSelector != nil || filter != nil { f := true if options.LabelSelector != nil { diff --git a/pkg/registry/configblame/fieldselector.go b/pkg/registry/options/fieldselector.go similarity index 71% rename from pkg/registry/configblame/fieldselector.go rename to pkg/registry/options/fieldselector.go index ea4b82c8..1f7cb2e2 100644 --- a/pkg/registry/configblame/fieldselector.go +++ b/pkg/registry/options/fieldselector.go @@ -14,7 +14,7 @@ See the License for the specific language governing permissions and limitations under the License. */ -package configblame +package options import ( "context" @@ -24,6 +24,8 @@ import ( "k8s.io/apimachinery/pkg/fields" "k8s.io/apimachinery/pkg/selection" genericapirequest "k8s.io/apiserver/pkg/endpoints/request" + metainternalversion "k8s.io/apimachinery/pkg/apis/meta/internalversion" + "sigs.k8s.io/controller-runtime/pkg/client" ) // Filter @@ -36,7 +38,7 @@ type Filter struct { } // parseFieldSelector parses client-provided fields.Selector into a packageFilter -func parseFieldSelector(ctx context.Context, fieldSelector fields.Selector) (*Filter, error) { +func ParseFieldSelector(ctx context.Context, fieldSelector fields.Selector) (*Filter, error) { var filter *Filter // add the namespace to the list @@ -80,3 +82,28 @@ func parseFieldSelector(ctx context.Context, fieldSelector fields.Selector) (*Fi return filter, nil } + + +func ListOptsFromInternal(filter *Filter, opts *metainternalversion.ListOptions) []client.ListOption { + listOpts := []client.ListOption{} + + if filter != nil && filter.Namespace != "" { + listOpts = append(listOpts, client.InNamespace(filter.Namespace)) + } + + if opts != nil { + if opts.LabelSelector != nil { + listOpts = append(listOpts, client.MatchingLabelsSelector{ + Selector: opts.LabelSelector, + }) + } + if opts.Limit > 0 { + listOpts = append(listOpts, client.Limit(opts.Limit)) + } + if opts.Continue != "" { + listOpts = append(listOpts, client.Continue(opts.Continue)) + } + } + + return listOpts +} \ No newline at end of file diff --git a/pkg/registry/runningconfig/fieldselector.go b/pkg/registry/runningconfig/fieldselector.go deleted file mode 100644 index db1d34ea..00000000 --- a/pkg/registry/runningconfig/fieldselector.go +++ /dev/null @@ -1,82 +0,0 @@ -/* -Copyright 2024 Nokia. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ - -package runningconfig - -import ( - "context" - "fmt" - - apierrors "k8s.io/apimachinery/pkg/api/errors" - "k8s.io/apimachinery/pkg/fields" - "k8s.io/apimachinery/pkg/selection" - genericapirequest "k8s.io/apiserver/pkg/endpoints/request" -) - -// Filter -type Filter struct { - // Name filters by the name of the objects - Name string - - // Namespace filters by the namespace of the objects - Namespace string -} - -// parseFieldSelector parses client-provided fields.Selector into a packageFilter -func parseFieldSelector(ctx context.Context, fieldSelector fields.Selector) (*Filter, error) { - var filter *Filter - - // add the namespace to the list - namespace, ok := genericapirequest.NamespaceFrom(ctx) - if fieldSelector == nil { - if ok { - return &Filter{Namespace: namespace}, nil - } - return filter, nil - } - - requirements := fieldSelector.Requirements() - for _, requirement := range requirements { - filter = &Filter{} - switch requirement.Operator { - case selection.Equals, selection.DoesNotExist: - if requirement.Value == "" { - return filter, apierrors.NewBadRequest(fmt.Sprintf("unsupported fieldSelector value %q for field %q with operator %q", requirement.Value, requirement.Field, requirement.Operator)) - } - default: - return filter, apierrors.NewBadRequest(fmt.Sprintf("unsupported fieldSelector operator %q for field %q", requirement.Operator, requirement.Field)) - } - - switch requirement.Field { - case "metadata.name": - filter.Name = requirement.Value - case "metadata.namespace": - filter.Namespace = requirement.Value - default: - return filter, apierrors.NewBadRequest(fmt.Sprintf("unknown fieldSelector field %q", requirement.Field)) - } - } - // add namespace to the filter selector if specified - if ok { - if filter != nil { - filter.Namespace = namespace - } else { - filter = &Filter{Namespace: namespace} - } - } - - return filter, nil -} diff --git a/pkg/registry/runningconfig/strategy_resource.go b/pkg/registry/runningconfig/strategy_resource.go index d345de36..83218d46 100644 --- a/pkg/registry/runningconfig/strategy_resource.go +++ b/pkg/registry/runningconfig/strategy_resource.go @@ -39,7 +39,6 @@ import ( "k8s.io/apimachinery/pkg/types" "k8s.io/apimachinery/pkg/util/validation/field" "k8s.io/apimachinery/pkg/watch" - genericapirequest "k8s.io/apiserver/pkg/endpoints/request" "k8s.io/apiserver/pkg/storage/names" "sigs.k8s.io/controller-runtime/pkg/client" "sigs.k8s.io/structured-merge-diff/v6/fieldpath" @@ -208,25 +207,14 @@ func (r *strategy) Get(ctx context.Context, key types.NamespacedName) (runtime.O return r.getRunningConfig(ctx, target, key) } -func (r *strategy) List(ctx context.Context, options *metainternalversion.ListOptions) (runtime.Object, error) { +func (r *strategy) List(ctx context.Context, opts *metainternalversion.ListOptions) (runtime.Object, error) { log := log.FromContext(ctx) - filter, err := parseFieldSelector(ctx, options.FieldSelector) + filter, err := options.ParseFieldSelector(ctx, opts.FieldSelector) if err != nil { return nil, err } - namespace, ok := genericapirequest.NamespaceFrom(ctx) - if ok { - if filter != nil { - filter.Namespace = namespace - } else { - filter = &Filter{ - Namespace: namespace, - } - } - } - newListObj := r.obj.NewList() v, err := utils.GetListPrt(newListObj) if err != nil { @@ -234,7 +222,7 @@ func (r *strategy) List(ctx context.Context, options *metainternalversion.ListOp } targets := &invv1alpha1.TargetList{} - if err := r.client.List(ctx, targets); err != nil { + if err := r.client.List(ctx, targets, options.ListOptsFromInternal(filter, opts)...); err != nil { return nil, err } From 0d2a3c470f860b6d9766689ef91504d716025c85 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Sat, 28 Feb 2026 21:58:39 +0100 Subject: [PATCH 061/135] update k get sdc failure --- pkg/registry/generic/store.go | 2 ++ 1 file changed, 2 insertions(+) diff --git a/pkg/registry/generic/store.go b/pkg/registry/generic/store.go index 8eba27e8..8aa83c94 100644 --- a/pkg/registry/generic/store.go +++ b/pkg/registry/generic/store.go @@ -136,6 +136,8 @@ func NewStatusREST( statusStore := *registryStore statusStore.CreateStrategy = nil statusStore.DeleteStrategy = nil + statusStore.CategoryList = nil + statusStore.ShortNameList = nil statusStrategy := NewStatusStrategy(obj, scheme, registryStore.Storage, watcherManager, opts) statusStore.UpdateStrategy = statusStrategy statusStore.ResetFieldsStrategy = statusStrategy From 260a8a7e2833e407bc40ed6890959c56d25f0f30 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Sun, 1 Mar 2026 07:01:14 +0100 Subject: [PATCH 062/135] renamed condition -> clearer naming --- apis/inv/v1alpha1/condition.go | 12 ++++++------ pkg/reconcilers/targetconfig/reconciler.go | 2 +- pkg/reconcilers/targetrecovery/reconciler.go | 7 +++++-- 3 files changed, 12 insertions(+), 9 deletions(-) diff --git a/apis/inv/v1alpha1/condition.go b/apis/inv/v1alpha1/condition.go index 711ca605..a77e7cc4 100644 --- a/apis/inv/v1alpha1/condition.go +++ b/apis/inv/v1alpha1/condition.go @@ -123,9 +123,9 @@ func DatastoreSchemaNotReady(msg string) condv1alpha1.Condition { }} } -// ConfigReady return a condition that indicates the config +// ConfigRecoveryReady return a condition that indicates the config // get re-applied when the target became ready -func ConfigReady(msg string) condv1alpha1.Condition { +func ConfigRecoveryReady(msg string) condv1alpha1.Condition { return condv1alpha1.Condition{Condition: metav1.Condition{ Type: string(ConditionTypeConfigRecoveryReady), Status: metav1.ConditionTrue, @@ -135,9 +135,9 @@ func ConfigReady(msg string) condv1alpha1.Condition { }} } -// ConfigFailed returns a condition that indicates the config +// ConfigRecoveryFailed returns a condition that indicates the config // is in failed condition due to a dependency -func ConfigFailed(msg string) condv1alpha1.Condition { +func ConfigRecoveryFailed(msg string) condv1alpha1.Condition { return condv1alpha1.Condition{Condition: metav1.Condition{ Type: string(ConditionTypeConfigRecoveryReady), Status: metav1.ConditionFalse, @@ -147,9 +147,9 @@ func ConfigFailed(msg string) condv1alpha1.Condition { }} } -// ConfigReApplyFailed returns a condition that indicates the config +// ConfigRecoveryReApplyFailed returns a condition that indicates the config // we we reapplied to the target -func ConfigReApplyFailed(msg string) condv1alpha1.Condition { +func ConfigRecoveryReApplyFailed(msg string) condv1alpha1.Condition { return condv1alpha1.Condition{Condition: metav1.Condition{ Type: string(ConditionTypeConfigRecoveryReady), Status: metav1.ConditionFalse, diff --git a/pkg/reconcilers/targetconfig/reconciler.go b/pkg/reconcilers/targetconfig/reconciler.go index 56e58f95..487b8bff 100644 --- a/pkg/reconcilers/targetconfig/reconciler.go +++ b/pkg/reconcilers/targetconfig/reconciler.go @@ -190,7 +190,7 @@ func (r *reconciler) Reconcile(ctx context.Context, req ctrl.Request) (ctrl.Resu configv1alpha1.TargetFailed("target not recovered"), ) log.Info("config transaction -> target not recovered yet") - return ctrl.Result{}, err + return ctrl.Result{RequeueAfter: 5 * time.Second}, err } retry, err := r.transactor.Transact(ctx, target, dsctx, configv1alpha1.TargetReady("target ready")) diff --git a/pkg/reconcilers/targetrecovery/reconciler.go b/pkg/reconcilers/targetrecovery/reconciler.go index 468d8b1b..6a720d19 100644 --- a/pkg/reconcilers/targetrecovery/reconciler.go +++ b/pkg/reconcilers/targetrecovery/reconciler.go @@ -36,6 +36,7 @@ import ( "k8s.io/apimachinery/pkg/runtime/schema" "k8s.io/client-go/discovery" "k8s.io/client-go/tools/events" + "k8s.io/utils/ptr" ctrl "sigs.k8s.io/controller-runtime" "sigs.k8s.io/controller-runtime/pkg/client" "sigs.k8s.io/controller-runtime/pkg/event" @@ -162,7 +163,7 @@ func (r *reconciler) handleSuccess(ctx context.Context, target *invv1alpha1.Targ if msg != nil { newMsg = *msg } - newCond := invv1alpha1.ConfigReady(newMsg) + newCond := invv1alpha1.ConfigRecoveryReady(newMsg) oldCond := target.GetCondition(invv1alpha1.ConditionTypeConfigRecoveryReady) if newCond.Equal(oldCond) { @@ -181,6 +182,7 @@ func (r *reconciler) handleSuccess(ctx context.Context, target *invv1alpha1.Targ return r.client.Status().Apply(ctx, applyConfig, &client.SubResourceApplyOptions{ ApplyOptions: client.ApplyOptions{ FieldManager: reconcilerName, + Force: ptr.To(true), }, }) } @@ -191,7 +193,7 @@ func (r *reconciler) handleError(ctx context.Context, target *invv1alpha1.Target if err != nil { msg = fmt.Sprintf("%s err %s", msg, err.Error()) } - newCond := invv1alpha1.ConfigFailed(msg) + newCond := invv1alpha1.ConfigRecoveryFailed(msg) oldCond := target.GetCondition(invv1alpha1.ConditionTypeConfigRecoveryReady) if newCond.Equal(oldCond) { @@ -211,6 +213,7 @@ func (r *reconciler) handleError(ctx context.Context, target *invv1alpha1.Target return r.client.Status().Apply(ctx, applyConfig, &client.SubResourceApplyOptions{ ApplyOptions: client.ApplyOptions{ FieldManager: reconcilerName, + Force: ptr.To(true), }, }) } From f560699046617e9ecb9f57cbd51c3dee571e3ef3 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Sun, 1 Mar 2026 09:56:00 +0100 Subject: [PATCH 063/135] move target to config domain for subresources --- apis/condition/v1alpha1/generated.pb.go | 136 +- .../v1alpha1/generated.protomessage.pb.go | 28 + apis/config/condition.go | 9 +- apis/config/config_resource.go | 12 +- apis/config/configblame_resource.go | 12 +- apis/config/configset_resource.go | 12 +- apis/config/configset_types.go | 8 +- apis/config/deviation_resource.go | 12 +- apis/config/deviation_types.go | 4 +- apis/config/handlers/confighandler.go | 6 +- apis/config/register.go | 2 + apis/config/running_config_resource.go | 12 +- apis/config/sensitive_config_resource.go | 12 +- apis/config/target_helpers.go | 72 + apis/config/target_resource.go | 354 + apis/config/target_types.go | 108 + apis/config/v1alpha1/condition.go | 147 +- apis/config/v1alpha1/config_helpers.go | 4 +- apis/config/v1alpha1/configset_types.go | 8 +- apis/config/v1alpha1/generated.pb.go | 5562 +++++--- apis/config/v1alpha1/generated.proto | 102 +- .../v1alpha1/generated.protomessage.pb.go | 100 + apis/config/v1alpha1/register.go | 2 + apis/config/v1alpha1/target_helpers.go | 166 + apis/config/v1alpha1/target_resource.go | 79 + apis/config/v1alpha1/target_types.go | 109 + .../v1alpha1/zz_generated.conversion.go | 294 +- apis/config/v1alpha1/zz_generated.deepcopy.go | 156 +- apis/config/zz_generated.deepcopy.go | 176 +- apis/inv/v1alpha1/condition.go | 143 +- apis/inv/v1alpha1/discoveryrule_types.go | 74 +- apis/inv/v1alpha1/generated.pb.go | 11109 ++++++---------- apis/inv/v1alpha1/generated.proto | 115 +- .../inv/v1alpha1/generated.protomessage.pb.go | 118 + apis/inv/v1alpha1/target_helpers.go | 2 + apis/inv/v1alpha1/target_types.go | 4 +- apis/inv/v1alpha1/targetconnprofile_types.go | 2 +- apis/inv/v1alpha1/targetsyncprofile_types.go | 2 +- apis/inv/v1alpha1/zz_generated.deepcopy.go | 142 - artifacts/in/configmap-input-vars.yaml | 2 +- artifacts/inv.sdcio.dev_targets.yaml | 211 - artifacts/rbac-cluster-role-api-server.yaml | 2 +- artifacts/rbac-cluster-role-controller.yaml | 2 +- ...c-cluster-role-data-server-controller.yaml | 2 +- go.mod | 2 +- pkg/discovery/discoveryrule/children.go | 2 +- pkg/discovery/discoveryrule/deviation.go | 5 +- pkg/discovery/discoveryrule/discover_gnmi.go | 7 +- .../discover_gnmi_discovery_test.go | 10 +- pkg/discovery/discoveryrule/discover_none.go | 3 +- pkg/discovery/discoveryrule/target.go | 23 +- .../config/v1alpha1/configsetspec.go | 4 +- .../config/v1alpha1/configsetstatus.go | 4 +- .../config/v1alpha1/configsettarget.go | 43 + .../config/v1alpha1/configsettargetstatus.go | 46 + .../config/v1alpha1/discoveryinfo.go | 111 + .../config/v1alpha1/target.go | 219 +- .../config/v1alpha1/targetspec.go | 89 + .../config/v1alpha1/targetstatus.go | 39 +- .../v1alpha1/targetstatususedreferences.go | 65 + pkg/generated/applyconfiguration/utils.go | 20 +- .../typed/config/v1alpha1/config_client.go | 5 + .../v1alpha1/fake/fake_config_client.go | 4 + .../v1alpha1/fake/fake_target.go | 8 +- .../config/v1alpha1/generated_expansion.go | 2 + .../typed/{inv => config}/v1alpha1/target.go | 24 +- .../inv/v1alpha1/fake/fake_inv_client.go | 4 - .../typed/inv/v1alpha1/generated_expansion.go | 2 - .../typed/inv/v1alpha1/inv_client.go | 5 - .../config/v1alpha1/interface.go | 7 + .../{inv => config}/v1alpha1/target.go | 22 +- .../informers/externalversions/generic.go | 4 +- .../inv/v1alpha1/interface.go | 7 - .../config/v1alpha1/expansion_generated.go | 8 + .../{inv => config}/v1alpha1/target.go | 16 +- .../inv/v1alpha1/expansion_generated.go | 8 - pkg/generated/openapi/zz_generated.openapi.go | 708 +- pkg/reconcilers/configset/reconciler.go | 17 +- .../eventhandler/watch_schema_for_target.go | 3 +- .../eventhandler/watch_secret_for_target.go | 4 +- .../eventhandler/watch_target_for_config.go | 5 +- .../watch_target_for_configset.go | 5 +- .../watch_target_for_subscription.go | 5 +- .../watch_targetconnprofile_for_target.go | 3 +- .../watch_targetsyncprofile_for_target.go | 3 +- pkg/reconcilers/rollout/transaction.go | 3 +- pkg/reconcilers/subscription/reconciler.go | 3 +- pkg/reconcilers/target/reconciler.go | 14 +- pkg/reconcilers/targetconfig/reconciler.go | 27 +- pkg/reconcilers/targetdatastore/reconciler.go | 35 +- pkg/reconcilers/targetrecovery/reconciler.go | 25 +- pkg/registry/configblame/strategy_resource.go | 8 +- pkg/registry/generic/store.go | 4 +- pkg/registry/generic/strategy_resource.go | 2 +- pkg/registry/options/fieldselector.go | 47 +- .../runningconfig/strategy_resource.go | 8 +- pkg/sdc/target/manager/dryrun.go | 4 +- pkg/sdc/target/manager/manager.go | 6 +- pkg/sdc/target/manager/runtime.go | 12 +- pkg/sdc/target/manager/transactor.go | 12 +- 100 files changed, 10558 insertions(+), 10857 deletions(-) create mode 100644 apis/condition/v1alpha1/generated.protomessage.pb.go create mode 100644 apis/config/target_helpers.go create mode 100644 apis/config/target_resource.go create mode 100644 apis/config/target_types.go create mode 100644 apis/config/v1alpha1/generated.protomessage.pb.go create mode 100644 apis/config/v1alpha1/target_helpers.go create mode 100644 apis/config/v1alpha1/target_resource.go create mode 100644 apis/config/v1alpha1/target_types.go create mode 100644 apis/inv/v1alpha1/generated.protomessage.pb.go delete mode 100644 artifacts/inv.sdcio.dev_targets.yaml create mode 100644 pkg/generated/applyconfiguration/config/v1alpha1/configsettarget.go create mode 100644 pkg/generated/applyconfiguration/config/v1alpha1/configsettargetstatus.go create mode 100644 pkg/generated/applyconfiguration/config/v1alpha1/discoveryinfo.go create mode 100644 pkg/generated/applyconfiguration/config/v1alpha1/targetspec.go create mode 100644 pkg/generated/applyconfiguration/config/v1alpha1/targetstatususedreferences.go rename pkg/generated/clientset/versioned/typed/{inv => config}/v1alpha1/fake/fake_target.go (83%) rename pkg/generated/clientset/versioned/typed/{inv => config}/v1alpha1/target.go (64%) rename pkg/generated/informers/externalversions/{inv => config}/v1alpha1/target.go (81%) rename pkg/generated/listers/{inv => config}/v1alpha1/target.go (77%) diff --git a/apis/condition/v1alpha1/generated.pb.go b/apis/condition/v1alpha1/generated.pb.go index ddb41232..dbc740da 100644 --- a/apis/condition/v1alpha1/generated.pb.go +++ b/apis/condition/v1alpha1/generated.pb.go @@ -22,146 +22,16 @@ import ( fmt "fmt" io "io" - math "math" math_bits "math/bits" reflect "reflect" strings "strings" - - proto "github.com/gogo/protobuf/proto" ) -// Reference imports to suppress errors if they are not otherwise used. -var _ = proto.Marshal -var _ = fmt.Errorf -var _ = math.Inf - -// This is a compile-time assertion to ensure that this generated file -// is compatible with the proto package it is being compiled against. -// A compilation error at this line likely means your copy of the -// proto package needs to be updated. -const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package - -func (m *Condition) Reset() { *m = Condition{} } -func (*Condition) ProtoMessage() {} -func (*Condition) Descriptor() ([]byte, []int) { - return fileDescriptor_04bc400a18951c3b, []int{0} -} -func (m *Condition) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *Condition) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err - } - return b[:n], nil -} -func (m *Condition) XXX_Merge(src proto.Message) { - xxx_messageInfo_Condition.Merge(m, src) -} -func (m *Condition) XXX_Size() int { - return m.Size() -} -func (m *Condition) XXX_DiscardUnknown() { - xxx_messageInfo_Condition.DiscardUnknown(m) -} +func (m *Condition) Reset() { *m = Condition{} } -var xxx_messageInfo_Condition proto.InternalMessageInfo +func (m *ConditionedStatus) Reset() { *m = ConditionedStatus{} } -func (m *ConditionedStatus) Reset() { *m = ConditionedStatus{} } -func (*ConditionedStatus) ProtoMessage() {} -func (*ConditionedStatus) Descriptor() ([]byte, []int) { - return fileDescriptor_04bc400a18951c3b, []int{1} -} -func (m *ConditionedStatus) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *ConditionedStatus) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err - } - return b[:n], nil -} -func (m *ConditionedStatus) XXX_Merge(src proto.Message) { - xxx_messageInfo_ConditionedStatus.Merge(m, src) -} -func (m *ConditionedStatus) XXX_Size() int { - return m.Size() -} -func (m *ConditionedStatus) XXX_DiscardUnknown() { - xxx_messageInfo_ConditionedStatus.DiscardUnknown(m) -} - -var xxx_messageInfo_ConditionedStatus proto.InternalMessageInfo - -func (m *UnrecoverableMessage) Reset() { *m = UnrecoverableMessage{} } -func (*UnrecoverableMessage) ProtoMessage() {} -func (*UnrecoverableMessage) Descriptor() ([]byte, []int) { - return fileDescriptor_04bc400a18951c3b, []int{2} -} -func (m *UnrecoverableMessage) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *UnrecoverableMessage) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err - } - return b[:n], nil -} -func (m *UnrecoverableMessage) XXX_Merge(src proto.Message) { - xxx_messageInfo_UnrecoverableMessage.Merge(m, src) -} -func (m *UnrecoverableMessage) XXX_Size() int { - return m.Size() -} -func (m *UnrecoverableMessage) XXX_DiscardUnknown() { - xxx_messageInfo_UnrecoverableMessage.DiscardUnknown(m) -} - -var xxx_messageInfo_UnrecoverableMessage proto.InternalMessageInfo - -func init() { - proto.RegisterType((*Condition)(nil), "github.com.sdcio.config_server.apis.condition.v1alpha1.Condition") - proto.RegisterType((*ConditionedStatus)(nil), "github.com.sdcio.config_server.apis.condition.v1alpha1.ConditionedStatus") - proto.RegisterType((*UnrecoverableMessage)(nil), "github.com.sdcio.config_server.apis.condition.v1alpha1.UnrecoverableMessage") -} - -func init() { - proto.RegisterFile("github.com/sdcio/config-server/apis/condition/v1alpha1/generated.proto", fileDescriptor_04bc400a18951c3b) -} - -var fileDescriptor_04bc400a18951c3b = []byte{ - // 379 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x9c, 0xd2, 0x3f, 0x8f, 0xda, 0x30, - 0x18, 0x06, 0xf0, 0xb8, 0x1d, 0x10, 0x66, 0x40, 0x44, 0x95, 0x8a, 0x18, 0x0c, 0x62, 0xa2, 0x03, - 0xb6, 0x40, 0x15, 0xea, 0x0a, 0x95, 0xba, 0x75, 0x49, 0xd5, 0x0e, 0x55, 0xa5, 0xd6, 0x24, 0x2f, - 0xc6, 0x82, 0xc4, 0x91, 0x9d, 0x44, 0xea, 0xd6, 0xa1, 0xd3, 0x4d, 0xf7, 0xb1, 0x18, 0x19, 0x99, - 0xd0, 0x91, 0xfb, 0x22, 0xa7, 0xfc, 0x25, 0x77, 0xb7, 0xb1, 0xc5, 0x7e, 0xed, 0xdf, 0xf3, 0xc8, - 0x0a, 0xfe, 0x22, 0x64, 0xb4, 0x8d, 0xd7, 0xd4, 0x55, 0x3e, 0x33, 0x9e, 0x2b, 0x15, 0x73, 0x55, - 0xb0, 0x91, 0x62, 0x6a, 0x40, 0x27, 0xa0, 0x19, 0x0f, 0xa5, 0xc9, 0xb6, 0x3c, 0x19, 0x49, 0x15, - 0xb0, 0x64, 0xc6, 0xf7, 0xe1, 0x96, 0xcf, 0x98, 0x80, 0x00, 0x34, 0x8f, 0xc0, 0xa3, 0xa1, 0x56, - 0x91, 0xb2, 0x17, 0x57, 0x87, 0xe6, 0x0e, 0x2d, 0x9c, 0xdf, 0x85, 0x43, 0x33, 0x87, 0xd6, 0x0e, - 0xad, 0x9c, 0xc1, 0xb4, 0x91, 0x2f, 0x94, 0x50, 0x2c, 0xe7, 0xd6, 0xf1, 0x26, 0x5f, 0xe5, 0x8b, - 0xfc, 0xab, 0x88, 0x19, 0x7c, 0xdc, 0x7d, 0x32, 0x54, 0xaa, 0xac, 0x96, 0xcf, 0xdd, 0xad, 0x0c, - 0x40, 0xff, 0x65, 0xe1, 0x4e, 0x14, 0x3d, 0x7d, 0x88, 0x38, 0x4b, 0x5e, 0x95, 0x1b, 0xfb, 0xb8, - 0xfd, 0xb9, 0x8a, 0xb6, 0xff, 0xe0, 0x76, 0xdd, 0xa3, 0x8f, 0x46, 0x68, 0xd2, 0x99, 0x33, 0x5a, - 0xb0, 0xb4, 0xc9, 0xd2, 0x70, 0x27, 0x8a, 0xda, 0x19, 0x4b, 0x93, 0x19, 0xad, 0x8d, 0x55, 0xef, - 0x70, 0x1e, 0x5a, 0xe9, 0x79, 0x78, 0x65, 0x9d, 0x2b, 0x3a, 0xbe, 0x43, 0xb8, 0x57, 0x0f, 0xc0, - 0xfb, 0x16, 0xf1, 0x28, 0x36, 0x76, 0x8c, 0x71, 0x7d, 0xc4, 0xf4, 0xd1, 0xe8, 0xed, 0xa4, 0x33, - 0x5f, 0xd2, 0xdb, 0x9e, 0xad, 0x51, 0xc5, 0x2e, 0xab, 0xe0, 0x7a, 0xcb, 0x38, 0x8d, 0xa0, 0xf1, - 0x7f, 0x84, 0xdf, 0x7d, 0x0f, 0x34, 0xb8, 0x2a, 0x01, 0xcd, 0xd7, 0x7b, 0xf8, 0x0a, 0xc6, 0x70, - 0x01, 0xf6, 0x12, 0x77, 0x35, 0x18, 0x15, 0x6b, 0x17, 0x7e, 0x80, 0x36, 0xd5, 0x6b, 0xb4, 0x57, - 0xef, 0x4b, 0xb1, 0xeb, 0x3c, 0x1f, 0x3b, 0x2f, 0xcf, 0xdb, 0x1f, 0x70, 0xcb, 0x2f, 0xb4, 0xfe, - 0x9b, 0xfc, 0x6a, 0xb7, 0xbc, 0xda, 0x2a, 0x43, 0x9c, 0x6a, 0xbe, 0xfa, 0x75, 0xb8, 0x10, 0xeb, - 0x78, 0x21, 0xd6, 0xe9, 0x42, 0xac, 0x7f, 0x29, 0x41, 0x87, 0x94, 0xa0, 0x63, 0x4a, 0xd0, 0x29, - 0x25, 0xe8, 0x21, 0x25, 0xe8, 0xfe, 0x91, 0x58, 0x3f, 0x17, 0xb7, 0xfd, 0x8d, 0x4f, 0x01, 0x00, - 0x00, 0xff, 0xff, 0x88, 0x6b, 0xe8, 0xb6, 0xc6, 0x02, 0x00, 0x00, -} +func (m *UnrecoverableMessage) Reset() { *m = UnrecoverableMessage{} } func (m *Condition) Marshal() (dAtA []byte, err error) { size := m.Size() diff --git a/apis/condition/v1alpha1/generated.protomessage.pb.go b/apis/condition/v1alpha1/generated.protomessage.pb.go new file mode 100644 index 00000000..45017bc2 --- /dev/null +++ b/apis/condition/v1alpha1/generated.protomessage.pb.go @@ -0,0 +1,28 @@ +//go:build kubernetes_protomessage_one_more_release +// +build kubernetes_protomessage_one_more_release + +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +// Code generated by go-to-protobuf. DO NOT EDIT. + +package v1alpha1 + +func (*Condition) ProtoMessage() {} + +func (*ConditionedStatus) ProtoMessage() {} + +func (*UnrecoverableMessage) ProtoMessage() {} diff --git a/apis/config/condition.go b/apis/config/condition.go index abac2f12..a5faa21f 100644 --- a/apis/config/condition.go +++ b/apis/config/condition.go @@ -36,11 +36,12 @@ const ( // ConditionTypeTargetConnectionReady represents the resource target ready condition ConditionTypeTargetConnectionReady cond.ConditionType = "TargetConnectionReady" - ConditionTypeConfigApply cond.ConditionType = "ConfigApply" - ConditionTypeConfigConfirm cond.ConditionType = "ConfigConfirm" - ConditionTypeConfigCancel cond.ConditionType = "ConfigCancel" + //ConditionTypeConfigApply cond.ConditionType = "ConfigApply" + //ConditionTypeConfigConfirm cond.ConditionType = "ConfigConfirm" + //ConditionTypeConfigCancel cond.ConditionType = "ConfigCancel" + + //ConditionTypeSchemaServerReady cond.ConditionType = "SchemaServerReady" - ConditionTypeSchemaServerReady cond.ConditionType = "SchemaServerReady" ) // A ConditionReason represents the reason a resource is in a condition. diff --git a/apis/config/config_resource.go b/apis/config/config_resource.go index a2a345b6..70c949d3 100644 --- a/apis/config/config_resource.go +++ b/apis/config/config_resource.go @@ -267,12 +267,12 @@ func (r *ConfigFilter) Filter(ctx context.Context, obj runtime.Object) bool { return true } if r.Name != "" && o.GetName() != r.Name { - return true - } - if r.Namespace != "" && o.GetNamespace() != r.Namespace { - return true - } - return false + return true + } + if r.Namespace != "" && o.GetNamespace() != r.Namespace { + return true + } + return false } func (r *Config) PrepareForCreate(ctx context.Context, obj runtime.Object) { diff --git a/apis/config/configblame_resource.go b/apis/config/configblame_resource.go index 3af53f7d..bb2c1dee 100644 --- a/apis/config/configblame_resource.go +++ b/apis/config/configblame_resource.go @@ -206,12 +206,12 @@ func (r *ConfigBlameFilter) Filter(ctx context.Context, obj runtime.Object) bool return true } if r.Name != "" && o.GetName() != r.Name { - return true - } - if r.Namespace != "" && o.GetNamespace() != r.Namespace { - return true - } - return false + return true + } + if r.Namespace != "" && o.GetNamespace() != r.Namespace { + return true + } + return false } func (r *ConfigBlame) PrepareForCreate(ctx context.Context, obj runtime.Object) { diff --git a/apis/config/configset_resource.go b/apis/config/configset_resource.go index 65eb28cc..b6270aeb 100644 --- a/apis/config/configset_resource.go +++ b/apis/config/configset_resource.go @@ -259,12 +259,12 @@ func (r *ConfigSetFilter) Filter(ctx context.Context, obj runtime.Object) bool { return true } if r.Name != "" && o.GetName() != r.Name { - return true - } - if r.Namespace != "" && o.GetNamespace() != r.Namespace { - return true - } - return false + return true + } + if r.Namespace != "" && o.GetNamespace() != r.Namespace { + return true + } + return false } func (r *ConfigSet) PrepareForCreate(ctx context.Context, obj runtime.Object) { diff --git a/apis/config/configset_types.go b/apis/config/configset_types.go index 20ec0444..afb8edd7 100644 --- a/apis/config/configset_types.go +++ b/apis/config/configset_types.go @@ -26,7 +26,7 @@ import ( // ConfigSetSpec defines the desired state of Config type ConfigSetSpec struct { // Targets defines the targets on which this configSet applies - Target Target `json:"target" protobuf:"bytes,1,opt,name=target"` + Target ConfigSetTarget `json:"target" protobuf:"bytes,1,opt,name=target"` // Lifecycle determines the lifecycle policies the resource e.g. delete is orphan or delete // will follow Lifecycle *Lifecycle `json:"lifecycle,omitempty" protobuf:"bytes,2,opt,name=lifecycle"` @@ -39,7 +39,7 @@ type ConfigSetSpec struct { Config []ConfigBlob `json:"config" protobuf:"bytes,5,rep,name=config"` } -type Target struct { +type ConfigSetTarget struct { // TargetSelector defines the selector used to select the targets to which the config applies TargetSelector *metav1.LabelSelector `json:"targetSelector,omitempty" protobuf:"bytes,1,opt,name=targetSelector"` } @@ -50,10 +50,10 @@ type ConfigSetStatus struct { // if the condition is true the other attributes in the status are meaningful condition.ConditionedStatus `json:",inline" protobuf:"bytes,1,opt,name=conditionedStatus"` // Targets defines the status of the configSet resource on the respective target - Targets []TargetStatus `json:"targets,omitempty" protobuf:"bytes,2,rep,name=targets"` + Targets []ConfigSetTargetStatus `json:"targets,omitempty" protobuf:"bytes,2,rep,name=targets"` } -type TargetStatus struct { +type ConfigSetTargetStatus struct { Name string `json:"name" protobuf:"bytes,1,opt,name=name"` // right now we assume the namespace of the config and target are aligned //NameSpace string `json:"namespace" protobuf:"bytes,2,opt,name=name"` diff --git a/apis/config/deviation_resource.go b/apis/config/deviation_resource.go index ad52ab60..e8f16ac5 100644 --- a/apis/config/deviation_resource.go +++ b/apis/config/deviation_resource.go @@ -261,12 +261,12 @@ func (r *DeviationFilter) Filter(ctx context.Context, obj runtime.Object) bool { return true } if r.Name != "" && o.GetName() != r.Name { - return true - } - if r.Namespace != "" && o.GetNamespace() != r.Namespace { - return true - } - return false + return true + } + if r.Namespace != "" && o.GetNamespace() != r.Namespace { + return true + } + return false } func (r *Deviation) PrepareForCreate(ctx context.Context, obj runtime.Object) { diff --git a/apis/config/deviation_types.go b/apis/config/deviation_types.go index f71c9004..1bfd0339 100644 --- a/apis/config/deviation_types.go +++ b/apis/config/deviation_types.go @@ -53,9 +53,9 @@ type ConfigDeviation struct { Path string `json:"path,omitempty" protobuf:"bytes,1,opt,name=path"` // DesiredValue is the desired value of the config belonging to the path DesiredValue *string `json:"desiredValue,omitempty" protobuf:"bytes,2,opt,name=desiredValue"` - // CurrentValue defines the current value of the config belonging to the path + // ActualValue defines the current value of the config belonging to the path // that is currently configured on the target - CurrentValue *string `json:"actualValue,omitempty" protobuf:"bytes,3,opt,name=actualValue"` + ActualValue *string `json:"actualValue,omitempty" protobuf:"bytes,3,opt,name=actualValue"` // Reason defines the reason of the deviation Reason string `json:"reason,omitempty" protobuf:"bytes,4,opt,name=reason"` } diff --git a/apis/config/handlers/confighandler.go b/apis/config/handlers/confighandler.go index 55dbcd64..3ec7a693 100644 --- a/apis/config/handlers/confighandler.go +++ b/apis/config/handlers/confighandler.go @@ -6,7 +6,7 @@ import ( "github.com/henderiw/apiserver-store/pkg/storebackend" "github.com/sdcio/config-server/apis/config" - invv1alpha1 "github.com/sdcio/config-server/apis/inv/v1alpha1" + configv1alpha1 "github.com/sdcio/config-server/apis/config/v1alpha1" targetmanager "github.com/sdcio/config-server/pkg/sdc/target/manager" sdcpb "github.com/sdcio/sdc-protos/sdcpb" "k8s.io/apimachinery/pkg/api/meta" @@ -83,7 +83,7 @@ func (r *ConfigStoreHandler) prepareConfigAndTarget( ctx context.Context, key types.NamespacedName, obj runtime.Object, -) (*config.Config, *invv1alpha1.Target, error) { +) (*config.Config, *configv1alpha1.Target, error) { accessor, err := meta.Accessor(obj) if err != nil { return nil, nil, err @@ -98,7 +98,7 @@ func (r *ConfigStoreHandler) prepareConfigAndTarget( return nil, nil, fmt.Errorf("expected *config.Config, got %T", obj) } - target := &invv1alpha1.Target{} + target := &configv1alpha1.Target{} if err := r.Client.Get(ctx, key, target); err != nil { return nil, nil, err } diff --git a/apis/config/register.go b/apis/config/register.go index 927ae640..16fc8fcd 100644 --- a/apis/config/register.go +++ b/apis/config/register.go @@ -52,6 +52,8 @@ func addKnownTypes(scheme *runtime.Scheme) error { &DeviationList{}, &ConfigBlame{}, &ConfigBlameList{}, + &Target{}, + &TargetList{}, ) return nil } diff --git a/apis/config/running_config_resource.go b/apis/config/running_config_resource.go index d02f6a62..2390f57e 100644 --- a/apis/config/running_config_resource.go +++ b/apis/config/running_config_resource.go @@ -206,12 +206,12 @@ func (r *RunningConfigFilter) Filter(ctx context.Context, obj runtime.Object) bo return true } if r.Name != "" && o.GetName() != r.Name { - return true - } - if r.Namespace != "" && o.GetNamespace() != r.Namespace { - return true - } - return false + return true + } + if r.Namespace != "" && o.GetNamespace() != r.Namespace { + return true + } + return false } func (r *RunningConfig) PrepareForCreate(ctx context.Context, obj runtime.Object) { diff --git a/apis/config/sensitive_config_resource.go b/apis/config/sensitive_config_resource.go index e58eaff2..a85a3311 100644 --- a/apis/config/sensitive_config_resource.go +++ b/apis/config/sensitive_config_resource.go @@ -267,12 +267,12 @@ func (r *SensitiveConfigFilter) Filter(ctx context.Context, obj runtime.Object) return true } if r.Name != "" && o.GetName() != r.Name { - return true - } - if r.Namespace != "" && o.GetNamespace() != r.Namespace { - return true - } - return false + return true + } + if r.Namespace != "" && o.GetNamespace() != r.Namespace { + return true + } + return false } func (r *SensitiveConfig) PrepareForCreate(ctx context.Context, obj runtime.Object) { diff --git a/apis/config/target_helpers.go b/apis/config/target_helpers.go new file mode 100644 index 00000000..de1eb924 --- /dev/null +++ b/apis/config/target_helpers.go @@ -0,0 +1,72 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package config + +import ( + "github.com/sdcio/config-server/apis/condition" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" +) + +// GetCondition returns the condition based on the condition kind +func (r *Target) GetCondition(t condition.ConditionType) condition.Condition { + return r.Status.GetCondition(t) +} + +// SetConditions sets the conditions on the resource. it allows for 0, 1 or more conditions +// to be set at once +func (r *Target) SetConditions(c ...condition.Condition) { + r.Status.SetConditions(c...) +} + +func (r *Target) IsConditionReady() bool { + return r.GetCondition(condition.ConditionTypeReady).Status == metav1.ConditionTrue +} + +func (r *TargetStatus) GetDiscoveryInfo() DiscoveryInfo { + if r.DiscoveryInfo != nil { + return *r.DiscoveryInfo + } + return DiscoveryInfo{} +} + +// BuildTarget returns a reource from a client Object a Spec/Status +func BuildTarget(meta metav1.ObjectMeta, spec TargetSpec) *Target { + return &Target{ + TypeMeta: metav1.TypeMeta{ + APIVersion: SchemeGroupVersion.Identifier(), + Kind: ConfigKind, + }, + ObjectMeta: meta, + Spec: spec, + } +} + +func BuildEmptyTarget() *Target { + return &Target{ + TypeMeta: metav1.TypeMeta{ + APIVersion: SchemeGroupVersion.Identifier(), + Kind: TargetKind, + }, + } +} + +func (r *Target) IsReady() bool { + return r.GetCondition(condition.ConditionTypeReady).Status == metav1.ConditionTrue && + r.GetCondition(ConditionTypeDiscoveryReady).Status == metav1.ConditionTrue && + r.GetCondition(ConditionTypeDatastoreReady).Status == metav1.ConditionTrue && + r.GetCondition(ConditionTypeTargetConnectionReady).Status == metav1.ConditionTrue +} diff --git a/apis/config/target_resource.go b/apis/config/target_resource.go new file mode 100644 index 00000000..50ad3fee --- /dev/null +++ b/apis/config/target_resource.go @@ -0,0 +1,354 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package config + +import ( + "context" + "fmt" + "strings" + + "github.com/henderiw/apiserver-builder/pkg/builder/resource" + "github.com/henderiw/apiserver-store/pkg/generic/registry" + "github.com/sdcio/config-server/apis/condition" + apiequality "k8s.io/apimachinery/pkg/api/equality" + apierrors "k8s.io/apimachinery/pkg/api/errors" + "k8s.io/apimachinery/pkg/api/meta" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/fields" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime/schema" + "k8s.io/apimachinery/pkg/selection" + "k8s.io/apimachinery/pkg/util/validation/field" + genericapirequest "k8s.io/apiserver/pkg/endpoints/request" + "k8s.io/apiserver/pkg/registry/rest" +) + +const ( + TargetPlural = "targets" + TargetSingular = "target" +) + +var ( + TargetShortNames = []string{} + TargetCategories = []string{"sdc", "knet"} +) + +// +k8s:deepcopy-gen=false +var _ resource.InternalObject = &Target{} +var _ resource.ObjectList = &TargetList{} +var _ resource.ObjectWithStatusSubResource = &Target{} +var _ resource.StatusSubResource = &TargetStatus{} + +func (Target) GetGroupVersionResource() schema.GroupVersionResource { + return schema.GroupVersionResource{ + Group: SchemeGroupVersion.Group, + Version: SchemeGroupVersion.Version, + Resource: TargetPlural, + } +} + +// IsStorageVersion returns true -- Target is used as the internal version. +// IsStorageVersion implements resource.Object +func (Target) IsStorageVersion() bool { + return true +} + +// NamespaceScoped returns true to indicate Fortune is a namespaced resource. +// NamespaceScoped implements resource.Object +func (Target) NamespaceScoped() bool { + return true +} + +// GetObjectMeta implements resource.Object +// GetObjectMeta implements resource.Object +func (r *Target) GetObjectMeta() *metav1.ObjectMeta { + return &r.ObjectMeta +} + +// GetSingularName returns the singular name of the resource +// GetSingularName implements resource.Object +func (Target) GetSingularName() string { + return TargetSingular +} + +// GetShortNames returns the shortnames for the resource +// GetShortNames implements resource.Object +func (Target) GetShortNames() []string { + return TargetShortNames +} + +// GetCategories return the categories of the resource +// GetCategories implements resource.Object +func (Target) GetCategories() []string { + return TargetCategories +} + +// New return an empty resource +// New implements resource.Object +func (Target) New() runtime.Object { + return &Target{} +} + +// NewList return an empty resourceList +// NewList implements resource.Object +func (Target) NewList() runtime.Object { + return &TargetList{} +} + +// IsEqual returns a bool indicating if the desired state of both resources is equal or not +func (r *Target) IsEqual(ctx context.Context, obj, old runtime.Object) bool { + newobj := obj.(*Target) + oldobj := old.(*Target) + + if !apiequality.Semantic.DeepEqual(oldobj.ObjectMeta, newobj.ObjectMeta) { + return false + } + // if equal we also test the spec + return apiequality.Semantic.DeepEqual(oldobj.Spec, newobj.Spec) +} + +// GetStatus return the resource.StatusSubResource interface +func (r *Target) GetStatus() resource.StatusSubResource { + return r.Status +} + +// IsStatusEqual returns a bool indicating if the status of both resources is equal or not +func (r *Target) IsStatusEqual(ctx context.Context, obj, old runtime.Object) bool { + newobj := obj.(*Target) + oldobj := old.(*Target) + return apiequality.Semantic.DeepEqual(oldobj.Status, newobj.Status) +} + +// PrepareForStatusUpdate prepares the status update +func (r *Target) PrepareForStatusUpdate(ctx context.Context, obj, old runtime.Object) { + newObj := obj.(*Target) + oldObj := old.(*Target) + newObj.Spec = oldObj.Spec + + // Status updates are for only for updating status, not objectmeta. + metav1.ResetObjectMetaForStatus(&newObj.ObjectMeta, &newObj.ObjectMeta) +} + +// ValidateStatusUpdate validates status updates +func (r *Target) ValidateStatusUpdate(ctx context.Context, obj, old runtime.Object) field.ErrorList { + var allErrs field.ErrorList + return allErrs +} + +// SubResourceName resturns the name of the subresource +// SubResourceName implements the resource.StatusSubResource +func (TargetStatus) SubResourceName() string { + return fmt.Sprintf("%s/%s", TargetPlural, "status") +} + +// CopyTo copies the content of the status subresource to a parent resource. +// CopyTo implements the resource.StatusSubResource +func (r TargetStatus) CopyTo(obj resource.ObjectWithStatusSubResource) { + parent, ok := obj.(*Target) + if ok { + parent.Status = r + } +} + +// GetListMeta returns the ListMeta +// GetListMeta implements the resource.ObjectList +func (r *TargetList) GetListMeta() *metav1.ListMeta { + return &r.ListMeta +} + +// TableConvertor return the table format of the resource +func (r *Target) TableConvertor() func(gr schema.GroupResource) rest.TableConvertor { + return func(gr schema.GroupResource) rest.TableConvertor { + return registry.NewTableConverter( + gr, + func(obj runtime.Object) []interface{} { + target, ok := obj.(*Target) + if !ok { + return nil + } + d := target.Status.GetDiscoveryInfo() + return []interface{}{ + fmt.Sprintf("%s.%s/%s", strings.ToLower(TargetKind), GroupName, target.Name), + target.GetCondition(condition.ConditionTypeReady).Status, + target.GetCondition(condition.ConditionTypeReady).Message, + target.Spec.Provider, + d.Version, + target.Spec.Address, + d.Platform, + d.SerialNumber, + d.MacAddress, + } + }, + []metav1.TableColumnDefinition{ + {Name: "NAME", Type: "string"}, + {Name: "READY", Type: "string"}, + {Name: "REASON", Type: "string"}, + {Name: "PROVIDER", Type: "string"}, + {Name: "VERSION", Type: "string"}, + {Name: "ADDRESS", Type: "string"}, + {Name: "PLATFORM", Type: "string"}, + {Name: "SERIALNUMBER", Type: "string"}, + {Name: "MACADDRESS", Type: "string"}, + }, + ) + } +} + +// FieldLabelConversion is the schema conversion function for normalizing the FieldSelector for the resource +func (r *Target) FieldLabelConversion() runtime.FieldLabelConversionFunc { + return func(label, value string) (internalLabel, internalValue string, err error) { + switch label { + case "metadata.name": + return label, value, nil + case "metadata.namespace": + return label, value, nil + default: + return "", "", fmt.Errorf("%q is not a known field selector", label) + } + } +} + +func (r *Target) FieldSelector() func(ctx context.Context, fieldSelector fields.Selector) (resource.Filter, error) { + return func(ctx context.Context, fieldSelector fields.Selector) (resource.Filter, error) { + filter := &TargetFilter{} + + if fieldSelector != nil { + for _, requirement := range fieldSelector.Requirements() { + switch requirement.Operator { + case selection.Equals, selection.DoesNotExist: + if requirement.Value == "" { + return filter, apierrors.NewBadRequest(fmt.Sprintf("unsupported fieldSelector value %q for field %q with operator %q", requirement.Value, requirement.Field, requirement.Operator)) + } + default: + return filter, apierrors.NewBadRequest(fmt.Sprintf("unsupported fieldSelector operator %q for field %q", requirement.Operator, requirement.Field)) + } + + switch requirement.Field { + case "metadata.name": + filter.Name = requirement.Value + case "metadata.namespace": + filter.Namespace = requirement.Value + default: + return filter, apierrors.NewBadRequest(fmt.Sprintf("unknown fieldSelector field %q", requirement.Field)) + } + } + } + // add namespace to the filter selector if specified + namespace, ok := genericapirequest.NamespaceFrom(ctx) + if ok { + if filter.Namespace == "" { + filter.Namespace = namespace + } + } + + return filter, nil + } + +} + +type TargetFilter struct { + // Name filters by the name of the objects + Name string `protobuf:"bytes,1,opt,name=name"` + + // Namespace filters by the namespace of the objects + Namespace string `protobuf:"bytes,2,opt,name=namespace"` +} + +func (r *TargetFilter) Filter(ctx context.Context, obj runtime.Object) bool { + o, ok := obj.(*Target) + if !ok { + return true + } + if r.Name != "" && o.GetName() != r.Name { + return true + } + if r.Namespace != "" && o.GetNamespace() != r.Namespace { + return true + } + return false +} + +func (r *Target) PrepareForCreate(ctx context.Context, obj runtime.Object) { + // status cannot be set upon create -> reset it + newobj := obj.(*Target) + newobj.Status = TargetStatus{} +} + +// ValidateCreate statically validates +func (r *Target) ValidateCreate(ctx context.Context, obj runtime.Object) field.ErrorList { + var allErrs field.ErrorList + + return allErrs +} + +func (r *Target) PrepareForUpdate(ctx context.Context, obj, old runtime.Object) { + // ensure the sttaus dont get updated + newobj := obj.(*Target) + oldObj := old.(*Target) + newobj.Status = oldObj.Status +} + +func (r *Target) ValidateUpdate(ctx context.Context, obj, old runtime.Object) field.ErrorList { + var allErrs field.ErrorList + + newaccessor, err := meta.Accessor(obj) + if err != nil { + allErrs = append(allErrs, field.Invalid( + field.NewPath(""), + obj, + err.Error(), + )) + return allErrs + } + newKey, err := GetTargetKey(newaccessor.GetLabels()) + if err != nil { + allErrs = append(allErrs, field.Invalid( + field.NewPath("metadata.labels"), + obj, + err.Error(), + )) + } + oldaccessor, err := meta.Accessor(old) + if err != nil { + allErrs = append(allErrs, field.Invalid( + field.NewPath(""), + obj, + err.Error(), + )) + return allErrs + } + oldKey, err := GetTargetKey(oldaccessor.GetLabels()) + if err != nil { + allErrs = append(allErrs, field.Invalid( + field.NewPath("metadata.labels"), + obj, + err.Error(), + )) + } + + if len(allErrs) != 0 { + return allErrs + } + if oldKey.String() != newKey.String() { + allErrs = append(allErrs, field.Invalid( + field.NewPath("metadata.labels"), + obj, + fmt.Errorf("target keys are immutable: oldKey: %s, newKey %s", oldKey.String(), newKey.String()).Error(), + )) + } + return allErrs +} diff --git a/apis/config/target_types.go b/apis/config/target_types.go new file mode 100644 index 00000000..b5bda59d --- /dev/null +++ b/apis/config/target_types.go @@ -0,0 +1,108 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package config + +import ( + "reflect" + + "github.com/sdcio/config-server/apis/condition" + invv1alpha1 "github.com/sdcio/config-server/apis/inv/v1alpha1" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/runtime/schema" +) + +// TargetSpec defines the desired state of Target +type TargetSpec struct { + // Provider specifies the provider using this target. + Provider string `json:"provider" protobuf:"bytes,1,opt,name=provider"` + // Address defines the address to connect to the target + Address string `json:"address" protobuf:"bytes,2,opt,name=address"` + // TargetProfile defines the Credentials/TLSSecret and sync/connectivity profile to connect to the target + invv1alpha1.TargetProfile `json:",inline" protobuf:"bytes,3,opt,name=targetProfile"` +} + +// TargetStatus defines the observed state of Target +type TargetStatus struct { + // ConditionedStatus provides the status of the Target using conditions + condition.ConditionedStatus `json:",inline" protobuf:"bytes,1,opt,name=conditionedStatus"` + // Discovery info defines the information retrieved during discovery + DiscoveryInfo *DiscoveryInfo `json:"discoveryInfo,omitempty" protobuf:"bytes,2,opt,name=discoveryInfo"` + // UsedReferences track the resource used to reconcile the cr + UsedReferences *TargetStatusUsedReferences `json:"usedReferences,omitempty" protobuf:"bytes,3,opt,name=usedReferences"` +} + +type DiscoveryInfo struct { + // Protocol used for discovery + Protocol string `json:"protocol,omitempty" protobuf:"bytes,1,opt,name=protocol"` + // Type associated with the target + Provider string `json:"provider,omitempty" protobuf:"bytes,2,opt,name=provider"` + // Version associated with the target + Version string `json:"version,omitempty" protobuf:"bytes,3,opt,name=version"` + // Hostname associated with the target + Hostname string `json:"hostname,omitempty" protobuf:"bytes,4,opt,name=hostname"` + // Platform associated with the target + Platform string `json:"platform,omitempty" protobuf:"bytes,5,opt,name=platform"` + // MacAddress associated with the target + MacAddress string `json:"macAddress,omitempty" protobuf:"bytes,6,opt,name=macAddress"` + // SerialNumber associated with the target + SerialNumber string `json:"serialNumber,omitempty" protobuf:"bytes,7,opt,name=serialNumber"` + // Supported Encodings of the target + // +listType=atomic + SupportedEncodings []string `json:"supportedEncodings,omitempty" protobuf:"bytes,8,rep,name=supportedEncodings"` + // Last discovery time + //LastSeen metav1.Time `json:"lastSeen,omitempty"` +} + +type TargetStatusUsedReferences struct { + SecretResourceVersion string `json:"secretResourceVersion,omitempty" yaml:"secretResourceVersion,omitempty" protobuf:"bytes,1,opt,name=secretResourceVersion"` + TLSSecretResourceVersion string `json:"tlsSecretResourceVersion,omitempty" yaml:"tlsSecretResourceVersion,omitempty" protobuf:"bytes,2,opt,name=tlsSecretResourceVersion"` + ConnectionProfileResourceVersion string `json:"connectionProfileResourceVersion" yaml:"connectionProfileResourceVersion" protobuf:"bytes,3,opt,name=connectionProfileResourceVersion"` + SyncProfileResourceVersion string `json:"syncProfileResourceVersion" yaml:"syncProfileResourceVersion" protobuf:"bytes,4,opt,name=syncProfileResourceVersion"` +} + +// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object +// +kubebuilder:object:root=true +// +kubebuilder:storageversion +// +kubebuilder:subresource:status +// +kubebuilder:resource:categories={sdc} + +// Target is the Schema for the Target API +// +k8s:openapi-gen=true +type Target struct { + metav1.TypeMeta `json:",inline" yaml:",inline"` + metav1.ObjectMeta `json:"metadata,omitempty" yaml:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + + Spec TargetSpec `json:"spec,omitempty" yaml:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"` + Status TargetStatus `json:"status,omitempty" yaml:"status,omitempty" protobuf:"bytes,3,opt,name=status"` +} + +// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object +// +kubebuilder:object:root=true + +// TargetList contains a list of Targets +type TargetList struct { + metav1.TypeMeta `json:",inline" yaml:",inline"` + metav1.ListMeta `json:"metadata,omitempty" yaml:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + Items []Target `json:"items" yaml:"items" protobuf:"bytes,2,rep,name=items"` +} + +var ( + TargetKind = reflect.TypeOf(Target{}).Name() + TargetGroupKind = schema.GroupKind{Group: SchemeGroupVersion.Group, Kind: TargetKind}.String() + TargetKindAPIVersion = TargetKind + "." + SchemeGroupVersion.String() + TargetGroupVersionKind = SchemeGroupVersion.WithKind(TargetKind) +) diff --git a/apis/config/v1alpha1/condition.go b/apis/config/v1alpha1/condition.go index 54579088..03d69411 100644 --- a/apis/config/v1alpha1/condition.go +++ b/apis/config/v1alpha1/condition.go @@ -23,8 +23,19 @@ import ( // Condition Types. const ( - ConditionTypeConfigReady condv1alpha1.ConditionType = "ConfigReady" - ConditionTypeTargetReady condv1alpha1.ConditionType = "TargetReady" + // Config related conditions + ConditionTypeConfigReady condv1alpha1.ConditionType = "ConfigReady" + ConditionTypeTargetForConfigReady condv1alpha1.ConditionType = "TargetForConfigReady" + + // Target relation conditions + // ConditionTypeDiscoveryReady represents the resource discovery ready condition + ConditionTypeTargetDiscoveryReady condv1alpha1.ConditionType = "TargetDiscoveryReady" + // ConditionTypeDatastoreReady represents the resource datastore ready condition + ConditionTypeTargetDatastoreReady condv1alpha1.ConditionType = "TargetDatastoreReady" + // ConditionTypeConfigRecoveryReady represents the resource config recovery ready condition + ConditionTypeTargetConfigRecoveryReady condv1alpha1.ConditionType = "TargetConfigRecoveryReady" + // ConditionTypeTargetConnectionReady represents the resource target ready condition + ConditionTypeTargetConnectionReady condv1alpha1.ConditionType = "TargetConnectionReady" ) // Reasons a resource is ready or not @@ -33,8 +44,8 @@ const ( ConditionReasonCreating condv1alpha1.ConditionReason = "creating" ConditionReasonUpdating condv1alpha1.ConditionReason = "updating" //ConditionReasonTargetDeleted condv1alpha1.ConditionReason = "target Deleted" - ConditionReasonTargetNotReady condv1alpha1.ConditionReason = "target not ready" - ConditionReasonTargetNotFound condv1alpha1.ConditionReason = "target not found" + //ConditionReasonTargetNotReady condv1alpha1.ConditionReason = "target not ready" + //ConditionReasonTargetNotFound condv1alpha1.ConditionReason = "target not found" ) // Creating returns a condition that indicates a create transaction @@ -85,11 +96,11 @@ func ConfigFailed(msg string) condv1alpha1.Condition { }} } -// TargetReady return a condition that indicates +// TargetForConfigReady return a condition that indicates // the target became ready -func TargetReady(msg string) condv1alpha1.Condition { +func TargetForConfigReady(msg string) condv1alpha1.Condition { return condv1alpha1.Condition{Condition: metav1.Condition{ - Type: string(ConditionTypeTargetReady), + Type: string(ConditionTypeTargetForConfigReady), Status: metav1.ConditionTrue, LastTransitionTime: metav1.Now(), Reason: string(condv1alpha1.ConditionReasonReady), @@ -99,9 +110,127 @@ func TargetReady(msg string) condv1alpha1.Condition { // ConfigFailed returns a condition that indicates the config // is in failed condition due to a dependency -func TargetFailed(msg string) condv1alpha1.Condition { +func TargetForConfigFailed(msg string) condv1alpha1.Condition { + return condv1alpha1.Condition{Condition: metav1.Condition{ + Type: string(ConditionTypeTargetForConfigReady), + Status: metav1.ConditionFalse, + LastTransitionTime: metav1.Now(), + Reason: string(condv1alpha1.ConditionReasonFailed), + Message: msg, + }} +} + +// Target related conditions + +// TargetDatastoreReady indicates the datastire is ready +func TargetDatastoreReady() condv1alpha1.Condition { + return condv1alpha1.Condition{Condition: metav1.Condition{ + Type: string(ConditionTypeTargetDatastoreReady), + Status: metav1.ConditionTrue, + LastTransitionTime: metav1.Now(), + Reason: string(condv1alpha1.ConditionReasonReady), + }} +} + +// DatastoreFailed returns a condition that indicates the datastore +// failed to get reconciled. +func TargetDatastoreFailed(msg string) condv1alpha1.Condition { + return condv1alpha1.Condition{Condition: metav1.Condition{ + Type: string(ConditionTypeTargetDatastoreReady), + Status: metav1.ConditionFalse, + LastTransitionTime: metav1.Now(), + Reason: string(condv1alpha1.ConditionReasonFailed), + Message: msg, + }} +} + +// TargetDatastoreSchemaNotReady returns a condition that indicates the schema +// of the datastore is not ready. +func TargetDatastoreSchemaNotReady(msg string) condv1alpha1.Condition { + return condv1alpha1.Condition{Condition: metav1.Condition{ + Type: string(ConditionTypeTargetDatastoreReady), + Status: metav1.ConditionFalse, + LastTransitionTime: metav1.Now(), + Reason: string("schema not ready"), + Message: msg, + }} +} + +// TargetConfigRecoveryReady return a condition that indicates the config +// get re-applied when the target became ready +func TargetConfigRecoveryReady(msg string) condv1alpha1.Condition { + return condv1alpha1.Condition{Condition: metav1.Condition{ + Type: string(ConditionTypeTargetConfigRecoveryReady), + Status: metav1.ConditionTrue, + LastTransitionTime: metav1.Now(), + Reason: string(condv1alpha1.ConditionReasonReady), + Message: msg, + }} +} + +// TargetConfigRecoveryFailed returns a condition that indicates the config +// is in failed condition due to a dependency +func TargetConfigRecoveryFailed(msg string) condv1alpha1.Condition { + return condv1alpha1.Condition{Condition: metav1.Condition{ + Type: string(ConditionTypeTargetConfigRecoveryReady), + Status: metav1.ConditionFalse, + LastTransitionTime: metav1.Now(), + Reason: string(condv1alpha1.ConditionReasonFailed), + Message: msg, + }} +} + +// TargetConfigRecoveryReApplyFailed returns a condition that indicates the config +// we we reapplied to the target +func TargetConfigRecoveryReApplyFailed(msg string) condv1alpha1.Condition { + return condv1alpha1.Condition{Condition: metav1.Condition{ + Type: string(ConditionTypeTargetConfigRecoveryReady), + Status: metav1.ConditionFalse, + LastTransitionTime: metav1.Now(), + Reason: string("recovery config transaction failed"), + Message: msg, + }} +} + +// TargetDiscoveryReady return a condition that indicates the discovery +// is ready +func TargetDiscoveryReady() condv1alpha1.Condition { + return condv1alpha1.Condition{Condition: metav1.Condition{ + Type: string(ConditionTypeTargetDiscoveryReady), + Status: metav1.ConditionTrue, + LastTransitionTime: metav1.Now(), + Reason: string(condv1alpha1.ConditionReasonReady), + }} +} + +// TargetDiscoveryFailed returns a condition that indicates the discovery +// is in failed condition +func TargetDiscoveryFailed(msg string) condv1alpha1.Condition { + return condv1alpha1.Condition{Condition: metav1.Condition{ + Type: string(ConditionTypeTargetDiscoveryReady), + Status: metav1.ConditionFalse, + LastTransitionTime: metav1.Now(), + Reason: string(condv1alpha1.ConditionReasonFailed), + Message: msg, + }} +} + +// TargetConnectionReady return a condition that indicates the target connection +// is ready +func TargetConnectionReady() condv1alpha1.Condition { + return condv1alpha1.Condition{Condition: metav1.Condition{ + Type: string(ConditionTypeTargetConnectionReady), + Status: metav1.ConditionTrue, + LastTransitionTime: metav1.Now(), + Reason: string(condv1alpha1.ConditionReasonReady), + }} +} + +// TargetConnectionFailed returns a condition that indicates the target connection +// is in failed condition +func TargetConnectionFailed(msg string) condv1alpha1.Condition { return condv1alpha1.Condition{Condition: metav1.Condition{ - Type: string(ConditionTypeTargetReady), + Type: string(ConditionTypeTargetConnectionReady), Status: metav1.ConditionFalse, LastTransitionTime: metav1.Now(), Reason: string(condv1alpha1.ConditionReasonFailed), diff --git a/apis/config/v1alpha1/config_helpers.go b/apis/config/v1alpha1/config_helpers.go index 292d3577..c8cd2d98 100644 --- a/apis/config/v1alpha1/config_helpers.go +++ b/apis/config/v1alpha1/config_helpers.go @@ -275,7 +275,7 @@ func (r *Config) DeepObjectCopy() client.Object { func (r *Config) SetOverallStatus() { cfgC := r.GetCondition(ConditionTypeConfigReady) - tgtC := r.GetCondition(ConditionTypeTargetReady) + tgtC := r.GetCondition(ConditionTypeTargetForConfigReady) ready := cfgC.IsTrue() && tgtC.IsTrue() @@ -309,7 +309,7 @@ func (r *Config) SetOverallStatus() { func GetOverallCondition(r *Config) condv1alpha1.Condition { cfgC := r.GetCondition(ConditionTypeConfigReady) - tgtC := r.GetCondition(ConditionTypeTargetReady) + tgtC := r.GetCondition(ConditionTypeTargetForConfigReady) ready := cfgC.IsTrue() && tgtC.IsTrue() diff --git a/apis/config/v1alpha1/configset_types.go b/apis/config/v1alpha1/configset_types.go index 836a7020..d3c3f409 100644 --- a/apis/config/v1alpha1/configset_types.go +++ b/apis/config/v1alpha1/configset_types.go @@ -26,7 +26,7 @@ import ( // ConfigSetSpec defines the desired state of Config type ConfigSetSpec struct { // Targets defines the targets on which this configSet applies - Target Target `json:"target" protobuf:"bytes,1,opt,name=target"` + Target ConfigSetTarget `json:"target" protobuf:"bytes,1,opt,name=target"` // Lifecycle determines the lifecycle policies the resource e.g. delete is orphan or delete // will follow Lifecycle *Lifecycle `json:"lifecycle,omitempty" protobuf:"bytes,2,opt,name=lifecycle"` @@ -40,7 +40,7 @@ type ConfigSetSpec struct { Config []ConfigBlob `json:"config" protobuf:"bytes,5,rep,name=config"` } -type Target struct { +type ConfigSetTarget struct { // TargetSelector defines the selector used to select the targets to which the config applies TargetSelector *metav1.LabelSelector `json:"targetSelector,omitempty" protobuf:"bytes,1,opt,name=targetSelector"` } @@ -52,10 +52,10 @@ type ConfigSetStatus struct { condv1alpha1.ConditionedStatus `json:",inline" protobuf:"bytes,1,opt,name=conditionedStatus"` // Targets defines the status of the configSet resource on the respective target // +listType=atomic - Targets []TargetStatus `json:"targets,omitempty" protobuf:"bytes,2,rep,name=targets"` + Targets []ConfigSetTargetStatus `json:"targets,omitempty" protobuf:"bytes,2,rep,name=targets"` } -type TargetStatus struct { +type ConfigSetTargetStatus struct { Name string `json:"name" protobuf:"bytes,1,opt,name=name"` // right now we assume the namespace of the config and target are aligned //NameSpace string `json:"namespace" protobuf:"bytes,2,opt,name=name"` diff --git a/apis/config/v1alpha1/generated.pb.go b/apis/config/v1alpha1/generated.pb.go index 347ec2ce..4aee6b04 100644 --- a/apis/config/v1alpha1/generated.pb.go +++ b/apis/config/v1alpha1/generated.pb.go @@ -23,888 +23,86 @@ import ( io "io" - proto "github.com/gogo/protobuf/proto" v1 "k8s.io/apimachinery/pkg/apis/meta/v1" - math "math" math_bits "math/bits" reflect "reflect" strings "strings" ) -// Reference imports to suppress errors if they are not otherwise used. -var _ = proto.Marshal -var _ = fmt.Errorf -var _ = math.Inf - -// This is a compile-time assertion to ensure that this generated file -// is compatible with the proto package it is being compiled against. -// A compilation error at this line likely means your copy of the -// proto package needs to be updated. -const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package -func (m *Config) Reset() { *m = Config{} } -func (*Config) ProtoMessage() {} -func (*Config) Descriptor() ([]byte, []int) { - return fileDescriptor_609f4c56ac31047c, []int{2} -} -func (m *Config) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *Config) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err - } - return b[:n], nil -} -func (m *Config) XXX_Merge(src proto.Message) { - xxx_messageInfo_Config.Merge(m, src) -} -func (m *Config) XXX_Size() int { - return m.Size() -} -func (m *Config) XXX_DiscardUnknown() { - xxx_messageInfo_Config.DiscardUnknown(m) -} - -var xxx_messageInfo_Config proto.InternalMessageInfo - -func (m *ConfigBlame) Reset() { *m = ConfigBlame{} } -func (*ConfigBlame) ProtoMessage() {} -func (*ConfigBlame) Descriptor() ([]byte, []int) { - return fileDescriptor_609f4c56ac31047c, []int{3} -} -func (m *ConfigBlame) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *ConfigBlame) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err - } - return b[:n], nil -} -func (m *ConfigBlame) XXX_Merge(src proto.Message) { - xxx_messageInfo_ConfigBlame.Merge(m, src) -} -func (m *ConfigBlame) XXX_Size() int { - return m.Size() -} -func (m *ConfigBlame) XXX_DiscardUnknown() { - xxx_messageInfo_ConfigBlame.DiscardUnknown(m) -} - -var xxx_messageInfo_ConfigBlame proto.InternalMessageInfo - -func (m *ConfigBlameList) Reset() { *m = ConfigBlameList{} } -func (*ConfigBlameList) ProtoMessage() {} -func (*ConfigBlameList) Descriptor() ([]byte, []int) { - return fileDescriptor_609f4c56ac31047c, []int{4} -} -func (m *ConfigBlameList) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *ConfigBlameList) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err - } - return b[:n], nil -} -func (m *ConfigBlameList) XXX_Merge(src proto.Message) { - xxx_messageInfo_ConfigBlameList.Merge(m, src) -} -func (m *ConfigBlameList) XXX_Size() int { - return m.Size() -} -func (m *ConfigBlameList) XXX_DiscardUnknown() { - xxx_messageInfo_ConfigBlameList.DiscardUnknown(m) -} - -var xxx_messageInfo_ConfigBlameList proto.InternalMessageInfo - -func (m *ConfigBlameSpec) Reset() { *m = ConfigBlameSpec{} } -func (*ConfigBlameSpec) ProtoMessage() {} -func (*ConfigBlameSpec) Descriptor() ([]byte, []int) { - return fileDescriptor_609f4c56ac31047c, []int{5} -} -func (m *ConfigBlameSpec) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *ConfigBlameSpec) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err - } - return b[:n], nil -} -func (m *ConfigBlameSpec) XXX_Merge(src proto.Message) { - xxx_messageInfo_ConfigBlameSpec.Merge(m, src) -} -func (m *ConfigBlameSpec) XXX_Size() int { - return m.Size() -} -func (m *ConfigBlameSpec) XXX_DiscardUnknown() { - xxx_messageInfo_ConfigBlameSpec.DiscardUnknown(m) -} - -var xxx_messageInfo_ConfigBlameSpec proto.InternalMessageInfo - -func (m *ConfigBlameStatus) Reset() { *m = ConfigBlameStatus{} } -func (*ConfigBlameStatus) ProtoMessage() {} -func (*ConfigBlameStatus) Descriptor() ([]byte, []int) { - return fileDescriptor_609f4c56ac31047c, []int{6} -} -func (m *ConfigBlameStatus) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *ConfigBlameStatus) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err - } - return b[:n], nil -} -func (m *ConfigBlameStatus) XXX_Merge(src proto.Message) { - xxx_messageInfo_ConfigBlameStatus.Merge(m, src) -} -func (m *ConfigBlameStatus) XXX_Size() int { - return m.Size() -} -func (m *ConfigBlameStatus) XXX_DiscardUnknown() { - xxx_messageInfo_ConfigBlameStatus.DiscardUnknown(m) -} - -var xxx_messageInfo_ConfigBlameStatus proto.InternalMessageInfo - -func (m *ConfigBlob) Reset() { *m = ConfigBlob{} } -func (*ConfigBlob) ProtoMessage() {} -func (*ConfigBlob) Descriptor() ([]byte, []int) { - return fileDescriptor_609f4c56ac31047c, []int{7} -} -func (m *ConfigBlob) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *ConfigBlob) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err - } - return b[:n], nil -} -func (m *ConfigBlob) XXX_Merge(src proto.Message) { - xxx_messageInfo_ConfigBlob.Merge(m, src) -} -func (m *ConfigBlob) XXX_Size() int { - return m.Size() -} -func (m *ConfigBlob) XXX_DiscardUnknown() { - xxx_messageInfo_ConfigBlob.DiscardUnknown(m) -} - -var xxx_messageInfo_ConfigBlob proto.InternalMessageInfo - -func (m *ConfigDeviation) Reset() { *m = ConfigDeviation{} } -func (*ConfigDeviation) ProtoMessage() {} -func (*ConfigDeviation) Descriptor() ([]byte, []int) { - return fileDescriptor_609f4c56ac31047c, []int{8} -} -func (m *ConfigDeviation) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *ConfigDeviation) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err - } - return b[:n], nil -} -func (m *ConfigDeviation) XXX_Merge(src proto.Message) { - xxx_messageInfo_ConfigDeviation.Merge(m, src) -} -func (m *ConfigDeviation) XXX_Size() int { - return m.Size() -} -func (m *ConfigDeviation) XXX_DiscardUnknown() { - xxx_messageInfo_ConfigDeviation.DiscardUnknown(m) -} - -var xxx_messageInfo_ConfigDeviation proto.InternalMessageInfo - -func (m *ConfigList) Reset() { *m = ConfigList{} } -func (*ConfigList) ProtoMessage() {} -func (*ConfigList) Descriptor() ([]byte, []int) { - return fileDescriptor_609f4c56ac31047c, []int{9} -} -func (m *ConfigList) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *ConfigList) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err - } - return b[:n], nil -} -func (m *ConfigList) XXX_Merge(src proto.Message) { - xxx_messageInfo_ConfigList.Merge(m, src) -} -func (m *ConfigList) XXX_Size() int { - return m.Size() -} -func (m *ConfigList) XXX_DiscardUnknown() { - xxx_messageInfo_ConfigList.DiscardUnknown(m) -} +func (m *Config) Reset() { *m = Config{} } -var xxx_messageInfo_ConfigList proto.InternalMessageInfo +func (m *ConfigBlame) Reset() { *m = ConfigBlame{} } -func (m *ConfigSet) Reset() { *m = ConfigSet{} } -func (*ConfigSet) ProtoMessage() {} -func (*ConfigSet) Descriptor() ([]byte, []int) { - return fileDescriptor_609f4c56ac31047c, []int{10} -} -func (m *ConfigSet) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *ConfigSet) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err - } - return b[:n], nil -} -func (m *ConfigSet) XXX_Merge(src proto.Message) { - xxx_messageInfo_ConfigSet.Merge(m, src) -} -func (m *ConfigSet) XXX_Size() int { - return m.Size() -} -func (m *ConfigSet) XXX_DiscardUnknown() { - xxx_messageInfo_ConfigSet.DiscardUnknown(m) -} +func (m *ConfigBlameList) Reset() { *m = ConfigBlameList{} } -var xxx_messageInfo_ConfigSet proto.InternalMessageInfo +func (m *ConfigBlameSpec) Reset() { *m = ConfigBlameSpec{} } -func (m *ConfigSetList) Reset() { *m = ConfigSetList{} } -func (*ConfigSetList) ProtoMessage() {} -func (*ConfigSetList) Descriptor() ([]byte, []int) { - return fileDescriptor_609f4c56ac31047c, []int{11} -} -func (m *ConfigSetList) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *ConfigSetList) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err - } - return b[:n], nil -} -func (m *ConfigSetList) XXX_Merge(src proto.Message) { - xxx_messageInfo_ConfigSetList.Merge(m, src) -} -func (m *ConfigSetList) XXX_Size() int { - return m.Size() -} -func (m *ConfigSetList) XXX_DiscardUnknown() { - xxx_messageInfo_ConfigSetList.DiscardUnknown(m) -} +func (m *ConfigBlameStatus) Reset() { *m = ConfigBlameStatus{} } -var xxx_messageInfo_ConfigSetList proto.InternalMessageInfo +func (m *ConfigBlob) Reset() { *m = ConfigBlob{} } -func (m *ConfigSetSpec) Reset() { *m = ConfigSetSpec{} } -func (*ConfigSetSpec) ProtoMessage() {} -func (*ConfigSetSpec) Descriptor() ([]byte, []int) { - return fileDescriptor_609f4c56ac31047c, []int{12} -} -func (m *ConfigSetSpec) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *ConfigSetSpec) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err - } - return b[:n], nil -} -func (m *ConfigSetSpec) XXX_Merge(src proto.Message) { - xxx_messageInfo_ConfigSetSpec.Merge(m, src) -} -func (m *ConfigSetSpec) XXX_Size() int { - return m.Size() -} -func (m *ConfigSetSpec) XXX_DiscardUnknown() { - xxx_messageInfo_ConfigSetSpec.DiscardUnknown(m) -} +func (m *ConfigDeviation) Reset() { *m = ConfigDeviation{} } -var xxx_messageInfo_ConfigSetSpec proto.InternalMessageInfo +func (m *ConfigList) Reset() { *m = ConfigList{} } -func (m *ConfigSetStatus) Reset() { *m = ConfigSetStatus{} } -func (*ConfigSetStatus) ProtoMessage() {} -func (*ConfigSetStatus) Descriptor() ([]byte, []int) { - return fileDescriptor_609f4c56ac31047c, []int{13} -} -func (m *ConfigSetStatus) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *ConfigSetStatus) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err - } - return b[:n], nil -} -func (m *ConfigSetStatus) XXX_Merge(src proto.Message) { - xxx_messageInfo_ConfigSetStatus.Merge(m, src) -} -func (m *ConfigSetStatus) XXX_Size() int { - return m.Size() -} -func (m *ConfigSetStatus) XXX_DiscardUnknown() { - xxx_messageInfo_ConfigSetStatus.DiscardUnknown(m) -} +func (m *ConfigSet) Reset() { *m = ConfigSet{} } -var xxx_messageInfo_ConfigSetStatus proto.InternalMessageInfo +func (m *ConfigSetList) Reset() { *m = ConfigSetList{} } -func (m *ConfigSpec) Reset() { *m = ConfigSpec{} } -func (*ConfigSpec) ProtoMessage() {} -func (*ConfigSpec) Descriptor() ([]byte, []int) { - return fileDescriptor_609f4c56ac31047c, []int{14} -} -func (m *ConfigSpec) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *ConfigSpec) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err - } - return b[:n], nil -} -func (m *ConfigSpec) XXX_Merge(src proto.Message) { - xxx_messageInfo_ConfigSpec.Merge(m, src) -} -func (m *ConfigSpec) XXX_Size() int { - return m.Size() -} -func (m *ConfigSpec) XXX_DiscardUnknown() { - xxx_messageInfo_ConfigSpec.DiscardUnknown(m) -} +func (m *ConfigSetSpec) Reset() { *m = ConfigSetSpec{} } -var xxx_messageInfo_ConfigSpec proto.InternalMessageInfo +func (m *ConfigSetStatus) Reset() { *m = ConfigSetStatus{} } -func (m *ConfigStatus) Reset() { *m = ConfigStatus{} } -func (*ConfigStatus) ProtoMessage() {} -func (*ConfigStatus) Descriptor() ([]byte, []int) { - return fileDescriptor_609f4c56ac31047c, []int{15} -} -func (m *ConfigStatus) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *ConfigStatus) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err - } - return b[:n], nil -} -func (m *ConfigStatus) XXX_Merge(src proto.Message) { - xxx_messageInfo_ConfigStatus.Merge(m, src) -} -func (m *ConfigStatus) XXX_Size() int { - return m.Size() -} -func (m *ConfigStatus) XXX_DiscardUnknown() { - xxx_messageInfo_ConfigStatus.DiscardUnknown(m) -} +func (m *ConfigSetTarget) Reset() { *m = ConfigSetTarget{} } -var xxx_messageInfo_ConfigStatus proto.InternalMessageInfo +func (m *ConfigSetTargetStatus) Reset() { *m = ConfigSetTargetStatus{} } -func (m *ConfigStatusLastKnownGoodSchema) Reset() { *m = ConfigStatusLastKnownGoodSchema{} } -func (*ConfigStatusLastKnownGoodSchema) ProtoMessage() {} -func (*ConfigStatusLastKnownGoodSchema) Descriptor() ([]byte, []int) { - return fileDescriptor_609f4c56ac31047c, []int{16} -} -func (m *ConfigStatusLastKnownGoodSchema) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *ConfigStatusLastKnownGoodSchema) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err - } - return b[:n], nil -} -func (m *ConfigStatusLastKnownGoodSchema) XXX_Merge(src proto.Message) { - xxx_messageInfo_ConfigStatusLastKnownGoodSchema.Merge(m, src) -} -func (m *ConfigStatusLastKnownGoodSchema) XXX_Size() int { - return m.Size() -} -func (m *ConfigStatusLastKnownGoodSchema) XXX_DiscardUnknown() { - xxx_messageInfo_ConfigStatusLastKnownGoodSchema.DiscardUnknown(m) -} +func (m *ConfigSpec) Reset() { *m = ConfigSpec{} } -var xxx_messageInfo_ConfigStatusLastKnownGoodSchema proto.InternalMessageInfo +func (m *ConfigStatus) Reset() { *m = ConfigStatus{} } -func (m *Deviation) Reset() { *m = Deviation{} } -func (*Deviation) ProtoMessage() {} -func (*Deviation) Descriptor() ([]byte, []int) { - return fileDescriptor_609f4c56ac31047c, []int{17} -} -func (m *Deviation) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *Deviation) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err - } - return b[:n], nil -} -func (m *Deviation) XXX_Merge(src proto.Message) { - xxx_messageInfo_Deviation.Merge(m, src) -} -func (m *Deviation) XXX_Size() int { - return m.Size() -} -func (m *Deviation) XXX_DiscardUnknown() { - xxx_messageInfo_Deviation.DiscardUnknown(m) -} +func (m *ConfigStatusLastKnownGoodSchema) Reset() { *m = ConfigStatusLastKnownGoodSchema{} } -var xxx_messageInfo_Deviation proto.InternalMessageInfo +func (m *Deviation) Reset() { *m = Deviation{} } -func (m *DeviationList) Reset() { *m = DeviationList{} } -func (*DeviationList) ProtoMessage() {} -func (*DeviationList) Descriptor() ([]byte, []int) { - return fileDescriptor_609f4c56ac31047c, []int{18} -} -func (m *DeviationList) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *DeviationList) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err - } - return b[:n], nil -} -func (m *DeviationList) XXX_Merge(src proto.Message) { - xxx_messageInfo_DeviationList.Merge(m, src) -} -func (m *DeviationList) XXX_Size() int { - return m.Size() -} -func (m *DeviationList) XXX_DiscardUnknown() { - xxx_messageInfo_DeviationList.DiscardUnknown(m) -} +func (m *DeviationList) Reset() { *m = DeviationList{} } -var xxx_messageInfo_DeviationList proto.InternalMessageInfo +func (m *DeviationSpec) Reset() { *m = DeviationSpec{} } -func (m *DeviationSpec) Reset() { *m = DeviationSpec{} } -func (*DeviationSpec) ProtoMessage() {} -func (*DeviationSpec) Descriptor() ([]byte, []int) { - return fileDescriptor_609f4c56ac31047c, []int{19} -} -func (m *DeviationSpec) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *DeviationSpec) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err - } - return b[:n], nil -} -func (m *DeviationSpec) XXX_Merge(src proto.Message) { - xxx_messageInfo_DeviationSpec.Merge(m, src) -} -func (m *DeviationSpec) XXX_Size() int { - return m.Size() -} -func (m *DeviationSpec) XXX_DiscardUnknown() { - xxx_messageInfo_DeviationSpec.DiscardUnknown(m) -} +func (m *DeviationStatus) Reset() { *m = DeviationStatus{} } -var xxx_messageInfo_DeviationSpec proto.InternalMessageInfo +func (m *DiscoveryInfo) Reset() { *m = DiscoveryInfo{} } -func (m *DeviationStatus) Reset() { *m = DeviationStatus{} } -func (*DeviationStatus) ProtoMessage() {} -func (*DeviationStatus) Descriptor() ([]byte, []int) { - return fileDescriptor_609f4c56ac31047c, []int{20} -} -func (m *DeviationStatus) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *DeviationStatus) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err - } - return b[:n], nil -} -func (m *DeviationStatus) XXX_Merge(src proto.Message) { - xxx_messageInfo_DeviationStatus.Merge(m, src) -} -func (m *DeviationStatus) XXX_Size() int { - return m.Size() -} -func (m *DeviationStatus) XXX_DiscardUnknown() { - xxx_messageInfo_DeviationStatus.DiscardUnknown(m) -} +func (m *Lifecycle) Reset() { *m = Lifecycle{} } -var xxx_messageInfo_DeviationStatus proto.InternalMessageInfo +func (m *RunningConfig) Reset() { *m = RunningConfig{} } -func (m *Lifecycle) Reset() { *m = Lifecycle{} } -func (*Lifecycle) ProtoMessage() {} -func (*Lifecycle) Descriptor() ([]byte, []int) { - return fileDescriptor_609f4c56ac31047c, []int{21} -} -func (m *Lifecycle) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *Lifecycle) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err - } - return b[:n], nil -} -func (m *Lifecycle) XXX_Merge(src proto.Message) { - xxx_messageInfo_Lifecycle.Merge(m, src) -} -func (m *Lifecycle) XXX_Size() int { - return m.Size() -} -func (m *Lifecycle) XXX_DiscardUnknown() { - xxx_messageInfo_Lifecycle.DiscardUnknown(m) -} +func (m *RunningConfigList) Reset() { *m = RunningConfigList{} } -var xxx_messageInfo_Lifecycle proto.InternalMessageInfo +func (m *RunningConfigSpec) Reset() { *m = RunningConfigSpec{} } -func (m *RunningConfig) Reset() { *m = RunningConfig{} } -func (*RunningConfig) ProtoMessage() {} -func (*RunningConfig) Descriptor() ([]byte, []int) { - return fileDescriptor_609f4c56ac31047c, []int{22} -} -func (m *RunningConfig) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *RunningConfig) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err - } - return b[:n], nil -} -func (m *RunningConfig) XXX_Merge(src proto.Message) { - xxx_messageInfo_RunningConfig.Merge(m, src) -} -func (m *RunningConfig) XXX_Size() int { - return m.Size() -} -func (m *RunningConfig) XXX_DiscardUnknown() { - xxx_messageInfo_RunningConfig.DiscardUnknown(m) -} +func (m *RunningConfigStatus) Reset() { *m = RunningConfigStatus{} } -var xxx_messageInfo_RunningConfig proto.InternalMessageInfo +func (m *SensitiveConfig) Reset() { *m = SensitiveConfig{} } -func (m *RunningConfigList) Reset() { *m = RunningConfigList{} } -func (*RunningConfigList) ProtoMessage() {} -func (*RunningConfigList) Descriptor() ([]byte, []int) { - return fileDescriptor_609f4c56ac31047c, []int{23} -} -func (m *RunningConfigList) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *RunningConfigList) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err - } - return b[:n], nil -} -func (m *RunningConfigList) XXX_Merge(src proto.Message) { - xxx_messageInfo_RunningConfigList.Merge(m, src) -} -func (m *RunningConfigList) XXX_Size() int { - return m.Size() -} -func (m *RunningConfigList) XXX_DiscardUnknown() { - xxx_messageInfo_RunningConfigList.DiscardUnknown(m) -} +func (m *SensitiveConfigData) Reset() { *m = SensitiveConfigData{} } -var xxx_messageInfo_RunningConfigList proto.InternalMessageInfo +func (m *SensitiveConfigList) Reset() { *m = SensitiveConfigList{} } -func (m *RunningConfigSpec) Reset() { *m = RunningConfigSpec{} } -func (*RunningConfigSpec) ProtoMessage() {} -func (*RunningConfigSpec) Descriptor() ([]byte, []int) { - return fileDescriptor_609f4c56ac31047c, []int{24} -} -func (m *RunningConfigSpec) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *RunningConfigSpec) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err - } - return b[:n], nil -} -func (m *RunningConfigSpec) XXX_Merge(src proto.Message) { - xxx_messageInfo_RunningConfigSpec.Merge(m, src) -} -func (m *RunningConfigSpec) XXX_Size() int { - return m.Size() -} -func (m *RunningConfigSpec) XXX_DiscardUnknown() { - xxx_messageInfo_RunningConfigSpec.DiscardUnknown(m) -} +func (m *SensitiveConfigSpec) Reset() { *m = SensitiveConfigSpec{} } -var xxx_messageInfo_RunningConfigSpec proto.InternalMessageInfo +func (m *SensitiveConfigStatus) Reset() { *m = SensitiveConfigStatus{} } -func (m *RunningConfigStatus) Reset() { *m = RunningConfigStatus{} } -func (*RunningConfigStatus) ProtoMessage() {} -func (*RunningConfigStatus) Descriptor() ([]byte, []int) { - return fileDescriptor_609f4c56ac31047c, []int{25} -} -func (m *RunningConfigStatus) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *RunningConfigStatus) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err - } - return b[:n], nil -} -func (m *RunningConfigStatus) XXX_Merge(src proto.Message) { - xxx_messageInfo_RunningConfigStatus.Merge(m, src) -} -func (m *RunningConfigStatus) XXX_Size() int { - return m.Size() -} -func (m *RunningConfigStatus) XXX_DiscardUnknown() { - xxx_messageInfo_RunningConfigStatus.DiscardUnknown(m) -} +func (m *Target) Reset() { *m = Target{} } -var xxx_messageInfo_RunningConfigStatus proto.InternalMessageInfo +func (m *TargetList) Reset() { *m = TargetList{} } -func (m *Target) Reset() { *m = Target{} } -func (*Target) ProtoMessage() {} -func (*Target) Descriptor() ([]byte, []int) { - return fileDescriptor_609f4c56ac31047c, []int{31} -} -func (m *Target) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *Target) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err - } - return b[:n], nil -} -func (m *Target) XXX_Merge(src proto.Message) { - xxx_messageInfo_Target.Merge(m, src) -} -func (m *Target) XXX_Size() int { - return m.Size() -} -func (m *Target) XXX_DiscardUnknown() { - xxx_messageInfo_Target.DiscardUnknown(m) -} +func (m *TargetSpec) Reset() { *m = TargetSpec{} } -var xxx_messageInfo_Target proto.InternalMessageInfo +func (m *TargetStatus) Reset() { *m = TargetStatus{} } -func (m *TargetStatus) Reset() { *m = TargetStatus{} } -func (*TargetStatus) ProtoMessage() {} -func (*TargetStatus) Descriptor() ([]byte, []int) { - return fileDescriptor_609f4c56ac31047c, []int{32} -} -func (m *TargetStatus) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *TargetStatus) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err - } - return b[:n], nil -} -func (m *TargetStatus) XXX_Merge(src proto.Message) { - xxx_messageInfo_TargetStatus.Merge(m, src) -} -func (m *TargetStatus) XXX_Size() int { - return m.Size() -} -func (m *TargetStatus) XXX_DiscardUnknown() { - xxx_messageInfo_TargetStatus.DiscardUnknown(m) -} - -var xxx_messageInfo_TargetStatus proto.InternalMessageInfo - -func init() { - proto.RegisterType((*Config)(nil), "github.com.sdcio.config_server.apis.config.v1alpha1.Config") - proto.RegisterType((*ConfigBlame)(nil), "github.com.sdcio.config_server.apis.config.v1alpha1.ConfigBlame") - proto.RegisterType((*ConfigBlameList)(nil), "github.com.sdcio.config_server.apis.config.v1alpha1.ConfigBlameList") - proto.RegisterType((*ConfigBlameSpec)(nil), "github.com.sdcio.config_server.apis.config.v1alpha1.ConfigBlameSpec") - proto.RegisterType((*ConfigBlameStatus)(nil), "github.com.sdcio.config_server.apis.config.v1alpha1.ConfigBlameStatus") - proto.RegisterType((*ConfigBlob)(nil), "github.com.sdcio.config_server.apis.config.v1alpha1.ConfigBlob") - proto.RegisterType((*ConfigDeviation)(nil), "github.com.sdcio.config_server.apis.config.v1alpha1.ConfigDeviation") - proto.RegisterType((*ConfigList)(nil), "github.com.sdcio.config_server.apis.config.v1alpha1.ConfigList") - proto.RegisterType((*ConfigSet)(nil), "github.com.sdcio.config_server.apis.config.v1alpha1.ConfigSet") - proto.RegisterType((*ConfigSetList)(nil), "github.com.sdcio.config_server.apis.config.v1alpha1.ConfigSetList") - proto.RegisterType((*ConfigSetSpec)(nil), "github.com.sdcio.config_server.apis.config.v1alpha1.ConfigSetSpec") - proto.RegisterType((*ConfigSetStatus)(nil), "github.com.sdcio.config_server.apis.config.v1alpha1.ConfigSetStatus") - proto.RegisterType((*ConfigSpec)(nil), "github.com.sdcio.config_server.apis.config.v1alpha1.ConfigSpec") - proto.RegisterType((*ConfigStatus)(nil), "github.com.sdcio.config_server.apis.config.v1alpha1.ConfigStatus") - proto.RegisterType((*ConfigStatusLastKnownGoodSchema)(nil), "github.com.sdcio.config_server.apis.config.v1alpha1.ConfigStatusLastKnownGoodSchema") - proto.RegisterType((*Deviation)(nil), "github.com.sdcio.config_server.apis.config.v1alpha1.Deviation") - proto.RegisterType((*DeviationList)(nil), "github.com.sdcio.config_server.apis.config.v1alpha1.DeviationList") - proto.RegisterType((*DeviationSpec)(nil), "github.com.sdcio.config_server.apis.config.v1alpha1.DeviationSpec") - proto.RegisterType((*DeviationStatus)(nil), "github.com.sdcio.config_server.apis.config.v1alpha1.DeviationStatus") - proto.RegisterType((*Lifecycle)(nil), "github.com.sdcio.config_server.apis.config.v1alpha1.Lifecycle") - proto.RegisterType((*RunningConfig)(nil), "github.com.sdcio.config_server.apis.config.v1alpha1.RunningConfig") - proto.RegisterType((*RunningConfigList)(nil), "github.com.sdcio.config_server.apis.config.v1alpha1.RunningConfigList") - proto.RegisterType((*RunningConfigSpec)(nil), "github.com.sdcio.config_server.apis.config.v1alpha1.RunningConfigSpec") - proto.RegisterType((*RunningConfigStatus)(nil), "github.com.sdcio.config_server.apis.config.v1alpha1.RunningConfigStatus") - proto.RegisterType((*Target)(nil), "github.com.sdcio.config_server.apis.config.v1alpha1.Target") - proto.RegisterType((*TargetStatus)(nil), "github.com.sdcio.config_server.apis.config.v1alpha1.TargetStatus") -} - -func init() { - proto.RegisterFile("github.com/sdcio/config-server/apis/config/v1alpha1/generated.proto", fileDescriptor_609f4c56ac31047c) -} - -var fileDescriptor_609f4c56ac31047c = []byte{ - // 1580 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xec, 0x5a, 0xcd, 0x6f, 0x1b, 0x45, - 0x14, 0xcf, 0xda, 0x49, 0x1a, 0x4f, 0x9c, 0xa4, 0x9e, 0x94, 0x12, 0x22, 0xb0, 0xa3, 0x15, 0x42, - 0x41, 0xd0, 0x35, 0x4d, 0xab, 0xaa, 0x12, 0x12, 0x25, 0x5b, 0xd3, 0x0f, 0x1a, 0x68, 0x34, 0x89, - 0x22, 0x81, 0x40, 0x74, 0xb2, 0x9e, 0xd8, 0xdb, 0xac, 0x77, 0x57, 0xbb, 0x63, 0xb7, 0xbe, 0xf5, - 0xc4, 0x81, 0x13, 0x42, 0x88, 0x0b, 0x48, 0x5c, 0x80, 0xbf, 0xa1, 0x17, 0x0e, 0x1c, 0x10, 0x3d, - 0x80, 0xa8, 0xa8, 0x84, 0x2a, 0x0e, 0x16, 0x35, 0xff, 0x45, 0x4f, 0x68, 0x67, 0x67, 0xbf, 0xbd, - 0x49, 0xea, 0x4d, 0xac, 0x16, 0x71, 0xcb, 0xbc, 0x99, 0xf7, 0x7b, 0x1f, 0xf3, 0x9b, 0xb7, 0x6f, - 0xc6, 0x01, 0x17, 0x1b, 0x2a, 0x6d, 0xb6, 0xb7, 0x25, 0xc5, 0x68, 0x55, 0xed, 0xba, 0xa2, 0x1a, - 0x55, 0xc5, 0xd0, 0x77, 0xd4, 0xc6, 0x29, 0x9b, 0x58, 0x1d, 0x62, 0x55, 0xb1, 0xa9, 0xda, 0x5c, - 0x54, 0xed, 0x9c, 0xc6, 0x9a, 0xd9, 0xc4, 0xa7, 0xab, 0x0d, 0xa2, 0x13, 0x0b, 0x53, 0x52, 0x97, - 0x4c, 0xcb, 0xa0, 0x06, 0x3c, 0x13, 0x80, 0x48, 0x0c, 0x44, 0x72, 0x35, 0x3e, 0x71, 0x41, 0x24, - 0x07, 0x84, 0x8b, 0x24, 0x0f, 0x64, 0xf1, 0x54, 0xc8, 0x72, 0xc3, 0x68, 0x18, 0x55, 0x86, 0xb5, - 0xdd, 0xde, 0x61, 0x23, 0x36, 0x60, 0x7f, 0xb9, 0x36, 0x16, 0x2f, 0x1d, 0xd0, 0xd1, 0xba, 0x4a, - 0x55, 0x43, 0x4f, 0xf5, 0x75, 0xf1, 0xec, 0xee, 0x79, 0x5b, 0x52, 0x0d, 0x67, 0x7d, 0x0b, 0x2b, - 0x4d, 0x55, 0x27, 0x56, 0xb7, 0x6a, 0xee, 0x36, 0x5c, 0x80, 0x16, 0xa1, 0xb8, 0xda, 0x49, 0x6a, - 0x55, 0xd3, 0xb4, 0xac, 0xb6, 0x4e, 0xd5, 0x16, 0x49, 0x28, 0x9c, 0xdb, 0x4f, 0xc1, 0x56, 0x9a, - 0xa4, 0x85, 0xe3, 0x7a, 0xe2, 0x79, 0x70, 0x62, 0xcd, 0x50, 0xb0, 0x76, 0x7d, 0xfb, 0x26, 0x51, - 0x28, 0x22, 0x3b, 0xc4, 0x22, 0xba, 0x42, 0xe0, 0x12, 0x18, 0xd7, 0x71, 0x8b, 0x2c, 0x08, 0x4b, - 0xc2, 0x72, 0x41, 0x2e, 0xde, 0xeb, 0x55, 0xc6, 0xfa, 0xbd, 0xca, 0xf8, 0xfb, 0xb8, 0x45, 0x10, - 0x9b, 0x11, 0x1f, 0x0b, 0xa0, 0xb4, 0x41, 0x14, 0x8b, 0xd0, 0x6b, 0xa4, 0xbb, 0x41, 0x34, 0xa2, - 0x50, 0xc3, 0x82, 0x5f, 0x0b, 0xe0, 0x84, 0x36, 0x00, 0x90, 0x01, 0x4d, 0xaf, 0x5c, 0x95, 0x86, - 0xd8, 0x3a, 0x69, 0x90, 0x87, 0xf2, 0x8b, 0xdc, 0xa7, 0x81, 0xfe, 0xa3, 0x81, 0x4e, 0xc0, 0x97, - 0x40, 0x7e, 0x97, 0x74, 0x17, 0x72, 0x2c, 0xa8, 0x69, 0x0e, 0x90, 0xbf, 0x46, 0xba, 0xc8, 0x91, - 0xc3, 0x65, 0x30, 0x65, 0x98, 0xce, 0x76, 0x62, 0x6d, 0x21, 0xbf, 0x24, 0x2c, 0x4f, 0xc9, 0xc5, - 0x7e, 0xaf, 0x32, 0x75, 0x9d, 0xcb, 0x90, 0x3f, 0x2b, 0xde, 0xcd, 0x81, 0xc9, 0x8b, 0xcc, 0x4b, - 0x78, 0x03, 0x4c, 0x39, 0xbb, 0x58, 0xc7, 0x14, 0xf3, 0x20, 0xdf, 0x90, 0xdc, 0xcd, 0x90, 0xc2, - 0x9b, 0x21, 0x99, 0xbb, 0x0d, 0x37, 0x3a, 0x67, 0xb5, 0xd4, 0x39, 0x2d, 0xb9, 0xce, 0xbd, 0x47, - 0x28, 0x96, 0x21, 0x77, 0x05, 0x04, 0x32, 0xe4, 0xa3, 0x42, 0x0c, 0xc6, 0x6d, 0x93, 0x28, 0xcc, - 0xed, 0xe9, 0x95, 0x0b, 0x43, 0xa5, 0xd0, 0x75, 0x76, 0xc3, 0x24, 0x4a, 0xb0, 0x99, 0xce, 0x08, - 0x31, 0x68, 0xa8, 0x82, 0x49, 0x9b, 0x62, 0xda, 0xb6, 0x59, 0xdc, 0xd3, 0x2b, 0xab, 0x59, 0x8c, - 0x30, 0x20, 0x79, 0x96, 0x9b, 0x99, 0x74, 0xc7, 0x88, 0x1b, 0x10, 0x7f, 0xc9, 0x81, 0x69, 0x77, - 0xa1, 0xac, 0xe1, 0x16, 0x19, 0x41, 0xfe, 0x76, 0x22, 0xf9, 0xab, 0x65, 0x08, 0x8d, 0x79, 0x9c, - 0x9a, 0x44, 0x3d, 0x96, 0xc4, 0x4b, 0x99, 0x2d, 0xed, 0x9d, 0xc9, 0x3f, 0x05, 0x30, 0x17, 0x5a, - 0xbd, 0xa6, 0xda, 0x14, 0x7e, 0x94, 0xc8, 0xa6, 0x74, 0xb0, 0x6c, 0x3a, 0xda, 0x2c, 0x97, 0xc7, - 0xb9, 0xb5, 0x29, 0x4f, 0x12, 0xca, 0x24, 0x01, 0x13, 0x2a, 0x25, 0x2d, 0x7b, 0x21, 0xb7, 0x94, - 0x5f, 0x9e, 0x5e, 0x79, 0x3b, 0x6b, 0x80, 0xf2, 0x0c, 0x37, 0x36, 0x71, 0xd5, 0x81, 0x45, 0x2e, - 0xba, 0x58, 0x8a, 0xc4, 0xe5, 0x64, 0x58, 0x6c, 0x80, 0x52, 0x22, 0x31, 0x10, 0x81, 0x89, 0x0e, - 0xd6, 0xda, 0x84, 0xef, 0xec, 0xa9, 0xd4, 0x48, 0x79, 0x11, 0x94, 0x10, 0xbe, 0xf5, 0xce, 0x6d, - 0x4a, 0x74, 0x5b, 0x35, 0xf4, 0xc0, 0xf6, 0x96, 0x83, 0x81, 0x5c, 0x28, 0xf1, 0x53, 0x01, 0x00, - 0xcf, 0x92, 0xb1, 0x0d, 0x5f, 0x06, 0x93, 0xae, 0xff, 0xf1, 0x4a, 0xb8, 0x8e, 0x69, 0x13, 0xf1, - 0xb9, 0x23, 0x71, 0xe4, 0x67, 0x7f, 0x77, 0x6b, 0xa4, 0xa3, 0x62, 0xa7, 0xf0, 0x38, 0x55, 0xd9, - 0xc4, 0xb4, 0x39, 0xd0, 0x17, 0x36, 0x03, 0xcf, 0x82, 0x62, 0x9d, 0xd8, 0xaa, 0x45, 0xea, 0x5b, - 0xbe, 0x43, 0x05, 0xf9, 0x78, 0xbf, 0x57, 0x29, 0xd6, 0x42, 0x72, 0x14, 0x59, 0x05, 0x57, 0xc0, - 0x34, 0x56, 0x68, 0x1b, 0x6b, 0xae, 0x52, 0x3e, 0x50, 0xba, 0xd8, 0xb6, 0x2c, 0xa2, 0x53, 0x57, - 0x29, 0xbc, 0x08, 0xbe, 0x02, 0x26, 0x2d, 0x82, 0x6d, 0x43, 0x5f, 0x18, 0x67, 0xcb, 0x7d, 0x96, - 0x22, 0x26, 0x45, 0x7c, 0x56, 0xfc, 0xd5, 0x4f, 0xe8, 0x08, 0x08, 0x7a, 0x23, 0x4a, 0xd0, 0x37, - 0xb3, 0x10, 0x74, 0x30, 0x37, 0x7f, 0xca, 0x81, 0x02, 0xaf, 0x73, 0x84, 0x8e, 0xa0, 0x78, 0xd5, - 0x23, 0xc5, 0x4b, 0xce, 0x52, 0x97, 0x09, 0x4d, 0x2d, 0x5d, 0x5a, 0xac, 0x74, 0xd5, 0x32, 0xda, - 0xd9, 0xbb, 0x70, 0xfd, 0x21, 0x80, 0x19, 0x7f, 0xed, 0x08, 0x58, 0xa1, 0x44, 0x59, 0xf1, 0x56, - 0xb6, 0xe0, 0x52, 0x88, 0xf1, 0x7d, 0x3e, 0x14, 0x94, 0x93, 0x5a, 0xa8, 0x80, 0x49, 0x8a, 0xad, - 0x06, 0xa1, 0x3c, 0xa4, 0xe1, 0xd8, 0xb8, 0xc9, 0x20, 0x82, 0x5c, 0xba, 0x63, 0xc4, 0xa1, 0xe1, - 0x2e, 0x28, 0x68, 0xea, 0x0e, 0x51, 0xba, 0x8a, 0xe6, 0x95, 0x9f, 0xe1, 0xe2, 0x5b, 0xf3, 0x50, - 0xe4, 0x99, 0x7e, 0xaf, 0x52, 0xf0, 0x87, 0x28, 0xc0, 0x87, 0xaf, 0x83, 0x29, 0xd3, 0x52, 0x0d, - 0x4b, 0xa5, 0x5d, 0x46, 0x94, 0x7c, 0x90, 0xf6, 0x75, 0x2e, 0x47, 0xfe, 0x0a, 0xf8, 0x1a, 0x28, - 0x58, 0xa4, 0x43, 0x2c, 0xaa, 0x76, 0x08, 0x2b, 0x12, 0x53, 0x2e, 0x34, 0xf2, 0x84, 0x28, 0x98, - 0x87, 0x0d, 0xbf, 0xd0, 0x4e, 0xb0, 0x4d, 0xba, 0x90, 0xe9, 0xdb, 0x62, 0x6c, 0x07, 0x09, 0x73, - 0x65, 0x5e, 0xad, 0x16, 0xbf, 0xcc, 0x79, 0x75, 0xd5, 0x27, 0x2a, 0xfc, 0x42, 0x00, 0x25, 0xbf, - 0x97, 0x27, 0x75, 0x57, 0xfa, 0xa4, 0x2d, 0xab, 0xab, 0x1d, 0xf1, 0x25, 0x0a, 0x28, 0xbf, 0xc0, - 0x5d, 0x2a, 0x25, 0xa6, 0x50, 0xd2, 0x3c, 0xd4, 0xc0, 0x31, 0x77, 0x8f, 0x3d, 0xde, 0xae, 0x66, - 0xe0, 0x0f, 0xf7, 0x60, 0x8e, 0x7b, 0x70, 0xcc, 0x95, 0xda, 0xc8, 0x33, 0x21, 0xfe, 0x98, 0xf3, - 0xca, 0x34, 0xe3, 0x6e, 0x84, 0x56, 0xc2, 0x08, 0x69, 0x95, 0x7b, 0x32, 0x5a, 0xe5, 0x0f, 0x4c, - 0xab, 0xf1, 0xa3, 0xa5, 0xd5, 0x67, 0xe3, 0xa0, 0x18, 0xee, 0x7f, 0x9f, 0x4e, 0x4e, 0x7d, 0x2b, - 0x80, 0x79, 0x0d, 0xdb, 0xf4, 0x9a, 0x6e, 0xdc, 0xd2, 0x2f, 0x1b, 0x46, 0x7d, 0x83, 0x5d, 0x0b, - 0x79, 0xe1, 0xd8, 0xcc, 0xdc, 0xf5, 0xaf, 0x25, 0xb1, 0xe5, 0xe7, 0xfb, 0xbd, 0xca, 0xfc, 0x80, - 0x09, 0x34, 0xc8, 0x13, 0x78, 0x1b, 0xcc, 0x60, 0xd3, 0xd4, 0x54, 0x52, 0x77, 0x71, 0xf9, 0x07, - 0x29, 0xf3, 0xad, 0xa7, 0xd4, 0xef, 0x55, 0x66, 0x56, 0xc3, 0xc8, 0x28, 0x6a, 0x08, 0x5e, 0x05, - 0xf3, 0x75, 0xaf, 0xd3, 0xba, 0xec, 0x5e, 0x93, 0x55, 0xde, 0xdd, 0xe4, 0xdd, 0x20, 0x6a, 0xc9, - 0x69, 0x34, 0x48, 0x47, 0xfc, 0x4a, 0x00, 0x95, 0x7d, 0xd2, 0xe2, 0xf4, 0x72, 0xb4, 0x6b, 0x26, - 0x6e, 0xd8, 0x9b, 0x5d, 0x93, 0x20, 0x36, 0xe3, 0x74, 0x58, 0x1d, 0xa2, 0xd7, 0x0d, 0x8b, 0x77, - 0x71, 0x3e, 0xf5, 0xb6, 0x98, 0x14, 0xf1, 0x59, 0xf8, 0x2a, 0x38, 0xd6, 0x21, 0x96, 0xd3, 0x4a, - 0xf2, 0xce, 0xcd, 0x3f, 0xe5, 0x5b, 0xae, 0x18, 0x79, 0xf3, 0xac, 0x7b, 0x09, 0xda, 0xc9, 0x67, - 0xa3, 0x7b, 0xf1, 0xfd, 0x3d, 0xe2, 0xee, 0x25, 0xb0, 0xb3, 0x7f, 0xf7, 0xe2, 0xaf, 0x7d, 0x56, - 0xba, 0x17, 0xdf, 0xe1, 0x94, 0xee, 0xe5, 0x41, 0x38, 0x28, 0xf6, 0x05, 0xb8, 0x02, 0x66, 0x7c, - 0x6a, 0x6f, 0x06, 0x44, 0x15, 0x9d, 0x73, 0x54, 0x0b, 0x4f, 0x3c, 0x8e, 0x0b, 0x50, 0x54, 0x11, - 0xde, 0x06, 0xc0, 0x17, 0x78, 0x51, 0x64, 0x69, 0x30, 0x83, 0x58, 0x7c, 0xf2, 0xf9, 0x22, 0x1b, - 0x85, 0x6c, 0x89, 0x3f, 0x08, 0x60, 0x2e, 0xb6, 0xad, 0x4f, 0x65, 0x5d, 0x16, 0x3f, 0x06, 0xc1, - 0x97, 0x11, 0xae, 0x83, 0xd9, 0x3a, 0xd1, 0x88, 0xb3, 0x60, 0xdd, 0xd0, 0x54, 0xa5, 0xcb, 0x53, - 0xbf, 0xcc, 0x21, 0x67, 0x6b, 0x91, 0xd9, 0xc7, 0x09, 0x09, 0x8a, 0xe9, 0x8b, 0xbf, 0xe5, 0xc0, - 0x0c, 0x6a, 0xeb, 0xba, 0xaa, 0x37, 0x46, 0xf6, 0x6a, 0xd5, 0x8c, 0x1c, 0xfd, 0xe1, 0xde, 0x42, - 0x22, 0x3e, 0xa7, 0x1e, 0x7f, 0x33, 0x76, 0xfc, 0xaf, 0x1c, 0x82, 0xad, 0xbd, 0x4b, 0xc0, 0x5f, - 0x02, 0x28, 0x45, 0xd6, 0x8f, 0xa0, 0x0c, 0x34, 0xa2, 0x65, 0x40, 0xce, 0x1e, 0x64, 0x4a, 0x29, - 0x98, 0x8f, 0xc5, 0xc6, 0xde, 0x5f, 0x54, 0x30, 0x3f, 0x20, 0x41, 0x47, 0xf2, 0xf0, 0xf1, 0x20, - 0x07, 0xe6, 0x36, 0x9c, 0x15, 0x4e, 0x03, 0x37, 0x32, 0xba, 0xde, 0x8c, 0xd0, 0x75, 0x38, 0x0a, - 0xc5, 0xbc, 0x4e, 0x25, 0xac, 0x15, 0x23, 0xec, 0xbb, 0x87, 0x62, 0x6d, 0x6f, 0xca, 0xde, 0x17, - 0xc0, 0x7c, 0x4c, 0xa3, 0xe6, 0xc4, 0x7d, 0x2e, 0x91, 0xec, 0x81, 0xaf, 0x4b, 0x89, 0x1d, 0xb9, - 0x23, 0x80, 0xa2, 0xed, 0x3d, 0xff, 0x23, 0xb2, 0x93, 0xe9, 0x9c, 0x27, 0x7e, 0x47, 0x90, 0x4f, - 0x70, 0xeb, 0xc5, 0x8d, 0x90, 0x0d, 0x14, 0xb1, 0x28, 0xf6, 0x92, 0x21, 0x8d, 0xe0, 0x1c, 0xaa, - 0xd1, 0x73, 0x58, 0x3b, 0x8c, 0xbd, 0x4b, 0x39, 0x89, 0xbf, 0xe7, 0x12, 0x01, 0xfe, 0xa7, 0x2e, - 0x67, 0x66, 0xec, 0x72, 0x76, 0x28, 0xa7, 0xce, 0x61, 0x75, 0xea, 0x2d, 0xed, 0xee, 0x38, 0x78, - 0x6e, 0xe0, 0xb9, 0xf9, 0xff, 0xba, 0x36, 0xdc, 0x75, 0xed, 0x1b, 0x01, 0x9c, 0xe4, 0xd7, 0xa8, - 0x78, 0x19, 0xc9, 0x1f, 0x72, 0x25, 0x5d, 0xec, 0xf7, 0x2a, 0x27, 0x57, 0x07, 0xda, 0x42, 0x29, - 0x3e, 0x1c, 0xe6, 0x9d, 0xae, 0x0b, 0xf8, 0xd3, 0x1b, 0x34, 0xc0, 0xac, 0xfb, 0x6a, 0xe2, 0x55, - 0x2b, 0x4e, 0x93, 0x33, 0x07, 0xac, 0x32, 0x78, 0x9b, 0x68, 0x7e, 0xa1, 0x83, 0x4e, 0x43, 0xb7, - 0x19, 0x81, 0x43, 0x31, 0x78, 0xf1, 0x3b, 0x01, 0x14, 0xc3, 0xcf, 0x38, 0xfb, 0xff, 0x3a, 0x0b, - 0x2d, 0x50, 0xf0, 0xe9, 0xf4, 0xa4, 0xbf, 0xe9, 0xa5, 0xb2, 0x58, 0x2e, 0x71, 0x4b, 0x05, 0x5f, - 0x84, 0x02, 0x33, 0xf2, 0x07, 0xf7, 0x1e, 0x95, 0xc7, 0xee, 0x3f, 0x2a, 0x8f, 0x3d, 0x7c, 0x54, - 0x1e, 0xbb, 0xd3, 0x2f, 0x0b, 0xf7, 0xfa, 0x65, 0xe1, 0x7e, 0xbf, 0x2c, 0x3c, 0xec, 0x97, 0x85, - 0xbf, 0xfb, 0x65, 0xe1, 0xf3, 0x7f, 0xca, 0x63, 0x1f, 0x9e, 0x19, 0xe2, 0x3f, 0x00, 0xfe, 0x0d, - 0x00, 0x00, 0xff, 0xff, 0x7d, 0x5c, 0xbd, 0xd2, 0x37, 0x20, 0x00, 0x00, -} +func (m *TargetStatusUsedReferences) Reset() { *m = TargetStatusUsedReferences{} } func (m *Config) Marshal() (dAtA []byte, err error) { size := m.Size() @@ -1466,7 +664,7 @@ func (m *ConfigSetStatus) MarshalToSizedBuffer(dAtA []byte) (int, error) { return len(dAtA) - i, nil } -func (m *ConfigSpec) Marshal() (dAtA []byte, err error) { +func (m *ConfigSetTarget) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) @@ -1476,26 +674,99 @@ func (m *ConfigSpec) Marshal() (dAtA []byte, err error) { return dAtA[:n], nil } -func (m *ConfigSpec) MarshalTo(dAtA []byte) (int, error) { +func (m *ConfigSetTarget) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } -func (m *ConfigSpec) MarshalToSizedBuffer(dAtA []byte) (int, error) { +func (m *ConfigSetTarget) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l - if len(m.Config) > 0 { - for iNdEx := len(m.Config) - 1; iNdEx >= 0; iNdEx-- { - { - size, err := m.Config[iNdEx].MarshalToSizedBuffer(dAtA[:i]) - if err != nil { - return 0, err - } - i -= size - i = encodeVarintGenerated(dAtA, i, uint64(size)) - } + if m.TargetSelector != nil { + { + size, err := m.TargetSelector.MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintGenerated(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0xa + } + return len(dAtA) - i, nil +} + +func (m *ConfigSetTargetStatus) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *ConfigSetTargetStatus) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *ConfigSetTargetStatus) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + { + size, err := m.Condition.MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintGenerated(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0x1a + i -= len(m.Name) + copy(dAtA[i:], m.Name) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Name))) + i-- + dAtA[i] = 0xa + return len(dAtA) - i, nil +} + +func (m *ConfigSpec) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *ConfigSpec) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *ConfigSpec) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + if len(m.Config) > 0 { + for iNdEx := len(m.Config) - 1; iNdEx >= 0; iNdEx-- { + { + size, err := m.Config[iNdEx].MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintGenerated(dAtA, i, uint64(size)) + } i-- dAtA[i] = 0x22 } @@ -1805,6 +1076,73 @@ func (m *DeviationStatus) MarshalToSizedBuffer(dAtA []byte) (int, error) { return len(dAtA) - i, nil } +func (m *DiscoveryInfo) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *DiscoveryInfo) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *DiscoveryInfo) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + if len(m.SupportedEncodings) > 0 { + for iNdEx := len(m.SupportedEncodings) - 1; iNdEx >= 0; iNdEx-- { + i -= len(m.SupportedEncodings[iNdEx]) + copy(dAtA[i:], m.SupportedEncodings[iNdEx]) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.SupportedEncodings[iNdEx]))) + i-- + dAtA[i] = 0x42 + } + } + i -= len(m.SerialNumber) + copy(dAtA[i:], m.SerialNumber) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.SerialNumber))) + i-- + dAtA[i] = 0x3a + i -= len(m.MacAddress) + copy(dAtA[i:], m.MacAddress) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.MacAddress))) + i-- + dAtA[i] = 0x32 + i -= len(m.Platform) + copy(dAtA[i:], m.Platform) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Platform))) + i-- + dAtA[i] = 0x2a + i -= len(m.Hostname) + copy(dAtA[i:], m.Hostname) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Hostname))) + i-- + dAtA[i] = 0x22 + i -= len(m.Version) + copy(dAtA[i:], m.Version) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Version))) + i-- + dAtA[i] = 0x1a + i -= len(m.Provider) + copy(dAtA[i:], m.Provider) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Provider))) + i-- + dAtA[i] = 0x12 + i -= len(m.Protocol) + copy(dAtA[i:], m.Protocol) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Protocol))) + i-- + dAtA[i] = 0xa + return len(dAtA) - i, nil +} + func (m *Lifecycle) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) @@ -1989,7 +1327,7 @@ func (m *RunningConfigStatus) MarshalToSizedBuffer(dAtA []byte) (int, error) { return len(dAtA) - i, nil } -func (m *Target) Marshal() (dAtA []byte, err error) { +func (m *SensitiveConfig) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) @@ -1999,32 +1337,50 @@ func (m *Target) Marshal() (dAtA []byte, err error) { return dAtA[:n], nil } -func (m *Target) MarshalTo(dAtA []byte) (int, error) { +func (m *SensitiveConfig) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } -func (m *Target) MarshalToSizedBuffer(dAtA []byte) (int, error) { +func (m *SensitiveConfig) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l - if m.TargetSelector != nil { - { - size, err := m.TargetSelector.MarshalToSizedBuffer(dAtA[:i]) - if err != nil { - return 0, err - } - i -= size - i = encodeVarintGenerated(dAtA, i, uint64(size)) + { + size, err := m.Status.MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err } - i-- - dAtA[i] = 0xa + i -= size + i = encodeVarintGenerated(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0x1a + { + size, err := m.Spec.MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintGenerated(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0x12 + { + size, err := m.ObjectMeta.MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintGenerated(dAtA, i, uint64(size)) } + i-- + dAtA[i] = 0xa return len(dAtA) - i, nil } -func (m *TargetStatus) Marshal() (dAtA []byte, err error) { +func (m *SensitiveConfigData) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) @@ -2034,18 +1390,18 @@ func (m *TargetStatus) Marshal() (dAtA []byte, err error) { return dAtA[:n], nil } -func (m *TargetStatus) MarshalTo(dAtA []byte) (int, error) { +func (m *SensitiveConfigData) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } -func (m *TargetStatus) MarshalToSizedBuffer(dAtA []byte) (int, error) { +func (m *SensitiveConfigData) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l { - size, err := m.Condition.MarshalToSizedBuffer(dAtA[:i]) + size, err := m.SecretKeyRef.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } @@ -2053,279 +1409,457 @@ func (m *TargetStatus) MarshalToSizedBuffer(dAtA []byte) (int, error) { i = encodeVarintGenerated(dAtA, i, uint64(size)) } i-- - dAtA[i] = 0x1a - i -= len(m.Name) - copy(dAtA[i:], m.Name) - i = encodeVarintGenerated(dAtA, i, uint64(len(m.Name))) + dAtA[i] = 0x12 + i -= len(m.Path) + copy(dAtA[i:], m.Path) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Path))) i-- dAtA[i] = 0xa return len(dAtA) - i, nil } -func encodeVarintGenerated(dAtA []byte, offset int, v uint64) int { - offset -= sovGenerated(v) - base := offset - for v >= 1<<7 { - dAtA[offset] = uint8(v&0x7f | 0x80) - v >>= 7 - offset++ - } - dAtA[offset] = uint8(v) - return base -} -func (m *Config) Size() (n int) { - if m == nil { - return 0 +func (m *SensitiveConfigList) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) + if err != nil { + return nil, err } - var l int - _ = l - l = m.ObjectMeta.Size() - n += 1 + l + sovGenerated(uint64(l)) - l = m.Spec.Size() - n += 1 + l + sovGenerated(uint64(l)) - l = m.Status.Size() - n += 1 + l + sovGenerated(uint64(l)) - return n + return dAtA[:n], nil } -func (m *ConfigBlame) Size() (n int) { - if m == nil { - return 0 - } - var l int - _ = l - l = m.ObjectMeta.Size() - n += 1 + l + sovGenerated(uint64(l)) - l = m.Spec.Size() - n += 1 + l + sovGenerated(uint64(l)) - l = m.Status.Size() - n += 1 + l + sovGenerated(uint64(l)) - return n +func (m *SensitiveConfigList) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) } -func (m *ConfigBlameList) Size() (n int) { - if m == nil { - return 0 - } +func (m *SensitiveConfigList) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i var l int _ = l - l = m.ListMeta.Size() - n += 1 + l + sovGenerated(uint64(l)) if len(m.Items) > 0 { - for _, e := range m.Items { - l = e.Size() - n += 1 + l + sovGenerated(uint64(l)) + for iNdEx := len(m.Items) - 1; iNdEx >= 0; iNdEx-- { + { + size, err := m.Items[iNdEx].MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintGenerated(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0x12 } } - return n -} - -func (m *ConfigBlameSpec) Size() (n int) { - if m == nil { - return 0 + { + size, err := m.ListMeta.MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintGenerated(dAtA, i, uint64(size)) } - var l int - _ = l - return n + i-- + dAtA[i] = 0xa + return len(dAtA) - i, nil } -func (m *ConfigBlameStatus) Size() (n int) { - if m == nil { - return 0 +func (m *SensitiveConfigSpec) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) + if err != nil { + return nil, err } - var l int - _ = l - l = m.Value.Size() - n += 1 + l + sovGenerated(uint64(l)) - return n + return dAtA[:n], nil } -func (m *ConfigBlob) Size() (n int) { - if m == nil { - return 0 - } - var l int - _ = l - l = len(m.Path) - n += 1 + l + sovGenerated(uint64(l)) - l = m.Value.Size() - n += 1 + l + sovGenerated(uint64(l)) - return n +func (m *SensitiveConfigSpec) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) } -func (m *ConfigDeviation) Size() (n int) { - if m == nil { - return 0 - } +func (m *SensitiveConfigSpec) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i var l int _ = l - l = len(m.Path) - n += 1 + l + sovGenerated(uint64(l)) - if m.DesiredValue != nil { - l = len(*m.DesiredValue) - n += 1 + l + sovGenerated(uint64(l)) - } - if m.ActualValue != nil { - l = len(*m.ActualValue) - n += 1 + l + sovGenerated(uint64(l)) + if len(m.Config) > 0 { + for iNdEx := len(m.Config) - 1; iNdEx >= 0; iNdEx-- { + { + size, err := m.Config[iNdEx].MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintGenerated(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0x22 + } } - l = len(m.Reason) - n += 1 + l + sovGenerated(uint64(l)) - return n -} - -func (m *ConfigList) Size() (n int) { - if m == nil { - return 0 + if m.Revertive != nil { + i-- + if *m.Revertive { + dAtA[i] = 1 + } else { + dAtA[i] = 0 + } + i-- + dAtA[i] = 0x18 } - var l int - _ = l - l = m.ListMeta.Size() - n += 1 + l + sovGenerated(uint64(l)) - if len(m.Items) > 0 { - for _, e := range m.Items { - l = e.Size() - n += 1 + l + sovGenerated(uint64(l)) + i = encodeVarintGenerated(dAtA, i, uint64(m.Priority)) + i-- + dAtA[i] = 0x10 + if m.Lifecycle != nil { + { + size, err := m.Lifecycle.MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintGenerated(dAtA, i, uint64(size)) } + i-- + dAtA[i] = 0xa } - return n + return len(dAtA) - i, nil } -func (m *ConfigSet) Size() (n int) { - if m == nil { - return 0 +func (m *SensitiveConfigStatus) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) + if err != nil { + return nil, err } - var l int - _ = l - l = m.ObjectMeta.Size() - n += 1 + l + sovGenerated(uint64(l)) - l = m.Spec.Size() - n += 1 + l + sovGenerated(uint64(l)) - l = m.Status.Size() - n += 1 + l + sovGenerated(uint64(l)) - return n + return dAtA[:n], nil } -func (m *ConfigSetList) Size() (n int) { - if m == nil { - return 0 - } - var l int - _ = l - l = m.ListMeta.Size() - n += 1 + l + sovGenerated(uint64(l)) - if len(m.Items) > 0 { - for _, e := range m.Items { - l = e.Size() - n += 1 + l + sovGenerated(uint64(l)) - } - } - return n +func (m *SensitiveConfigStatus) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) } -func (m *ConfigSetSpec) Size() (n int) { - if m == nil { - return 0 - } +func (m *SensitiveConfigStatus) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i var l int _ = l - l = m.Target.Size() - n += 1 + l + sovGenerated(uint64(l)) - if m.Lifecycle != nil { - l = m.Lifecycle.Size() - n += 1 + l + sovGenerated(uint64(l)) - } - n += 1 + sovGenerated(uint64(m.Priority)) - if m.Revertive != nil { - n += 2 + if m.DeviationGeneration != nil { + i = encodeVarintGenerated(dAtA, i, uint64(*m.DeviationGeneration)) + i-- + dAtA[i] = 0x20 } - if len(m.Config) > 0 { - for _, e := range m.Config { - l = e.Size() - n += 1 + l + sovGenerated(uint64(l)) + if m.AppliedSensitiveConfig != nil { + { + size, err := m.AppliedSensitiveConfig.MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintGenerated(dAtA, i, uint64(size)) } + i-- + dAtA[i] = 0x1a } - return n -} - -func (m *ConfigSetStatus) Size() (n int) { - if m == nil { - return 0 + if m.LastKnownGoodSchema != nil { + { + size, err := m.LastKnownGoodSchema.MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintGenerated(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0x12 } - var l int - _ = l - l = m.ConditionedStatus.Size() - n += 1 + l + sovGenerated(uint64(l)) - if len(m.Targets) > 0 { - for _, e := range m.Targets { - l = e.Size() - n += 1 + l + sovGenerated(uint64(l)) + { + size, err := m.ConditionedStatus.MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err } + i -= size + i = encodeVarintGenerated(dAtA, i, uint64(size)) } - return n + i-- + dAtA[i] = 0xa + return len(dAtA) - i, nil } -func (m *ConfigSpec) Size() (n int) { - if m == nil { - return 0 +func (m *Target) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) + if err != nil { + return nil, err } + return dAtA[:n], nil +} + +func (m *Target) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *Target) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i var l int _ = l - if m.Lifecycle != nil { - l = m.Lifecycle.Size() - n += 1 + l + sovGenerated(uint64(l)) + { + size, err := m.Status.MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintGenerated(dAtA, i, uint64(size)) } - n += 1 + sovGenerated(uint64(m.Priority)) - if m.Revertive != nil { - n += 2 + i-- + dAtA[i] = 0x1a + { + size, err := m.Spec.MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintGenerated(dAtA, i, uint64(size)) } - if len(m.Config) > 0 { - for _, e := range m.Config { - l = e.Size() - n += 1 + l + sovGenerated(uint64(l)) + i-- + dAtA[i] = 0x12 + { + size, err := m.ObjectMeta.MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err } + i -= size + i = encodeVarintGenerated(dAtA, i, uint64(size)) } - return n + i-- + dAtA[i] = 0xa + return len(dAtA) - i, nil } -func (m *ConfigStatus) Size() (n int) { - if m == nil { - return 0 +func (m *TargetList) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) + if err != nil { + return nil, err } + return dAtA[:n], nil +} + +func (m *TargetList) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *TargetList) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i var l int _ = l - l = m.ConditionedStatus.Size() - n += 1 + l + sovGenerated(uint64(l)) - if m.LastKnownGoodSchema != nil { - l = m.LastKnownGoodSchema.Size() - n += 1 + l + sovGenerated(uint64(l)) + if len(m.Items) > 0 { + for iNdEx := len(m.Items) - 1; iNdEx >= 0; iNdEx-- { + { + size, err := m.Items[iNdEx].MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintGenerated(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0x12 + } } - if m.AppliedConfig != nil { - l = m.AppliedConfig.Size() - n += 1 + l + sovGenerated(uint64(l)) + { + size, err := m.ListMeta.MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintGenerated(dAtA, i, uint64(size)) } - if m.DeviationGeneration != nil { - n += 1 + sovGenerated(uint64(*m.DeviationGeneration)) + i-- + dAtA[i] = 0xa + return len(dAtA) - i, nil +} + +func (m *TargetSpec) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) + if err != nil { + return nil, err } - return n + return dAtA[:n], nil } -func (m *ConfigStatusLastKnownGoodSchema) Size() (n int) { +func (m *TargetSpec) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *TargetSpec) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + { + size, err := m.TargetProfile.MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintGenerated(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0x1a + i -= len(m.Address) + copy(dAtA[i:], m.Address) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Address))) + i-- + dAtA[i] = 0x12 + i -= len(m.Provider) + copy(dAtA[i:], m.Provider) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Provider))) + i-- + dAtA[i] = 0xa + return len(dAtA) - i, nil +} + +func (m *TargetStatus) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *TargetStatus) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *TargetStatus) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + if m.UsedReferences != nil { + { + size, err := m.UsedReferences.MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintGenerated(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0x1a + } + if m.DiscoveryInfo != nil { + { + size, err := m.DiscoveryInfo.MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintGenerated(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0x12 + } + { + size, err := m.ConditionedStatus.MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintGenerated(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0xa + return len(dAtA) - i, nil +} + +func (m *TargetStatusUsedReferences) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *TargetStatusUsedReferences) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *TargetStatusUsedReferences) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + i -= len(m.SyncProfileResourceVersion) + copy(dAtA[i:], m.SyncProfileResourceVersion) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.SyncProfileResourceVersion))) + i-- + dAtA[i] = 0x22 + i -= len(m.ConnectionProfileResourceVersion) + copy(dAtA[i:], m.ConnectionProfileResourceVersion) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.ConnectionProfileResourceVersion))) + i-- + dAtA[i] = 0x1a + i -= len(m.TLSSecretResourceVersion) + copy(dAtA[i:], m.TLSSecretResourceVersion) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.TLSSecretResourceVersion))) + i-- + dAtA[i] = 0x12 + i -= len(m.SecretResourceVersion) + copy(dAtA[i:], m.SecretResourceVersion) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.SecretResourceVersion))) + i-- + dAtA[i] = 0xa + return len(dAtA) - i, nil +} + +func encodeVarintGenerated(dAtA []byte, offset int, v uint64) int { + offset -= sovGenerated(v) + base := offset + for v >= 1<<7 { + dAtA[offset] = uint8(v&0x7f | 0x80) + v >>= 7 + offset++ + } + dAtA[offset] = uint8(v) + return base +} + +func (m *Config) Size() (n int) { if m == nil { return 0 } var l int _ = l - l = len(m.Type) + l = m.ObjectMeta.Size() n += 1 + l + sovGenerated(uint64(l)) - l = len(m.Vendor) + l = m.Spec.Size() n += 1 + l + sovGenerated(uint64(l)) - l = len(m.Version) + l = m.Status.Size() n += 1 + l + sovGenerated(uint64(l)) return n } -func (m *Deviation) Size() (n int) { +func (m *ConfigBlame) Size() (n int) { if m == nil { return 0 } @@ -2340,7 +1874,7 @@ func (m *Deviation) Size() (n int) { return n } -func (m *DeviationList) Size() (n int) { +func (m *ConfigBlameList) Size() (n int) { if m == nil { return 0 } @@ -2357,63 +1891,61 @@ func (m *DeviationList) Size() (n int) { return n } -func (m *DeviationSpec) Size() (n int) { +func (m *ConfigBlameSpec) Size() (n int) { if m == nil { return 0 } var l int _ = l - if m.DeviationType != nil { - l = len(*m.DeviationType) - n += 1 + l + sovGenerated(uint64(l)) - } - if len(m.Deviations) > 0 { - for _, e := range m.Deviations { - l = e.Size() - n += 1 + l + sovGenerated(uint64(l)) - } - } return n } -func (m *DeviationStatus) Size() (n int) { +func (m *ConfigBlameStatus) Size() (n int) { if m == nil { return 0 } var l int _ = l - l = m.ConditionedStatus.Size() + l = m.Value.Size() n += 1 + l + sovGenerated(uint64(l)) return n } -func (m *Lifecycle) Size() (n int) { +func (m *ConfigBlob) Size() (n int) { if m == nil { return 0 } var l int _ = l - l = len(m.DeletionPolicy) + l = len(m.Path) + n += 1 + l + sovGenerated(uint64(l)) + l = m.Value.Size() n += 1 + l + sovGenerated(uint64(l)) return n } -func (m *RunningConfig) Size() (n int) { +func (m *ConfigDeviation) Size() (n int) { if m == nil { return 0 } var l int _ = l - l = m.ObjectMeta.Size() - n += 1 + l + sovGenerated(uint64(l)) - l = m.Spec.Size() + l = len(m.Path) n += 1 + l + sovGenerated(uint64(l)) - l = m.Status.Size() + if m.DesiredValue != nil { + l = len(*m.DesiredValue) + n += 1 + l + sovGenerated(uint64(l)) + } + if m.ActualValue != nil { + l = len(*m.ActualValue) + n += 1 + l + sovGenerated(uint64(l)) + } + l = len(m.Reason) n += 1 + l + sovGenerated(uint64(l)) return n } -func (m *RunningConfigList) Size() (n int) { +func (m *ConfigList) Size() (n int) { if m == nil { return 0 } @@ -2430,41 +1962,95 @@ func (m *RunningConfigList) Size() (n int) { return n } -func (m *RunningConfigSpec) Size() (n int) { +func (m *ConfigSet) Size() (n int) { if m == nil { return 0 } var l int _ = l + l = m.ObjectMeta.Size() + n += 1 + l + sovGenerated(uint64(l)) + l = m.Spec.Size() + n += 1 + l + sovGenerated(uint64(l)) + l = m.Status.Size() + n += 1 + l + sovGenerated(uint64(l)) return n } -func (m *RunningConfigStatus) Size() (n int) { +func (m *ConfigSetList) Size() (n int) { if m == nil { return 0 } var l int _ = l - l = m.Value.Size() + l = m.ListMeta.Size() n += 1 + l + sovGenerated(uint64(l)) + if len(m.Items) > 0 { + for _, e := range m.Items { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + } return n } -func (m *Target) Size() (n int) { +func (m *ConfigSetSpec) Size() (n int) { if m == nil { return 0 } var l int _ = l - if m.TargetSelector != nil { - l = m.TargetSelector.Size() + l = m.Target.Size() + n += 1 + l + sovGenerated(uint64(l)) + if m.Lifecycle != nil { + l = m.Lifecycle.Size() n += 1 + l + sovGenerated(uint64(l)) } - return n -} - -func (m *TargetStatus) Size() (n int) { - if m == nil { + n += 1 + sovGenerated(uint64(m.Priority)) + if m.Revertive != nil { + n += 2 + } + if len(m.Config) > 0 { + for _, e := range m.Config { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + } + return n +} + +func (m *ConfigSetStatus) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + l = m.ConditionedStatus.Size() + n += 1 + l + sovGenerated(uint64(l)) + if len(m.Targets) > 0 { + for _, e := range m.Targets { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + } + return n +} + +func (m *ConfigSetTarget) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + if m.TargetSelector != nil { + l = m.TargetSelector.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + return n +} + +func (m *ConfigSetTargetStatus) Size() (n int) { + if m == nil { return 0 } var l int @@ -2476,358 +2062,1858 @@ func (m *TargetStatus) Size() (n int) { return n } -func sovGenerated(x uint64) (n int) { - return (math_bits.Len64(x|1) + 6) / 7 -} -func sozGenerated(x uint64) (n int) { - return sovGenerated(uint64((x << 1) ^ uint64((int64(x) >> 63)))) -} -func (this *Config) String() string { - if this == nil { - return "nil" +func (m *ConfigSpec) Size() (n int) { + if m == nil { + return 0 } - s := strings.Join([]string{`&Config{`, - `ObjectMeta:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ObjectMeta), "ObjectMeta", "v1.ObjectMeta", 1), `&`, ``, 1) + `,`, - `Spec:` + strings.Replace(strings.Replace(this.Spec.String(), "ConfigSpec", "ConfigSpec", 1), `&`, ``, 1) + `,`, - `Status:` + strings.Replace(strings.Replace(this.Status.String(), "ConfigStatus", "ConfigStatus", 1), `&`, ``, 1) + `,`, - `}`, - }, "") - return s -} -func (this *ConfigBlame) String() string { - if this == nil { - return "nil" + var l int + _ = l + if m.Lifecycle != nil { + l = m.Lifecycle.Size() + n += 1 + l + sovGenerated(uint64(l)) } - s := strings.Join([]string{`&ConfigBlame{`, - `ObjectMeta:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ObjectMeta), "ObjectMeta", "v1.ObjectMeta", 1), `&`, ``, 1) + `,`, - `Spec:` + strings.Replace(strings.Replace(this.Spec.String(), "ConfigBlameSpec", "ConfigBlameSpec", 1), `&`, ``, 1) + `,`, - `Status:` + strings.Replace(strings.Replace(this.Status.String(), "ConfigBlameStatus", "ConfigBlameStatus", 1), `&`, ``, 1) + `,`, - `}`, - }, "") - return s -} -func (this *ConfigBlameList) String() string { - if this == nil { - return "nil" + n += 1 + sovGenerated(uint64(m.Priority)) + if m.Revertive != nil { + n += 2 } - repeatedStringForItems := "[]ConfigBlame{" - for _, f := range this.Items { - repeatedStringForItems += strings.Replace(strings.Replace(f.String(), "ConfigBlame", "ConfigBlame", 1), `&`, ``, 1) + "," + if len(m.Config) > 0 { + for _, e := range m.Config { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } } - repeatedStringForItems += "}" - s := strings.Join([]string{`&ConfigBlameList{`, - `ListMeta:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ListMeta), "ListMeta", "v1.ListMeta", 1), `&`, ``, 1) + `,`, - `Items:` + repeatedStringForItems + `,`, - `}`, - }, "") - return s + return n } -func (this *ConfigBlameSpec) String() string { - if this == nil { - return "nil" + +func (m *ConfigStatus) Size() (n int) { + if m == nil { + return 0 } - s := strings.Join([]string{`&ConfigBlameSpec{`, - `}`, - }, "") - return s -} -func (this *ConfigBlameStatus) String() string { - if this == nil { - return "nil" + var l int + _ = l + l = m.ConditionedStatus.Size() + n += 1 + l + sovGenerated(uint64(l)) + if m.LastKnownGoodSchema != nil { + l = m.LastKnownGoodSchema.Size() + n += 1 + l + sovGenerated(uint64(l)) } - s := strings.Join([]string{`&ConfigBlameStatus{`, - `Value:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Value), "RawExtension", "runtime.RawExtension", 1), `&`, ``, 1) + `,`, - `}`, - }, "") - return s + if m.AppliedConfig != nil { + l = m.AppliedConfig.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + if m.DeviationGeneration != nil { + n += 1 + sovGenerated(uint64(*m.DeviationGeneration)) + } + return n } -func (this *ConfigBlob) String() string { - if this == nil { - return "nil" + +func (m *ConfigStatusLastKnownGoodSchema) Size() (n int) { + if m == nil { + return 0 } - s := strings.Join([]string{`&ConfigBlob{`, - `Path:` + fmt.Sprintf("%v", this.Path) + `,`, - `Value:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Value), "RawExtension", "runtime.RawExtension", 1), `&`, ``, 1) + `,`, - `}`, - }, "") - return s + var l int + _ = l + l = len(m.Type) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.Vendor) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.Version) + n += 1 + l + sovGenerated(uint64(l)) + return n } -func (this *ConfigDeviation) String() string { - if this == nil { - return "nil" + +func (m *Deviation) Size() (n int) { + if m == nil { + return 0 } - s := strings.Join([]string{`&ConfigDeviation{`, - `Path:` + fmt.Sprintf("%v", this.Path) + `,`, - `DesiredValue:` + valueToStringGenerated(this.DesiredValue) + `,`, - `CurrentValue:` + valueToStringGenerated(this.ActualValue) + `,`, - `Reason:` + fmt.Sprintf("%v", this.Reason) + `,`, - `}`, - }, "") - return s + var l int + _ = l + l = m.ObjectMeta.Size() + n += 1 + l + sovGenerated(uint64(l)) + l = m.Spec.Size() + n += 1 + l + sovGenerated(uint64(l)) + l = m.Status.Size() + n += 1 + l + sovGenerated(uint64(l)) + return n } -func (this *ConfigList) String() string { - if this == nil { - return "nil" + +func (m *DeviationList) Size() (n int) { + if m == nil { + return 0 } - repeatedStringForItems := "[]Config{" - for _, f := range this.Items { - repeatedStringForItems += strings.Replace(strings.Replace(f.String(), "Config", "Config", 1), `&`, ``, 1) + "," + var l int + _ = l + l = m.ListMeta.Size() + n += 1 + l + sovGenerated(uint64(l)) + if len(m.Items) > 0 { + for _, e := range m.Items { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } } - repeatedStringForItems += "}" - s := strings.Join([]string{`&ConfigList{`, - `ListMeta:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ListMeta), "ListMeta", "v1.ListMeta", 1), `&`, ``, 1) + `,`, - `Items:` + repeatedStringForItems + `,`, - `}`, - }, "") - return s + return n } -func (this *ConfigSet) String() string { - if this == nil { - return "nil" + +func (m *DeviationSpec) Size() (n int) { + if m == nil { + return 0 } - s := strings.Join([]string{`&ConfigSet{`, - `ObjectMeta:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ObjectMeta), "ObjectMeta", "v1.ObjectMeta", 1), `&`, ``, 1) + `,`, - `Spec:` + strings.Replace(strings.Replace(this.Spec.String(), "ConfigSetSpec", "ConfigSetSpec", 1), `&`, ``, 1) + `,`, - `Status:` + strings.Replace(strings.Replace(this.Status.String(), "ConfigSetStatus", "ConfigSetStatus", 1), `&`, ``, 1) + `,`, - `}`, - }, "") - return s -} -func (this *ConfigSetList) String() string { - if this == nil { - return "nil" + var l int + _ = l + if m.DeviationType != nil { + l = len(*m.DeviationType) + n += 1 + l + sovGenerated(uint64(l)) } - repeatedStringForItems := "[]ConfigSet{" - for _, f := range this.Items { - repeatedStringForItems += strings.Replace(strings.Replace(f.String(), "ConfigSet", "ConfigSet", 1), `&`, ``, 1) + "," + if len(m.Deviations) > 0 { + for _, e := range m.Deviations { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } } - repeatedStringForItems += "}" - s := strings.Join([]string{`&ConfigSetList{`, - `ListMeta:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ListMeta), "ListMeta", "v1.ListMeta", 1), `&`, ``, 1) + `,`, - `Items:` + repeatedStringForItems + `,`, - `}`, - }, "") - return s + return n } -func (this *ConfigSetSpec) String() string { - if this == nil { - return "nil" + +func (m *DeviationStatus) Size() (n int) { + if m == nil { + return 0 } - repeatedStringForConfig := "[]ConfigBlob{" - for _, f := range this.Config { - repeatedStringForConfig += strings.Replace(strings.Replace(f.String(), "ConfigBlob", "ConfigBlob", 1), `&`, ``, 1) + "," - } - repeatedStringForConfig += "}" - s := strings.Join([]string{`&ConfigSetSpec{`, - `Target:` + strings.Replace(strings.Replace(this.Target.String(), "Target", "Target", 1), `&`, ``, 1) + `,`, - `Lifecycle:` + strings.Replace(this.Lifecycle.String(), "Lifecycle", "Lifecycle", 1) + `,`, - `Priority:` + fmt.Sprintf("%v", this.Priority) + `,`, - `Revertive:` + valueToStringGenerated(this.Revertive) + `,`, - `Config:` + repeatedStringForConfig + `,`, - `}`, - }, "") - return s -} -func (this *ConfigSetStatus) String() string { - if this == nil { - return "nil" - } - repeatedStringForTargets := "[]TargetStatus{" - for _, f := range this.Targets { - repeatedStringForTargets += strings.Replace(strings.Replace(f.String(), "TargetStatus", "TargetStatus", 1), `&`, ``, 1) + "," - } - repeatedStringForTargets += "}" - s := strings.Join([]string{`&ConfigSetStatus{`, - `ConditionedStatus:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ConditionedStatus), "ConditionedStatus", "v1alpha1.ConditionedStatus", 1), `&`, ``, 1) + `,`, - `Targets:` + repeatedStringForTargets + `,`, - `}`, - }, "") - return s + var l int + _ = l + l = m.ConditionedStatus.Size() + n += 1 + l + sovGenerated(uint64(l)) + return n } -func (this *ConfigSpec) String() string { - if this == nil { - return "nil" - } - repeatedStringForConfig := "[]ConfigBlob{" - for _, f := range this.Config { - repeatedStringForConfig += strings.Replace(strings.Replace(f.String(), "ConfigBlob", "ConfigBlob", 1), `&`, ``, 1) + "," + +func (m *DiscoveryInfo) Size() (n int) { + if m == nil { + return 0 } - repeatedStringForConfig += "}" - s := strings.Join([]string{`&ConfigSpec{`, - `Lifecycle:` + strings.Replace(this.Lifecycle.String(), "Lifecycle", "Lifecycle", 1) + `,`, - `Priority:` + fmt.Sprintf("%v", this.Priority) + `,`, - `Revertive:` + valueToStringGenerated(this.Revertive) + `,`, - `Config:` + repeatedStringForConfig + `,`, - `}`, - }, "") - return s -} -func (this *ConfigStatus) String() string { - if this == nil { - return "nil" + var l int + _ = l + l = len(m.Protocol) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.Provider) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.Version) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.Hostname) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.Platform) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.MacAddress) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.SerialNumber) + n += 1 + l + sovGenerated(uint64(l)) + if len(m.SupportedEncodings) > 0 { + for _, s := range m.SupportedEncodings { + l = len(s) + n += 1 + l + sovGenerated(uint64(l)) + } } - s := strings.Join([]string{`&ConfigStatus{`, - `ConditionedStatus:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ConditionedStatus), "ConditionedStatus", "v1alpha1.ConditionedStatus", 1), `&`, ``, 1) + `,`, - `LastKnownGoodSchema:` + strings.Replace(this.LastKnownGoodSchema.String(), "ConfigStatusLastKnownGoodSchema", "ConfigStatusLastKnownGoodSchema", 1) + `,`, - `AppliedConfig:` + strings.Replace(this.AppliedConfig.String(), "ConfigSpec", "ConfigSpec", 1) + `,`, - `DeviationGeneration:` + valueToStringGenerated(this.DeviationGeneration) + `,`, - `}`, - }, "") - return s + return n } -func (this *ConfigStatusLastKnownGoodSchema) String() string { - if this == nil { - return "nil" + +func (m *Lifecycle) Size() (n int) { + if m == nil { + return 0 } - s := strings.Join([]string{`&ConfigStatusLastKnownGoodSchema{`, - `Type:` + fmt.Sprintf("%v", this.Type) + `,`, - `Vendor:` + fmt.Sprintf("%v", this.Vendor) + `,`, - `Version:` + fmt.Sprintf("%v", this.Version) + `,`, - `}`, - }, "") - return s + var l int + _ = l + l = len(m.DeletionPolicy) + n += 1 + l + sovGenerated(uint64(l)) + return n } -func (this *Deviation) String() string { - if this == nil { - return "nil" + +func (m *RunningConfig) Size() (n int) { + if m == nil { + return 0 } - s := strings.Join([]string{`&Deviation{`, - `ObjectMeta:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ObjectMeta), "ObjectMeta", "v1.ObjectMeta", 1), `&`, ``, 1) + `,`, - `Spec:` + strings.Replace(strings.Replace(this.Spec.String(), "DeviationSpec", "DeviationSpec", 1), `&`, ``, 1) + `,`, - `Status:` + strings.Replace(strings.Replace(this.Status.String(), "DeviationStatus", "DeviationStatus", 1), `&`, ``, 1) + `,`, - `}`, - }, "") - return s + var l int + _ = l + l = m.ObjectMeta.Size() + n += 1 + l + sovGenerated(uint64(l)) + l = m.Spec.Size() + n += 1 + l + sovGenerated(uint64(l)) + l = m.Status.Size() + n += 1 + l + sovGenerated(uint64(l)) + return n } -func (this *DeviationList) String() string { - if this == nil { - return "nil" + +func (m *RunningConfigList) Size() (n int) { + if m == nil { + return 0 } - repeatedStringForItems := "[]Deviation{" - for _, f := range this.Items { - repeatedStringForItems += strings.Replace(strings.Replace(f.String(), "Deviation", "Deviation", 1), `&`, ``, 1) + "," + var l int + _ = l + l = m.ListMeta.Size() + n += 1 + l + sovGenerated(uint64(l)) + if len(m.Items) > 0 { + for _, e := range m.Items { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } } - repeatedStringForItems += "}" - s := strings.Join([]string{`&DeviationList{`, - `ListMeta:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ListMeta), "ListMeta", "v1.ListMeta", 1), `&`, ``, 1) + `,`, - `Items:` + repeatedStringForItems + `,`, - `}`, - }, "") - return s + return n } -func (this *DeviationSpec) String() string { - if this == nil { - return "nil" - } - repeatedStringForDeviations := "[]ConfigDeviation{" - for _, f := range this.Deviations { - repeatedStringForDeviations += strings.Replace(strings.Replace(f.String(), "ConfigDeviation", "ConfigDeviation", 1), `&`, ``, 1) + "," + +func (m *RunningConfigSpec) Size() (n int) { + if m == nil { + return 0 } - repeatedStringForDeviations += "}" - s := strings.Join([]string{`&DeviationSpec{`, - `DeviationType:` + valueToStringGenerated(this.DeviationType) + `,`, - `Deviations:` + repeatedStringForDeviations + `,`, - `}`, - }, "") - return s + var l int + _ = l + return n } -func (this *DeviationStatus) String() string { - if this == nil { - return "nil" + +func (m *RunningConfigStatus) Size() (n int) { + if m == nil { + return 0 } - s := strings.Join([]string{`&DeviationStatus{`, - `ConditionedStatus:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ConditionedStatus), "ConditionedStatus", "v1alpha1.ConditionedStatus", 1), `&`, ``, 1) + `,`, - `}`, - }, "") - return s + var l int + _ = l + l = m.Value.Size() + n += 1 + l + sovGenerated(uint64(l)) + return n } -func (this *Lifecycle) String() string { - if this == nil { - return "nil" + +func (m *SensitiveConfig) Size() (n int) { + if m == nil { + return 0 } - s := strings.Join([]string{`&Lifecycle{`, - `DeletionPolicy:` + fmt.Sprintf("%v", this.DeletionPolicy) + `,`, - `}`, - }, "") - return s + var l int + _ = l + l = m.ObjectMeta.Size() + n += 1 + l + sovGenerated(uint64(l)) + l = m.Spec.Size() + n += 1 + l + sovGenerated(uint64(l)) + l = m.Status.Size() + n += 1 + l + sovGenerated(uint64(l)) + return n } -func (this *RunningConfig) String() string { - if this == nil { - return "nil" + +func (m *SensitiveConfigData) Size() (n int) { + if m == nil { + return 0 } - s := strings.Join([]string{`&RunningConfig{`, - `ObjectMeta:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ObjectMeta), "ObjectMeta", "v1.ObjectMeta", 1), `&`, ``, 1) + `,`, - `Spec:` + strings.Replace(strings.Replace(this.Spec.String(), "RunningConfigSpec", "RunningConfigSpec", 1), `&`, ``, 1) + `,`, - `Status:` + strings.Replace(strings.Replace(this.Status.String(), "RunningConfigStatus", "RunningConfigStatus", 1), `&`, ``, 1) + `,`, - `}`, - }, "") - return s + var l int + _ = l + l = len(m.Path) + n += 1 + l + sovGenerated(uint64(l)) + l = m.SecretKeyRef.Size() + n += 1 + l + sovGenerated(uint64(l)) + return n } -func (this *RunningConfigList) String() string { - if this == nil { - return "nil" + +func (m *SensitiveConfigList) Size() (n int) { + if m == nil { + return 0 } - repeatedStringForItems := "[]RunningConfig{" - for _, f := range this.Items { - repeatedStringForItems += strings.Replace(strings.Replace(f.String(), "RunningConfig", "RunningConfig", 1), `&`, ``, 1) + "," + var l int + _ = l + l = m.ListMeta.Size() + n += 1 + l + sovGenerated(uint64(l)) + if len(m.Items) > 0 { + for _, e := range m.Items { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } } - repeatedStringForItems += "}" - s := strings.Join([]string{`&RunningConfigList{`, - `ListMeta:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ListMeta), "ListMeta", "v1.ListMeta", 1), `&`, ``, 1) + `,`, - `Items:` + repeatedStringForItems + `,`, - `}`, - }, "") - return s + return n } -func (this *RunningConfigSpec) String() string { - if this == nil { - return "nil" + +func (m *SensitiveConfigSpec) Size() (n int) { + if m == nil { + return 0 } - s := strings.Join([]string{`&RunningConfigSpec{`, - `}`, - }, "") + var l int + _ = l + if m.Lifecycle != nil { + l = m.Lifecycle.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + n += 1 + sovGenerated(uint64(m.Priority)) + if m.Revertive != nil { + n += 2 + } + if len(m.Config) > 0 { + for _, e := range m.Config { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + } + return n +} + +func (m *SensitiveConfigStatus) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + l = m.ConditionedStatus.Size() + n += 1 + l + sovGenerated(uint64(l)) + if m.LastKnownGoodSchema != nil { + l = m.LastKnownGoodSchema.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + if m.AppliedSensitiveConfig != nil { + l = m.AppliedSensitiveConfig.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + if m.DeviationGeneration != nil { + n += 1 + sovGenerated(uint64(*m.DeviationGeneration)) + } + return n +} + +func (m *Target) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + l = m.ObjectMeta.Size() + n += 1 + l + sovGenerated(uint64(l)) + l = m.Spec.Size() + n += 1 + l + sovGenerated(uint64(l)) + l = m.Status.Size() + n += 1 + l + sovGenerated(uint64(l)) + return n +} + +func (m *TargetList) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + l = m.ListMeta.Size() + n += 1 + l + sovGenerated(uint64(l)) + if len(m.Items) > 0 { + for _, e := range m.Items { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + } + return n +} + +func (m *TargetSpec) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + l = len(m.Provider) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.Address) + n += 1 + l + sovGenerated(uint64(l)) + l = m.TargetProfile.Size() + n += 1 + l + sovGenerated(uint64(l)) + return n +} + +func (m *TargetStatus) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + l = m.ConditionedStatus.Size() + n += 1 + l + sovGenerated(uint64(l)) + if m.DiscoveryInfo != nil { + l = m.DiscoveryInfo.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + if m.UsedReferences != nil { + l = m.UsedReferences.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + return n +} + +func (m *TargetStatusUsedReferences) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + l = len(m.SecretResourceVersion) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.TLSSecretResourceVersion) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.ConnectionProfileResourceVersion) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.SyncProfileResourceVersion) + n += 1 + l + sovGenerated(uint64(l)) + return n +} + +func sovGenerated(x uint64) (n int) { + return (math_bits.Len64(x|1) + 6) / 7 +} +func sozGenerated(x uint64) (n int) { + return sovGenerated(uint64((x << 1) ^ uint64((int64(x) >> 63)))) +} + +func (this *Config) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&Config{`, + `ObjectMeta:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ObjectMeta), "ObjectMeta", "v1.ObjectMeta", 1), `&`, ``, 1) + `,`, + `Spec:` + strings.Replace(strings.Replace(this.Spec.String(), "ConfigSpec", "ConfigSpec", 1), `&`, ``, 1) + `,`, + `Status:` + strings.Replace(strings.Replace(this.Status.String(), "ConfigStatus", "ConfigStatus", 1), `&`, ``, 1) + `,`, + `}`, + }, "") return s } -func (this *RunningConfigStatus) String() string { +func (this *ConfigBlame) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&ConfigBlame{`, + `ObjectMeta:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ObjectMeta), "ObjectMeta", "v1.ObjectMeta", 1), `&`, ``, 1) + `,`, + `Spec:` + strings.Replace(strings.Replace(this.Spec.String(), "ConfigBlameSpec", "ConfigBlameSpec", 1), `&`, ``, 1) + `,`, + `Status:` + strings.Replace(strings.Replace(this.Status.String(), "ConfigBlameStatus", "ConfigBlameStatus", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func (this *ConfigBlameList) String() string { + if this == nil { + return "nil" + } + repeatedStringForItems := "[]ConfigBlame{" + for _, f := range this.Items { + repeatedStringForItems += strings.Replace(strings.Replace(f.String(), "ConfigBlame", "ConfigBlame", 1), `&`, ``, 1) + "," + } + repeatedStringForItems += "}" + s := strings.Join([]string{`&ConfigBlameList{`, + `ListMeta:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ListMeta), "ListMeta", "v1.ListMeta", 1), `&`, ``, 1) + `,`, + `Items:` + repeatedStringForItems + `,`, + `}`, + }, "") + return s +} +func (this *ConfigBlameSpec) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&ConfigBlameSpec{`, + `}`, + }, "") + return s +} +func (this *ConfigBlameStatus) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&ConfigBlameStatus{`, + `Value:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Value), "RawExtension", "runtime.RawExtension", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func (this *ConfigBlob) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&ConfigBlob{`, + `Path:` + fmt.Sprintf("%v", this.Path) + `,`, + `Value:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Value), "RawExtension", "runtime.RawExtension", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func (this *ConfigDeviation) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&ConfigDeviation{`, + `Path:` + fmt.Sprintf("%v", this.Path) + `,`, + `DesiredValue:` + valueToStringGenerated(this.DesiredValue) + `,`, + `ActualValue:` + valueToStringGenerated(this.ActualValue) + `,`, + `Reason:` + fmt.Sprintf("%v", this.Reason) + `,`, + `}`, + }, "") + return s +} +func (this *ConfigList) String() string { + if this == nil { + return "nil" + } + repeatedStringForItems := "[]Config{" + for _, f := range this.Items { + repeatedStringForItems += strings.Replace(strings.Replace(f.String(), "Config", "Config", 1), `&`, ``, 1) + "," + } + repeatedStringForItems += "}" + s := strings.Join([]string{`&ConfigList{`, + `ListMeta:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ListMeta), "ListMeta", "v1.ListMeta", 1), `&`, ``, 1) + `,`, + `Items:` + repeatedStringForItems + `,`, + `}`, + }, "") + return s +} +func (this *ConfigSet) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&ConfigSet{`, + `ObjectMeta:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ObjectMeta), "ObjectMeta", "v1.ObjectMeta", 1), `&`, ``, 1) + `,`, + `Spec:` + strings.Replace(strings.Replace(this.Spec.String(), "ConfigSetSpec", "ConfigSetSpec", 1), `&`, ``, 1) + `,`, + `Status:` + strings.Replace(strings.Replace(this.Status.String(), "ConfigSetStatus", "ConfigSetStatus", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func (this *ConfigSetList) String() string { if this == nil { return "nil" } - s := strings.Join([]string{`&RunningConfigStatus{`, - `Value:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Value), "RawExtension", "runtime.RawExtension", 1), `&`, ``, 1) + `,`, - `}`, - }, "") - return s -} -func (this *Target) String() string { - if this == nil { - return "nil" + repeatedStringForItems := "[]ConfigSet{" + for _, f := range this.Items { + repeatedStringForItems += strings.Replace(strings.Replace(f.String(), "ConfigSet", "ConfigSet", 1), `&`, ``, 1) + "," + } + repeatedStringForItems += "}" + s := strings.Join([]string{`&ConfigSetList{`, + `ListMeta:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ListMeta), "ListMeta", "v1.ListMeta", 1), `&`, ``, 1) + `,`, + `Items:` + repeatedStringForItems + `,`, + `}`, + }, "") + return s +} +func (this *ConfigSetSpec) String() string { + if this == nil { + return "nil" + } + repeatedStringForConfig := "[]ConfigBlob{" + for _, f := range this.Config { + repeatedStringForConfig += strings.Replace(strings.Replace(f.String(), "ConfigBlob", "ConfigBlob", 1), `&`, ``, 1) + "," + } + repeatedStringForConfig += "}" + s := strings.Join([]string{`&ConfigSetSpec{`, + `Target:` + strings.Replace(strings.Replace(this.Target.String(), "Target", "Target", 1), `&`, ``, 1) + `,`, + `Lifecycle:` + strings.Replace(this.Lifecycle.String(), "Lifecycle", "Lifecycle", 1) + `,`, + `Priority:` + fmt.Sprintf("%v", this.Priority) + `,`, + `Revertive:` + valueToStringGenerated(this.Revertive) + `,`, + `Config:` + repeatedStringForConfig + `,`, + `}`, + }, "") + return s +} +func (this *ConfigSetStatus) String() string { + if this == nil { + return "nil" + } + repeatedStringForTargets := "[]ConfigSetTargetStatus{" + for _, f := range this.Targets { + repeatedStringForTargets += strings.Replace(strings.Replace(f.String(), "ConfigSetTargetStatus", "ConfigSetTargetStatus", 1), `&`, ``, 1) + "," + } + repeatedStringForTargets += "}" + s := strings.Join([]string{`&ConfigSetStatus{`, + `ConditionedStatus:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ConditionedStatus), "ConditionedStatus", "v1alpha1.ConditionedStatus", 1), `&`, ``, 1) + `,`, + `Targets:` + repeatedStringForTargets + `,`, + `}`, + }, "") + return s +} +func (this *ConfigSetTarget) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&ConfigSetTarget{`, + `TargetSelector:` + strings.Replace(fmt.Sprintf("%v", this.TargetSelector), "LabelSelector", "v1.LabelSelector", 1) + `,`, + `}`, + }, "") + return s +} +func (this *ConfigSetTargetStatus) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&ConfigSetTargetStatus{`, + `Name:` + fmt.Sprintf("%v", this.Name) + `,`, + `Condition:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Condition), "Condition", "v1alpha1.Condition", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func (this *ConfigSpec) String() string { + if this == nil { + return "nil" + } + repeatedStringForConfig := "[]ConfigBlob{" + for _, f := range this.Config { + repeatedStringForConfig += strings.Replace(strings.Replace(f.String(), "ConfigBlob", "ConfigBlob", 1), `&`, ``, 1) + "," + } + repeatedStringForConfig += "}" + s := strings.Join([]string{`&ConfigSpec{`, + `Lifecycle:` + strings.Replace(this.Lifecycle.String(), "Lifecycle", "Lifecycle", 1) + `,`, + `Priority:` + fmt.Sprintf("%v", this.Priority) + `,`, + `Revertive:` + valueToStringGenerated(this.Revertive) + `,`, + `Config:` + repeatedStringForConfig + `,`, + `}`, + }, "") + return s +} +func (this *ConfigStatus) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&ConfigStatus{`, + `ConditionedStatus:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ConditionedStatus), "ConditionedStatus", "v1alpha1.ConditionedStatus", 1), `&`, ``, 1) + `,`, + `LastKnownGoodSchema:` + strings.Replace(this.LastKnownGoodSchema.String(), "ConfigStatusLastKnownGoodSchema", "ConfigStatusLastKnownGoodSchema", 1) + `,`, + `AppliedConfig:` + strings.Replace(this.AppliedConfig.String(), "ConfigSpec", "ConfigSpec", 1) + `,`, + `DeviationGeneration:` + valueToStringGenerated(this.DeviationGeneration) + `,`, + `}`, + }, "") + return s +} +func (this *ConfigStatusLastKnownGoodSchema) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&ConfigStatusLastKnownGoodSchema{`, + `Type:` + fmt.Sprintf("%v", this.Type) + `,`, + `Vendor:` + fmt.Sprintf("%v", this.Vendor) + `,`, + `Version:` + fmt.Sprintf("%v", this.Version) + `,`, + `}`, + }, "") + return s +} +func (this *Deviation) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&Deviation{`, + `ObjectMeta:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ObjectMeta), "ObjectMeta", "v1.ObjectMeta", 1), `&`, ``, 1) + `,`, + `Spec:` + strings.Replace(strings.Replace(this.Spec.String(), "DeviationSpec", "DeviationSpec", 1), `&`, ``, 1) + `,`, + `Status:` + strings.Replace(strings.Replace(this.Status.String(), "DeviationStatus", "DeviationStatus", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func (this *DeviationList) String() string { + if this == nil { + return "nil" + } + repeatedStringForItems := "[]Deviation{" + for _, f := range this.Items { + repeatedStringForItems += strings.Replace(strings.Replace(f.String(), "Deviation", "Deviation", 1), `&`, ``, 1) + "," + } + repeatedStringForItems += "}" + s := strings.Join([]string{`&DeviationList{`, + `ListMeta:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ListMeta), "ListMeta", "v1.ListMeta", 1), `&`, ``, 1) + `,`, + `Items:` + repeatedStringForItems + `,`, + `}`, + }, "") + return s +} +func (this *DeviationSpec) String() string { + if this == nil { + return "nil" + } + repeatedStringForDeviations := "[]ConfigDeviation{" + for _, f := range this.Deviations { + repeatedStringForDeviations += strings.Replace(strings.Replace(f.String(), "ConfigDeviation", "ConfigDeviation", 1), `&`, ``, 1) + "," + } + repeatedStringForDeviations += "}" + s := strings.Join([]string{`&DeviationSpec{`, + `DeviationType:` + valueToStringGenerated(this.DeviationType) + `,`, + `Deviations:` + repeatedStringForDeviations + `,`, + `}`, + }, "") + return s +} +func (this *DeviationStatus) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&DeviationStatus{`, + `ConditionedStatus:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ConditionedStatus), "ConditionedStatus", "v1alpha1.ConditionedStatus", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func (this *DiscoveryInfo) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&DiscoveryInfo{`, + `Protocol:` + fmt.Sprintf("%v", this.Protocol) + `,`, + `Provider:` + fmt.Sprintf("%v", this.Provider) + `,`, + `Version:` + fmt.Sprintf("%v", this.Version) + `,`, + `Hostname:` + fmt.Sprintf("%v", this.Hostname) + `,`, + `Platform:` + fmt.Sprintf("%v", this.Platform) + `,`, + `MacAddress:` + fmt.Sprintf("%v", this.MacAddress) + `,`, + `SerialNumber:` + fmt.Sprintf("%v", this.SerialNumber) + `,`, + `SupportedEncodings:` + fmt.Sprintf("%v", this.SupportedEncodings) + `,`, + `}`, + }, "") + return s +} +func (this *Lifecycle) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&Lifecycle{`, + `DeletionPolicy:` + fmt.Sprintf("%v", this.DeletionPolicy) + `,`, + `}`, + }, "") + return s +} +func (this *RunningConfig) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&RunningConfig{`, + `ObjectMeta:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ObjectMeta), "ObjectMeta", "v1.ObjectMeta", 1), `&`, ``, 1) + `,`, + `Spec:` + strings.Replace(strings.Replace(this.Spec.String(), "RunningConfigSpec", "RunningConfigSpec", 1), `&`, ``, 1) + `,`, + `Status:` + strings.Replace(strings.Replace(this.Status.String(), "RunningConfigStatus", "RunningConfigStatus", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func (this *RunningConfigList) String() string { + if this == nil { + return "nil" + } + repeatedStringForItems := "[]RunningConfig{" + for _, f := range this.Items { + repeatedStringForItems += strings.Replace(strings.Replace(f.String(), "RunningConfig", "RunningConfig", 1), `&`, ``, 1) + "," + } + repeatedStringForItems += "}" + s := strings.Join([]string{`&RunningConfigList{`, + `ListMeta:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ListMeta), "ListMeta", "v1.ListMeta", 1), `&`, ``, 1) + `,`, + `Items:` + repeatedStringForItems + `,`, + `}`, + }, "") + return s +} +func (this *RunningConfigSpec) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&RunningConfigSpec{`, + `}`, + }, "") + return s +} +func (this *RunningConfigStatus) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&RunningConfigStatus{`, + `Value:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Value), "RawExtension", "runtime.RawExtension", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func (this *SensitiveConfig) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&SensitiveConfig{`, + `ObjectMeta:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ObjectMeta), "ObjectMeta", "v1.ObjectMeta", 1), `&`, ``, 1) + `,`, + `Spec:` + strings.Replace(strings.Replace(this.Spec.String(), "SensitiveConfigSpec", "SensitiveConfigSpec", 1), `&`, ``, 1) + `,`, + `Status:` + strings.Replace(strings.Replace(this.Status.String(), "SensitiveConfigStatus", "SensitiveConfigStatus", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func (this *SensitiveConfigData) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&SensitiveConfigData{`, + `Path:` + fmt.Sprintf("%v", this.Path) + `,`, + `SecretKeyRef:` + strings.Replace(strings.Replace(this.SecretKeyRef.String(), "SecretKeySelector", "SecretKeySelector", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func (this *SensitiveConfigList) String() string { + if this == nil { + return "nil" + } + repeatedStringForItems := "[]SensitiveConfig{" + for _, f := range this.Items { + repeatedStringForItems += strings.Replace(strings.Replace(f.String(), "SensitiveConfig", "SensitiveConfig", 1), `&`, ``, 1) + "," + } + repeatedStringForItems += "}" + s := strings.Join([]string{`&SensitiveConfigList{`, + `ListMeta:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ListMeta), "ListMeta", "v1.ListMeta", 1), `&`, ``, 1) + `,`, + `Items:` + repeatedStringForItems + `,`, + `}`, + }, "") + return s +} +func (this *SensitiveConfigSpec) String() string { + if this == nil { + return "nil" + } + repeatedStringForConfig := "[]SensitiveConfigData{" + for _, f := range this.Config { + repeatedStringForConfig += strings.Replace(strings.Replace(f.String(), "SensitiveConfigData", "SensitiveConfigData", 1), `&`, ``, 1) + "," + } + repeatedStringForConfig += "}" + s := strings.Join([]string{`&SensitiveConfigSpec{`, + `Lifecycle:` + strings.Replace(this.Lifecycle.String(), "Lifecycle", "Lifecycle", 1) + `,`, + `Priority:` + fmt.Sprintf("%v", this.Priority) + `,`, + `Revertive:` + valueToStringGenerated(this.Revertive) + `,`, + `Config:` + repeatedStringForConfig + `,`, + `}`, + }, "") + return s +} +func (this *SensitiveConfigStatus) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&SensitiveConfigStatus{`, + `ConditionedStatus:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ConditionedStatus), "ConditionedStatus", "v1alpha1.ConditionedStatus", 1), `&`, ``, 1) + `,`, + `LastKnownGoodSchema:` + strings.Replace(this.LastKnownGoodSchema.String(), "ConfigStatusLastKnownGoodSchema", "ConfigStatusLastKnownGoodSchema", 1) + `,`, + `AppliedSensitiveConfig:` + strings.Replace(this.AppliedSensitiveConfig.String(), "SensitiveConfigSpec", "SensitiveConfigSpec", 1) + `,`, + `DeviationGeneration:` + valueToStringGenerated(this.DeviationGeneration) + `,`, + `}`, + }, "") + return s +} +func (this *Target) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&Target{`, + `ObjectMeta:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ObjectMeta), "ObjectMeta", "v1.ObjectMeta", 1), `&`, ``, 1) + `,`, + `Spec:` + strings.Replace(strings.Replace(this.Spec.String(), "TargetSpec", "TargetSpec", 1), `&`, ``, 1) + `,`, + `Status:` + strings.Replace(strings.Replace(this.Status.String(), "TargetStatus", "TargetStatus", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func (this *TargetList) String() string { + if this == nil { + return "nil" + } + repeatedStringForItems := "[]Target{" + for _, f := range this.Items { + repeatedStringForItems += strings.Replace(strings.Replace(f.String(), "Target", "Target", 1), `&`, ``, 1) + "," + } + repeatedStringForItems += "}" + s := strings.Join([]string{`&TargetList{`, + `ListMeta:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ListMeta), "ListMeta", "v1.ListMeta", 1), `&`, ``, 1) + `,`, + `Items:` + repeatedStringForItems + `,`, + `}`, + }, "") + return s +} +func (this *TargetSpec) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&TargetSpec{`, + `Provider:` + fmt.Sprintf("%v", this.Provider) + `,`, + `Address:` + fmt.Sprintf("%v", this.Address) + `,`, + `TargetProfile:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.TargetProfile), "TargetProfile", "v1alpha11.TargetProfile", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func (this *TargetStatus) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&TargetStatus{`, + `ConditionedStatus:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ConditionedStatus), "ConditionedStatus", "v1alpha1.ConditionedStatus", 1), `&`, ``, 1) + `,`, + `DiscoveryInfo:` + strings.Replace(this.DiscoveryInfo.String(), "DiscoveryInfo", "DiscoveryInfo", 1) + `,`, + `UsedReferences:` + strings.Replace(this.UsedReferences.String(), "TargetStatusUsedReferences", "TargetStatusUsedReferences", 1) + `,`, + `}`, + }, "") + return s +} +func (this *TargetStatusUsedReferences) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&TargetStatusUsedReferences{`, + `SecretResourceVersion:` + fmt.Sprintf("%v", this.SecretResourceVersion) + `,`, + `TLSSecretResourceVersion:` + fmt.Sprintf("%v", this.TLSSecretResourceVersion) + `,`, + `ConnectionProfileResourceVersion:` + fmt.Sprintf("%v", this.ConnectionProfileResourceVersion) + `,`, + `SyncProfileResourceVersion:` + fmt.Sprintf("%v", this.SyncProfileResourceVersion) + `,`, + `}`, + }, "") + return s +} +func valueToStringGenerated(v interface{}) string { + rv := reflect.ValueOf(v) + if rv.IsNil() { + return "nil" + } + pv := reflect.Indirect(rv).Interface() + return fmt.Sprintf("*%v", pv) +} +func (m *Config) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: Config: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: Config: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return ErrInvalidLengthGenerated + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Spec", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return ErrInvalidLengthGenerated + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.Spec.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return ErrInvalidLengthGenerated + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.Status.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *ConfigBlame) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: ConfigBlame: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: ConfigBlame: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return ErrInvalidLengthGenerated + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Spec", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return ErrInvalidLengthGenerated + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.Spec.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return ErrInvalidLengthGenerated + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.Status.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *ConfigBlameList) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: ConfigBlameList: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: ConfigBlameList: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ListMeta", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return ErrInvalidLengthGenerated + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return ErrInvalidLengthGenerated + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Items = append(m.Items, ConfigBlame{}) + if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *ConfigBlameSpec) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: ConfigBlameSpec: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: ConfigBlameSpec: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *ConfigBlameStatus) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: ConfigBlameStatus: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: ConfigBlameStatus: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Value", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return ErrInvalidLengthGenerated + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.Value.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *ConfigBlob) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: ConfigBlob: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: ConfigBlob: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Path", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return ErrInvalidLengthGenerated + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Path = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Value", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return ErrInvalidLengthGenerated + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.Value.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *ConfigDeviation) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: ConfigDeviation: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: ConfigDeviation: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Path", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return ErrInvalidLengthGenerated + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Path = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field DesiredValue", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return ErrInvalidLengthGenerated + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + s := string(dAtA[iNdEx:postIndex]) + m.DesiredValue = &s + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ActualValue", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return ErrInvalidLengthGenerated + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + s := string(dAtA[iNdEx:postIndex]) + m.ActualValue = &s + iNdEx = postIndex + case 4: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Reason", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return ErrInvalidLengthGenerated + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Reason = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF } - s := strings.Join([]string{`&Target{`, - `TargetSelector:` + strings.Replace(fmt.Sprintf("%v", this.TargetSelector), "LabelSelector", "v1.LabelSelector", 1) + `,`, - `}`, - }, "") - return s + return nil } -func (this *TargetStatus) String() string { - if this == nil { - return "nil" +func (m *ConfigList) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: ConfigList: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: ConfigList: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ListMeta", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return ErrInvalidLengthGenerated + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return ErrInvalidLengthGenerated + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Items = append(m.Items, Config{}) + if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } } - s := strings.Join([]string{`&TargetStatus{`, - `Name:` + fmt.Sprintf("%v", this.Name) + `,`, - `Condition:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Condition), "Condition", "v1alpha1.Condition", 1), `&`, ``, 1) + `,`, - `}`, - }, "") - return s -} -func valueToStringGenerated(v interface{}) string { - rv := reflect.ValueOf(v) - if rv.IsNil() { - return "nil" + + if iNdEx > l { + return io.ErrUnexpectedEOF } - pv := reflect.Indirect(rv).Interface() - return fmt.Sprintf("*%v", pv) + return nil } -func (m *Config) Unmarshal(dAtA []byte) error { +func (m *ConfigSet) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -2850,10 +3936,10 @@ func (m *Config) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: Config: wiretype end group for non-group") + return fmt.Errorf("proto: ConfigSet: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: Config: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: ConfigSet: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: @@ -2976,7 +4062,7 @@ func (m *Config) Unmarshal(dAtA []byte) error { } return nil } -func (m *ConfigBlame) Unmarshal(dAtA []byte) error { +func (m *ConfigSetList) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -2999,15 +4085,15 @@ func (m *ConfigBlame) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: ConfigBlame: wiretype end group for non-group") + return fmt.Errorf("proto: ConfigSetList: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: ConfigBlame: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: ConfigSetList: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field ListMeta", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -3034,46 +4120,13 @@ func (m *ConfigBlame) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Spec", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - msglen |= int(b&0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + msglen - if postIndex < 0 { - return ErrInvalidLengthGenerated - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - if err := m.Spec.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - case 3: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -3100,7 +4153,8 @@ func (m *ConfigBlame) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Status.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + m.Items = append(m.Items, ConfigSet{}) + if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -3125,7 +4179,7 @@ func (m *ConfigBlame) Unmarshal(dAtA []byte) error { } return nil } -func (m *ConfigBlameList) Unmarshal(dAtA []byte) error { +func (m *ConfigSetSpec) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -3148,15 +4202,48 @@ func (m *ConfigBlameList) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: ConfigBlameList: wiretype end group for non-group") + return fmt.Errorf("proto: ConfigSetSpec: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: ConfigBlameList: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: ConfigSetSpec: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ListMeta", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Target", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return ErrInvalidLengthGenerated + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.Target.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Lifecycle", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -3183,13 +4270,56 @@ func (m *ConfigBlameList) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + if m.Lifecycle == nil { + m.Lifecycle = &Lifecycle{} + } + if err := m.Lifecycle.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex - case 2: + case 3: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Priority", wireType) + } + m.Priority = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.Priority |= int64(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 4: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Revertive", wireType) + } + var v int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + b := bool(v != 0) + m.Revertive = &b + case 5: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Config", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -3216,8 +4346,8 @@ func (m *ConfigBlameList) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Items = append(m.Items, ConfigBlame{}) - if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + m.Config = append(m.Config, ConfigBlob{}) + if err := m.Config[len(m.Config)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -3242,7 +4372,7 @@ func (m *ConfigBlameList) Unmarshal(dAtA []byte) error { } return nil } -func (m *ConfigBlameSpec) Unmarshal(dAtA []byte) error { +func (m *ConfigSetStatus) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -3265,65 +4395,48 @@ func (m *ConfigBlameSpec) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: ConfigBlameSpec: wiretype end group for non-group") + return fmt.Errorf("proto: ConfigSetStatus: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: ConfigBlameSpec: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: ConfigSetStatus: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { - default: - iNdEx = preIndex - skippy, err := skipGenerated(dAtA[iNdEx:]) - if err != nil { - return err + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ConditionedStatus", wireType) } - if (skippy < 0) || (iNdEx+skippy) < 0 { - return ErrInvalidLengthGenerated + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF + if msglen < 0 { + return ErrInvalidLengthGenerated } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *ConfigBlameStatus) Unmarshal(dAtA []byte) error { - l := len(dAtA) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated + postIndex := iNdEx + msglen + if postIndex < 0 { + return ErrInvalidLengthGenerated } - if iNdEx >= l { + if postIndex > l { return io.ErrUnexpectedEOF } - b := dAtA[iNdEx] - iNdEx++ - wire |= uint64(b&0x7F) << shift - if b < 0x80 { - break + if err := m.ConditionedStatus.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: ConfigBlameStatus: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: ConfigBlameStatus: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { + iNdEx = postIndex case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Value", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Targets", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -3350,7 +4463,8 @@ func (m *ConfigBlameStatus) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Value.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + m.Targets = append(m.Targets, ConfigSetTargetStatus{}) + if err := m.Targets[len(m.Targets)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -3375,7 +4489,7 @@ func (m *ConfigBlameStatus) Unmarshal(dAtA []byte) error { } return nil } -func (m *ConfigBlob) Unmarshal(dAtA []byte) error { +func (m *ConfigSetTarget) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -3398,47 +4512,15 @@ func (m *ConfigBlob) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: ConfigBlob: wiretype end group for non-group") + return fmt.Errorf("proto: ConfigSetTarget: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: ConfigBlob: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: ConfigSetTarget: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Path", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - stringLen |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex < 0 { - return ErrInvalidLengthGenerated - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Path = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex - case 2: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Value", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field TargetSelector", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -3465,7 +4547,10 @@ func (m *ConfigBlob) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Value.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + if m.TargetSelector == nil { + m.TargetSelector = &v1.LabelSelector{} + } + if err := m.TargetSelector.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -3490,7 +4575,7 @@ func (m *ConfigBlob) Unmarshal(dAtA []byte) error { } return nil } -func (m *ConfigDeviation) Unmarshal(dAtA []byte) error { +func (m *ConfigSetTargetStatus) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -3513,80 +4598,15 @@ func (m *ConfigDeviation) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: ConfigDeviation: wiretype end group for non-group") + return fmt.Errorf("proto: ConfigSetTargetStatus: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: ConfigDeviation: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: ConfigSetTargetStatus: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Path", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - stringLen |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex < 0 { - return ErrInvalidLengthGenerated - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Path = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex - case 2: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field DesiredValue", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - stringLen |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex < 0 { - return ErrInvalidLengthGenerated - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - s := string(dAtA[iNdEx:postIndex]) - m.DesiredValue = &s - iNdEx = postIndex - case 3: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field CurrentValue", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -3614,14 +4634,13 @@ func (m *ConfigDeviation) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - s := string(dAtA[iNdEx:postIndex]) - m.ActualValue = &s + m.Name = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex - case 4: + case 3: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Reason", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Condition", wireType) } - var stringLen uint64 + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -3631,23 +4650,24 @@ func (m *ConfigDeviation) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - stringLen |= uint64(b&0x7F) << shift + msglen |= int(b&0x7F) << shift if b < 0x80 { break } } - intStringLen := int(stringLen) - if intStringLen < 0 { + if msglen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + intStringLen + postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthGenerated } if postIndex > l { return io.ErrUnexpectedEOF } - m.Reason = string(dAtA[iNdEx:postIndex]) + if err := m.Condition.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } iNdEx = postIndex default: iNdEx = preIndex @@ -3670,7 +4690,7 @@ func (m *ConfigDeviation) Unmarshal(dAtA []byte) error { } return nil } -func (m *ConfigList) Unmarshal(dAtA []byte) error { +func (m *ConfigSpec) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -3693,15 +4713,15 @@ func (m *ConfigList) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: ConfigList: wiretype end group for non-group") + return fmt.Errorf("proto: ConfigSpec: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: ConfigList: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: ConfigSpec: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ListMeta", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Lifecycle", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -3728,13 +4748,56 @@ func (m *ConfigList) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + if m.Lifecycle == nil { + m.Lifecycle = &Lifecycle{} + } + if err := m.Lifecycle.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex case 2: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Priority", wireType) + } + m.Priority = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.Priority |= int64(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 3: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Revertive", wireType) + } + var v int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + b := bool(v != 0) + m.Revertive = &b + case 4: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Config", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -3761,8 +4824,8 @@ func (m *ConfigList) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Items = append(m.Items, Config{}) - if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + m.Config = append(m.Config, ConfigBlob{}) + if err := m.Config[len(m.Config)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -3787,7 +4850,7 @@ func (m *ConfigList) Unmarshal(dAtA []byte) error { } return nil } -func (m *ConfigSet) Unmarshal(dAtA []byte) error { +func (m *ConfigStatus) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -3810,15 +4873,15 @@ func (m *ConfigSet) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: ConfigSet: wiretype end group for non-group") + return fmt.Errorf("proto: ConfigStatus: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: ConfigSet: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: ConfigStatus: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field ConditionedStatus", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -3845,13 +4908,13 @@ func (m *ConfigSet) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + if err := m.ConditionedStatus.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Spec", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field LastKnownGoodSchema", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -3878,13 +4941,16 @@ func (m *ConfigSet) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Spec.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + if m.LastKnownGoodSchema == nil { + m.LastKnownGoodSchema = &ConfigStatusLastKnownGoodSchema{} + } + if err := m.LastKnownGoodSchema.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex case 3: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field AppliedConfig", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -3911,10 +4977,33 @@ func (m *ConfigSet) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Status.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + if m.AppliedConfig == nil { + m.AppliedConfig = &ConfigSpec{} + } + if err := m.AppliedConfig.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex + case 4: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field DeviationGeneration", wireType) + } + var v int64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= int64(b&0x7F) << shift + if b < 0x80 { + break + } + } + m.DeviationGeneration = &v default: iNdEx = preIndex skippy, err := skipGenerated(dAtA[iNdEx:]) @@ -3936,7 +5025,7 @@ func (m *ConfigSet) Unmarshal(dAtA []byte) error { } return nil } -func (m *ConfigSetList) Unmarshal(dAtA []byte) error { +func (m *ConfigStatusLastKnownGoodSchema) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -3959,17 +5048,17 @@ func (m *ConfigSetList) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: ConfigSetList: wiretype end group for non-group") + return fmt.Errorf("proto: ConfigStatusLastKnownGoodSchema: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: ConfigSetList: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: ConfigStatusLastKnownGoodSchema: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ListMeta", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Type", wireType) } - var msglen int + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -3979,30 +5068,29 @@ func (m *ConfigSetList) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - msglen |= int(b&0x7F) << shift + stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { + intStringLen := int(stringLen) + if intStringLen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + msglen + postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthGenerated } if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } + m.Type = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Vendor", wireType) } - var msglen int + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -4012,25 +5100,55 @@ func (m *ConfigSetList) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - msglen |= int(b&0x7F) << shift + stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { + intStringLen := int(stringLen) + if intStringLen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + msglen + postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthGenerated } if postIndex > l { return io.ErrUnexpectedEOF } - m.Items = append(m.Items, ConfigSet{}) - if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err + m.Vendor = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Version", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return ErrInvalidLengthGenerated + } + if postIndex > l { + return io.ErrUnexpectedEOF } + m.Version = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex @@ -4053,7 +5171,7 @@ func (m *ConfigSetList) Unmarshal(dAtA []byte) error { } return nil } -func (m *ConfigSetSpec) Unmarshal(dAtA []byte) error { +func (m *Deviation) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -4076,15 +5194,15 @@ func (m *ConfigSetSpec) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: ConfigSetSpec: wiretype end group for non-group") + return fmt.Errorf("proto: Deviation: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: ConfigSetSpec: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: Deviation: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Target", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -4111,13 +5229,13 @@ func (m *ConfigSetSpec) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Target.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Lifecycle", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Spec", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -4135,65 +5253,22 @@ func (m *ConfigSetSpec) Unmarshal(dAtA []byte) error { } } if msglen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + msglen - if postIndex < 0 { - return ErrInvalidLengthGenerated - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - if m.Lifecycle == nil { - m.Lifecycle = &Lifecycle{} - } - if err := m.Lifecycle.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - case 3: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field Priority", wireType) - } - m.Priority = 0 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - m.Priority |= int64(b&0x7F) << shift - if b < 0x80 { - break - } - } - case 4: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field Revertive", wireType) - } - var v int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - v |= int(b&0x7F) << shift - if b < 0x80 { - break - } + return ErrInvalidLengthGenerated } - b := bool(v != 0) - m.Revertive = &b - case 5: + postIndex := iNdEx + msglen + if postIndex < 0 { + return ErrInvalidLengthGenerated + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.Spec.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 3: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Config", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -4220,8 +5295,7 @@ func (m *ConfigSetSpec) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Config = append(m.Config, ConfigBlob{}) - if err := m.Config[len(m.Config)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + if err := m.Status.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -4246,7 +5320,7 @@ func (m *ConfigSetSpec) Unmarshal(dAtA []byte) error { } return nil } -func (m *ConfigSetStatus) Unmarshal(dAtA []byte) error { +func (m *DeviationList) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -4269,15 +5343,15 @@ func (m *ConfigSetStatus) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: ConfigSetStatus: wiretype end group for non-group") + return fmt.Errorf("proto: DeviationList: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: ConfigSetStatus: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: DeviationList: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ConditionedStatus", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field ListMeta", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -4304,13 +5378,13 @@ func (m *ConfigSetStatus) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ConditionedStatus.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Targets", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -4337,8 +5411,8 @@ func (m *ConfigSetStatus) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Targets = append(m.Targets, TargetStatus{}) - if err := m.Targets[len(m.Targets)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + m.Items = append(m.Items, Deviation{}) + if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -4363,7 +5437,7 @@ func (m *ConfigSetStatus) Unmarshal(dAtA []byte) error { } return nil } -func (m *ConfigSpec) Unmarshal(dAtA []byte) error { +func (m *DeviationSpec) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -4386,17 +5460,17 @@ func (m *ConfigSpec) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: ConfigSpec: wiretype end group for non-group") + return fmt.Errorf("proto: DeviationSpec: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: ConfigSpec: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: DeviationSpec: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Lifecycle", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field DeviationType", wireType) } - var msglen int + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -4406,33 +5480,30 @@ func (m *ConfigSpec) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - msglen |= int(b&0x7F) << shift + stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { + intStringLen := int(stringLen) + if intStringLen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + msglen + postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthGenerated } if postIndex > l { return io.ErrUnexpectedEOF } - if m.Lifecycle == nil { - m.Lifecycle = &Lifecycle{} - } - if err := m.Lifecycle.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } + s := DeviationType(dAtA[iNdEx:postIndex]) + m.DeviationType = &s iNdEx = postIndex case 2: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field Priority", wireType) + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Deviations", wireType) } - m.Priority = 0 + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -4442,35 +5513,79 @@ func (m *ConfigSpec) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - m.Priority |= int64(b&0x7F) << shift + msglen |= int(b&0x7F) << shift if b < 0x80 { break } } - case 3: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field Revertive", wireType) + if msglen < 0 { + return ErrInvalidLengthGenerated } - var v int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - v |= int(b&0x7F) << shift - if b < 0x80 { - break - } + postIndex := iNdEx + msglen + if postIndex < 0 { + return ErrInvalidLengthGenerated } - b := bool(v != 0) - m.Revertive = &b - case 4: + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Deviations = append(m.Deviations, ConfigDeviation{}) + if err := m.Deviations[len(m.Deviations)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *DeviationStatus) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: DeviationStatus: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: DeviationStatus: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Config", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field ConditionedStatus", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -4497,8 +5612,7 @@ func (m *ConfigSpec) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Config = append(m.Config, ConfigBlob{}) - if err := m.Config[len(m.Config)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + if err := m.ConditionedStatus.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -4523,7 +5637,7 @@ func (m *ConfigSpec) Unmarshal(dAtA []byte) error { } return nil } -func (m *ConfigStatus) Unmarshal(dAtA []byte) error { +func (m *DiscoveryInfo) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -4546,17 +5660,17 @@ func (m *ConfigStatus) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: ConfigStatus: wiretype end group for non-group") + return fmt.Errorf("proto: DiscoveryInfo: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: ConfigStatus: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: DiscoveryInfo: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ConditionedStatus", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Protocol", wireType) } - var msglen int + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -4566,30 +5680,29 @@ func (m *ConfigStatus) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - msglen |= int(b&0x7F) << shift + stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { + intStringLen := int(stringLen) + if intStringLen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + msglen + postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthGenerated } if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ConditionedStatus.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } + m.Protocol = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field LastKnownGoodSchema", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Provider", wireType) } - var msglen int + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -4599,33 +5712,29 @@ func (m *ConfigStatus) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - msglen |= int(b&0x7F) << shift + stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { + intStringLen := int(stringLen) + if intStringLen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + msglen + postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthGenerated } if postIndex > l { return io.ErrUnexpectedEOF } - if m.LastKnownGoodSchema == nil { - m.LastKnownGoodSchema = &ConfigStatusLastKnownGoodSchema{} - } - if err := m.LastKnownGoodSchema.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } + m.Provider = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 3: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field AppliedConfig", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Version", wireType) } - var msglen int + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -4635,33 +5744,29 @@ func (m *ConfigStatus) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - msglen |= int(b&0x7F) << shift + stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { + intStringLen := int(stringLen) + if intStringLen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + msglen + postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthGenerated } if postIndex > l { return io.ErrUnexpectedEOF } - if m.AppliedConfig == nil { - m.AppliedConfig = &ConfigSpec{} - } - if err := m.AppliedConfig.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } + m.Version = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 4: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field DeviationGeneration", wireType) + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Hostname", wireType) } - var v int64 + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -4671,65 +5776,59 @@ func (m *ConfigStatus) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - v |= int64(b&0x7F) << shift + stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } - m.DeviationGeneration = &v - default: - iNdEx = preIndex - skippy, err := skipGenerated(dAtA[iNdEx:]) - if err != nil { - return err + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated } - if (skippy < 0) || (iNdEx+skippy) < 0 { + postIndex := iNdEx + intStringLen + if postIndex < 0 { return ErrInvalidLengthGenerated } - if (iNdEx + skippy) > l { + if postIndex > l { return io.ErrUnexpectedEOF } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *ConfigStatusLastKnownGoodSchema) Unmarshal(dAtA []byte) error { - l := len(dAtA) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated + m.Hostname = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 5: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Platform", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } } - if iNdEx >= l { - return io.ErrUnexpectedEOF + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated } - b := dAtA[iNdEx] - iNdEx++ - wire |= uint64(b&0x7F) << shift - if b < 0x80 { - break + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return ErrInvalidLengthGenerated } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: ConfigStatusLastKnownGoodSchema: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: ConfigStatusLastKnownGoodSchema: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Platform = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 6: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Type", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field MacAddress", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -4757,11 +5856,11 @@ func (m *ConfigStatusLastKnownGoodSchema) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Type = string(dAtA[iNdEx:postIndex]) + m.MacAddress = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex - case 2: + case 7: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Vendor", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field SerialNumber", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -4789,11 +5888,11 @@ func (m *ConfigStatusLastKnownGoodSchema) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Vendor = string(dAtA[iNdEx:postIndex]) + m.SerialNumber = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex - case 3: + case 8: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Version", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field SupportedEncodings", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -4821,7 +5920,7 @@ func (m *ConfigStatusLastKnownGoodSchema) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Version = string(dAtA[iNdEx:postIndex]) + m.SupportedEncodings = append(m.SupportedEncodings, string(dAtA[iNdEx:postIndex])) iNdEx = postIndex default: iNdEx = preIndex @@ -4844,7 +5943,7 @@ func (m *ConfigStatusLastKnownGoodSchema) Unmarshal(dAtA []byte) error { } return nil } -func (m *Deviation) Unmarshal(dAtA []byte) error { +func (m *Lifecycle) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -4867,83 +5966,17 @@ func (m *Deviation) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: Deviation: wiretype end group for non-group") + return fmt.Errorf("proto: Lifecycle: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: Deviation: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: Lifecycle: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - msglen |= int(b&0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + msglen - if postIndex < 0 { - return ErrInvalidLengthGenerated - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - case 2: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Spec", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - msglen |= int(b&0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + msglen - if postIndex < 0 { - return ErrInvalidLengthGenerated - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - if err := m.Spec.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - case 3: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field DeletionPolicy", wireType) } - var msglen int + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -4953,24 +5986,23 @@ func (m *Deviation) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - msglen |= int(b&0x7F) << shift + stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { + intStringLen := int(stringLen) + if intStringLen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + msglen + postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthGenerated } if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Status.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } + m.DeletionPolicy = DeletionPolicy(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex @@ -4993,7 +6025,7 @@ func (m *Deviation) Unmarshal(dAtA []byte) error { } return nil } -func (m *DeviationList) Unmarshal(dAtA []byte) error { +func (m *RunningConfig) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -5016,15 +6048,15 @@ func (m *DeviationList) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: DeviationList: wiretype end group for non-group") + return fmt.Errorf("proto: RunningConfig: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: DeviationList: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: RunningConfig: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ListMeta", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -5051,13 +6083,13 @@ func (m *DeviationList) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Spec", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -5084,8 +6116,40 @@ func (m *DeviationList) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Items = append(m.Items, Deviation{}) - if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + if err := m.Spec.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return ErrInvalidLengthGenerated + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.Status.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -5110,7 +6174,7 @@ func (m *DeviationList) Unmarshal(dAtA []byte) error { } return nil } -func (m *DeviationSpec) Unmarshal(dAtA []byte) error { +func (m *RunningConfigList) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -5133,17 +6197,17 @@ func (m *DeviationSpec) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: DeviationSpec: wiretype end group for non-group") + return fmt.Errorf("proto: RunningConfigList: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: DeviationSpec: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: RunningConfigList: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field DeviationType", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field ListMeta", wireType) } - var stringLen uint64 + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -5153,28 +6217,28 @@ func (m *DeviationSpec) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - stringLen |= uint64(b&0x7F) << shift + msglen |= int(b&0x7F) << shift if b < 0x80 { break } } - intStringLen := int(stringLen) - if intStringLen < 0 { + if msglen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + intStringLen + postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthGenerated } if postIndex > l { return io.ErrUnexpectedEOF } - s := DeviationType(dAtA[iNdEx:postIndex]) - m.DeviationType = &s + if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } iNdEx = postIndex case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Deviations", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -5201,8 +6265,8 @@ func (m *DeviationSpec) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Deviations = append(m.Deviations, ConfigDeviation{}) - if err := m.Deviations[len(m.Deviations)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + m.Items = append(m.Items, RunningConfig{}) + if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -5227,7 +6291,7 @@ func (m *DeviationSpec) Unmarshal(dAtA []byte) error { } return nil } -func (m *DeviationStatus) Unmarshal(dAtA []byte) error { +func (m *RunningConfigSpec) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -5250,45 +6314,12 @@ func (m *DeviationStatus) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: DeviationStatus: wiretype end group for non-group") + return fmt.Errorf("proto: RunningConfigSpec: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: DeviationStatus: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: RunningConfigSpec: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ConditionedStatus", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - msglen |= int(b&0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + msglen - if postIndex < 0 { - return ErrInvalidLengthGenerated - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - if err := m.ConditionedStatus.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipGenerated(dAtA[iNdEx:]) @@ -5310,7 +6341,7 @@ func (m *DeviationStatus) Unmarshal(dAtA []byte) error { } return nil } -func (m *Lifecycle) Unmarshal(dAtA []byte) error { +func (m *RunningConfigStatus) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -5333,17 +6364,17 @@ func (m *Lifecycle) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: Lifecycle: wiretype end group for non-group") + return fmt.Errorf("proto: RunningConfigStatus: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: Lifecycle: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: RunningConfigStatus: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { - case 1: + case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field DeletionPolicy", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Value", wireType) } - var stringLen uint64 + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -5353,23 +6384,24 @@ func (m *Lifecycle) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - stringLen |= uint64(b&0x7F) << shift + msglen |= int(b&0x7F) << shift if b < 0x80 { break } } - intStringLen := int(stringLen) - if intStringLen < 0 { + if msglen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + intStringLen + postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthGenerated } if postIndex > l { return io.ErrUnexpectedEOF } - m.DeletionPolicy = DeletionPolicy(dAtA[iNdEx:postIndex]) + if err := m.Value.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } iNdEx = postIndex default: iNdEx = preIndex @@ -5392,7 +6424,7 @@ func (m *Lifecycle) Unmarshal(dAtA []byte) error { } return nil } -func (m *RunningConfig) Unmarshal(dAtA []byte) error { +func (m *SensitiveConfig) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -5415,10 +6447,10 @@ func (m *RunningConfig) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: RunningConfig: wiretype end group for non-group") + return fmt.Errorf("proto: SensitiveConfig: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: RunningConfig: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: SensitiveConfig: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: @@ -5541,7 +6573,7 @@ func (m *RunningConfig) Unmarshal(dAtA []byte) error { } return nil } -func (m *RunningConfigList) Unmarshal(dAtA []byte) error { +func (m *SensitiveConfigData) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -5564,17 +6596,17 @@ func (m *RunningConfigList) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: RunningConfigList: wiretype end group for non-group") + return fmt.Errorf("proto: SensitiveConfigData: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: RunningConfigList: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: SensitiveConfigData: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ListMeta", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Path", wireType) } - var msglen int + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -5584,28 +6616,27 @@ func (m *RunningConfigList) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - msglen |= int(b&0x7F) << shift + stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { + intStringLen := int(stringLen) + if intStringLen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + msglen + postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthGenerated } if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } + m.Path = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field SecretKeyRef", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -5632,8 +6663,7 @@ func (m *RunningConfigList) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Items = append(m.Items, RunningConfig{}) - if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + if err := m.SecretKeyRef.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -5658,7 +6688,7 @@ func (m *RunningConfigList) Unmarshal(dAtA []byte) error { } return nil } -func (m *RunningConfigSpec) Unmarshal(dAtA []byte) error { +func (m *SensitiveConfigList) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -5681,12 +6711,79 @@ func (m *RunningConfigSpec) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: RunningConfigSpec: wiretype end group for non-group") + return fmt.Errorf("proto: SensitiveConfigList: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: RunningConfigSpec: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: SensitiveConfigList: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ListMeta", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return ErrInvalidLengthGenerated + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return ErrInvalidLengthGenerated + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Items = append(m.Items, SensitiveConfig{}) + if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipGenerated(dAtA[iNdEx:]) @@ -5708,7 +6805,7 @@ func (m *RunningConfigSpec) Unmarshal(dAtA []byte) error { } return nil } -func (m *RunningConfigStatus) Unmarshal(dAtA []byte) error { +func (m *SensitiveConfigSpec) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -5731,15 +6828,91 @@ func (m *RunningConfigStatus) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: RunningConfigStatus: wiretype end group for non-group") + return fmt.Errorf("proto: SensitiveConfigSpec: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: RunningConfigStatus: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: SensitiveConfigSpec: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Lifecycle", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return ErrInvalidLengthGenerated + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.Lifecycle == nil { + m.Lifecycle = &Lifecycle{} + } + if err := m.Lifecycle.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex case 2: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Priority", wireType) + } + m.Priority = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.Priority |= int64(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 3: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Revertive", wireType) + } + var v int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + b := bool(v != 0) + m.Revertive = &b + case 4: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Value", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Config", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -5766,7 +6939,8 @@ func (m *RunningConfigStatus) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Value.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + m.Config = append(m.Config, SensitiveConfigData{}) + if err := m.Config[len(m.Config)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -5791,7 +6965,7 @@ func (m *RunningConfigStatus) Unmarshal(dAtA []byte) error { } return nil } -func (m *SensitiveConfig) Unmarshal(dAtA []byte) error { +func (m *SensitiveConfigStatus) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -5814,15 +6988,15 @@ func (m *SensitiveConfig) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: SensitiveConfig: wiretype end group for non-group") + return fmt.Errorf("proto: SensitiveConfigStatus: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: SensitiveConfig: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: SensitiveConfigStatus: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field ConditionedStatus", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -5849,13 +7023,13 @@ func (m *SensitiveConfig) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + if err := m.ConditionedStatus.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Spec", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field LastKnownGoodSchema", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -5882,13 +7056,16 @@ func (m *SensitiveConfig) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Spec.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + if m.LastKnownGoodSchema == nil { + m.LastKnownGoodSchema = &ConfigStatusLastKnownGoodSchema{} + } + if err := m.LastKnownGoodSchema.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex case 3: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field AppliedSensitiveConfig", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -5915,10 +7092,33 @@ func (m *SensitiveConfig) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Status.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + if m.AppliedSensitiveConfig == nil { + m.AppliedSensitiveConfig = &SensitiveConfigSpec{} + } + if err := m.AppliedSensitiveConfig.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex + case 4: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field DeviationGeneration", wireType) + } + var v int64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= int64(b&0x7F) << shift + if b < 0x80 { + break + } + } + m.DeviationGeneration = &v default: iNdEx = preIndex skippy, err := skipGenerated(dAtA[iNdEx:]) @@ -5940,7 +7140,7 @@ func (m *SensitiveConfig) Unmarshal(dAtA []byte) error { } return nil } -func (m *SensitiveConfigData) Unmarshal(dAtA []byte) error { +func (m *Target) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -5963,17 +7163,17 @@ func (m *SensitiveConfigData) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: SensitiveConfigData: wiretype end group for non-group") + return fmt.Errorf("proto: Target: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: SensitiveConfigData: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: Target: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Path", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType) } - var stringLen uint64 + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -5983,27 +7183,28 @@ func (m *SensitiveConfigData) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - stringLen |= uint64(b&0x7F) << shift + msglen |= int(b&0x7F) << shift if b < 0x80 { break } } - intStringLen := int(stringLen) - if intStringLen < 0 { + if msglen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + intStringLen + postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthGenerated } if postIndex > l { return io.ErrUnexpectedEOF } - m.Path = string(dAtA[iNdEx:postIndex]) + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } iNdEx = postIndex case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field SecretKeyRef", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Spec", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -6030,7 +7231,40 @@ func (m *SensitiveConfigData) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.SecretKeyRef.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + if err := m.Spec.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return ErrInvalidLengthGenerated + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.Status.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -6055,7 +7289,7 @@ func (m *SensitiveConfigData) Unmarshal(dAtA []byte) error { } return nil } -func (m *SensitiveConfigList) Unmarshal(dAtA []byte) error { +func (m *TargetList) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -6078,10 +7312,10 @@ func (m *SensitiveConfigList) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: SensitiveConfigList: wiretype end group for non-group") + return fmt.Errorf("proto: TargetList: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: SensitiveConfigList: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: TargetList: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: @@ -6146,7 +7380,7 @@ func (m *SensitiveConfigList) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Items = append(m.Items, SensitiveConfig{}) + m.Items = append(m.Items, Target{}) if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } @@ -6172,7 +7406,7 @@ func (m *SensitiveConfigList) Unmarshal(dAtA []byte) error { } return nil } -func (m *SensitiveConfigSpec) Unmarshal(dAtA []byte) error { +func (m *TargetSpec) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -6195,17 +7429,17 @@ func (m *SensitiveConfigSpec) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: SensitiveConfigSpec: wiretype end group for non-group") + return fmt.Errorf("proto: TargetSpec: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: SensitiveConfigSpec: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: TargetSpec: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Lifecycle", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Provider", wireType) } - var msglen int + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -6215,33 +7449,29 @@ func (m *SensitiveConfigSpec) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - msglen |= int(b&0x7F) << shift + stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { + intStringLen := int(stringLen) + if intStringLen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + msglen + postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthGenerated } if postIndex > l { return io.ErrUnexpectedEOF } - if m.Lifecycle == nil { - m.Lifecycle = &Lifecycle{} - } - if err := m.Lifecycle.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } + m.Provider = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field Priority", wireType) + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Address", wireType) } - m.Priority = 0 + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -6251,35 +7481,27 @@ func (m *SensitiveConfigSpec) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - m.Priority |= int64(b&0x7F) << shift + stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } - case 3: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field Revertive", wireType) + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated } - var v int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - v |= int(b&0x7F) << shift - if b < 0x80 { - break - } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return ErrInvalidLengthGenerated } - b := bool(v != 0) - m.Revertive = &b - case 4: + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Address = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 3: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Config", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field TargetProfile", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -6306,8 +7528,7 @@ func (m *SensitiveConfigSpec) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Config = append(m.Config, SensitiveConfigData{}) - if err := m.Config[len(m.Config)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + if err := m.TargetProfile.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -6332,7 +7553,7 @@ func (m *SensitiveConfigSpec) Unmarshal(dAtA []byte) error { } return nil } -func (m *SensitiveConfigStatus) Unmarshal(dAtA []byte) error { +func (m *TargetStatus) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -6355,10 +7576,10 @@ func (m *SensitiveConfigStatus) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: SensitiveConfigStatus: wiretype end group for non-group") + return fmt.Errorf("proto: TargetStatus: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: SensitiveConfigStatus: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: TargetStatus: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: @@ -6396,7 +7617,7 @@ func (m *SensitiveConfigStatus) Unmarshal(dAtA []byte) error { iNdEx = postIndex case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field LastKnownGoodSchema", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field DiscoveryInfo", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -6423,16 +7644,16 @@ func (m *SensitiveConfigStatus) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if m.LastKnownGoodSchema == nil { - m.LastKnownGoodSchema = &ConfigStatusLastKnownGoodSchema{} + if m.DiscoveryInfo == nil { + m.DiscoveryInfo = &DiscoveryInfo{} } - if err := m.LastKnownGoodSchema.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + if err := m.DiscoveryInfo.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex case 3: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field AppliedSensitiveConfig", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field UsedReferences", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -6459,33 +7680,13 @@ func (m *SensitiveConfigStatus) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if m.AppliedSensitiveConfig == nil { - m.AppliedSensitiveConfig = &SensitiveConfigSpec{} + if m.UsedReferences == nil { + m.UsedReferences = &TargetStatusUsedReferences{} } - if err := m.AppliedSensitiveConfig.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + if err := m.UsedReferences.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex - case 4: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field DeviationGeneration", wireType) - } - var v int64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - v |= int64(b&0x7F) << shift - if b < 0x80 { - break - } - } - m.DeviationGeneration = &v default: iNdEx = preIndex skippy, err := skipGenerated(dAtA[iNdEx:]) @@ -6507,7 +7708,7 @@ func (m *SensitiveConfigStatus) Unmarshal(dAtA []byte) error { } return nil } -func (m *Target) Unmarshal(dAtA []byte) error { +func (m *TargetStatusUsedReferences) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -6530,17 +7731,17 @@ func (m *Target) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: Target: wiretype end group for non-group") + return fmt.Errorf("proto: TargetStatusUsedReferences: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: Target: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: TargetStatusUsedReferences: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field TargetSelector", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field SecretResourceVersion", wireType) } - var msglen int + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -6550,81 +7751,59 @@ func (m *Target) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - msglen |= int(b&0x7F) << shift + stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { + intStringLen := int(stringLen) + if intStringLen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + msglen + postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthGenerated } if postIndex > l { return io.ErrUnexpectedEOF } - if m.TargetSelector == nil { - m.TargetSelector = &v1.LabelSelector{} - } - if err := m.TargetSelector.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } + m.SecretResourceVersion = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipGenerated(dAtA[iNdEx:]) - if err != nil { - return err + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field TLSSecretResourceVersion", wireType) } - if (skippy < 0) || (iNdEx+skippy) < 0 { - return ErrInvalidLengthGenerated + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *TargetStatus) Unmarshal(dAtA []byte) error { - l := len(dAtA) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return ErrInvalidLengthGenerated } - if iNdEx >= l { + if postIndex > l { return io.ErrUnexpectedEOF } - b := dAtA[iNdEx] - iNdEx++ - wire |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: TargetStatus: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: TargetStatus: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: + m.TLSSecretResourceVersion = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 3: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field ConnectionProfileResourceVersion", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -6652,13 +7831,13 @@ func (m *TargetStatus) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Name = string(dAtA[iNdEx:postIndex]) + m.ConnectionProfileResourceVersion = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex - case 3: + case 4: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Condition", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field SyncProfileResourceVersion", wireType) } - var msglen int + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -6668,24 +7847,23 @@ func (m *TargetStatus) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - msglen |= int(b&0x7F) << shift + stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { + intStringLen := int(stringLen) + if intStringLen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + msglen + postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthGenerated } if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Condition.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } + m.SyncProfileResourceVersion = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex diff --git a/apis/config/v1alpha1/generated.proto b/apis/config/v1alpha1/generated.proto index 54e12e13..524e4669 100644 --- a/apis/config/v1alpha1/generated.proto +++ b/apis/config/v1alpha1/generated.proto @@ -20,6 +20,7 @@ syntax = "proto2"; package github.com.sdcio.config_server.apis.config.v1alpha1; import "github.com/sdcio/config-server/apis/condition/v1alpha1/generated.proto"; +import "github.com/sdcio/config-server/apis/inv/v1alpha1/generated.proto"; import "k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto"; import "k8s.io/apimachinery/pkg/runtime/generated.proto"; import "k8s.io/apimachinery/pkg/runtime/schema/generated.proto"; @@ -102,7 +103,7 @@ message ConfigDeviation { // DesiredValue is the desired value of the config belonging to the path optional string desiredValue = 2; - // CurrentValue defines the current value of the config belonging to the path + // ActualValue defines the current value of the config belonging to the path // that is currently configured on the target optional string actualValue = 3; @@ -150,6 +151,7 @@ message ConfigSetSpec { // Config defines the configuration to be applied to a target device // +kubebuilder:pruning:PreserveUnknownFields + // +listType=atomic repeated ConfigBlob config = 5; } @@ -160,7 +162,22 @@ message ConfigSetStatus { optional .github.com.sdcio.config_server.apis.condition.v1alpha1.ConditionedStatus conditionedStatus = 1; // Targets defines the status of the configSet resource on the respective target - repeated TargetStatus targets = 2; + // +listType=atomic + repeated ConfigSetTargetStatus targets = 2; +} + +message ConfigSetTarget { + // TargetSelector defines the selector used to select the targets to which the config applies + optional .k8s.io.apimachinery.pkg.apis.meta.v1.LabelSelector targetSelector = 1; +} + +message ConfigSetTargetStatus { + optional string name = 1; + + // right now we assume the namespace of the config and target are aligned + // NameSpace string `json:"namespace" protobuf:"bytes,2,opt,name=name"` + // Condition of the configCR status + optional .github.com.sdcio.config_server.apis.condition.v1alpha1.Condition condition = 3; } // ConfigSpec defines the desired state of Config @@ -177,6 +194,7 @@ message ConfigSpec { // Config defines the configuration to be applied to a target device // +kubebuilder:pruning:PreserveUnknownFields + // +listType=atomic repeated ConfigBlob config = 4; } @@ -228,6 +246,7 @@ message DeviationSpec { optional string deviationType = 1; // Deviations identify the configuration deviation based on the last applied config CR + // +listType=atomic repeated ConfigDeviation deviations = 2; } @@ -238,6 +257,33 @@ message DeviationStatus { optional .github.com.sdcio.config_server.apis.condition.v1alpha1.ConditionedStatus conditionedStatus = 1; } +message DiscoveryInfo { + // Protocol used for discovery + optional string protocol = 1; + + // Type associated with the target + optional string provider = 2; + + // Version associated with the target + optional string version = 3; + + // Hostname associated with the target + optional string hostname = 4; + + // Platform associated with the target + optional string platform = 5; + + // MacAddress associated with the target + optional string macAddress = 6; + + // SerialNumber associated with the target + optional string serialNumber = 7; + + // Supported Encodings of the target + // +listType=atomic + repeated string supportedEncodings = 8; +} + message Lifecycle { // DeletionPolicy specifies what will happen to the underlying resource // when this resource is deleted - either "delete" or "orphan" the @@ -310,6 +356,7 @@ message SensitiveConfigSpec { optional bool revertive = 3; // SensitiveConfig defines the SensitiveConfiguration to be applied to a target device + // +listType=atomic repeated SensitiveConfigData config = 4; } @@ -329,17 +376,54 @@ message SensitiveConfigStatus { optional int64 deviationGeneration = 4; } +// Target is the Schema for the Target API +// +k8s:openapi-gen=true message Target { - // TargetSelector defines the selector used to select the targets to which the config applies - optional .k8s.io.apimachinery.pkg.apis.meta.v1.LabelSelector targetSelector = 1; + optional .k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1; + + optional TargetSpec spec = 2; + + optional TargetStatus status = 3; +} + +// TargetList contains a list of Targets +message TargetList { + optional .k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta metadata = 1; + + repeated Target items = 2; +} + +// TargetSpec defines the desired state of Target +message TargetSpec { + // Provider specifies the provider using this target. + optional string provider = 1; + + // Address defines the address to connect to the target + optional string address = 2; + + // TargetProfile defines the Credentials/TLSSecret and sync/connectivity profile to connect to the target + optional .github.com.sdcio.config_server.apis.inv.v1alpha1.TargetProfile targetProfile = 3; } +// TargetStatus defines the observed state of Target message TargetStatus { - optional string name = 1; + // ConditionedStatus provides the status of the Target using conditions + optional .github.com.sdcio.config_server.apis.condition.v1alpha1.ConditionedStatus conditionedStatus = 1; - // right now we assume the namespace of the config and target are aligned - // NameSpace string `json:"namespace" protobuf:"bytes,2,opt,name=name"` - // Condition of the configCR status - optional .github.com.sdcio.config_server.apis.condition.v1alpha1.Condition condition = 3; + // Discovery info defines the information retrieved during discovery + optional DiscoveryInfo discoveryInfo = 2; + + // UsedReferences track the resource used to reconcile the cr + optional TargetStatusUsedReferences usedReferences = 3; +} + +message TargetStatusUsedReferences { + optional string secretResourceVersion = 1; + + optional string tlsSecretResourceVersion = 2; + + optional string connectionProfileResourceVersion = 3; + + optional string syncProfileResourceVersion = 4; } diff --git a/apis/config/v1alpha1/generated.protomessage.pb.go b/apis/config/v1alpha1/generated.protomessage.pb.go new file mode 100644 index 00000000..9f5cb55a --- /dev/null +++ b/apis/config/v1alpha1/generated.protomessage.pb.go @@ -0,0 +1,100 @@ +//go:build kubernetes_protomessage_one_more_release +// +build kubernetes_protomessage_one_more_release + +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +// Code generated by go-to-protobuf. DO NOT EDIT. + +package v1alpha1 + +func (*LocalObjectReference) ProtoMessage() {} + +func (*SecretKeySelector) ProtoMessage() {} + +func (*Config) ProtoMessage() {} + +func (*ConfigBlame) ProtoMessage() {} + +func (*ConfigBlameList) ProtoMessage() {} + +func (*ConfigBlameSpec) ProtoMessage() {} + +func (*ConfigBlameStatus) ProtoMessage() {} + +func (*ConfigBlob) ProtoMessage() {} + +func (*ConfigDeviation) ProtoMessage() {} + +func (*ConfigList) ProtoMessage() {} + +func (*ConfigSet) ProtoMessage() {} + +func (*ConfigSetList) ProtoMessage() {} + +func (*ConfigSetSpec) ProtoMessage() {} + +func (*ConfigSetStatus) ProtoMessage() {} + +func (*ConfigSetTarget) ProtoMessage() {} + +func (*ConfigSetTargetStatus) ProtoMessage() {} + +func (*ConfigSpec) ProtoMessage() {} + +func (*ConfigStatus) ProtoMessage() {} + +func (*ConfigStatusLastKnownGoodSchema) ProtoMessage() {} + +func (*Deviation) ProtoMessage() {} + +func (*DeviationList) ProtoMessage() {} + +func (*DeviationSpec) ProtoMessage() {} + +func (*DeviationStatus) ProtoMessage() {} + +func (*DiscoveryInfo) ProtoMessage() {} + +func (*Lifecycle) ProtoMessage() {} + +func (*RunningConfig) ProtoMessage() {} + +func (*RunningConfigList) ProtoMessage() {} + +func (*RunningConfigSpec) ProtoMessage() {} + +func (*RunningConfigStatus) ProtoMessage() {} + +func (*SensitiveConfig) ProtoMessage() {} + +func (*SensitiveConfigData) ProtoMessage() {} + +func (*SensitiveConfigList) ProtoMessage() {} + +func (*SensitiveConfigSpec) ProtoMessage() {} + +func (*SensitiveConfigStatus) ProtoMessage() {} + +func (*Target) ProtoMessage() {} + +func (*TargetList) ProtoMessage() {} + +func (*TargetSpec) ProtoMessage() {} + +func (*TargetStatus) ProtoMessage() {} + +func (*TargetStatusUsedReferences) ProtoMessage() {} diff --git a/apis/config/v1alpha1/register.go b/apis/config/v1alpha1/register.go index ea196478..559f9d88 100644 --- a/apis/config/v1alpha1/register.go +++ b/apis/config/v1alpha1/register.go @@ -63,6 +63,8 @@ func addKnownTypes(scheme *runtime.Scheme) error { &DeviationList{}, &ConfigBlame{}, &ConfigBlameList{}, + &Target{}, + &TargetList{}, ) metav1.AddToGroupVersion(scheme, SchemeGroupVersion) diff --git a/apis/config/v1alpha1/target_helpers.go b/apis/config/v1alpha1/target_helpers.go new file mode 100644 index 00000000..2c29f2d9 --- /dev/null +++ b/apis/config/v1alpha1/target_helpers.go @@ -0,0 +1,166 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1alpha1 + +import ( + "fmt" + "strings" + + condv1alpha1 "github.com/sdcio/config-server/apis/condition/v1alpha1" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/types" + "k8s.io/utils/ptr" + "sigs.k8s.io/controller-runtime/pkg/client" +) + +// GetCondition returns the condition based on the condition kind +func (r *Target) GetCondition(t condv1alpha1.ConditionType) condv1alpha1.Condition { + return r.Status.GetCondition(t) +} + +// SetConditions sets the conditions on the resource. it allows for 0, 1 or more conditions +// to be set at once +func (r *Target) SetConditions(c ...condv1alpha1.Condition) { + r.Status.SetConditions(c...) +} + +func (r *Target) IsConditionReady() bool { + return r.GetCondition(condv1alpha1.ConditionTypeReady).Status == metav1.ConditionTrue +} + +func (r *Target) GetOwnerReference() metav1.OwnerReference { + return metav1.OwnerReference{ + APIVersion: r.APIVersion, + Kind: r.Kind, + Name: r.Name, + UID: r.UID, + Controller: ptr.To(true), + } +} + +func (r *Target) GetNamespacedName() types.NamespacedName { + return types.NamespacedName{Namespace: r.Namespace, Name: r.Name} +} + +func (r *Target) SetOverallStatus(target *Target) { + ready := true + msg := "target ready" + if ready && !target.GetCondition(ConditionTypeTargetDiscoveryReady).IsTrue() { + ready = false + msg = "discovery not ready" // target.GetCondition(ConditionTypeDiscoveryReady).Message) + } + if ready && !target.GetCondition(ConditionTypeTargetDatastoreReady).IsTrue() { + ready = false + msg = "datastore not ready" // target.GetCondition(ConditionTypeDatastoreReady).Message) + } + if ready && !target.GetCondition(ConditionTypeTargetConfigRecoveryReady).IsTrue() { + ready = false + msg = "config not ready" //, target.GetCondition(ConditionTypeConfigReady).Message) + } + if ready && !target.GetCondition(ConditionTypeTargetConnectionReady).IsTrue() { + ready = false + msg = "datastore connection not ready" // target.GetCondition(ConditionTypeTargetConnectionReady).Message) + } + if ready { + r.Status.SetConditions(condv1alpha1.Ready()) + } else { + r.Status.SetConditions(condv1alpha1.Failed(msg)) + } +} + +func GetOverallStatus(target *Target) condv1alpha1.Condition { + ready := true + msg := "target ready" + if ready && !target.GetCondition(ConditionTypeTargetDiscoveryReady).IsTrue() { + ready = false + msg = "discovery not ready" // target.GetCondition(ConditionTypeDiscoveryReady).Message) + } + if ready && !target.GetCondition(ConditionTypeTargetDatastoreReady).IsTrue() { + ready = false + msg = "datastore not ready" // target.GetCondition(ConditionTypeDatastoreReady).Message) + } + if ready && !target.GetCondition(ConditionTypeTargetConfigRecoveryReady).IsTrue() { + ready = false + msg = "config not ready" //, target.GetCondition(ConditionTypeConfigReady).Message) + } + if ready && !target.GetCondition(ConditionTypeTargetConnectionReady).IsTrue() { + ready = false + msg = "datastore connection not ready" // target.GetCondition(ConditionTypeTargetConnectionReady).Message) + } + if !ready { + return condv1alpha1.Failed(msg) + } + return condv1alpha1.Ready() +} + +func (r *Target) IsDatastoreReady() bool { + return r.GetCondition(ConditionTypeTargetDiscoveryReady).Status == metav1.ConditionTrue && + r.GetCondition(ConditionTypeTargetDatastoreReady).Status == metav1.ConditionTrue && + r.GetCondition(ConditionTypeTargetConnectionReady).Status == metav1.ConditionTrue +} + +func (r *Target) IsReady() bool { + return r.GetCondition(condv1alpha1.ConditionTypeReady).Status == metav1.ConditionTrue && + r.GetCondition(ConditionTypeTargetDiscoveryReady).Status == metav1.ConditionTrue && + r.GetCondition(ConditionTypeTargetDatastoreReady).Status == metav1.ConditionTrue && + r.GetCondition(ConditionTypeTargetConnectionReady).Status == metav1.ConditionTrue +} + +func (r *Target) NotReadyReason() string { + reasons := []string{} + + check := func(name string, cond condv1alpha1.Condition) { + if cond.Status != metav1.ConditionTrue { + reasons = append(reasons, + fmt.Sprintf("%s: %s (Reason: %s, Msg: %s)", + name, cond.Status, cond.Reason, cond.Message)) + } + } + + check("DiscoveryReady", r.GetCondition(ConditionTypeTargetDiscoveryReady)) + check("DatastoreReady", r.GetCondition(ConditionTypeTargetDatastoreReady)) + check("ConfigReady", r.GetCondition(ConditionTypeTargetConfigRecoveryReady)) + check("ConnectionReady", r.GetCondition(ConditionTypeTargetConnectionReady)) + + if len(reasons) == 0 { + return "All conditions are ready" + } + + return strings.Join(reasons, "; ") +} + +func (r *TargetList) GetItems() []client.Object { + objs := []client.Object{} + for _, r := range r.Items { + objs = append(objs, &r) + } + return objs +} + +// BuildTarget returns a Target from a client Object a crName and +// an Target Spec/Status +func BuildTarget(meta metav1.ObjectMeta, spec TargetSpec, status TargetStatus) *Target { + return &Target{ + TypeMeta: metav1.TypeMeta{ + APIVersion: SchemeGroupVersion.Identifier(), + Kind: TargetKind, + }, + ObjectMeta: meta, + Spec: spec, + Status: status, + } +} diff --git a/apis/config/v1alpha1/target_resource.go b/apis/config/v1alpha1/target_resource.go new file mode 100644 index 00000000..59856cc1 --- /dev/null +++ b/apis/config/v1alpha1/target_resource.go @@ -0,0 +1,79 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1alpha1 + +import ( + "github.com/henderiw/apiserver-builder/pkg/builder/resource" + "github.com/sdcio/config-server/apis/config" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime/schema" +) + +// +k8s:deepcopy-gen=false +var _ resource.Object = &Target{} +var _ resource.ObjectList = &TargetList{} +var _ resource.MultiVersionObject = &Target{} + +func (Target) GetGroupVersionResource() schema.GroupVersionResource { + return schema.GroupVersionResource{ + Group: SchemeGroupVersion.Group, + Version: SchemeGroupVersion.Version, + Resource: config.TargetPlural, + } +} + +// IsStorageVersion returns true -- Target is used as the internal version. +// IsStorageVersion implements resource.Object +func (Target) IsStorageVersion() bool { + return false +} + +// NamespaceScoped returns true to indicate Fortune is a namespaced resource. +// NamespaceScoped implements resource.Object +func (Target) NamespaceScoped() bool { + return true +} + +// GetObjectMeta implements resource.Object +func (r *Target) GetObjectMeta() *metav1.ObjectMeta { + return &r.ObjectMeta +} + +// New return an empty resource +// New implements resource.Object +func (Target) New() runtime.Object { + return &Target{} +} + +// NewList return an empty resourceList +// NewList implements resource.Object +func (Target) NewList() runtime.Object { + return &TargetList{} +} + +// GetListMeta returns the ListMeta +// GetListMeta implements resource.ObjectList +func (r *TargetList) GetListMeta() *metav1.ListMeta { + return &r.ListMeta +} + +// RegisterConversions registers the conversions. +// RegisterConversions implements resource.MultiVersionObject +func (Target) RegisterConversions() func(s *runtime.Scheme) error { + return RegisterConversions +} diff --git a/apis/config/v1alpha1/target_types.go b/apis/config/v1alpha1/target_types.go new file mode 100644 index 00000000..e5d82b68 --- /dev/null +++ b/apis/config/v1alpha1/target_types.go @@ -0,0 +1,109 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1alpha1 + +import ( + "reflect" + + condv1alpha1 "github.com/sdcio/config-server/apis/condition/v1alpha1" + invv1alpha1 "github.com/sdcio/config-server/apis/inv/v1alpha1" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/runtime/schema" +) + +// TargetSpec defines the desired state of Target +type TargetSpec struct { + // Provider specifies the provider using this target. + Provider string `json:"provider" protobuf:"bytes,1,opt,name=provider"` + // Address defines the address to connect to the target + Address string `json:"address" protobuf:"bytes,2,opt,name=address"` + // TargetProfile defines the Credentials/TLSSecret and sync/connectivity profile to connect to the target + invv1alpha1.TargetProfile `json:",inline" protobuf:"bytes,3,opt,name=targetProfile"` +} + +// TargetStatus defines the observed state of Target +type TargetStatus struct { + // ConditionedStatus provides the status of the Target using conditions + condv1alpha1.ConditionedStatus `json:",inline" protobuf:"bytes,1,opt,name=conditionedStatus"` + // Discovery info defines the information retrieved during discovery + DiscoveryInfo *DiscoveryInfo `json:"discoveryInfo,omitempty" protobuf:"bytes,2,opt,name=discoveryInfo"` + // UsedReferences track the resource used to reconcile the cr + UsedReferences *TargetStatusUsedReferences `json:"usedReferences,omitempty" protobuf:"bytes,3,opt,name=usedReferences"` +} + +type DiscoveryInfo struct { + // Protocol used for discovery + Protocol string `json:"protocol,omitempty" protobuf:"bytes,1,opt,name=protocol"` + // Type associated with the target + Provider string `json:"provider,omitempty" protobuf:"bytes,2,opt,name=provider"` + // Version associated with the target + Version string `json:"version,omitempty" protobuf:"bytes,3,opt,name=version"` + // Hostname associated with the target + Hostname string `json:"hostname,omitempty" protobuf:"bytes,4,opt,name=hostname"` + // Platform associated with the target + Platform string `json:"platform,omitempty" protobuf:"bytes,5,opt,name=platform"` + // MacAddress associated with the target + MacAddress string `json:"macAddress,omitempty" protobuf:"bytes,6,opt,name=macAddress"` + // SerialNumber associated with the target + SerialNumber string `json:"serialNumber,omitempty" protobuf:"bytes,7,opt,name=serialNumber"` + // Supported Encodings of the target + // +listType=atomic + SupportedEncodings []string `json:"supportedEncodings,omitempty" protobuf:"bytes,8,rep,name=supportedEncodings"` + // Last discovery time + //LastSeen metav1.Time `json:"lastSeen,omitempty"` +} + +type TargetStatusUsedReferences struct { + SecretResourceVersion string `json:"secretResourceVersion,omitempty" yaml:"secretResourceVersion,omitempty" protobuf:"bytes,1,opt,name=secretResourceVersion"` + TLSSecretResourceVersion string `json:"tlsSecretResourceVersion,omitempty" yaml:"tlsSecretResourceVersion,omitempty" protobuf:"bytes,2,opt,name=tlsSecretResourceVersion"` + ConnectionProfileResourceVersion string `json:"connectionProfileResourceVersion" yaml:"connectionProfileResourceVersion" protobuf:"bytes,3,opt,name=connectionProfileResourceVersion"` + SyncProfileResourceVersion string `json:"syncProfileResourceVersion" yaml:"syncProfileResourceVersion" protobuf:"bytes,4,opt,name=syncProfileResourceVersion"` +} + +// +genclient +// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object +// +kubebuilder:object:root=true +// +kubebuilder:storageversion +// +kubebuilder:subresource:status +// +kubebuilder:resource:categories={sdc} + +// Target is the Schema for the Target API +// +k8s:openapi-gen=true +type Target struct { + metav1.TypeMeta `json:",inline" yaml:",inline"` + metav1.ObjectMeta `json:"metadata,omitempty" yaml:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + + Spec TargetSpec `json:"spec,omitempty" yaml:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"` + Status TargetStatus `json:"status,omitempty" yaml:"status,omitempty" protobuf:"bytes,3,opt,name=status"` +} + +// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object +// +kubebuilder:object:root=true + +// TargetList contains a list of Targets +type TargetList struct { + metav1.TypeMeta `json:",inline" yaml:",inline"` + metav1.ListMeta `json:"metadata,omitempty" yaml:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + Items []Target `json:"items" yaml:"items" protobuf:"bytes,2,rep,name=items"` +} + +var ( + TargetKind = reflect.TypeOf(Target{}).Name() + TargetGroupKind = schema.GroupKind{Group: SchemeGroupVersion.Group, Kind: TargetKind}.String() + TargetKindAPIVersion = TargetKind + "." + SchemeGroupVersion.String() + TargetGroupVersionKind = SchemeGroupVersion.WithKind(TargetKind) +) diff --git a/apis/config/v1alpha1/zz_generated.conversion.go b/apis/config/v1alpha1/zz_generated.conversion.go index aa359115..19c26e75 100644 --- a/apis/config/v1alpha1/zz_generated.conversion.go +++ b/apis/config/v1alpha1/zz_generated.conversion.go @@ -98,6 +98,16 @@ func RegisterConversions(s *runtime.Scheme) error { }); err != nil { return err } + if err := s.AddGeneratedConversionFunc((*ConfigDeviation)(nil), (*config.ConfigDeviation)(nil), func(a, b interface{}, scope conversion.Scope) error { + return Convert_v1alpha1_ConfigDeviation_To_config_ConfigDeviation(a.(*ConfigDeviation), b.(*config.ConfigDeviation), scope) + }); err != nil { + return err + } + if err := s.AddGeneratedConversionFunc((*config.ConfigDeviation)(nil), (*ConfigDeviation)(nil), func(a, b interface{}, scope conversion.Scope) error { + return Convert_config_ConfigDeviation_To_v1alpha1_ConfigDeviation(a.(*config.ConfigDeviation), b.(*ConfigDeviation), scope) + }); err != nil { + return err + } if err := s.AddGeneratedConversionFunc((*ConfigList)(nil), (*config.ConfigList)(nil), func(a, b interface{}, scope conversion.Scope) error { return Convert_v1alpha1_ConfigList_To_config_ConfigList(a.(*ConfigList), b.(*config.ConfigList), scope) }); err != nil { @@ -148,6 +158,26 @@ func RegisterConversions(s *runtime.Scheme) error { }); err != nil { return err } + if err := s.AddGeneratedConversionFunc((*ConfigSetTarget)(nil), (*config.ConfigSetTarget)(nil), func(a, b interface{}, scope conversion.Scope) error { + return Convert_v1alpha1_ConfigSetTarget_To_config_ConfigSetTarget(a.(*ConfigSetTarget), b.(*config.ConfigSetTarget), scope) + }); err != nil { + return err + } + if err := s.AddGeneratedConversionFunc((*config.ConfigSetTarget)(nil), (*ConfigSetTarget)(nil), func(a, b interface{}, scope conversion.Scope) error { + return Convert_config_ConfigSetTarget_To_v1alpha1_ConfigSetTarget(a.(*config.ConfigSetTarget), b.(*ConfigSetTarget), scope) + }); err != nil { + return err + } + if err := s.AddGeneratedConversionFunc((*ConfigSetTargetStatus)(nil), (*config.ConfigSetTargetStatus)(nil), func(a, b interface{}, scope conversion.Scope) error { + return Convert_v1alpha1_ConfigSetTargetStatus_To_config_ConfigSetTargetStatus(a.(*ConfigSetTargetStatus), b.(*config.ConfigSetTargetStatus), scope) + }); err != nil { + return err + } + if err := s.AddGeneratedConversionFunc((*config.ConfigSetTargetStatus)(nil), (*ConfigSetTargetStatus)(nil), func(a, b interface{}, scope conversion.Scope) error { + return Convert_config_ConfigSetTargetStatus_To_v1alpha1_ConfigSetTargetStatus(a.(*config.ConfigSetTargetStatus), b.(*ConfigSetTargetStatus), scope) + }); err != nil { + return err + } if err := s.AddGeneratedConversionFunc((*ConfigSpec)(nil), (*config.ConfigSpec)(nil), func(a, b interface{}, scope conversion.Scope) error { return Convert_v1alpha1_ConfigSpec_To_config_ConfigSpec(a.(*ConfigSpec), b.(*config.ConfigSpec), scope) }); err != nil { @@ -218,6 +248,16 @@ func RegisterConversions(s *runtime.Scheme) error { }); err != nil { return err } + if err := s.AddGeneratedConversionFunc((*DiscoveryInfo)(nil), (*config.DiscoveryInfo)(nil), func(a, b interface{}, scope conversion.Scope) error { + return Convert_v1alpha1_DiscoveryInfo_To_config_DiscoveryInfo(a.(*DiscoveryInfo), b.(*config.DiscoveryInfo), scope) + }); err != nil { + return err + } + if err := s.AddGeneratedConversionFunc((*config.DiscoveryInfo)(nil), (*DiscoveryInfo)(nil), func(a, b interface{}, scope conversion.Scope) error { + return Convert_config_DiscoveryInfo_To_v1alpha1_DiscoveryInfo(a.(*config.DiscoveryInfo), b.(*DiscoveryInfo), scope) + }); err != nil { + return err + } if err := s.AddGeneratedConversionFunc((*Lifecycle)(nil), (*config.Lifecycle)(nil), func(a, b interface{}, scope conversion.Scope) error { return Convert_v1alpha1_Lifecycle_To_config_Lifecycle(a.(*Lifecycle), b.(*config.Lifecycle), scope) }); err != nil { @@ -328,6 +368,26 @@ func RegisterConversions(s *runtime.Scheme) error { }); err != nil { return err } + if err := s.AddGeneratedConversionFunc((*TargetList)(nil), (*config.TargetList)(nil), func(a, b interface{}, scope conversion.Scope) error { + return Convert_v1alpha1_TargetList_To_config_TargetList(a.(*TargetList), b.(*config.TargetList), scope) + }); err != nil { + return err + } + if err := s.AddGeneratedConversionFunc((*config.TargetList)(nil), (*TargetList)(nil), func(a, b interface{}, scope conversion.Scope) error { + return Convert_config_TargetList_To_v1alpha1_TargetList(a.(*config.TargetList), b.(*TargetList), scope) + }); err != nil { + return err + } + if err := s.AddGeneratedConversionFunc((*TargetSpec)(nil), (*config.TargetSpec)(nil), func(a, b interface{}, scope conversion.Scope) error { + return Convert_v1alpha1_TargetSpec_To_config_TargetSpec(a.(*TargetSpec), b.(*config.TargetSpec), scope) + }); err != nil { + return err + } + if err := s.AddGeneratedConversionFunc((*config.TargetSpec)(nil), (*TargetSpec)(nil), func(a, b interface{}, scope conversion.Scope) error { + return Convert_config_TargetSpec_To_v1alpha1_TargetSpec(a.(*config.TargetSpec), b.(*TargetSpec), scope) + }); err != nil { + return err + } if err := s.AddGeneratedConversionFunc((*TargetStatus)(nil), (*config.TargetStatus)(nil), func(a, b interface{}, scope conversion.Scope) error { return Convert_v1alpha1_TargetStatus_To_config_TargetStatus(a.(*TargetStatus), b.(*config.TargetStatus), scope) }); err != nil { @@ -338,6 +398,16 @@ func RegisterConversions(s *runtime.Scheme) error { }); err != nil { return err } + if err := s.AddGeneratedConversionFunc((*TargetStatusUsedReferences)(nil), (*config.TargetStatusUsedReferences)(nil), func(a, b interface{}, scope conversion.Scope) error { + return Convert_v1alpha1_TargetStatusUsedReferences_To_config_TargetStatusUsedReferences(a.(*TargetStatusUsedReferences), b.(*config.TargetStatusUsedReferences), scope) + }); err != nil { + return err + } + if err := s.AddGeneratedConversionFunc((*config.TargetStatusUsedReferences)(nil), (*TargetStatusUsedReferences)(nil), func(a, b interface{}, scope conversion.Scope) error { + return Convert_config_TargetStatusUsedReferences_To_v1alpha1_TargetStatusUsedReferences(a.(*config.TargetStatusUsedReferences), b.(*TargetStatusUsedReferences), scope) + }); err != nil { + return err + } if err := s.AddConversionFunc((*condition.Condition)(nil), (*conditionv1alpha1.Condition)(nil), func(a, b interface{}, scope conversion.Scope) error { return Convert_condition_Condition_To_v1alpha1_Condition(a.(*condition.Condition), b.(*conditionv1alpha1.Condition), scope) }); err != nil { @@ -510,19 +580,29 @@ func Convert_config_ConfigBlob_To_v1alpha1_ConfigBlob(in *config.ConfigBlob, out func autoConvert_v1alpha1_ConfigDeviation_To_config_ConfigDeviation(in *ConfigDeviation, out *config.ConfigDeviation, s conversion.Scope) error { out.Path = in.Path out.DesiredValue = (*string)(unsafe.Pointer(in.DesiredValue)) - // WARNING: in.ActualValue requires manual conversion: does not exist in peer-type + out.ActualValue = (*string)(unsafe.Pointer(in.ActualValue)) out.Reason = in.Reason return nil } +// Convert_v1alpha1_ConfigDeviation_To_config_ConfigDeviation is an autogenerated conversion function. +func Convert_v1alpha1_ConfigDeviation_To_config_ConfigDeviation(in *ConfigDeviation, out *config.ConfigDeviation, s conversion.Scope) error { + return autoConvert_v1alpha1_ConfigDeviation_To_config_ConfigDeviation(in, out, s) +} + func autoConvert_config_ConfigDeviation_To_v1alpha1_ConfigDeviation(in *config.ConfigDeviation, out *ConfigDeviation, s conversion.Scope) error { out.Path = in.Path out.DesiredValue = (*string)(unsafe.Pointer(in.DesiredValue)) - // WARNING: in.CurrentValue requires manual conversion: does not exist in peer-type + out.ActualValue = (*string)(unsafe.Pointer(in.ActualValue)) out.Reason = in.Reason return nil } +// Convert_config_ConfigDeviation_To_v1alpha1_ConfigDeviation is an autogenerated conversion function. +func Convert_config_ConfigDeviation_To_v1alpha1_ConfigDeviation(in *config.ConfigDeviation, out *ConfigDeviation, s conversion.Scope) error { + return autoConvert_config_ConfigDeviation_To_v1alpha1_ConfigDeviation(in, out, s) +} + func autoConvert_v1alpha1_ConfigList_To_config_ConfigList(in *ConfigList, out *config.ConfigList, s conversion.Scope) error { out.ListMeta = in.ListMeta if in.Items != nil { @@ -640,7 +720,7 @@ func Convert_config_ConfigSetList_To_v1alpha1_ConfigSetList(in *config.ConfigSet } func autoConvert_v1alpha1_ConfigSetSpec_To_config_ConfigSetSpec(in *ConfigSetSpec, out *config.ConfigSetSpec, s conversion.Scope) error { - if err := Convert_v1alpha1_Target_To_config_Target(&in.Target, &out.Target, s); err != nil { + if err := Convert_v1alpha1_ConfigSetTarget_To_config_ConfigSetTarget(&in.Target, &out.Target, s); err != nil { return err } out.Lifecycle = (*config.Lifecycle)(unsafe.Pointer(in.Lifecycle)) @@ -656,7 +736,7 @@ func Convert_v1alpha1_ConfigSetSpec_To_config_ConfigSetSpec(in *ConfigSetSpec, o } func autoConvert_config_ConfigSetSpec_To_v1alpha1_ConfigSetSpec(in *config.ConfigSetSpec, out *ConfigSetSpec, s conversion.Scope) error { - if err := Convert_config_Target_To_v1alpha1_Target(&in.Target, &out.Target, s); err != nil { + if err := Convert_config_ConfigSetTarget_To_v1alpha1_ConfigSetTarget(&in.Target, &out.Target, s); err != nil { return err } out.Lifecycle = (*Lifecycle)(unsafe.Pointer(in.Lifecycle)) @@ -677,9 +757,9 @@ func autoConvert_v1alpha1_ConfigSetStatus_To_config_ConfigSetStatus(in *ConfigSe } if in.Targets != nil { in, out := &in.Targets, &out.Targets - *out = make([]config.TargetStatus, len(*in)) + *out = make([]config.ConfigSetTargetStatus, len(*in)) for i := range *in { - if err := Convert_v1alpha1_TargetStatus_To_config_TargetStatus(&(*in)[i], &(*out)[i], s); err != nil { + if err := Convert_v1alpha1_ConfigSetTargetStatus_To_config_ConfigSetTargetStatus(&(*in)[i], &(*out)[i], s); err != nil { return err } } @@ -700,9 +780,9 @@ func autoConvert_config_ConfigSetStatus_To_v1alpha1_ConfigSetStatus(in *config.C } if in.Targets != nil { in, out := &in.Targets, &out.Targets - *out = make([]TargetStatus, len(*in)) + *out = make([]ConfigSetTargetStatus, len(*in)) for i := range *in { - if err := Convert_config_TargetStatus_To_v1alpha1_TargetStatus(&(*in)[i], &(*out)[i], s); err != nil { + if err := Convert_config_ConfigSetTargetStatus_To_v1alpha1_ConfigSetTargetStatus(&(*in)[i], &(*out)[i], s); err != nil { return err } } @@ -717,6 +797,52 @@ func Convert_config_ConfigSetStatus_To_v1alpha1_ConfigSetStatus(in *config.Confi return autoConvert_config_ConfigSetStatus_To_v1alpha1_ConfigSetStatus(in, out, s) } +func autoConvert_v1alpha1_ConfigSetTarget_To_config_ConfigSetTarget(in *ConfigSetTarget, out *config.ConfigSetTarget, s conversion.Scope) error { + out.TargetSelector = (*v1.LabelSelector)(unsafe.Pointer(in.TargetSelector)) + return nil +} + +// Convert_v1alpha1_ConfigSetTarget_To_config_ConfigSetTarget is an autogenerated conversion function. +func Convert_v1alpha1_ConfigSetTarget_To_config_ConfigSetTarget(in *ConfigSetTarget, out *config.ConfigSetTarget, s conversion.Scope) error { + return autoConvert_v1alpha1_ConfigSetTarget_To_config_ConfigSetTarget(in, out, s) +} + +func autoConvert_config_ConfigSetTarget_To_v1alpha1_ConfigSetTarget(in *config.ConfigSetTarget, out *ConfigSetTarget, s conversion.Scope) error { + out.TargetSelector = (*v1.LabelSelector)(unsafe.Pointer(in.TargetSelector)) + return nil +} + +// Convert_config_ConfigSetTarget_To_v1alpha1_ConfigSetTarget is an autogenerated conversion function. +func Convert_config_ConfigSetTarget_To_v1alpha1_ConfigSetTarget(in *config.ConfigSetTarget, out *ConfigSetTarget, s conversion.Scope) error { + return autoConvert_config_ConfigSetTarget_To_v1alpha1_ConfigSetTarget(in, out, s) +} + +func autoConvert_v1alpha1_ConfigSetTargetStatus_To_config_ConfigSetTargetStatus(in *ConfigSetTargetStatus, out *config.ConfigSetTargetStatus, s conversion.Scope) error { + out.Name = in.Name + if err := Convert_v1alpha1_Condition_To_condition_Condition(&in.Condition, &out.Condition, s); err != nil { + return err + } + return nil +} + +// Convert_v1alpha1_ConfigSetTargetStatus_To_config_ConfigSetTargetStatus is an autogenerated conversion function. +func Convert_v1alpha1_ConfigSetTargetStatus_To_config_ConfigSetTargetStatus(in *ConfigSetTargetStatus, out *config.ConfigSetTargetStatus, s conversion.Scope) error { + return autoConvert_v1alpha1_ConfigSetTargetStatus_To_config_ConfigSetTargetStatus(in, out, s) +} + +func autoConvert_config_ConfigSetTargetStatus_To_v1alpha1_ConfigSetTargetStatus(in *config.ConfigSetTargetStatus, out *ConfigSetTargetStatus, s conversion.Scope) error { + out.Name = in.Name + if err := Convert_condition_Condition_To_v1alpha1_Condition(&in.Condition, &out.Condition, s); err != nil { + return err + } + return nil +} + +// Convert_config_ConfigSetTargetStatus_To_v1alpha1_ConfigSetTargetStatus is an autogenerated conversion function. +func Convert_config_ConfigSetTargetStatus_To_v1alpha1_ConfigSetTargetStatus(in *config.ConfigSetTargetStatus, out *ConfigSetTargetStatus, s conversion.Scope) error { + return autoConvert_config_ConfigSetTargetStatus_To_v1alpha1_ConfigSetTargetStatus(in, out, s) +} + func autoConvert_v1alpha1_ConfigSpec_To_config_ConfigSpec(in *ConfigSpec, out *config.ConfigSpec, s conversion.Scope) error { out.Lifecycle = (*config.Lifecycle)(unsafe.Pointer(in.Lifecycle)) out.Priority = in.Priority @@ -917,6 +1043,40 @@ func Convert_config_DeviationStatus_To_v1alpha1_DeviationStatus(in *config.Devia return autoConvert_config_DeviationStatus_To_v1alpha1_DeviationStatus(in, out, s) } +func autoConvert_v1alpha1_DiscoveryInfo_To_config_DiscoveryInfo(in *DiscoveryInfo, out *config.DiscoveryInfo, s conversion.Scope) error { + out.Protocol = in.Protocol + out.Provider = in.Provider + out.Version = in.Version + out.Hostname = in.Hostname + out.Platform = in.Platform + out.MacAddress = in.MacAddress + out.SerialNumber = in.SerialNumber + out.SupportedEncodings = *(*[]string)(unsafe.Pointer(&in.SupportedEncodings)) + return nil +} + +// Convert_v1alpha1_DiscoveryInfo_To_config_DiscoveryInfo is an autogenerated conversion function. +func Convert_v1alpha1_DiscoveryInfo_To_config_DiscoveryInfo(in *DiscoveryInfo, out *config.DiscoveryInfo, s conversion.Scope) error { + return autoConvert_v1alpha1_DiscoveryInfo_To_config_DiscoveryInfo(in, out, s) +} + +func autoConvert_config_DiscoveryInfo_To_v1alpha1_DiscoveryInfo(in *config.DiscoveryInfo, out *DiscoveryInfo, s conversion.Scope) error { + out.Protocol = in.Protocol + out.Provider = in.Provider + out.Version = in.Version + out.Hostname = in.Hostname + out.Platform = in.Platform + out.MacAddress = in.MacAddress + out.SerialNumber = in.SerialNumber + out.SupportedEncodings = *(*[]string)(unsafe.Pointer(&in.SupportedEncodings)) + return nil +} + +// Convert_config_DiscoveryInfo_To_v1alpha1_DiscoveryInfo is an autogenerated conversion function. +func Convert_config_DiscoveryInfo_To_v1alpha1_DiscoveryInfo(in *config.DiscoveryInfo, out *DiscoveryInfo, s conversion.Scope) error { + return autoConvert_config_DiscoveryInfo_To_v1alpha1_DiscoveryInfo(in, out, s) +} + func autoConvert_v1alpha1_Lifecycle_To_config_Lifecycle(in *Lifecycle, out *config.Lifecycle, s conversion.Scope) error { out.DeletionPolicy = config.DeletionPolicy(in.DeletionPolicy) return nil @@ -1182,7 +1342,13 @@ func Convert_config_SensitiveConfigStatus_To_v1alpha1_SensitiveConfigStatus(in * } func autoConvert_v1alpha1_Target_To_config_Target(in *Target, out *config.Target, s conversion.Scope) error { - out.TargetSelector = (*v1.LabelSelector)(unsafe.Pointer(in.TargetSelector)) + out.ObjectMeta = in.ObjectMeta + if err := Convert_v1alpha1_TargetSpec_To_config_TargetSpec(&in.Spec, &out.Spec, s); err != nil { + return err + } + if err := Convert_v1alpha1_TargetStatus_To_config_TargetStatus(&in.Status, &out.Status, s); err != nil { + return err + } return nil } @@ -1192,7 +1358,13 @@ func Convert_v1alpha1_Target_To_config_Target(in *Target, out *config.Target, s } func autoConvert_config_Target_To_v1alpha1_Target(in *config.Target, out *Target, s conversion.Scope) error { - out.TargetSelector = (*v1.LabelSelector)(unsafe.Pointer(in.TargetSelector)) + out.ObjectMeta = in.ObjectMeta + if err := Convert_config_TargetSpec_To_v1alpha1_TargetSpec(&in.Spec, &out.Spec, s); err != nil { + return err + } + if err := Convert_config_TargetStatus_To_v1alpha1_TargetStatus(&in.Status, &out.Status, s); err != nil { + return err + } return nil } @@ -1201,11 +1373,78 @@ func Convert_config_Target_To_v1alpha1_Target(in *config.Target, out *Target, s return autoConvert_config_Target_To_v1alpha1_Target(in, out, s) } +func autoConvert_v1alpha1_TargetList_To_config_TargetList(in *TargetList, out *config.TargetList, s conversion.Scope) error { + out.ListMeta = in.ListMeta + if in.Items != nil { + in, out := &in.Items, &out.Items + *out = make([]config.Target, len(*in)) + for i := range *in { + if err := Convert_v1alpha1_Target_To_config_Target(&(*in)[i], &(*out)[i], s); err != nil { + return err + } + } + } else { + out.Items = nil + } + return nil +} + +// Convert_v1alpha1_TargetList_To_config_TargetList is an autogenerated conversion function. +func Convert_v1alpha1_TargetList_To_config_TargetList(in *TargetList, out *config.TargetList, s conversion.Scope) error { + return autoConvert_v1alpha1_TargetList_To_config_TargetList(in, out, s) +} + +func autoConvert_config_TargetList_To_v1alpha1_TargetList(in *config.TargetList, out *TargetList, s conversion.Scope) error { + out.ListMeta = in.ListMeta + if in.Items != nil { + in, out := &in.Items, &out.Items + *out = make([]Target, len(*in)) + for i := range *in { + if err := Convert_config_Target_To_v1alpha1_Target(&(*in)[i], &(*out)[i], s); err != nil { + return err + } + } + } else { + out.Items = nil + } + return nil +} + +// Convert_config_TargetList_To_v1alpha1_TargetList is an autogenerated conversion function. +func Convert_config_TargetList_To_v1alpha1_TargetList(in *config.TargetList, out *TargetList, s conversion.Scope) error { + return autoConvert_config_TargetList_To_v1alpha1_TargetList(in, out, s) +} + +func autoConvert_v1alpha1_TargetSpec_To_config_TargetSpec(in *TargetSpec, out *config.TargetSpec, s conversion.Scope) error { + out.Provider = in.Provider + out.Address = in.Address + out.TargetProfile = in.TargetProfile + return nil +} + +// Convert_v1alpha1_TargetSpec_To_config_TargetSpec is an autogenerated conversion function. +func Convert_v1alpha1_TargetSpec_To_config_TargetSpec(in *TargetSpec, out *config.TargetSpec, s conversion.Scope) error { + return autoConvert_v1alpha1_TargetSpec_To_config_TargetSpec(in, out, s) +} + +func autoConvert_config_TargetSpec_To_v1alpha1_TargetSpec(in *config.TargetSpec, out *TargetSpec, s conversion.Scope) error { + out.Provider = in.Provider + out.Address = in.Address + out.TargetProfile = in.TargetProfile + return nil +} + +// Convert_config_TargetSpec_To_v1alpha1_TargetSpec is an autogenerated conversion function. +func Convert_config_TargetSpec_To_v1alpha1_TargetSpec(in *config.TargetSpec, out *TargetSpec, s conversion.Scope) error { + return autoConvert_config_TargetSpec_To_v1alpha1_TargetSpec(in, out, s) +} + func autoConvert_v1alpha1_TargetStatus_To_config_TargetStatus(in *TargetStatus, out *config.TargetStatus, s conversion.Scope) error { - out.Name = in.Name - if err := Convert_v1alpha1_Condition_To_condition_Condition(&in.Condition, &out.Condition, s); err != nil { + if err := Convert_v1alpha1_ConditionedStatus_To_condition_ConditionedStatus(&in.ConditionedStatus, &out.ConditionedStatus, s); err != nil { return err } + out.DiscoveryInfo = (*config.DiscoveryInfo)(unsafe.Pointer(in.DiscoveryInfo)) + out.UsedReferences = (*config.TargetStatusUsedReferences)(unsafe.Pointer(in.UsedReferences)) return nil } @@ -1215,10 +1454,11 @@ func Convert_v1alpha1_TargetStatus_To_config_TargetStatus(in *TargetStatus, out } func autoConvert_config_TargetStatus_To_v1alpha1_TargetStatus(in *config.TargetStatus, out *TargetStatus, s conversion.Scope) error { - out.Name = in.Name - if err := Convert_condition_Condition_To_v1alpha1_Condition(&in.Condition, &out.Condition, s); err != nil { + if err := Convert_condition_ConditionedStatus_To_v1alpha1_ConditionedStatus(&in.ConditionedStatus, &out.ConditionedStatus, s); err != nil { return err } + out.DiscoveryInfo = (*DiscoveryInfo)(unsafe.Pointer(in.DiscoveryInfo)) + out.UsedReferences = (*TargetStatusUsedReferences)(unsafe.Pointer(in.UsedReferences)) return nil } @@ -1226,3 +1466,29 @@ func autoConvert_config_TargetStatus_To_v1alpha1_TargetStatus(in *config.TargetS func Convert_config_TargetStatus_To_v1alpha1_TargetStatus(in *config.TargetStatus, out *TargetStatus, s conversion.Scope) error { return autoConvert_config_TargetStatus_To_v1alpha1_TargetStatus(in, out, s) } + +func autoConvert_v1alpha1_TargetStatusUsedReferences_To_config_TargetStatusUsedReferences(in *TargetStatusUsedReferences, out *config.TargetStatusUsedReferences, s conversion.Scope) error { + out.SecretResourceVersion = in.SecretResourceVersion + out.TLSSecretResourceVersion = in.TLSSecretResourceVersion + out.ConnectionProfileResourceVersion = in.ConnectionProfileResourceVersion + out.SyncProfileResourceVersion = in.SyncProfileResourceVersion + return nil +} + +// Convert_v1alpha1_TargetStatusUsedReferences_To_config_TargetStatusUsedReferences is an autogenerated conversion function. +func Convert_v1alpha1_TargetStatusUsedReferences_To_config_TargetStatusUsedReferences(in *TargetStatusUsedReferences, out *config.TargetStatusUsedReferences, s conversion.Scope) error { + return autoConvert_v1alpha1_TargetStatusUsedReferences_To_config_TargetStatusUsedReferences(in, out, s) +} + +func autoConvert_config_TargetStatusUsedReferences_To_v1alpha1_TargetStatusUsedReferences(in *config.TargetStatusUsedReferences, out *TargetStatusUsedReferences, s conversion.Scope) error { + out.SecretResourceVersion = in.SecretResourceVersion + out.TLSSecretResourceVersion = in.TLSSecretResourceVersion + out.ConnectionProfileResourceVersion = in.ConnectionProfileResourceVersion + out.SyncProfileResourceVersion = in.SyncProfileResourceVersion + return nil +} + +// Convert_config_TargetStatusUsedReferences_To_v1alpha1_TargetStatusUsedReferences is an autogenerated conversion function. +func Convert_config_TargetStatusUsedReferences_To_v1alpha1_TargetStatusUsedReferences(in *config.TargetStatusUsedReferences, out *TargetStatusUsedReferences, s conversion.Scope) error { + return autoConvert_config_TargetStatusUsedReferences_To_v1alpha1_TargetStatusUsedReferences(in, out, s) +} diff --git a/apis/config/v1alpha1/zz_generated.deepcopy.go b/apis/config/v1alpha1/zz_generated.deepcopy.go index dca45f42..d5b1ca11 100644 --- a/apis/config/v1alpha1/zz_generated.deepcopy.go +++ b/apis/config/v1alpha1/zz_generated.deepcopy.go @@ -324,7 +324,7 @@ func (in *ConfigSetStatus) DeepCopyInto(out *ConfigSetStatus) { in.ConditionedStatus.DeepCopyInto(&out.ConditionedStatus) if in.Targets != nil { in, out := &in.Targets, &out.Targets - *out = make([]TargetStatus, len(*in)) + *out = make([]ConfigSetTargetStatus, len(*in)) for i := range *in { (*in)[i].DeepCopyInto(&(*out)[i]) } @@ -342,6 +342,44 @@ func (in *ConfigSetStatus) DeepCopy() *ConfigSetStatus { return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *ConfigSetTarget) DeepCopyInto(out *ConfigSetTarget) { + *out = *in + if in.TargetSelector != nil { + in, out := &in.TargetSelector, &out.TargetSelector + *out = new(v1.LabelSelector) + (*in).DeepCopyInto(*out) + } + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ConfigSetTarget. +func (in *ConfigSetTarget) DeepCopy() *ConfigSetTarget { + if in == nil { + return nil + } + out := new(ConfigSetTarget) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *ConfigSetTargetStatus) DeepCopyInto(out *ConfigSetTargetStatus) { + *out = *in + in.Condition.DeepCopyInto(&out.Condition) + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ConfigSetTargetStatus. +func (in *ConfigSetTargetStatus) DeepCopy() *ConfigSetTargetStatus { + if in == nil { + return nil + } + out := new(ConfigSetTargetStatus) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *ConfigSpec) DeepCopyInto(out *ConfigSpec) { *out = *in @@ -529,6 +567,27 @@ func (in *DeviationStatus) DeepCopy() *DeviationStatus { return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *DiscoveryInfo) DeepCopyInto(out *DiscoveryInfo) { + *out = *in + if in.SupportedEncodings != nil { + in, out := &in.SupportedEncodings, &out.SupportedEncodings + *out = make([]string, len(*in)) + copy(*out, *in) + } + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DiscoveryInfo. +func (in *DiscoveryInfo) DeepCopy() *DiscoveryInfo { + if in == nil { + return nil + } + out := new(DiscoveryInfo) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *Lifecycle) DeepCopyInto(out *Lifecycle) { *out = *in @@ -785,11 +844,10 @@ func (in *SensitiveConfigStatus) DeepCopy() *SensitiveConfigStatus { // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *Target) DeepCopyInto(out *Target) { *out = *in - if in.TargetSelector != nil { - in, out := &in.TargetSelector, &out.TargetSelector - *out = new(v1.LabelSelector) - (*in).DeepCopyInto(*out) - } + out.TypeMeta = in.TypeMeta + in.ObjectMeta.DeepCopyInto(&out.ObjectMeta) + in.Spec.DeepCopyInto(&out.Spec) + in.Status.DeepCopyInto(&out.Status) return } @@ -803,10 +861,78 @@ func (in *Target) DeepCopy() *Target { return out } +// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. +func (in *Target) DeepCopyObject() runtime.Object { + if c := in.DeepCopy(); c != nil { + return c + } + return nil +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *TargetList) DeepCopyInto(out *TargetList) { + *out = *in + out.TypeMeta = in.TypeMeta + in.ListMeta.DeepCopyInto(&out.ListMeta) + if in.Items != nil { + in, out := &in.Items, &out.Items + *out = make([]Target, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new TargetList. +func (in *TargetList) DeepCopy() *TargetList { + if in == nil { + return nil + } + out := new(TargetList) + in.DeepCopyInto(out) + return out +} + +// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. +func (in *TargetList) DeepCopyObject() runtime.Object { + if c := in.DeepCopy(); c != nil { + return c + } + return nil +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *TargetSpec) DeepCopyInto(out *TargetSpec) { + *out = *in + in.TargetProfile.DeepCopyInto(&out.TargetProfile) + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new TargetSpec. +func (in *TargetSpec) DeepCopy() *TargetSpec { + if in == nil { + return nil + } + out := new(TargetSpec) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *TargetStatus) DeepCopyInto(out *TargetStatus) { *out = *in - in.Condition.DeepCopyInto(&out.Condition) + in.ConditionedStatus.DeepCopyInto(&out.ConditionedStatus) + if in.DiscoveryInfo != nil { + in, out := &in.DiscoveryInfo, &out.DiscoveryInfo + *out = new(DiscoveryInfo) + (*in).DeepCopyInto(*out) + } + if in.UsedReferences != nil { + in, out := &in.UsedReferences, &out.UsedReferences + *out = new(TargetStatusUsedReferences) + **out = **in + } return } @@ -819,3 +945,19 @@ func (in *TargetStatus) DeepCopy() *TargetStatus { in.DeepCopyInto(out) return out } + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *TargetStatusUsedReferences) DeepCopyInto(out *TargetStatusUsedReferences) { + *out = *in + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new TargetStatusUsedReferences. +func (in *TargetStatusUsedReferences) DeepCopy() *TargetStatusUsedReferences { + if in == nil { + return nil + } + out := new(TargetStatusUsedReferences) + in.DeepCopyInto(out) + return out +} diff --git a/apis/config/zz_generated.deepcopy.go b/apis/config/zz_generated.deepcopy.go index ea249c76..733769a4 100644 --- a/apis/config/zz_generated.deepcopy.go +++ b/apis/config/zz_generated.deepcopy.go @@ -188,8 +188,8 @@ func (in *ConfigDeviation) DeepCopyInto(out *ConfigDeviation) { *out = new(string) **out = **in } - if in.CurrentValue != nil { - in, out := &in.CurrentValue, &out.CurrentValue + if in.ActualValue != nil { + in, out := &in.ActualValue, &out.ActualValue *out = new(string) **out = **in } @@ -372,7 +372,7 @@ func (in *ConfigSetStatus) DeepCopyInto(out *ConfigSetStatus) { in.ConditionedStatus.DeepCopyInto(&out.ConditionedStatus) if in.Targets != nil { in, out := &in.Targets, &out.Targets - *out = make([]TargetStatus, len(*in)) + *out = make([]ConfigSetTargetStatus, len(*in)) for i := range *in { (*in)[i].DeepCopyInto(&(*out)[i]) } @@ -390,6 +390,44 @@ func (in *ConfigSetStatus) DeepCopy() *ConfigSetStatus { return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *ConfigSetTarget) DeepCopyInto(out *ConfigSetTarget) { + *out = *in + if in.TargetSelector != nil { + in, out := &in.TargetSelector, &out.TargetSelector + *out = new(v1.LabelSelector) + (*in).DeepCopyInto(*out) + } + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ConfigSetTarget. +func (in *ConfigSetTarget) DeepCopy() *ConfigSetTarget { + if in == nil { + return nil + } + out := new(ConfigSetTarget) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *ConfigSetTargetStatus) DeepCopyInto(out *ConfigSetTargetStatus) { + *out = *in + in.Condition.DeepCopyInto(&out.Condition) + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ConfigSetTargetStatus. +func (in *ConfigSetTargetStatus) DeepCopy() *ConfigSetTargetStatus { + if in == nil { + return nil + } + out := new(ConfigSetTargetStatus) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *ConfigSpec) DeepCopyInto(out *ConfigSpec) { *out = *in @@ -720,6 +758,27 @@ func (in *DeviationStatus) DeepCopy() *DeviationStatus { return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *DiscoveryInfo) DeepCopyInto(out *DiscoveryInfo) { + *out = *in + if in.SupportedEncodings != nil { + in, out := &in.SupportedEncodings, &out.SupportedEncodings + *out = make([]string, len(*in)) + copy(*out, *in) + } + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DiscoveryInfo. +func (in *DiscoveryInfo) DeepCopy() *DiscoveryInfo { + if in == nil { + return nil + } + out := new(DiscoveryInfo) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *Lifecycle) DeepCopyInto(out *Lifecycle) { *out = *in @@ -1044,11 +1103,10 @@ func (in *SensitiveConfigStatus) DeepCopy() *SensitiveConfigStatus { // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *Target) DeepCopyInto(out *Target) { *out = *in - if in.TargetSelector != nil { - in, out := &in.TargetSelector, &out.TargetSelector - *out = new(v1.LabelSelector) - (*in).DeepCopyInto(*out) - } + out.TypeMeta = in.TypeMeta + in.ObjectMeta.DeepCopyInto(&out.ObjectMeta) + in.Spec.DeepCopyInto(&out.Spec) + in.Status.DeepCopyInto(&out.Status) return } @@ -1062,10 +1120,94 @@ func (in *Target) DeepCopy() *Target { return out } +// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. +func (in *Target) DeepCopyObject() runtime.Object { + if c := in.DeepCopy(); c != nil { + return c + } + return nil +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *TargetFilter) DeepCopyInto(out *TargetFilter) { + *out = *in + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new TargetFilter. +func (in *TargetFilter) DeepCopy() *TargetFilter { + if in == nil { + return nil + } + out := new(TargetFilter) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *TargetList) DeepCopyInto(out *TargetList) { + *out = *in + out.TypeMeta = in.TypeMeta + in.ListMeta.DeepCopyInto(&out.ListMeta) + if in.Items != nil { + in, out := &in.Items, &out.Items + *out = make([]Target, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new TargetList. +func (in *TargetList) DeepCopy() *TargetList { + if in == nil { + return nil + } + out := new(TargetList) + in.DeepCopyInto(out) + return out +} + +// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. +func (in *TargetList) DeepCopyObject() runtime.Object { + if c := in.DeepCopy(); c != nil { + return c + } + return nil +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *TargetSpec) DeepCopyInto(out *TargetSpec) { + *out = *in + in.TargetProfile.DeepCopyInto(&out.TargetProfile) + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new TargetSpec. +func (in *TargetSpec) DeepCopy() *TargetSpec { + if in == nil { + return nil + } + out := new(TargetSpec) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *TargetStatus) DeepCopyInto(out *TargetStatus) { *out = *in - in.Condition.DeepCopyInto(&out.Condition) + in.ConditionedStatus.DeepCopyInto(&out.ConditionedStatus) + if in.DiscoveryInfo != nil { + in, out := &in.DiscoveryInfo, &out.DiscoveryInfo + *out = new(DiscoveryInfo) + (*in).DeepCopyInto(*out) + } + if in.UsedReferences != nil { + in, out := &in.UsedReferences, &out.UsedReferences + *out = new(TargetStatusUsedReferences) + **out = **in + } return } @@ -1078,3 +1220,19 @@ func (in *TargetStatus) DeepCopy() *TargetStatus { in.DeepCopyInto(out) return out } + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *TargetStatusUsedReferences) DeepCopyInto(out *TargetStatusUsedReferences) { + *out = *in + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new TargetStatusUsedReferences. +func (in *TargetStatusUsedReferences) DeepCopy() *TargetStatusUsedReferences { + if in == nil { + return nil + } + out := new(TargetStatusUsedReferences) + in.DeepCopyInto(out) + return out +} diff --git a/apis/inv/v1alpha1/condition.go b/apis/inv/v1alpha1/condition.go index a77e7cc4..8091189a 100644 --- a/apis/inv/v1alpha1/condition.go +++ b/apis/inv/v1alpha1/condition.go @@ -23,19 +23,23 @@ import ( // Condition Types. const ( - // ConditionTypeDiscoveryReady represents the resource discovery ready condition - ConditionTypeDiscoveryReady condv1alpha1.ConditionType = "DiscoveryReady" - // ConditionTypeDatastoreReady represents the resource datastore ready condition - ConditionTypeDatastoreReady condv1alpha1.ConditionType = "DatastoreReady" - // ConditionTypeConfigRecoveryReady represents the resource config recovery ready condition - ConditionTypeConfigRecoveryReady condv1alpha1.ConditionType = "ConfigRecoveryReady" - // ConditionTypeTargetConnectionReady represents the resource target ready condition - ConditionTypeTargetConnectionReady condv1alpha1.ConditionType = "TargetConnectionReady" - + /* + // ConditionTypeDiscoveryReady represents the resource discovery ready condition + ConditionTypeDiscoveryReady condv1alpha1.ConditionType = "DiscoveryReady" + // ConditionTypeDatastoreReady represents the resource datastore ready condition + ConditionTypeDatastoreReady condv1alpha1.ConditionType = "DatastoreReady" + // ConditionTypeConfigRecoveryReady represents the resource config recovery ready condition + ConditionTypeConfigRecoveryReady condv1alpha1.ConditionType = "ConfigRecoveryReady" + // ConditionTypeTargetConnectionReady represents the resource target ready condition + ConditionTypeTargetConnectionReady condv1alpha1.ConditionType = "TargetConnectionReady" + */ + + // Rollout Conditions ConditionTypeConfigApply condv1alpha1.ConditionType = "ConfigApply" ConditionTypeConfigConfirm condv1alpha1.ConditionType = "ConfigConfirm" ConditionTypeConfigCancel condv1alpha1.ConditionType = "ConfigCancel" + // Schema Conditions ConditionTypeSchemaServerReady condv1alpha1.ConditionType = "SchemaServerReady" ) @@ -89,125 +93,7 @@ func Loading() condv1alpha1.Condition { }} } -// DatastoreReady indicates the datastire is ready -func DatastoreReady() condv1alpha1.Condition { - return condv1alpha1.Condition{Condition: metav1.Condition{ - Type: string(ConditionTypeDatastoreReady), - Status: metav1.ConditionTrue, - LastTransitionTime: metav1.Now(), - Reason: string(condv1alpha1.ConditionReasonReady), - }} -} - -// DatastoreFailed returns a condition that indicates the datastore -// failed to get reconciled. -func DatastoreFailed(msg string) condv1alpha1.Condition { - return condv1alpha1.Condition{Condition: metav1.Condition{ - Type: string(ConditionTypeDatastoreReady), - Status: metav1.ConditionFalse, - LastTransitionTime: metav1.Now(), - Reason: string(condv1alpha1.ConditionReasonFailed), - Message: msg, - }} -} - -// DatastoreSchemaNotReady returns a condition that indicates the schema -// of the datastore is not ready. -func DatastoreSchemaNotReady(msg string) condv1alpha1.Condition { - return condv1alpha1.Condition{Condition: metav1.Condition{ - Type: string(ConditionTypeDatastoreReady), - Status: metav1.ConditionFalse, - LastTransitionTime: metav1.Now(), - Reason: string(ConditionReasonSchemaNotReady), - Message: msg, - }} -} - -// ConfigRecoveryReady return a condition that indicates the config -// get re-applied when the target became ready -func ConfigRecoveryReady(msg string) condv1alpha1.Condition { - return condv1alpha1.Condition{Condition: metav1.Condition{ - Type: string(ConditionTypeConfigRecoveryReady), - Status: metav1.ConditionTrue, - LastTransitionTime: metav1.Now(), - Reason: string(condv1alpha1.ConditionReasonReady), - Message: msg, - }} -} - -// ConfigRecoveryFailed returns a condition that indicates the config -// is in failed condition due to a dependency -func ConfigRecoveryFailed(msg string) condv1alpha1.Condition { - return condv1alpha1.Condition{Condition: metav1.Condition{ - Type: string(ConditionTypeConfigRecoveryReady), - Status: metav1.ConditionFalse, - LastTransitionTime: metav1.Now(), - Reason: string(condv1alpha1.ConditionReasonFailed), - Message: msg, - }} -} - -// ConfigRecoveryReApplyFailed returns a condition that indicates the config -// we we reapplied to the target -func ConfigRecoveryReApplyFailed(msg string) condv1alpha1.Condition { - return condv1alpha1.Condition{Condition: metav1.Condition{ - Type: string(ConditionTypeConfigRecoveryReady), - Status: metav1.ConditionFalse, - LastTransitionTime: metav1.Now(), - Reason: string(ConditionReasonReApplyFailed), - Message: msg, - }} -} - -// DiscoveryReady return a condition that indicates the discovery -// is ready -func DiscoveryReady() condv1alpha1.Condition { - return condv1alpha1.Condition{Condition: metav1.Condition{ - Type: string(ConditionTypeDiscoveryReady), - Status: metav1.ConditionTrue, - LastTransitionTime: metav1.Now(), - Reason: string(condv1alpha1.ConditionReasonReady), - }} -} - -// DiscoveryFailed returns a condition that indicates the discovery -// is in failed condition -func DiscoveryFailed(msg string) condv1alpha1.Condition { - return condv1alpha1.Condition{Condition: metav1.Condition{ - Type: string(ConditionTypeDiscoveryReady), - Status: metav1.ConditionFalse, - LastTransitionTime: metav1.Now(), - Reason: string(condv1alpha1.ConditionReasonFailed), - Message: msg, - }} -} - -// TargetConnectionReady return a condition that indicates the target connection -// is ready -func TargetConnectionReady() condv1alpha1.Condition { - return condv1alpha1.Condition{Condition: metav1.Condition{ - Type: string(ConditionTypeTargetConnectionReady), - Status: metav1.ConditionTrue, - LastTransitionTime: metav1.Now(), - Reason: string(condv1alpha1.ConditionReasonReady), - }} -} - -// TargetConnectionFailed returns a condition that indicates the target connection -// is in failed condition -func TargetConnectionFailed(msg string) condv1alpha1.Condition { - return condv1alpha1.Condition{Condition: metav1.Condition{ - Type: string(ConditionTypeTargetConnectionReady), - Status: metav1.ConditionFalse, - LastTransitionTime: metav1.Now(), - Reason: string(condv1alpha1.ConditionReasonFailed), - Message: msg, - }} -} - -// TargetConnectionFailed returns a condition that indicates the target connection -// is in failed condition - +// Config Rollout Conditions func ConfigApplyReady() condv1alpha1.Condition { return condv1alpha1.Condition{Condition: metav1.Condition{ Type: string(ConditionTypeConfigApply), @@ -284,6 +170,7 @@ func ConfigCancelFailed(msg string) condv1alpha1.Condition { }} } +// Schema server conditions func SchemaServerReady() condv1alpha1.Condition { return condv1alpha1.Condition{Condition: metav1.Condition{ Type: string(ConditionTypeSchemaServerReady), diff --git a/apis/inv/v1alpha1/discoveryrule_types.go b/apis/inv/v1alpha1/discoveryrule_types.go index c4ddb45b..25fbab97 100644 --- a/apis/inv/v1alpha1/discoveryrule_types.go +++ b/apis/inv/v1alpha1/discoveryrule_types.go @@ -38,94 +38,94 @@ const ( type DiscoveryRuleSpec struct { // IP Prefixes for which this discovery rule applies // +listType=atomic - Prefixes []DiscoveryRulePrefix `json:"prefixes,omitempty" yaml:"prefixes,omitempty" protobuf:"bytes,1,rep,name=prefixes"` + Prefixes []DiscoveryRulePrefix `json:"prefixes,omitempty" protobuf:"bytes,1,rep,name=prefixes"` // IP Prefixes for which this discovery rule applies // +listType=atomic - Addresses []DiscoveryRuleAddress `json:"addresses,omitempty" yaml:"addresses,omitempty" protobuf:"bytes,2,rep,name=addresses"` + Addresses []DiscoveryRuleAddress `json:"addresses,omitempty" protobuf:"bytes,2,rep,name=addresses"` // PodSelector defines the pod selector for which this discovery rule applies - PodSelector *metav1.LabelSelector `json:"podSelector,omitempty" yaml:"podSelector,omitempty" protobuf:"bytes,3,opt,name=podSelector"` + PodSelector *metav1.LabelSelector `json:"podSelector,omitempty" protobuf:"bytes,3,opt,name=podSelector"` // ServiceSelector defines the service selector for which this discovery rule applies - ServiceSelector *metav1.LabelSelector `json:"serviceSelector,omitempty" yaml:"serviceSelector,omitempty" protobuf:"bytes,4,opt,name=serviceSelector"` + ServiceSelector *metav1.LabelSelector `json:"serviceSelector,omitempty" protobuf:"bytes,4,opt,name=serviceSelector"` // ServiceDomain defines the service domain of the cluster, used by svc discovery to identify the // domain name in the k8s cluster where the service reside. - ServiceDomain string `json:"serviceDomain,omitempty" yaml:"serviceDomain,omitempty" protobuf:"bytes,5,opt,name=serviceDomain"` + ServiceDomain string `json:"serviceDomain,omitempty" protobuf:"bytes,5,opt,name=serviceDomain"` // Discovery defines the generic parameters of the discovery rule - DiscoveryParameters `json:",inline" yaml:",inline" protobuf:"bytes,6,opt,name=discoveryParameters"` + DiscoveryParameters `json:",inline" protobuf:"bytes,6,opt,name=discoveryParameters"` } type DiscoveryParameters struct { // DefaultSchema define the default schema used to connect to a target // Indicates that discovery is disable; cannot be used for prefix based discovery rules - DefaultSchema *SchemaKey `json:"defaultSchema,omitempty" yaml:"defaultSchema,omitempty" protobuf:"bytes,1,opt,name=defaultSchema"` + DefaultSchema *SchemaKey `json:"defaultSchema,omitempty" protobuf:"bytes,1,opt,name=defaultSchema"` // DiscoveryProfile define the profiles the discovery controller uses to discover targets - DiscoveryProfile *DiscoveryProfile `json:"discoveryProfile,omitempty" yaml:"discoveryProfile,omitempty" protobuf:"bytes,2,opt,name=discoveryProfile"` + DiscoveryProfile *DiscoveryProfile `json:"discoveryProfile,omitempty" protobuf:"bytes,2,opt,name=discoveryProfile"` // TargetConnectionProfiles define the profile the discovery controller uses to create targets // once discovered // +listType=atomic - TargetConnectionProfiles []TargetProfile `json:"targetConnectionProfiles" yaml:"targetConnectionProfiles" protobuf:"bytes,3,rep,name=targetConnectionProfiles"` + TargetConnectionProfiles []TargetProfile `json:"targetConnectionProfiles" protobuf:"bytes,3,rep,name=targetConnectionProfiles"` // TargetTemplate defines the template the discovery controller uses to create the targets as a result of the discovery - TargetTemplate *TargetTemplate `json:"targetTemplate,omitempty" yaml:"targetTemplate,omitempty" protobuf:"bytes,4,opt,name=targetTemplate"` + TargetTemplate *TargetTemplate `json:"targetTemplate,omitempty" protobuf:"bytes,4,opt,name=targetTemplate"` // Period defines the wait period between discovery rule runs - Period metav1.Duration `json:"period,omitempty" yaml:"period,omitempty" protobuf:"bytes,5,opt,name=period"` + Period metav1.Duration `json:"period,omitempty" protobuf:"bytes,5,opt,name=period"` // number of concurrent IP scan - ConcurrentScans int64 `json:"concurrentScans,omitempty" yaml:"concurrentScans,omitempty" protobuf:"varint,6,opt,name=concurrentScans"` + ConcurrentScans int64 `json:"concurrentScans,omitempty" protobuf:"varint,6,opt,name=concurrentScans"` } type DiscoveryRulePrefix struct { // Prefix of the target/target(s) - Prefix string `json:"prefix" yaml:"prefix" protobuf:"bytes,1,opt,name=prefix"` + Prefix string `json:"prefix" protobuf:"bytes,1,opt,name=prefix"` // IP Prefixes to be excluded // +listType=atomic - Excludes []string `json:"excludes,omitempty" yaml:"excludes,omitempty" protobuf:"bytes,2,rep,name=excludes"` + Excludes []string `json:"excludes,omitempty" protobuf:"bytes,2,rep,name=excludes"` } type DiscoveryRuleAddress struct { // Address (specified as IP or DNS name) of the target/target(s) - Address string `json:"address" yaml:"address" protobuf:"bytes,1,opt,name=address"` + Address string `json:"address" protobuf:"bytes,1,opt,name=address"` // HostName of the ip prefix; used for /32 or /128 addresses with discovery disabled - HostName string `json:"hostName,omitempty" yaml:"hostName,omitempty" protobuf:"bytes,2,opt,name=hostName"` + HostName string `json:"hostName,omitempty" protobuf:"bytes,2,opt,name=hostName"` } type DiscoveryProfile struct { // Credentials defines the name of the secret that holds the credentials to connect to the target - Credentials string `json:"credentials" yaml:"credentials" protobuf:"bytes,1,opt,name=credentials"` + Credentials string `json:"credentials" protobuf:"bytes,1,opt,name=credentials"` // TLSSecret defines the name of the TLS secret to connect to the target if mtls is used - TLSSecret *string `json:"tlsSecret,omitempty" yaml:"tlsSecret,omitempty" protobuf:"bytes,2,opt,name=tlsSecret"` + TLSSecret *string `json:"tlsSecret,omitempty" protobuf:"bytes,2,opt,name=tlsSecret"` // ConnectionProfiles define the list of profiles the discovery controller uses to discover the target. // The order in which they are specified is the order in which discovery is executed. // +listType=atomic - ConnectionProfiles []string `json:"connectionProfiles" yaml:"connectionProfiles" protobuf:"bytes,3,rep,name=connectionProfiles"` + ConnectionProfiles []string `json:"connectionProfiles" protobuf:"bytes,3,rep,name=connectionProfiles"` } type TargetProfile struct { // Credentials defines the name of the secret that holds the credentials to connect to the target - Credentials string `json:"credentials" yaml:"credentials" protobuf:"bytes,1,opt,name=credentials"` + Credentials string `json:"credentials" protobuf:"bytes,1,opt,name=credentials"` // TLSSecret defines the name of the TLS secret to connect to the target if mtls is used - TLSSecret *string `json:"tlsSecret,omitempty" yaml:"tlsSecret,omitempty" protobuf:"bytes,2,opt,name=tlsSecret"` + TLSSecret *string `json:"tlsSecret,omitempty" protobuf:"bytes,2,opt,name=tlsSecret"` // ConnectionProfile define the profile used to connect to the target once discovered - ConnectionProfile string `json:"connectionProfile" yaml:"connectionProfile" protobuf:"bytes,3,opt,name=connectionProfile"` + ConnectionProfile string `json:"connectionProfile" protobuf:"bytes,3,opt,name=connectionProfile"` // SyncProfile define the profile used to sync to the target config once discovered - SyncProfile *string `json:"syncProfile,omitempty" yaml:"syncProfile,omitempty" protobuf:"bytes,4,opt,name=syncProfile"` + SyncProfile *string `json:"syncProfile,omitempty" protobuf:"bytes,4,opt,name=syncProfile"` } // TargetTemplate defines the template of the target type TargetTemplate struct { // +kubebuilder:validation:XValidation:rule="self == oldSelf",message="nameTemplate is immutable" // target name template - NameTemplate string `json:"nameTemplate,omitempty" yaml:"nameTemplate,omitempty" protobuf:"bytes,1,opt,name=nameTemplate"` + NameTemplate string `json:"nameTemplate,omitempty" protobuf:"bytes,1,opt,name=nameTemplate"` // Annotations is a key value map to be copied to the target CR. // +optional - Annotations map[string]string `json:"annotations,omitempty" yaml:"annotations,omitempty" protobuf:"bytes,2,rep,name=annotations"` + Annotations map[string]string `json:"annotations,omitempty" protobuf:"bytes,2,rep,name=annotations"` // Labels is a key value map to be copied to the target CR. // +optional - Labels map[string]string `json:"labels,omitempty" yaml:"labels,omitempty" protobuf:"bytes,3,rep,name=labels"` + Labels map[string]string `json:"labels,omitempty" protobuf:"bytes,3,rep,name=labels"` } type SchemaKey struct { // Provider specifies the provider of the schema. - Provider string `json:"provider" yaml:"provider" protobuf:"bytes,1,opt,name=provider"` + Provider string `json:"provider" protobuf:"bytes,1,opt,name=provider"` // Version defines the version of the schema - Version string `json:"version" yaml:"version" protobuf:"bytes,2,opt,name=version"` + Version string `json:"version" protobuf:"bytes,2,opt,name=version"` } // DiscoveryRuleStatus defines the observed state of DiscoveryRule @@ -135,9 +135,9 @@ type DiscoveryRuleStatus struct { // - a condition for the reconcilation status // - a condition for the ready status // if both are true the other attributes in the status are meaningful - condv1alpha1.ConditionedStatus `json:",inline" yaml:",inline" protobuf:"bytes,1,opt,name=conditionedStatus"` + condv1alpha1.ConditionedStatus `json:",inline" protobuf:"bytes,1,opt,name=conditionedStatus"` // StartTime identifies when the dr got started - StartTime *metav1.Time `json:"startTime,omitempty" yaml:"startTime,omitempty" protobuf:"bytes,2,opt,name=startTime"` + StartTime *metav1.Time `json:"startTime,omitempty" protobuf:"bytes,2,opt,name=startTime"` } // +kubebuilder:object:root=true @@ -150,20 +150,20 @@ type DiscoveryRuleStatus struct { // DiscoveryRule is the Schema for the DiscoveryRule API // +k8s:openapi-gen=true type DiscoveryRule struct { - metav1.TypeMeta `json:",inline" yaml:",inline"` - metav1.ObjectMeta `json:"metadata,omitempty" yaml:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + metav1.TypeMeta `json:",inline"` + metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` - Spec DiscoveryRuleSpec `json:"spec,omitempty" yaml:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"` - Status DiscoveryRuleStatus `json:"status,omitempty" yaml:"status,omitempty" protobuf:"bytes,3,opt,name=status"` + Spec DiscoveryRuleSpec `json:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"` + Status DiscoveryRuleStatus `json:"status,omitempty" protobuf:"bytes,3,opt,name=status"` } // +kubebuilder:object:root=true // DiscoveryRuleList contains a list of DiscoveryRules // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object type DiscoveryRuleList struct { - metav1.TypeMeta `json:",inline" yaml:",inline"` - metav1.ListMeta `json:"metadata,omitempty" yaml:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` - Items []DiscoveryRule `json:"items" yaml:"items" protobuf:"bytes,2,rep,name=items"` + metav1.TypeMeta `json:",inline"` + metav1.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + Items []DiscoveryRule `json:"items" protobuf:"bytes,2,rep,name=items"` } func init() { diff --git a/apis/inv/v1alpha1/generated.pb.go b/apis/inv/v1alpha1/generated.pb.go index 92d1da1b..5b7dea38 100644 --- a/apis/inv/v1alpha1/generated.pb.go +++ b/apis/inv/v1alpha1/generated.pb.go @@ -22,1819 +22,684 @@ import ( fmt "fmt" io "io" + "sort" - proto "github.com/gogo/protobuf/proto" - github_com_gogo_protobuf_sortkeys "github.com/gogo/protobuf/sortkeys" v1 "k8s.io/apimachinery/pkg/apis/meta/v1" - math "math" math_bits "math/bits" reflect "reflect" strings "strings" ) -// Reference imports to suppress errors if they are not otherwise used. -var _ = proto.Marshal -var _ = fmt.Errorf -var _ = math.Inf +func (m *DiscoveryParameters) Reset() { *m = DiscoveryParameters{} } -// This is a compile-time assertion to ensure that this generated file -// is compatible with the proto package it is being compiled against. -// A compilation error at this line likely means your copy of the -// proto package needs to be updated. -const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package +func (m *DiscoveryPathDefinition) Reset() { *m = DiscoveryPathDefinition{} } -func (m *DiscoveryInfo) Reset() { *m = DiscoveryInfo{} } -func (*DiscoveryInfo) ProtoMessage() {} -func (*DiscoveryInfo) Descriptor() ([]byte, []int) { - return fileDescriptor_c428ff1fee4945a0, []int{0} -} -func (m *DiscoveryInfo) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *DiscoveryInfo) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err - } - return b[:n], nil -} -func (m *DiscoveryInfo) XXX_Merge(src proto.Message) { - xxx_messageInfo_DiscoveryInfo.Merge(m, src) -} -func (m *DiscoveryInfo) XXX_Size() int { - return m.Size() -} -func (m *DiscoveryInfo) XXX_DiscardUnknown() { - xxx_messageInfo_DiscoveryInfo.DiscardUnknown(m) -} +func (m *DiscoveryProfile) Reset() { *m = DiscoveryProfile{} } -var xxx_messageInfo_DiscoveryInfo proto.InternalMessageInfo +func (m *DiscoveryRule) Reset() { *m = DiscoveryRule{} } -func (m *DiscoveryParameters) Reset() { *m = DiscoveryParameters{} } -func (*DiscoveryParameters) ProtoMessage() {} -func (*DiscoveryParameters) Descriptor() ([]byte, []int) { - return fileDescriptor_c428ff1fee4945a0, []int{1} -} -func (m *DiscoveryParameters) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *DiscoveryParameters) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err - } - return b[:n], nil -} -func (m *DiscoveryParameters) XXX_Merge(src proto.Message) { - xxx_messageInfo_DiscoveryParameters.Merge(m, src) -} -func (m *DiscoveryParameters) XXX_Size() int { - return m.Size() -} -func (m *DiscoveryParameters) XXX_DiscardUnknown() { - xxx_messageInfo_DiscoveryParameters.DiscardUnknown(m) -} +func (m *DiscoveryRuleAddress) Reset() { *m = DiscoveryRuleAddress{} } -var xxx_messageInfo_DiscoveryParameters proto.InternalMessageInfo +func (m *DiscoveryRuleList) Reset() { *m = DiscoveryRuleList{} } -func (m *DiscoveryPathDefinition) Reset() { *m = DiscoveryPathDefinition{} } -func (*DiscoveryPathDefinition) ProtoMessage() {} -func (*DiscoveryPathDefinition) Descriptor() ([]byte, []int) { - return fileDescriptor_c428ff1fee4945a0, []int{2} -} -func (m *DiscoveryPathDefinition) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *DiscoveryPathDefinition) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err - } - return b[:n], nil -} -func (m *DiscoveryPathDefinition) XXX_Merge(src proto.Message) { - xxx_messageInfo_DiscoveryPathDefinition.Merge(m, src) -} -func (m *DiscoveryPathDefinition) XXX_Size() int { - return m.Size() -} -func (m *DiscoveryPathDefinition) XXX_DiscardUnknown() { - xxx_messageInfo_DiscoveryPathDefinition.DiscardUnknown(m) -} +func (m *DiscoveryRulePrefix) Reset() { *m = DiscoveryRulePrefix{} } -var xxx_messageInfo_DiscoveryPathDefinition proto.InternalMessageInfo +func (m *DiscoveryRuleSpec) Reset() { *m = DiscoveryRuleSpec{} } -func (m *DiscoveryProfile) Reset() { *m = DiscoveryProfile{} } -func (*DiscoveryProfile) ProtoMessage() {} -func (*DiscoveryProfile) Descriptor() ([]byte, []int) { - return fileDescriptor_c428ff1fee4945a0, []int{3} -} -func (m *DiscoveryProfile) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *DiscoveryProfile) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err - } - return b[:n], nil -} -func (m *DiscoveryProfile) XXX_Merge(src proto.Message) { - xxx_messageInfo_DiscoveryProfile.Merge(m, src) -} -func (m *DiscoveryProfile) XXX_Size() int { - return m.Size() -} -func (m *DiscoveryProfile) XXX_DiscardUnknown() { - xxx_messageInfo_DiscoveryProfile.DiscardUnknown(m) -} +func (m *DiscoveryRuleStatus) Reset() { *m = DiscoveryRuleStatus{} } -var xxx_messageInfo_DiscoveryProfile proto.InternalMessageInfo +func (m *DiscoveryVendorProfile) Reset() { *m = DiscoveryVendorProfile{} } -func (m *DiscoveryRule) Reset() { *m = DiscoveryRule{} } -func (*DiscoveryRule) ProtoMessage() {} -func (*DiscoveryRule) Descriptor() ([]byte, []int) { - return fileDescriptor_c428ff1fee4945a0, []int{4} -} -func (m *DiscoveryRule) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *DiscoveryRule) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err - } - return b[:n], nil -} -func (m *DiscoveryRule) XXX_Merge(src proto.Message) { - xxx_messageInfo_DiscoveryRule.Merge(m, src) -} -func (m *DiscoveryRule) XXX_Size() int { - return m.Size() -} -func (m *DiscoveryRule) XXX_DiscardUnknown() { - xxx_messageInfo_DiscoveryRule.DiscardUnknown(m) -} +func (m *DiscoveryVendorProfileList) Reset() { *m = DiscoveryVendorProfileList{} } -var xxx_messageInfo_DiscoveryRule proto.InternalMessageInfo +func (m *DiscoveryVendorProfileSpec) Reset() { *m = DiscoveryVendorProfileSpec{} } -func (m *DiscoveryRuleAddress) Reset() { *m = DiscoveryRuleAddress{} } -func (*DiscoveryRuleAddress) ProtoMessage() {} -func (*DiscoveryRuleAddress) Descriptor() ([]byte, []int) { - return fileDescriptor_c428ff1fee4945a0, []int{5} -} -func (m *DiscoveryRuleAddress) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *DiscoveryRuleAddress) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err - } - return b[:n], nil -} -func (m *DiscoveryRuleAddress) XXX_Merge(src proto.Message) { - xxx_messageInfo_DiscoveryRuleAddress.Merge(m, src) -} -func (m *DiscoveryRuleAddress) XXX_Size() int { - return m.Size() -} -func (m *DiscoveryRuleAddress) XXX_DiscardUnknown() { - xxx_messageInfo_DiscoveryRuleAddress.DiscardUnknown(m) -} +func (m *GnmiDiscoveryVendorProfileParameters) Reset() { *m = GnmiDiscoveryVendorProfileParameters{} } -var xxx_messageInfo_DiscoveryRuleAddress proto.InternalMessageInfo +func (m *Proxy) Reset() { *m = Proxy{} } -func (m *DiscoveryRuleList) Reset() { *m = DiscoveryRuleList{} } -func (*DiscoveryRuleList) ProtoMessage() {} -func (*DiscoveryRuleList) Descriptor() ([]byte, []int) { - return fileDescriptor_c428ff1fee4945a0, []int{6} -} -func (m *DiscoveryRuleList) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *DiscoveryRuleList) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err - } - return b[:n], nil -} -func (m *DiscoveryRuleList) XXX_Merge(src proto.Message) { - xxx_messageInfo_DiscoveryRuleList.Merge(m, src) -} -func (m *DiscoveryRuleList) XXX_Size() int { - return m.Size() -} -func (m *DiscoveryRuleList) XXX_DiscardUnknown() { - xxx_messageInfo_DiscoveryRuleList.DiscardUnknown(m) -} +func (m *Repository) Reset() { *m = Repository{} } -var xxx_messageInfo_DiscoveryRuleList proto.InternalMessageInfo +func (m *Rollout) Reset() { *m = Rollout{} } -func (m *DiscoveryRulePrefix) Reset() { *m = DiscoveryRulePrefix{} } -func (*DiscoveryRulePrefix) ProtoMessage() {} -func (*DiscoveryRulePrefix) Descriptor() ([]byte, []int) { - return fileDescriptor_c428ff1fee4945a0, []int{7} -} -func (m *DiscoveryRulePrefix) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *DiscoveryRulePrefix) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err - } - return b[:n], nil -} -func (m *DiscoveryRulePrefix) XXX_Merge(src proto.Message) { - xxx_messageInfo_DiscoveryRulePrefix.Merge(m, src) -} -func (m *DiscoveryRulePrefix) XXX_Size() int { - return m.Size() -} -func (m *DiscoveryRulePrefix) XXX_DiscardUnknown() { - xxx_messageInfo_DiscoveryRulePrefix.DiscardUnknown(m) -} +func (m *RolloutList) Reset() { *m = RolloutList{} } -var xxx_messageInfo_DiscoveryRulePrefix proto.InternalMessageInfo +func (m *RolloutSpec) Reset() { *m = RolloutSpec{} } -func (m *DiscoveryRuleSpec) Reset() { *m = DiscoveryRuleSpec{} } -func (*DiscoveryRuleSpec) ProtoMessage() {} -func (*DiscoveryRuleSpec) Descriptor() ([]byte, []int) { - return fileDescriptor_c428ff1fee4945a0, []int{8} -} -func (m *DiscoveryRuleSpec) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *DiscoveryRuleSpec) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err - } - return b[:n], nil -} -func (m *DiscoveryRuleSpec) XXX_Merge(src proto.Message) { - xxx_messageInfo_DiscoveryRuleSpec.Merge(m, src) -} -func (m *DiscoveryRuleSpec) XXX_Size() int { - return m.Size() -} -func (m *DiscoveryRuleSpec) XXX_DiscardUnknown() { - xxx_messageInfo_DiscoveryRuleSpec.DiscardUnknown(m) -} +func (m *RolloutStatus) Reset() { *m = RolloutStatus{} } -var xxx_messageInfo_DiscoveryRuleSpec proto.InternalMessageInfo +func (m *RolloutTargetStatus) Reset() { *m = RolloutTargetStatus{} } -func (m *DiscoveryRuleStatus) Reset() { *m = DiscoveryRuleStatus{} } -func (*DiscoveryRuleStatus) ProtoMessage() {} -func (*DiscoveryRuleStatus) Descriptor() ([]byte, []int) { - return fileDescriptor_c428ff1fee4945a0, []int{9} -} -func (m *DiscoveryRuleStatus) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *DiscoveryRuleStatus) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err - } - return b[:n], nil -} -func (m *DiscoveryRuleStatus) XXX_Merge(src proto.Message) { - xxx_messageInfo_DiscoveryRuleStatus.Merge(m, src) -} -func (m *DiscoveryRuleStatus) XXX_Size() int { - return m.Size() -} -func (m *DiscoveryRuleStatus) XXX_DiscardUnknown() { - xxx_messageInfo_DiscoveryRuleStatus.DiscardUnknown(m) -} +func (m *Schema) Reset() { *m = Schema{} } -var xxx_messageInfo_DiscoveryRuleStatus proto.InternalMessageInfo +func (m *SchemaKey) Reset() { *m = SchemaKey{} } -func (m *DiscoveryVendorProfile) Reset() { *m = DiscoveryVendorProfile{} } -func (*DiscoveryVendorProfile) ProtoMessage() {} -func (*DiscoveryVendorProfile) Descriptor() ([]byte, []int) { - return fileDescriptor_c428ff1fee4945a0, []int{10} -} -func (m *DiscoveryVendorProfile) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *DiscoveryVendorProfile) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err - } - return b[:n], nil -} -func (m *DiscoveryVendorProfile) XXX_Merge(src proto.Message) { - xxx_messageInfo_DiscoveryVendorProfile.Merge(m, src) -} -func (m *DiscoveryVendorProfile) XXX_Size() int { - return m.Size() -} -func (m *DiscoveryVendorProfile) XXX_DiscardUnknown() { - xxx_messageInfo_DiscoveryVendorProfile.DiscardUnknown(m) -} +func (m *SchemaList) Reset() { *m = SchemaList{} } -var xxx_messageInfo_DiscoveryVendorProfile proto.InternalMessageInfo +func (m *SchemaRepositoryStatus) Reset() { *m = SchemaRepositoryStatus{} } -func (m *DiscoveryVendorProfileList) Reset() { *m = DiscoveryVendorProfileList{} } -func (*DiscoveryVendorProfileList) ProtoMessage() {} -func (*DiscoveryVendorProfileList) Descriptor() ([]byte, []int) { - return fileDescriptor_c428ff1fee4945a0, []int{11} -} -func (m *DiscoveryVendorProfileList) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *DiscoveryVendorProfileList) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err - } - return b[:n], nil -} -func (m *DiscoveryVendorProfileList) XXX_Merge(src proto.Message) { - xxx_messageInfo_DiscoveryVendorProfileList.Merge(m, src) -} -func (m *DiscoveryVendorProfileList) XXX_Size() int { - return m.Size() -} -func (m *DiscoveryVendorProfileList) XXX_DiscardUnknown() { - xxx_messageInfo_DiscoveryVendorProfileList.DiscardUnknown(m) -} +func (m *SchemaSpec) Reset() { *m = SchemaSpec{} } -var xxx_messageInfo_DiscoveryVendorProfileList proto.InternalMessageInfo +func (m *SchemaSpecRepository) Reset() { *m = SchemaSpecRepository{} } -func (m *DiscoveryVendorProfileSpec) Reset() { *m = DiscoveryVendorProfileSpec{} } -func (*DiscoveryVendorProfileSpec) ProtoMessage() {} -func (*DiscoveryVendorProfileSpec) Descriptor() ([]byte, []int) { - return fileDescriptor_c428ff1fee4945a0, []int{12} -} -func (m *DiscoveryVendorProfileSpec) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *DiscoveryVendorProfileSpec) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err - } - return b[:n], nil -} -func (m *DiscoveryVendorProfileSpec) XXX_Merge(src proto.Message) { - xxx_messageInfo_DiscoveryVendorProfileSpec.Merge(m, src) -} -func (m *DiscoveryVendorProfileSpec) XXX_Size() int { - return m.Size() -} -func (m *DiscoveryVendorProfileSpec) XXX_DiscardUnknown() { - xxx_messageInfo_DiscoveryVendorProfileSpec.DiscardUnknown(m) -} +func (m *SchemaSpecSchema) Reset() { *m = SchemaSpecSchema{} } -var xxx_messageInfo_DiscoveryVendorProfileSpec proto.InternalMessageInfo +func (m *SchemaStatus) Reset() { *m = SchemaStatus{} } -func (m *GnmiDiscoveryVendorProfileParameters) Reset() { *m = GnmiDiscoveryVendorProfileParameters{} } -func (*GnmiDiscoveryVendorProfileParameters) ProtoMessage() {} -func (*GnmiDiscoveryVendorProfileParameters) Descriptor() ([]byte, []int) { - return fileDescriptor_c428ff1fee4945a0, []int{13} -} -func (m *GnmiDiscoveryVendorProfileParameters) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *GnmiDiscoveryVendorProfileParameters) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err - } - return b[:n], nil -} -func (m *GnmiDiscoveryVendorProfileParameters) XXX_Merge(src proto.Message) { - xxx_messageInfo_GnmiDiscoveryVendorProfileParameters.Merge(m, src) -} -func (m *GnmiDiscoveryVendorProfileParameters) XXX_Size() int { - return m.Size() -} -func (m *GnmiDiscoveryVendorProfileParameters) XXX_DiscardUnknown() { - xxx_messageInfo_GnmiDiscoveryVendorProfileParameters.DiscardUnknown(m) -} +func (m *SrcDstPath) Reset() { *m = SrcDstPath{} } -var xxx_messageInfo_GnmiDiscoveryVendorProfileParameters proto.InternalMessageInfo +func (m *Subscription) Reset() { *m = Subscription{} } -func (m *Proxy) Reset() { *m = Proxy{} } -func (*Proxy) ProtoMessage() {} -func (*Proxy) Descriptor() ([]byte, []int) { - return fileDescriptor_c428ff1fee4945a0, []int{14} -} -func (m *Proxy) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *Proxy) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err - } - return b[:n], nil -} -func (m *Proxy) XXX_Merge(src proto.Message) { - xxx_messageInfo_Proxy.Merge(m, src) -} -func (m *Proxy) XXX_Size() int { - return m.Size() -} -func (m *Proxy) XXX_DiscardUnknown() { - xxx_messageInfo_Proxy.DiscardUnknown(m) -} +func (m *SubscriptionList) Reset() { *m = SubscriptionList{} } -var xxx_messageInfo_Proxy proto.InternalMessageInfo +func (m *SubscriptionParameters) Reset() { *m = SubscriptionParameters{} } -func (m *Repository) Reset() { *m = Repository{} } -func (*Repository) ProtoMessage() {} -func (*Repository) Descriptor() ([]byte, []int) { - return fileDescriptor_c428ff1fee4945a0, []int{15} -} -func (m *Repository) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *Repository) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err - } - return b[:n], nil -} -func (m *Repository) XXX_Merge(src proto.Message) { - xxx_messageInfo_Repository.Merge(m, src) -} -func (m *Repository) XXX_Size() int { - return m.Size() -} -func (m *Repository) XXX_DiscardUnknown() { - xxx_messageInfo_Repository.DiscardUnknown(m) -} +func (m *SubscriptionSpec) Reset() { *m = SubscriptionSpec{} } -var xxx_messageInfo_Repository proto.InternalMessageInfo +func (m *SubscriptionStatus) Reset() { *m = SubscriptionStatus{} } -func (m *Rollout) Reset() { *m = Rollout{} } -func (*Rollout) ProtoMessage() {} -func (*Rollout) Descriptor() ([]byte, []int) { - return fileDescriptor_c428ff1fee4945a0, []int{16} -} -func (m *Rollout) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *Rollout) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err - } - return b[:n], nil -} -func (m *Rollout) XXX_Merge(src proto.Message) { - xxx_messageInfo_Rollout.Merge(m, src) -} -func (m *Rollout) XXX_Size() int { - return m.Size() -} -func (m *Rollout) XXX_DiscardUnknown() { - xxx_messageInfo_Rollout.DiscardUnknown(m) -} +func (m *SubscriptionTarget) Reset() { *m = SubscriptionTarget{} } -var xxx_messageInfo_Rollout proto.InternalMessageInfo +func (m *TargetConnectionProfile) Reset() { *m = TargetConnectionProfile{} } -func (m *RolloutList) Reset() { *m = RolloutList{} } -func (*RolloutList) ProtoMessage() {} -func (*RolloutList) Descriptor() ([]byte, []int) { - return fileDescriptor_c428ff1fee4945a0, []int{17} -} -func (m *RolloutList) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *RolloutList) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err - } - return b[:n], nil -} -func (m *RolloutList) XXX_Merge(src proto.Message) { - xxx_messageInfo_RolloutList.Merge(m, src) -} -func (m *RolloutList) XXX_Size() int { - return m.Size() -} -func (m *RolloutList) XXX_DiscardUnknown() { - xxx_messageInfo_RolloutList.DiscardUnknown(m) -} +func (m *TargetConnectionProfileList) Reset() { *m = TargetConnectionProfileList{} } -var xxx_messageInfo_RolloutList proto.InternalMessageInfo +func (m *TargetConnectionProfileSpec) Reset() { *m = TargetConnectionProfileSpec{} } -func (m *RolloutSpec) Reset() { *m = RolloutSpec{} } -func (*RolloutSpec) ProtoMessage() {} -func (*RolloutSpec) Descriptor() ([]byte, []int) { - return fileDescriptor_c428ff1fee4945a0, []int{18} -} -func (m *RolloutSpec) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *RolloutSpec) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err - } - return b[:n], nil -} -func (m *RolloutSpec) XXX_Merge(src proto.Message) { - xxx_messageInfo_RolloutSpec.Merge(m, src) -} -func (m *RolloutSpec) XXX_Size() int { - return m.Size() -} -func (m *RolloutSpec) XXX_DiscardUnknown() { - xxx_messageInfo_RolloutSpec.DiscardUnknown(m) -} +func (m *TargetProfile) Reset() { *m = TargetProfile{} } -var xxx_messageInfo_RolloutSpec proto.InternalMessageInfo +func (m *TargetSyncProfile) Reset() { *m = TargetSyncProfile{} } -func (m *RolloutStatus) Reset() { *m = RolloutStatus{} } -func (*RolloutStatus) ProtoMessage() {} -func (*RolloutStatus) Descriptor() ([]byte, []int) { - return fileDescriptor_c428ff1fee4945a0, []int{19} -} -func (m *RolloutStatus) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *RolloutStatus) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err - } - return b[:n], nil -} -func (m *RolloutStatus) XXX_Merge(src proto.Message) { - xxx_messageInfo_RolloutStatus.Merge(m, src) -} -func (m *RolloutStatus) XXX_Size() int { - return m.Size() -} -func (m *RolloutStatus) XXX_DiscardUnknown() { - xxx_messageInfo_RolloutStatus.DiscardUnknown(m) -} +func (m *TargetSyncProfileList) Reset() { *m = TargetSyncProfileList{} } -var xxx_messageInfo_RolloutStatus proto.InternalMessageInfo +func (m *TargetSyncProfileSpec) Reset() { *m = TargetSyncProfileSpec{} } -func (m *RolloutTargetStatus) Reset() { *m = RolloutTargetStatus{} } -func (*RolloutTargetStatus) ProtoMessage() {} -func (*RolloutTargetStatus) Descriptor() ([]byte, []int) { - return fileDescriptor_c428ff1fee4945a0, []int{20} -} -func (m *RolloutTargetStatus) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *RolloutTargetStatus) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err - } - return b[:n], nil -} -func (m *RolloutTargetStatus) XXX_Merge(src proto.Message) { - xxx_messageInfo_RolloutTargetStatus.Merge(m, src) -} -func (m *RolloutTargetStatus) XXX_Size() int { - return m.Size() -} -func (m *RolloutTargetStatus) XXX_DiscardUnknown() { - xxx_messageInfo_RolloutTargetStatus.DiscardUnknown(m) -} +func (m *TargetSyncProfileSync) Reset() { *m = TargetSyncProfileSync{} } -var xxx_messageInfo_RolloutTargetStatus proto.InternalMessageInfo +func (m *TargetTemplate) Reset() { *m = TargetTemplate{} } -func (m *Schema) Reset() { *m = Schema{} } -func (*Schema) ProtoMessage() {} -func (*Schema) Descriptor() ([]byte, []int) { - return fileDescriptor_c428ff1fee4945a0, []int{21} -} -func (m *Schema) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *Schema) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err - } - return b[:n], nil -} -func (m *Schema) XXX_Merge(src proto.Message) { - xxx_messageInfo_Schema.Merge(m, src) -} -func (m *Schema) XXX_Size() int { - return m.Size() -} -func (m *Schema) XXX_DiscardUnknown() { - xxx_messageInfo_Schema.DiscardUnknown(m) -} +func (m *Workspace) Reset() { *m = Workspace{} } -var xxx_messageInfo_Schema proto.InternalMessageInfo +func (m *WorkspaceList) Reset() { *m = WorkspaceList{} } -func (m *SchemaKey) Reset() { *m = SchemaKey{} } -func (*SchemaKey) ProtoMessage() {} -func (*SchemaKey) Descriptor() ([]byte, []int) { - return fileDescriptor_c428ff1fee4945a0, []int{22} -} -func (m *SchemaKey) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *SchemaKey) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err - } - return b[:n], nil -} -func (m *SchemaKey) XXX_Merge(src proto.Message) { - xxx_messageInfo_SchemaKey.Merge(m, src) -} -func (m *SchemaKey) XXX_Size() int { - return m.Size() -} -func (m *SchemaKey) XXX_DiscardUnknown() { - xxx_messageInfo_SchemaKey.DiscardUnknown(m) -} +func (m *WorkspaceSpec) Reset() { *m = WorkspaceSpec{} } -var xxx_messageInfo_SchemaKey proto.InternalMessageInfo +func (m *WorkspaceStatus) Reset() { *m = WorkspaceStatus{} } -func (m *SchemaList) Reset() { *m = SchemaList{} } -func (*SchemaList) ProtoMessage() {} -func (*SchemaList) Descriptor() ([]byte, []int) { - return fileDescriptor_c428ff1fee4945a0, []int{23} -} -func (m *SchemaList) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *SchemaList) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) +func (m *DiscoveryParameters) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } - return b[:n], nil -} -func (m *SchemaList) XXX_Merge(src proto.Message) { - xxx_messageInfo_SchemaList.Merge(m, src) -} -func (m *SchemaList) XXX_Size() int { - return m.Size() -} -func (m *SchemaList) XXX_DiscardUnknown() { - xxx_messageInfo_SchemaList.DiscardUnknown(m) + return dAtA[:n], nil } -var xxx_messageInfo_SchemaList proto.InternalMessageInfo - -func (m *SchemaRepositoryStatus) Reset() { *m = SchemaRepositoryStatus{} } -func (*SchemaRepositoryStatus) ProtoMessage() {} -func (*SchemaRepositoryStatus) Descriptor() ([]byte, []int) { - return fileDescriptor_c428ff1fee4945a0, []int{24} -} -func (m *SchemaRepositoryStatus) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *SchemaRepositoryStatus) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err - } - return b[:n], nil -} -func (m *SchemaRepositoryStatus) XXX_Merge(src proto.Message) { - xxx_messageInfo_SchemaRepositoryStatus.Merge(m, src) -} -func (m *SchemaRepositoryStatus) XXX_Size() int { - return m.Size() -} -func (m *SchemaRepositoryStatus) XXX_DiscardUnknown() { - xxx_messageInfo_SchemaRepositoryStatus.DiscardUnknown(m) +func (m *DiscoveryParameters) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) } -var xxx_messageInfo_SchemaRepositoryStatus proto.InternalMessageInfo - -func (m *SchemaSpec) Reset() { *m = SchemaSpec{} } -func (*SchemaSpec) ProtoMessage() {} -func (*SchemaSpec) Descriptor() ([]byte, []int) { - return fileDescriptor_c428ff1fee4945a0, []int{25} -} -func (m *SchemaSpec) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *SchemaSpec) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err +func (m *DiscoveryParameters) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + i = encodeVarintGenerated(dAtA, i, uint64(m.ConcurrentScans)) + i-- + dAtA[i] = 0x30 + { + size, err := m.Period.MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintGenerated(dAtA, i, uint64(size)) } - return b[:n], nil -} -func (m *SchemaSpec) XXX_Merge(src proto.Message) { - xxx_messageInfo_SchemaSpec.Merge(m, src) -} -func (m *SchemaSpec) XXX_Size() int { - return m.Size() -} -func (m *SchemaSpec) XXX_DiscardUnknown() { - xxx_messageInfo_SchemaSpec.DiscardUnknown(m) -} - -var xxx_messageInfo_SchemaSpec proto.InternalMessageInfo - -func (m *SchemaSpecRepository) Reset() { *m = SchemaSpecRepository{} } -func (*SchemaSpecRepository) ProtoMessage() {} -func (*SchemaSpecRepository) Descriptor() ([]byte, []int) { - return fileDescriptor_c428ff1fee4945a0, []int{26} -} -func (m *SchemaSpecRepository) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *SchemaSpecRepository) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err + i-- + dAtA[i] = 0x2a + if m.TargetTemplate != nil { + { + size, err := m.TargetTemplate.MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintGenerated(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0x22 } - return b[:n], nil -} -func (m *SchemaSpecRepository) XXX_Merge(src proto.Message) { - xxx_messageInfo_SchemaSpecRepository.Merge(m, src) -} -func (m *SchemaSpecRepository) XXX_Size() int { - return m.Size() -} -func (m *SchemaSpecRepository) XXX_DiscardUnknown() { - xxx_messageInfo_SchemaSpecRepository.DiscardUnknown(m) + if len(m.TargetConnectionProfiles) > 0 { + for iNdEx := len(m.TargetConnectionProfiles) - 1; iNdEx >= 0; iNdEx-- { + { + size, err := m.TargetConnectionProfiles[iNdEx].MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintGenerated(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0x1a + } + } + if m.DiscoveryProfile != nil { + { + size, err := m.DiscoveryProfile.MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintGenerated(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0x12 + } + if m.DefaultSchema != nil { + { + size, err := m.DefaultSchema.MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintGenerated(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0xa + } + return len(dAtA) - i, nil } -var xxx_messageInfo_SchemaSpecRepository proto.InternalMessageInfo - -func (m *SchemaSpecSchema) Reset() { *m = SchemaSpecSchema{} } -func (*SchemaSpecSchema) ProtoMessage() {} -func (*SchemaSpecSchema) Descriptor() ([]byte, []int) { - return fileDescriptor_c428ff1fee4945a0, []int{27} -} -func (m *SchemaSpecSchema) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *SchemaSpecSchema) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) +func (m *DiscoveryPathDefinition) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } - return b[:n], nil -} -func (m *SchemaSpecSchema) XXX_Merge(src proto.Message) { - xxx_messageInfo_SchemaSpecSchema.Merge(m, src) -} -func (m *SchemaSpecSchema) XXX_Size() int { - return m.Size() -} -func (m *SchemaSpecSchema) XXX_DiscardUnknown() { - xxx_messageInfo_SchemaSpecSchema.DiscardUnknown(m) + return dAtA[:n], nil } -var xxx_messageInfo_SchemaSpecSchema proto.InternalMessageInfo - -func (m *SchemaStatus) Reset() { *m = SchemaStatus{} } -func (*SchemaStatus) ProtoMessage() {} -func (*SchemaStatus) Descriptor() ([]byte, []int) { - return fileDescriptor_c428ff1fee4945a0, []int{28} -} -func (m *SchemaStatus) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) +func (m *DiscoveryPathDefinition) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) } -func (m *SchemaStatus) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err + +func (m *DiscoveryPathDefinition) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + if m.Regex != nil { + i -= len(*m.Regex) + copy(dAtA[i:], *m.Regex) + i = encodeVarintGenerated(dAtA, i, uint64(len(*m.Regex))) + i-- + dAtA[i] = 0x22 } - return b[:n], nil -} -func (m *SchemaStatus) XXX_Merge(src proto.Message) { - xxx_messageInfo_SchemaStatus.Merge(m, src) -} -func (m *SchemaStatus) XXX_Size() int { - return m.Size() -} -func (m *SchemaStatus) XXX_DiscardUnknown() { - xxx_messageInfo_SchemaStatus.DiscardUnknown(m) + if m.Script != nil { + i -= len(*m.Script) + copy(dAtA[i:], *m.Script) + i = encodeVarintGenerated(dAtA, i, uint64(len(*m.Script))) + i-- + dAtA[i] = 0x1a + } + i -= len(m.Path) + copy(dAtA[i:], m.Path) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Path))) + i-- + dAtA[i] = 0x12 + i -= len(m.Key) + copy(dAtA[i:], m.Key) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Key))) + i-- + dAtA[i] = 0xa + return len(dAtA) - i, nil } -var xxx_messageInfo_SchemaStatus proto.InternalMessageInfo - -func (m *SrcDstPath) Reset() { *m = SrcDstPath{} } -func (*SrcDstPath) ProtoMessage() {} -func (*SrcDstPath) Descriptor() ([]byte, []int) { - return fileDescriptor_c428ff1fee4945a0, []int{29} -} -func (m *SrcDstPath) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *SrcDstPath) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) +func (m *DiscoveryProfile) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } - return b[:n], nil -} -func (m *SrcDstPath) XXX_Merge(src proto.Message) { - xxx_messageInfo_SrcDstPath.Merge(m, src) -} -func (m *SrcDstPath) XXX_Size() int { - return m.Size() -} -func (m *SrcDstPath) XXX_DiscardUnknown() { - xxx_messageInfo_SrcDstPath.DiscardUnknown(m) + return dAtA[:n], nil } -var xxx_messageInfo_SrcDstPath proto.InternalMessageInfo - -func (m *Subscription) Reset() { *m = Subscription{} } -func (*Subscription) ProtoMessage() {} -func (*Subscription) Descriptor() ([]byte, []int) { - return fileDescriptor_c428ff1fee4945a0, []int{30} -} -func (m *Subscription) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) +func (m *DiscoveryProfile) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) } -func (m *Subscription) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err + +func (m *DiscoveryProfile) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + if len(m.ConnectionProfiles) > 0 { + for iNdEx := len(m.ConnectionProfiles) - 1; iNdEx >= 0; iNdEx-- { + i -= len(m.ConnectionProfiles[iNdEx]) + copy(dAtA[i:], m.ConnectionProfiles[iNdEx]) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.ConnectionProfiles[iNdEx]))) + i-- + dAtA[i] = 0x1a + } } - return b[:n], nil -} -func (m *Subscription) XXX_Merge(src proto.Message) { - xxx_messageInfo_Subscription.Merge(m, src) -} -func (m *Subscription) XXX_Size() int { - return m.Size() -} -func (m *Subscription) XXX_DiscardUnknown() { - xxx_messageInfo_Subscription.DiscardUnknown(m) + if m.TLSSecret != nil { + i -= len(*m.TLSSecret) + copy(dAtA[i:], *m.TLSSecret) + i = encodeVarintGenerated(dAtA, i, uint64(len(*m.TLSSecret))) + i-- + dAtA[i] = 0x12 + } + i -= len(m.Credentials) + copy(dAtA[i:], m.Credentials) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Credentials))) + i-- + dAtA[i] = 0xa + return len(dAtA) - i, nil } -var xxx_messageInfo_Subscription proto.InternalMessageInfo - -func (m *SubscriptionList) Reset() { *m = SubscriptionList{} } -func (*SubscriptionList) ProtoMessage() {} -func (*SubscriptionList) Descriptor() ([]byte, []int) { - return fileDescriptor_c428ff1fee4945a0, []int{31} -} -func (m *SubscriptionList) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *SubscriptionList) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) +func (m *DiscoveryRule) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } - return b[:n], nil -} -func (m *SubscriptionList) XXX_Merge(src proto.Message) { - xxx_messageInfo_SubscriptionList.Merge(m, src) -} -func (m *SubscriptionList) XXX_Size() int { - return m.Size() -} -func (m *SubscriptionList) XXX_DiscardUnknown() { - xxx_messageInfo_SubscriptionList.DiscardUnknown(m) + return dAtA[:n], nil } -var xxx_messageInfo_SubscriptionList proto.InternalMessageInfo - -func (m *SubscriptionParameters) Reset() { *m = SubscriptionParameters{} } -func (*SubscriptionParameters) ProtoMessage() {} -func (*SubscriptionParameters) Descriptor() ([]byte, []int) { - return fileDescriptor_c428ff1fee4945a0, []int{32} -} -func (m *SubscriptionParameters) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) +func (m *DiscoveryRule) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) } -func (m *SubscriptionParameters) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err + +func (m *DiscoveryRule) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + { + size, err := m.Status.MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintGenerated(dAtA, i, uint64(size)) } - return b[:n], nil -} -func (m *SubscriptionParameters) XXX_Merge(src proto.Message) { - xxx_messageInfo_SubscriptionParameters.Merge(m, src) -} -func (m *SubscriptionParameters) XXX_Size() int { - return m.Size() -} -func (m *SubscriptionParameters) XXX_DiscardUnknown() { - xxx_messageInfo_SubscriptionParameters.DiscardUnknown(m) + i-- + dAtA[i] = 0x1a + { + size, err := m.Spec.MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintGenerated(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0x12 + { + size, err := m.ObjectMeta.MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintGenerated(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0xa + return len(dAtA) - i, nil } -var xxx_messageInfo_SubscriptionParameters proto.InternalMessageInfo - -func (m *SubscriptionSpec) Reset() { *m = SubscriptionSpec{} } -func (*SubscriptionSpec) ProtoMessage() {} -func (*SubscriptionSpec) Descriptor() ([]byte, []int) { - return fileDescriptor_c428ff1fee4945a0, []int{33} -} -func (m *SubscriptionSpec) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *SubscriptionSpec) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) +func (m *DiscoveryRuleAddress) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } - return b[:n], nil -} -func (m *SubscriptionSpec) XXX_Merge(src proto.Message) { - xxx_messageInfo_SubscriptionSpec.Merge(m, src) -} -func (m *SubscriptionSpec) XXX_Size() int { - return m.Size() -} -func (m *SubscriptionSpec) XXX_DiscardUnknown() { - xxx_messageInfo_SubscriptionSpec.DiscardUnknown(m) + return dAtA[:n], nil } -var xxx_messageInfo_SubscriptionSpec proto.InternalMessageInfo - -func (m *SubscriptionStatus) Reset() { *m = SubscriptionStatus{} } -func (*SubscriptionStatus) ProtoMessage() {} -func (*SubscriptionStatus) Descriptor() ([]byte, []int) { - return fileDescriptor_c428ff1fee4945a0, []int{34} +func (m *DiscoveryRuleAddress) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) } -func (m *SubscriptionStatus) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) + +func (m *DiscoveryRuleAddress) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + i -= len(m.HostName) + copy(dAtA[i:], m.HostName) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.HostName))) + i-- + dAtA[i] = 0x12 + i -= len(m.Address) + copy(dAtA[i:], m.Address) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Address))) + i-- + dAtA[i] = 0xa + return len(dAtA) - i, nil } -func (m *SubscriptionStatus) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) + +func (m *DiscoveryRuleList) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } - return b[:n], nil -} -func (m *SubscriptionStatus) XXX_Merge(src proto.Message) { - xxx_messageInfo_SubscriptionStatus.Merge(m, src) -} -func (m *SubscriptionStatus) XXX_Size() int { - return m.Size() -} -func (m *SubscriptionStatus) XXX_DiscardUnknown() { - xxx_messageInfo_SubscriptionStatus.DiscardUnknown(m) + return dAtA[:n], nil } -var xxx_messageInfo_SubscriptionStatus proto.InternalMessageInfo - -func (m *SubscriptionTarget) Reset() { *m = SubscriptionTarget{} } -func (*SubscriptionTarget) ProtoMessage() {} -func (*SubscriptionTarget) Descriptor() ([]byte, []int) { - return fileDescriptor_c428ff1fee4945a0, []int{35} -} -func (m *SubscriptionTarget) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *SubscriptionTarget) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err - } - return b[:n], nil -} -func (m *SubscriptionTarget) XXX_Merge(src proto.Message) { - xxx_messageInfo_SubscriptionTarget.Merge(m, src) -} -func (m *SubscriptionTarget) XXX_Size() int { - return m.Size() -} -func (m *SubscriptionTarget) XXX_DiscardUnknown() { - xxx_messageInfo_SubscriptionTarget.DiscardUnknown(m) +func (m *DiscoveryRuleList) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) } -var xxx_messageInfo_SubscriptionTarget proto.InternalMessageInfo - -func (m *Target) Reset() { *m = Target{} } -func (*Target) ProtoMessage() {} -func (*Target) Descriptor() ([]byte, []int) { - return fileDescriptor_c428ff1fee4945a0, []int{36} -} -func (m *Target) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *Target) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err +func (m *DiscoveryRuleList) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + if len(m.Items) > 0 { + for iNdEx := len(m.Items) - 1; iNdEx >= 0; iNdEx-- { + { + size, err := m.Items[iNdEx].MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintGenerated(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0x12 + } } - return b[:n], nil -} -func (m *Target) XXX_Merge(src proto.Message) { - xxx_messageInfo_Target.Merge(m, src) -} -func (m *Target) XXX_Size() int { - return m.Size() -} -func (m *Target) XXX_DiscardUnknown() { - xxx_messageInfo_Target.DiscardUnknown(m) -} - -var xxx_messageInfo_Target proto.InternalMessageInfo - -func (m *TargetConnectionProfile) Reset() { *m = TargetConnectionProfile{} } -func (*TargetConnectionProfile) ProtoMessage() {} -func (*TargetConnectionProfile) Descriptor() ([]byte, []int) { - return fileDescriptor_c428ff1fee4945a0, []int{37} -} -func (m *TargetConnectionProfile) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *TargetConnectionProfile) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err + { + size, err := m.ListMeta.MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintGenerated(dAtA, i, uint64(size)) } - return b[:n], nil -} -func (m *TargetConnectionProfile) XXX_Merge(src proto.Message) { - xxx_messageInfo_TargetConnectionProfile.Merge(m, src) -} -func (m *TargetConnectionProfile) XXX_Size() int { - return m.Size() -} -func (m *TargetConnectionProfile) XXX_DiscardUnknown() { - xxx_messageInfo_TargetConnectionProfile.DiscardUnknown(m) + i-- + dAtA[i] = 0xa + return len(dAtA) - i, nil } -var xxx_messageInfo_TargetConnectionProfile proto.InternalMessageInfo - -func (m *TargetConnectionProfileList) Reset() { *m = TargetConnectionProfileList{} } -func (*TargetConnectionProfileList) ProtoMessage() {} -func (*TargetConnectionProfileList) Descriptor() ([]byte, []int) { - return fileDescriptor_c428ff1fee4945a0, []int{38} -} -func (m *TargetConnectionProfileList) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *TargetConnectionProfileList) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) +func (m *DiscoveryRulePrefix) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } - return b[:n], nil -} -func (m *TargetConnectionProfileList) XXX_Merge(src proto.Message) { - xxx_messageInfo_TargetConnectionProfileList.Merge(m, src) -} -func (m *TargetConnectionProfileList) XXX_Size() int { - return m.Size() -} -func (m *TargetConnectionProfileList) XXX_DiscardUnknown() { - xxx_messageInfo_TargetConnectionProfileList.DiscardUnknown(m) + return dAtA[:n], nil } -var xxx_messageInfo_TargetConnectionProfileList proto.InternalMessageInfo - -func (m *TargetConnectionProfileSpec) Reset() { *m = TargetConnectionProfileSpec{} } -func (*TargetConnectionProfileSpec) ProtoMessage() {} -func (*TargetConnectionProfileSpec) Descriptor() ([]byte, []int) { - return fileDescriptor_c428ff1fee4945a0, []int{39} -} -func (m *TargetConnectionProfileSpec) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) +func (m *DiscoveryRulePrefix) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) } -func (m *TargetConnectionProfileSpec) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err + +func (m *DiscoveryRulePrefix) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + if len(m.Excludes) > 0 { + for iNdEx := len(m.Excludes) - 1; iNdEx >= 0; iNdEx-- { + i -= len(m.Excludes[iNdEx]) + copy(dAtA[i:], m.Excludes[iNdEx]) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Excludes[iNdEx]))) + i-- + dAtA[i] = 0x12 + } } - return b[:n], nil -} -func (m *TargetConnectionProfileSpec) XXX_Merge(src proto.Message) { - xxx_messageInfo_TargetConnectionProfileSpec.Merge(m, src) -} -func (m *TargetConnectionProfileSpec) XXX_Size() int { - return m.Size() -} -func (m *TargetConnectionProfileSpec) XXX_DiscardUnknown() { - xxx_messageInfo_TargetConnectionProfileSpec.DiscardUnknown(m) + i -= len(m.Prefix) + copy(dAtA[i:], m.Prefix) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Prefix))) + i-- + dAtA[i] = 0xa + return len(dAtA) - i, nil } -var xxx_messageInfo_TargetConnectionProfileSpec proto.InternalMessageInfo - -func (m *TargetList) Reset() { *m = TargetList{} } -func (*TargetList) ProtoMessage() {} -func (*TargetList) Descriptor() ([]byte, []int) { - return fileDescriptor_c428ff1fee4945a0, []int{40} -} -func (m *TargetList) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *TargetList) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) +func (m *DiscoveryRuleSpec) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } - return b[:n], nil -} -func (m *TargetList) XXX_Merge(src proto.Message) { - xxx_messageInfo_TargetList.Merge(m, src) -} -func (m *TargetList) XXX_Size() int { - return m.Size() -} -func (m *TargetList) XXX_DiscardUnknown() { - xxx_messageInfo_TargetList.DiscardUnknown(m) + return dAtA[:n], nil } -var xxx_messageInfo_TargetList proto.InternalMessageInfo - -func (m *TargetProfile) Reset() { *m = TargetProfile{} } -func (*TargetProfile) ProtoMessage() {} -func (*TargetProfile) Descriptor() ([]byte, []int) { - return fileDescriptor_c428ff1fee4945a0, []int{41} -} -func (m *TargetProfile) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) +func (m *DiscoveryRuleSpec) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) } -func (m *TargetProfile) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err + +func (m *DiscoveryRuleSpec) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + { + size, err := m.DiscoveryParameters.MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintGenerated(dAtA, i, uint64(size)) } - return b[:n], nil -} -func (m *TargetProfile) XXX_Merge(src proto.Message) { - xxx_messageInfo_TargetProfile.Merge(m, src) -} -func (m *TargetProfile) XXX_Size() int { - return m.Size() -} -func (m *TargetProfile) XXX_DiscardUnknown() { - xxx_messageInfo_TargetProfile.DiscardUnknown(m) + i-- + dAtA[i] = 0x32 + i -= len(m.ServiceDomain) + copy(dAtA[i:], m.ServiceDomain) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.ServiceDomain))) + i-- + dAtA[i] = 0x2a + if m.ServiceSelector != nil { + { + size, err := m.ServiceSelector.MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintGenerated(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0x22 + } + if m.PodSelector != nil { + { + size, err := m.PodSelector.MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintGenerated(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0x1a + } + if len(m.Addresses) > 0 { + for iNdEx := len(m.Addresses) - 1; iNdEx >= 0; iNdEx-- { + { + size, err := m.Addresses[iNdEx].MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintGenerated(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0x12 + } + } + if len(m.Prefixes) > 0 { + for iNdEx := len(m.Prefixes) - 1; iNdEx >= 0; iNdEx-- { + { + size, err := m.Prefixes[iNdEx].MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintGenerated(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0xa + } + } + return len(dAtA) - i, nil } -var xxx_messageInfo_TargetProfile proto.InternalMessageInfo - -func (m *TargetSpec) Reset() { *m = TargetSpec{} } -func (*TargetSpec) ProtoMessage() {} -func (*TargetSpec) Descriptor() ([]byte, []int) { - return fileDescriptor_c428ff1fee4945a0, []int{42} -} -func (m *TargetSpec) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *TargetSpec) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) +func (m *DiscoveryRuleStatus) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } - return b[:n], nil -} -func (m *TargetSpec) XXX_Merge(src proto.Message) { - xxx_messageInfo_TargetSpec.Merge(m, src) -} -func (m *TargetSpec) XXX_Size() int { - return m.Size() -} -func (m *TargetSpec) XXX_DiscardUnknown() { - xxx_messageInfo_TargetSpec.DiscardUnknown(m) + return dAtA[:n], nil } -var xxx_messageInfo_TargetSpec proto.InternalMessageInfo - -func (m *TargetStatus) Reset() { *m = TargetStatus{} } -func (*TargetStatus) ProtoMessage() {} -func (*TargetStatus) Descriptor() ([]byte, []int) { - return fileDescriptor_c428ff1fee4945a0, []int{43} -} -func (m *TargetStatus) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) +func (m *DiscoveryRuleStatus) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) } -func (m *TargetStatus) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err + +func (m *DiscoveryRuleStatus) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + if m.StartTime != nil { + { + size, err := m.StartTime.MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintGenerated(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0x12 } - return b[:n], nil -} -func (m *TargetStatus) XXX_Merge(src proto.Message) { - xxx_messageInfo_TargetStatus.Merge(m, src) -} -func (m *TargetStatus) XXX_Size() int { - return m.Size() -} -func (m *TargetStatus) XXX_DiscardUnknown() { - xxx_messageInfo_TargetStatus.DiscardUnknown(m) + { + size, err := m.ConditionedStatus.MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintGenerated(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0xa + return len(dAtA) - i, nil } -var xxx_messageInfo_TargetStatus proto.InternalMessageInfo - -func (m *TargetStatusUsedReferences) Reset() { *m = TargetStatusUsedReferences{} } -func (*TargetStatusUsedReferences) ProtoMessage() {} -func (*TargetStatusUsedReferences) Descriptor() ([]byte, []int) { - return fileDescriptor_c428ff1fee4945a0, []int{44} -} -func (m *TargetStatusUsedReferences) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *TargetStatusUsedReferences) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) +func (m *DiscoveryVendorProfile) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } - return b[:n], nil -} -func (m *TargetStatusUsedReferences) XXX_Merge(src proto.Message) { - xxx_messageInfo_TargetStatusUsedReferences.Merge(m, src) -} -func (m *TargetStatusUsedReferences) XXX_Size() int { - return m.Size() -} -func (m *TargetStatusUsedReferences) XXX_DiscardUnknown() { - xxx_messageInfo_TargetStatusUsedReferences.DiscardUnknown(m) + return dAtA[:n], nil } -var xxx_messageInfo_TargetStatusUsedReferences proto.InternalMessageInfo - -func (m *TargetSyncProfile) Reset() { *m = TargetSyncProfile{} } -func (*TargetSyncProfile) ProtoMessage() {} -func (*TargetSyncProfile) Descriptor() ([]byte, []int) { - return fileDescriptor_c428ff1fee4945a0, []int{45} +func (m *DiscoveryVendorProfile) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) } -func (m *TargetSyncProfile) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *TargetSyncProfile) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err - } - return b[:n], nil -} -func (m *TargetSyncProfile) XXX_Merge(src proto.Message) { - xxx_messageInfo_TargetSyncProfile.Merge(m, src) -} -func (m *TargetSyncProfile) XXX_Size() int { - return m.Size() -} -func (m *TargetSyncProfile) XXX_DiscardUnknown() { - xxx_messageInfo_TargetSyncProfile.DiscardUnknown(m) -} - -var xxx_messageInfo_TargetSyncProfile proto.InternalMessageInfo - -func (m *TargetSyncProfileList) Reset() { *m = TargetSyncProfileList{} } -func (*TargetSyncProfileList) ProtoMessage() {} -func (*TargetSyncProfileList) Descriptor() ([]byte, []int) { - return fileDescriptor_c428ff1fee4945a0, []int{46} -} -func (m *TargetSyncProfileList) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *TargetSyncProfileList) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err - } - return b[:n], nil -} -func (m *TargetSyncProfileList) XXX_Merge(src proto.Message) { - xxx_messageInfo_TargetSyncProfileList.Merge(m, src) -} -func (m *TargetSyncProfileList) XXX_Size() int { - return m.Size() -} -func (m *TargetSyncProfileList) XXX_DiscardUnknown() { - xxx_messageInfo_TargetSyncProfileList.DiscardUnknown(m) -} - -var xxx_messageInfo_TargetSyncProfileList proto.InternalMessageInfo -func (m *TargetSyncProfileSpec) Reset() { *m = TargetSyncProfileSpec{} } -func (*TargetSyncProfileSpec) ProtoMessage() {} -func (*TargetSyncProfileSpec) Descriptor() ([]byte, []int) { - return fileDescriptor_c428ff1fee4945a0, []int{47} -} -func (m *TargetSyncProfileSpec) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *TargetSyncProfileSpec) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err +func (m *DiscoveryVendorProfile) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + { + size, err := m.Spec.MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintGenerated(dAtA, i, uint64(size)) } - return b[:n], nil -} -func (m *TargetSyncProfileSpec) XXX_Merge(src proto.Message) { - xxx_messageInfo_TargetSyncProfileSpec.Merge(m, src) -} -func (m *TargetSyncProfileSpec) XXX_Size() int { - return m.Size() -} -func (m *TargetSyncProfileSpec) XXX_DiscardUnknown() { - xxx_messageInfo_TargetSyncProfileSpec.DiscardUnknown(m) -} - -var xxx_messageInfo_TargetSyncProfileSpec proto.InternalMessageInfo - -func (m *TargetSyncProfileSync) Reset() { *m = TargetSyncProfileSync{} } -func (*TargetSyncProfileSync) ProtoMessage() {} -func (*TargetSyncProfileSync) Descriptor() ([]byte, []int) { - return fileDescriptor_c428ff1fee4945a0, []int{48} -} -func (m *TargetSyncProfileSync) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *TargetSyncProfileSync) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err + i-- + dAtA[i] = 0x12 + { + size, err := m.ObjectMeta.MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintGenerated(dAtA, i, uint64(size)) } - return b[:n], nil -} -func (m *TargetSyncProfileSync) XXX_Merge(src proto.Message) { - xxx_messageInfo_TargetSyncProfileSync.Merge(m, src) -} -func (m *TargetSyncProfileSync) XXX_Size() int { - return m.Size() -} -func (m *TargetSyncProfileSync) XXX_DiscardUnknown() { - xxx_messageInfo_TargetSyncProfileSync.DiscardUnknown(m) + i-- + dAtA[i] = 0xa + return len(dAtA) - i, nil } -var xxx_messageInfo_TargetSyncProfileSync proto.InternalMessageInfo - -func (m *TargetTemplate) Reset() { *m = TargetTemplate{} } -func (*TargetTemplate) ProtoMessage() {} -func (*TargetTemplate) Descriptor() ([]byte, []int) { - return fileDescriptor_c428ff1fee4945a0, []int{49} -} -func (m *TargetTemplate) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *TargetTemplate) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) +func (m *DiscoveryVendorProfileList) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } - return b[:n], nil -} -func (m *TargetTemplate) XXX_Merge(src proto.Message) { - xxx_messageInfo_TargetTemplate.Merge(m, src) -} -func (m *TargetTemplate) XXX_Size() int { - return m.Size() -} -func (m *TargetTemplate) XXX_DiscardUnknown() { - xxx_messageInfo_TargetTemplate.DiscardUnknown(m) + return dAtA[:n], nil } -var xxx_messageInfo_TargetTemplate proto.InternalMessageInfo - -func (m *Workspace) Reset() { *m = Workspace{} } -func (*Workspace) ProtoMessage() {} -func (*Workspace) Descriptor() ([]byte, []int) { - return fileDescriptor_c428ff1fee4945a0, []int{50} -} -func (m *Workspace) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *Workspace) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err - } - return b[:n], nil -} -func (m *Workspace) XXX_Merge(src proto.Message) { - xxx_messageInfo_Workspace.Merge(m, src) -} -func (m *Workspace) XXX_Size() int { - return m.Size() -} -func (m *Workspace) XXX_DiscardUnknown() { - xxx_messageInfo_Workspace.DiscardUnknown(m) +func (m *DiscoveryVendorProfileList) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) } -var xxx_messageInfo_Workspace proto.InternalMessageInfo - -func (m *WorkspaceList) Reset() { *m = WorkspaceList{} } -func (*WorkspaceList) ProtoMessage() {} -func (*WorkspaceList) Descriptor() ([]byte, []int) { - return fileDescriptor_c428ff1fee4945a0, []int{51} -} -func (m *WorkspaceList) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *WorkspaceList) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err +func (m *DiscoveryVendorProfileList) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + if len(m.Items) > 0 { + for iNdEx := len(m.Items) - 1; iNdEx >= 0; iNdEx-- { + { + size, err := m.Items[iNdEx].MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintGenerated(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0x12 + } } - return b[:n], nil -} -func (m *WorkspaceList) XXX_Merge(src proto.Message) { - xxx_messageInfo_WorkspaceList.Merge(m, src) -} -func (m *WorkspaceList) XXX_Size() int { - return m.Size() -} -func (m *WorkspaceList) XXX_DiscardUnknown() { - xxx_messageInfo_WorkspaceList.DiscardUnknown(m) -} - -var xxx_messageInfo_WorkspaceList proto.InternalMessageInfo - -func (m *WorkspaceSpec) Reset() { *m = WorkspaceSpec{} } -func (*WorkspaceSpec) ProtoMessage() {} -func (*WorkspaceSpec) Descriptor() ([]byte, []int) { - return fileDescriptor_c428ff1fee4945a0, []int{52} -} -func (m *WorkspaceSpec) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *WorkspaceSpec) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err + { + size, err := m.ListMeta.MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintGenerated(dAtA, i, uint64(size)) } - return b[:n], nil -} -func (m *WorkspaceSpec) XXX_Merge(src proto.Message) { - xxx_messageInfo_WorkspaceSpec.Merge(m, src) -} -func (m *WorkspaceSpec) XXX_Size() int { - return m.Size() -} -func (m *WorkspaceSpec) XXX_DiscardUnknown() { - xxx_messageInfo_WorkspaceSpec.DiscardUnknown(m) + i-- + dAtA[i] = 0xa + return len(dAtA) - i, nil } -var xxx_messageInfo_WorkspaceSpec proto.InternalMessageInfo - -func (m *WorkspaceStatus) Reset() { *m = WorkspaceStatus{} } -func (*WorkspaceStatus) ProtoMessage() {} -func (*WorkspaceStatus) Descriptor() ([]byte, []int) { - return fileDescriptor_c428ff1fee4945a0, []int{53} -} -func (m *WorkspaceStatus) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *WorkspaceStatus) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err - } - return b[:n], nil -} -func (m *WorkspaceStatus) XXX_Merge(src proto.Message) { - xxx_messageInfo_WorkspaceStatus.Merge(m, src) -} -func (m *WorkspaceStatus) XXX_Size() int { - return m.Size() -} -func (m *WorkspaceStatus) XXX_DiscardUnknown() { - xxx_messageInfo_WorkspaceStatus.DiscardUnknown(m) -} - -var xxx_messageInfo_WorkspaceStatus proto.InternalMessageInfo - -func init() { - proto.RegisterType((*DiscoveryInfo)(nil), "github.com.sdcio.config_server.apis.inv.v1alpha1.DiscoveryInfo") - proto.RegisterType((*DiscoveryParameters)(nil), "github.com.sdcio.config_server.apis.inv.v1alpha1.DiscoveryParameters") - proto.RegisterType((*DiscoveryPathDefinition)(nil), "github.com.sdcio.config_server.apis.inv.v1alpha1.DiscoveryPathDefinition") - proto.RegisterType((*DiscoveryProfile)(nil), "github.com.sdcio.config_server.apis.inv.v1alpha1.DiscoveryProfile") - proto.RegisterType((*DiscoveryRule)(nil), "github.com.sdcio.config_server.apis.inv.v1alpha1.DiscoveryRule") - proto.RegisterType((*DiscoveryRuleAddress)(nil), "github.com.sdcio.config_server.apis.inv.v1alpha1.DiscoveryRuleAddress") - proto.RegisterType((*DiscoveryRuleList)(nil), "github.com.sdcio.config_server.apis.inv.v1alpha1.DiscoveryRuleList") - proto.RegisterType((*DiscoveryRulePrefix)(nil), "github.com.sdcio.config_server.apis.inv.v1alpha1.DiscoveryRulePrefix") - proto.RegisterType((*DiscoveryRuleSpec)(nil), "github.com.sdcio.config_server.apis.inv.v1alpha1.DiscoveryRuleSpec") - proto.RegisterType((*DiscoveryRuleStatus)(nil), "github.com.sdcio.config_server.apis.inv.v1alpha1.DiscoveryRuleStatus") - proto.RegisterType((*DiscoveryVendorProfile)(nil), "github.com.sdcio.config_server.apis.inv.v1alpha1.DiscoveryVendorProfile") - proto.RegisterType((*DiscoveryVendorProfileList)(nil), "github.com.sdcio.config_server.apis.inv.v1alpha1.DiscoveryVendorProfileList") - proto.RegisterType((*DiscoveryVendorProfileSpec)(nil), "github.com.sdcio.config_server.apis.inv.v1alpha1.DiscoveryVendorProfileSpec") - proto.RegisterType((*GnmiDiscoveryVendorProfileParameters)(nil), "github.com.sdcio.config_server.apis.inv.v1alpha1.GnmiDiscoveryVendorProfileParameters") - proto.RegisterType((*Proxy)(nil), "github.com.sdcio.config_server.apis.inv.v1alpha1.Proxy") - proto.RegisterType((*Repository)(nil), "github.com.sdcio.config_server.apis.inv.v1alpha1.Repository") - proto.RegisterType((*Rollout)(nil), "github.com.sdcio.config_server.apis.inv.v1alpha1.Rollout") - proto.RegisterType((*RolloutList)(nil), "github.com.sdcio.config_server.apis.inv.v1alpha1.RolloutList") - proto.RegisterType((*RolloutSpec)(nil), "github.com.sdcio.config_server.apis.inv.v1alpha1.RolloutSpec") - proto.RegisterType((*RolloutStatus)(nil), "github.com.sdcio.config_server.apis.inv.v1alpha1.RolloutStatus") - proto.RegisterType((*RolloutTargetStatus)(nil), "github.com.sdcio.config_server.apis.inv.v1alpha1.RolloutTargetStatus") - proto.RegisterType((*Schema)(nil), "github.com.sdcio.config_server.apis.inv.v1alpha1.Schema") - proto.RegisterType((*SchemaKey)(nil), "github.com.sdcio.config_server.apis.inv.v1alpha1.SchemaKey") - proto.RegisterType((*SchemaList)(nil), "github.com.sdcio.config_server.apis.inv.v1alpha1.SchemaList") - proto.RegisterType((*SchemaRepositoryStatus)(nil), "github.com.sdcio.config_server.apis.inv.v1alpha1.SchemaRepositoryStatus") - proto.RegisterType((*SchemaSpec)(nil), "github.com.sdcio.config_server.apis.inv.v1alpha1.SchemaSpec") - proto.RegisterType((*SchemaSpecRepository)(nil), "github.com.sdcio.config_server.apis.inv.v1alpha1.SchemaSpecRepository") - proto.RegisterType((*SchemaSpecSchema)(nil), "github.com.sdcio.config_server.apis.inv.v1alpha1.SchemaSpecSchema") - proto.RegisterType((*SchemaStatus)(nil), "github.com.sdcio.config_server.apis.inv.v1alpha1.SchemaStatus") - proto.RegisterType((*SrcDstPath)(nil), "github.com.sdcio.config_server.apis.inv.v1alpha1.SrcDstPath") - proto.RegisterType((*Subscription)(nil), "github.com.sdcio.config_server.apis.inv.v1alpha1.Subscription") - proto.RegisterType((*SubscriptionList)(nil), "github.com.sdcio.config_server.apis.inv.v1alpha1.SubscriptionList") - proto.RegisterType((*SubscriptionParameters)(nil), "github.com.sdcio.config_server.apis.inv.v1alpha1.SubscriptionParameters") - proto.RegisterMapType((map[string]string)(nil), "github.com.sdcio.config_server.apis.inv.v1alpha1.SubscriptionParameters.LabelsEntry") - proto.RegisterType((*SubscriptionSpec)(nil), "github.com.sdcio.config_server.apis.inv.v1alpha1.SubscriptionSpec") - proto.RegisterType((*SubscriptionStatus)(nil), "github.com.sdcio.config_server.apis.inv.v1alpha1.SubscriptionStatus") - proto.RegisterType((*SubscriptionTarget)(nil), "github.com.sdcio.config_server.apis.inv.v1alpha1.SubscriptionTarget") - proto.RegisterType((*Target)(nil), "github.com.sdcio.config_server.apis.inv.v1alpha1.Target") - proto.RegisterType((*TargetConnectionProfile)(nil), "github.com.sdcio.config_server.apis.inv.v1alpha1.TargetConnectionProfile") - proto.RegisterType((*TargetConnectionProfileList)(nil), "github.com.sdcio.config_server.apis.inv.v1alpha1.TargetConnectionProfileList") - proto.RegisterType((*TargetConnectionProfileSpec)(nil), "github.com.sdcio.config_server.apis.inv.v1alpha1.TargetConnectionProfileSpec") - proto.RegisterType((*TargetList)(nil), "github.com.sdcio.config_server.apis.inv.v1alpha1.TargetList") - proto.RegisterType((*TargetProfile)(nil), "github.com.sdcio.config_server.apis.inv.v1alpha1.TargetProfile") - proto.RegisterType((*TargetSpec)(nil), "github.com.sdcio.config_server.apis.inv.v1alpha1.TargetSpec") - proto.RegisterType((*TargetStatus)(nil), "github.com.sdcio.config_server.apis.inv.v1alpha1.TargetStatus") - proto.RegisterType((*TargetStatusUsedReferences)(nil), "github.com.sdcio.config_server.apis.inv.v1alpha1.TargetStatusUsedReferences") - proto.RegisterType((*TargetSyncProfile)(nil), "github.com.sdcio.config_server.apis.inv.v1alpha1.TargetSyncProfile") - proto.RegisterType((*TargetSyncProfileList)(nil), "github.com.sdcio.config_server.apis.inv.v1alpha1.TargetSyncProfileList") - proto.RegisterType((*TargetSyncProfileSpec)(nil), "github.com.sdcio.config_server.apis.inv.v1alpha1.TargetSyncProfileSpec") - proto.RegisterType((*TargetSyncProfileSync)(nil), "github.com.sdcio.config_server.apis.inv.v1alpha1.TargetSyncProfileSync") - proto.RegisterType((*TargetTemplate)(nil), "github.com.sdcio.config_server.apis.inv.v1alpha1.TargetTemplate") - proto.RegisterMapType((map[string]string)(nil), "github.com.sdcio.config_server.apis.inv.v1alpha1.TargetTemplate.AnnotationsEntry") - proto.RegisterMapType((map[string]string)(nil), "github.com.sdcio.config_server.apis.inv.v1alpha1.TargetTemplate.LabelsEntry") - proto.RegisterType((*Workspace)(nil), "github.com.sdcio.config_server.apis.inv.v1alpha1.Workspace") - proto.RegisterType((*WorkspaceList)(nil), "github.com.sdcio.config_server.apis.inv.v1alpha1.WorkspaceList") - proto.RegisterType((*WorkspaceSpec)(nil), "github.com.sdcio.config_server.apis.inv.v1alpha1.WorkspaceSpec") - proto.RegisterType((*WorkspaceStatus)(nil), "github.com.sdcio.config_server.apis.inv.v1alpha1.WorkspaceStatus") -} - -func init() { - proto.RegisterFile("github.com/sdcio/config-server/apis/inv/v1alpha1/generated.proto", fileDescriptor_c428ff1fee4945a0) -} - -var fileDescriptor_c428ff1fee4945a0 = []byte{ - // 3350 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xd4, 0x1b, 0x4b, 0x8c, 0x23, 0x47, - 0x75, 0xdb, 0xf6, 0x7c, 0xfc, 0x3c, 0xde, 0xd9, 0xad, 0xfd, 0x39, 0x93, 0x64, 0x3c, 0x6a, 0x20, - 0xda, 0x90, 0xc4, 0x93, 0x5d, 0x02, 0x6c, 0xc8, 0x77, 0x3d, 0xb3, 0x9b, 0x2c, 0xd9, 0xcf, 0x50, - 0x9e, 0x9d, 0x04, 0x14, 0x92, 0xf4, 0x74, 0x97, 0x3d, 0x9d, 0xb1, 0xbb, 0xad, 0xea, 0xb6, 0xb3, - 0x46, 0x7b, 0x00, 0x42, 0xa4, 0x08, 0x09, 0x09, 0x10, 0xca, 0x01, 0x09, 0xc1, 0x31, 0x1c, 0x41, - 0xe2, 0x84, 0xc4, 0x09, 0x41, 0x50, 0x90, 0xc8, 0x01, 0x44, 0x24, 0xa4, 0x21, 0x71, 0x4e, 0x7c, - 0x24, 0xae, 0x68, 0xb9, 0xa0, 0xfa, 0x74, 0xf5, 0xc7, 0xee, 0xd9, 0xb1, 0xbd, 0x3b, 0xd9, 0xdc, - 0xec, 0xf7, 0x5e, 0xbd, 0xf7, 0xaa, 0xea, 0xd5, 0xfb, 0x55, 0x35, 0x3c, 0xdd, 0xb0, 0xfd, 0xad, - 0xce, 0x66, 0xc5, 0x74, 0x5b, 0xcb, 0x9e, 0x65, 0xda, 0xee, 0xb2, 0xe9, 0x3a, 0x75, 0xbb, 0xf1, - 0x90, 0x47, 0x68, 0x97, 0xd0, 0x65, 0xa3, 0x6d, 0x7b, 0xcb, 0xb6, 0xd3, 0x5d, 0xee, 0x9e, 0x32, - 0x9a, 0xed, 0x2d, 0xe3, 0xd4, 0x72, 0x83, 0x38, 0x84, 0x1a, 0x3e, 0xb1, 0x2a, 0x6d, 0xea, 0xfa, - 0x2e, 0x7a, 0x38, 0xe4, 0x50, 0xe1, 0x1c, 0x2a, 0x82, 0xc3, 0xcb, 0x82, 0x43, 0x85, 0x71, 0xa8, - 0xd8, 0x4e, 0xb7, 0x12, 0x70, 0x58, 0x78, 0x28, 0x22, 0xb3, 0xe1, 0x36, 0xdc, 0x65, 0xce, 0x68, - 0xb3, 0x53, 0xe7, 0xff, 0xf8, 0x1f, 0xfe, 0x4b, 0x08, 0x58, 0x38, 0xbf, 0x17, 0x15, 0x4d, 0xd7, - 0xb1, 0x6c, 0xdf, 0x76, 0x9d, 0x54, 0x45, 0x17, 0x1e, 0xd9, 0x3e, 0xe3, 0x55, 0x6c, 0x97, 0xd1, - 0xb7, 0x0c, 0x73, 0xcb, 0x76, 0x08, 0xed, 0x2d, 0xb7, 0xb7, 0x1b, 0x82, 0x41, 0x8b, 0xf8, 0xc6, - 0x72, 0x77, 0x70, 0xd4, 0x17, 0xd2, 0x46, 0xd1, 0x8e, 0xe3, 0xdb, 0x2d, 0xb2, 0xec, 0x99, 0x5b, - 0xa4, 0x65, 0x24, 0xc7, 0xe9, 0x6f, 0x67, 0xa1, 0xb8, 0x6a, 0x7b, 0xa6, 0xdb, 0x25, 0xb4, 0x77, - 0xc1, 0xa9, 0xbb, 0xe8, 0x41, 0x98, 0xe5, 0x28, 0xd3, 0x6d, 0x96, 0xb4, 0x25, 0xed, 0x64, 0xbe, - 0x7a, 0xe8, 0x9d, 0x9d, 0xf2, 0x81, 0xfe, 0x4e, 0x79, 0x76, 0x4d, 0xc2, 0xb1, 0xa2, 0x90, 0xd4, - 0x5d, 0xdb, 0x22, 0xb4, 0x94, 0x19, 0xa0, 0xe6, 0x70, 0xac, 0x28, 0xd0, 0xfd, 0x30, 0xd3, 0x25, - 0xd4, 0xb3, 0x5d, 0xa7, 0x94, 0xe5, 0xc4, 0xf3, 0x92, 0x78, 0x66, 0x43, 0x80, 0x71, 0x80, 0x67, - 0x8c, 0xb7, 0x5c, 0xcf, 0x77, 0x8c, 0x16, 0x29, 0xe5, 0xe2, 0x8c, 0x9f, 0x75, 0x3d, 0xff, 0xb2, - 0xd1, 0x22, 0x58, 0x51, 0x70, 0x35, 0x9a, 0x86, 0x5f, 0x77, 0x69, 0xab, 0x34, 0x95, 0x50, 0x43, - 0xc2, 0xb1, 0xa2, 0x40, 0xa7, 0x01, 0x5a, 0x86, 0x79, 0xd6, 0xb2, 0x28, 0xf1, 0xbc, 0xd2, 0x34, - 0xa7, 0x47, 0x92, 0x1e, 0x2e, 0x29, 0x0c, 0x8e, 0x50, 0xa1, 0x33, 0x30, 0xe7, 0x11, 0x6a, 0x1b, - 0xcd, 0xcb, 0x9d, 0xd6, 0x26, 0xa1, 0xa5, 0x19, 0x3e, 0xea, 0xa8, 0x1c, 0x35, 0x57, 0x8b, 0xe0, - 0x70, 0x8c, 0x12, 0x9d, 0x07, 0xe4, 0x75, 0xda, 0x6d, 0x97, 0xfa, 0xc4, 0x3a, 0xe7, 0x98, 0xae, - 0x65, 0x3b, 0x0d, 0xaf, 0x34, 0xbb, 0x94, 0x3d, 0x99, 0xaf, 0x1e, 0xef, 0xef, 0x94, 0x51, 0x6d, - 0x00, 0x8b, 0x87, 0x8c, 0xd0, 0xdf, 0x9d, 0x82, 0x23, 0x6a, 0xab, 0xd6, 0x0c, 0x6a, 0xb4, 0x88, - 0x4f, 0xa8, 0x87, 0x7c, 0x28, 0x5a, 0xa4, 0x6e, 0x74, 0x9a, 0x7e, 0x8d, 0xef, 0x31, 0xdf, 0xb5, - 0xc2, 0xe9, 0xc7, 0x2a, 0xa3, 0x5a, 0x7c, 0x45, 0x8c, 0x7f, 0x8e, 0xf4, 0xaa, 0x87, 0xfb, 0x3b, - 0xe5, 0xe2, 0x6a, 0x94, 0x2b, 0x8e, 0x0b, 0x41, 0xdf, 0xd1, 0xe0, 0x90, 0xa5, 0xb4, 0xa1, 0x6e, - 0xdd, 0x6e, 0x12, 0x6e, 0x01, 0x85, 0xd3, 0xd5, 0xd1, 0x25, 0xaf, 0x26, 0x38, 0x55, 0x8f, 0xf6, - 0x77, 0xca, 0x87, 0x92, 0x50, 0x3c, 0x20, 0x11, 0xfd, 0x44, 0x83, 0x92, 0x6f, 0xd0, 0x06, 0xf1, - 0x57, 0x5c, 0xc7, 0x21, 0x26, 0x3b, 0x5b, 0x12, 0xe7, 0x95, 0xb2, 0x4b, 0xd9, 0x93, 0x85, 0xd3, - 0x4f, 0x8d, 0xae, 0xce, 0x3a, 0xe7, 0x18, 0xe8, 0xb2, 0x24, 0x37, 0xb9, 0xb4, 0x9e, 0x22, 0x08, - 0xa7, 0xaa, 0x80, 0xae, 0xc3, 0x41, 0x81, 0x5b, 0x27, 0x2d, 0x66, 0x7f, 0xc2, 0x98, 0x0b, 0xa7, - 0x9f, 0x1e, 0x57, 0xa9, 0x80, 0x4f, 0x15, 0xf5, 0x77, 0xca, 0x07, 0xe3, 0x30, 0x9c, 0x90, 0x85, - 0x36, 0x60, 0xba, 0x4d, 0xa8, 0xed, 0x5a, 0xfc, 0x50, 0x14, 0x4e, 0x57, 0x2a, 0xc2, 0x4d, 0x54, - 0xa2, 0x6e, 0xa2, 0xd2, 0xde, 0x6e, 0x08, 0x71, 0xcc, 0xb9, 0x54, 0xba, 0xa7, 0x2a, 0xab, 0x1d, - 0x6a, 0xb0, 0x59, 0x54, 0x0f, 0xca, 0x99, 0x4f, 0xaf, 0x71, 0x2e, 0x58, 0x72, 0x43, 0x67, 0x61, - 0xde, 0x74, 0x1d, 0xb3, 0x43, 0x29, 0x71, 0xfc, 0x9a, 0x69, 0x38, 0xe2, 0x14, 0x65, 0xab, 0x27, - 0xe4, 0x80, 0xf9, 0x95, 0x38, 0x1a, 0x27, 0xe9, 0xf5, 0x9f, 0x6a, 0x70, 0x22, 0x62, 0xcd, 0xfe, - 0xd6, 0x2a, 0xa9, 0xdb, 0x0e, 0xf7, 0x8d, 0xe8, 0x5e, 0xc8, 0x6e, 0x93, 0x9e, 0xf4, 0x3e, 0x05, - 0xc9, 0x32, 0xfb, 0x1c, 0xe9, 0x61, 0x06, 0x47, 0x4b, 0x90, 0x6b, 0x1b, 0xfe, 0x96, 0xf4, 0x37, - 0x73, 0x12, 0x9f, 0x63, 0x4c, 0x30, 0xc7, 0x20, 0x1d, 0xa6, 0x3d, 0x93, 0xda, 0x6d, 0x5f, 0xba, - 0x19, 0x60, 0x73, 0xa8, 0x71, 0x08, 0x96, 0x18, 0x54, 0x86, 0x29, 0x4a, 0x1a, 0xe4, 0x9a, 0xf4, - 0x2e, 0xf9, 0xfe, 0x4e, 0x79, 0x0a, 0x33, 0x00, 0x16, 0x70, 0xfd, 0x37, 0x1a, 0x0c, 0x58, 0x20, - 0xfa, 0x3c, 0x14, 0x4c, 0x4a, 0x2c, 0xe2, 0xf8, 0xb6, 0xd1, 0xf4, 0xa4, 0x8a, 0x47, 0xa4, 0x0a, - 0x85, 0x95, 0x10, 0x85, 0xa3, 0x74, 0xe8, 0x01, 0xc8, 0xfb, 0x4d, 0xaf, 0x46, 0x4c, 0x4a, 0x7c, - 0xa9, 0x77, 0xb1, 0xbf, 0x53, 0xce, 0xaf, 0x5f, 0xac, 0x09, 0x20, 0x0e, 0xf1, 0xcc, 0x61, 0x98, - 0xc3, 0x8d, 0x59, 0x3a, 0x8c, 0x21, 0x16, 0x38, 0x64, 0x84, 0xfe, 0xfb, 0x4c, 0xc4, 0xb7, 0xe3, - 0x4e, 0x93, 0xa0, 0x57, 0x60, 0x96, 0xed, 0xb1, 0x65, 0xf8, 0x81, 0x97, 0x78, 0x78, 0x6f, 0x16, - 0x71, 0x65, 0xf3, 0x55, 0x62, 0xfa, 0x97, 0x88, 0x6f, 0x84, 0x8e, 0x32, 0x84, 0x61, 0xc5, 0x15, - 0x11, 0xc8, 0x79, 0x6d, 0x62, 0x4a, 0x4f, 0xb0, 0x32, 0x81, 0x27, 0x60, 0x0a, 0xd7, 0xda, 0xc4, - 0x0c, 0x37, 0x98, 0xfd, 0xc3, 0x9c, 0x3d, 0x6a, 0xc1, 0xb4, 0xe7, 0x1b, 0x7e, 0xc7, 0xe3, 0x1b, - 0x5c, 0x38, 0x7d, 0x6e, 0x52, 0x41, 0x9c, 0x59, 0x68, 0xef, 0xe2, 0x3f, 0x96, 0x42, 0x74, 0x17, - 0x8e, 0xc6, 0xc8, 0x83, 0xa0, 0x70, 0x3f, 0xcc, 0x18, 0x32, 0x8a, 0x68, 0xf1, 0x78, 0x16, 0x84, - 0x90, 0x00, 0x1f, 0xc4, 0x33, 0x16, 0xb7, 0x92, 0x81, 0x32, 0x1e, 0xcf, 0xd8, 0x2f, 0xfd, 0xaf, - 0x1a, 0x1c, 0x8e, 0x49, 0xbc, 0x68, 0x7b, 0x3e, 0x7a, 0x71, 0x60, 0xfb, 0xf6, 0x78, 0xa0, 0xd9, - 0x68, 0xbe, 0x79, 0x4a, 0x66, 0x00, 0x89, 0x6c, 0x9d, 0x05, 0x53, 0xb6, 0x4f, 0x5a, 0x5e, 0x29, - 0x33, 0xae, 0xdb, 0x8c, 0x69, 0x5c, 0x2d, 0x4a, 0x59, 0x53, 0x17, 0x18, 0x57, 0x2c, 0x98, 0xeb, - 0x8d, 0x48, 0x10, 0x63, 0x64, 0x6b, 0x94, 0xd4, 0xed, 0x6b, 0xe8, 0x3e, 0x98, 0x6e, 0xf3, 0x5f, - 0x72, 0x21, 0x43, 0xcf, 0xc3, 0xa1, 0x58, 0x62, 0xd1, 0x49, 0x98, 0x25, 0xd7, 0xcc, 0x66, 0xc7, - 0x22, 0x42, 0xcf, 0x7c, 0x75, 0x8e, 0x4d, 0xe7, 0x9c, 0x84, 0x61, 0x85, 0xd5, 0x7f, 0x31, 0x95, - 0x58, 0x42, 0x66, 0x3e, 0xc8, 0x63, 0xf9, 0x0a, 0xe3, 0x44, 0xd8, 0x96, 0x65, 0x6f, 0x81, 0xe9, - 0x08, 0x05, 0xa3, 0x69, 0x8f, 0x60, 0x8f, 0x95, 0x20, 0xf4, 0x1a, 0xe4, 0xa5, 0x19, 0x90, 0x60, - 0x75, 0xcf, 0x4f, 0x28, 0x55, 0xda, 0x57, 0xf5, 0xb0, 0x14, 0x9b, 0x3f, 0x1b, 0x08, 0xc0, 0xa1, - 0x2c, 0x54, 0x87, 0x42, 0xdb, 0xb5, 0x6a, 0xa4, 0x49, 0x4c, 0xdf, 0xa5, 0xf2, 0xac, 0x7c, 0x6e, - 0x8f, 0x36, 0x63, 0x6c, 0x92, 0x66, 0x30, 0xb4, 0x3a, 0xcf, 0xdc, 0xdb, 0x5a, 0xc8, 0x0b, 0x47, - 0x19, 0x23, 0x0a, 0xf3, 0x4c, 0x6d, 0xdb, 0x24, 0x4a, 0x56, 0x6e, 0x7c, 0x59, 0x47, 0x58, 0x00, - 0xa9, 0xc5, 0xf9, 0xe1, 0xa4, 0x00, 0xf4, 0x18, 0x14, 0x25, 0x68, 0xd5, 0x6d, 0x19, 0xb6, 0x23, - 0xf3, 0xbe, 0x63, 0x72, 0x41, 0x8a, 0xb5, 0x28, 0x12, 0xc7, 0x69, 0xd1, 0x8f, 0x34, 0x38, 0x62, - 0x0d, 0xe6, 0x52, 0x3c, 0x8a, 0x4d, 0x66, 0x12, 0x21, 0xb3, 0xea, 0xdd, 0x52, 0x95, 0x61, 0x59, - 0x1b, 0x1e, 0x26, 0x5e, 0x7f, 0x3d, 0x93, 0x38, 0x1d, 0xc2, 0x0f, 0xa1, 0x1f, 0x6a, 0x70, 0x58, - 0x95, 0x0e, 0xc4, 0x12, 0x50, 0xe9, 0x02, 0x2e, 0xec, 0x49, 0x59, 0x35, 0x3a, 0x54, 0x79, 0x25, - 0xc9, 0xb0, 0x7a, 0x97, 0x54, 0xf8, 0xf0, 0x00, 0x0a, 0x0f, 0x8a, 0x47, 0xcf, 0x43, 0xde, 0xf3, - 0x0d, 0xea, 0xaf, 0xdb, 0xad, 0x20, 0xf3, 0xfb, 0xec, 0xde, 0xb6, 0x9b, 0x8d, 0x10, 0xf1, 0xaf, - 0x16, 0x30, 0xc0, 0x21, 0x2f, 0xfd, 0x9f, 0x1a, 0x1c, 0x57, 0xab, 0xb0, 0x41, 0x1c, 0xcb, 0xa5, - 0x41, 0xf8, 0xbd, 0xfd, 0x01, 0xcc, 0x89, 0x05, 0xb0, 0x8b, 0x13, 0x58, 0x42, 0x4c, 0xf3, 0xb4, - 0x48, 0xa6, 0xff, 0x43, 0x83, 0x85, 0xe1, 0x43, 0xf6, 0xc1, 0xe5, 0xb7, 0xe2, 0x2e, 0xff, 0xd9, - 0x5b, 0x35, 0xdb, 0x14, 0xdf, 0xff, 0x56, 0xea, 0x5c, 0xb9, 0x6f, 0xbe, 0x06, 0xb9, 0x86, 0xd3, - 0xb2, 0xe5, 0x3c, 0x37, 0x46, 0x57, 0xe6, 0x19, 0xa7, 0x65, 0x0f, 0xe7, 0x1f, 0x39, 0x95, 0x6a, - 0x13, 0x18, 0x35, 0xe6, 0x12, 0xf5, 0xff, 0x65, 0xe0, 0xd3, 0x7b, 0x19, 0xcc, 0xaa, 0x40, 0x97, - 0x36, 0x0c, 0xc7, 0xfe, 0x06, 0x4f, 0x90, 0x65, 0xb0, 0x52, 0x55, 0xe0, 0x95, 0x08, 0x0e, 0xc7, - 0x28, 0x51, 0x05, 0xa0, 0xe5, 0x5a, 0xa4, 0x79, 0xc9, 0xf0, 0xcd, 0x20, 0x75, 0x3d, 0xc8, 0xeb, - 0x4d, 0x05, 0xc5, 0x11, 0x0a, 0xe4, 0xc0, 0x14, 0x4b, 0x65, 0x83, 0x22, 0xe6, 0xc2, 0x44, 0x2e, - 0x29, 0x9a, 0x5d, 0x87, 0x7b, 0xc3, 0xe0, 0x1e, 0x16, 0x62, 0xd0, 0x23, 0x30, 0x4b, 0x64, 0xa9, - 0x29, 0x33, 0xe2, 0x12, 0x0f, 0xac, 0x12, 0x76, 0x23, 0xf2, 0x1b, 0x2b, 0x4a, 0xb4, 0x02, 0x87, - 0xdb, 0x94, 0x70, 0x15, 0x58, 0xde, 0xe2, 0xb5, 0x0d, 0x93, 0x70, 0x47, 0x3c, 0x5b, 0x3d, 0xc6, - 0x1c, 0xc9, 0x5a, 0x12, 0x89, 0x07, 0xe9, 0xf5, 0x0d, 0x98, 0x5a, 0xa3, 0xee, 0xb5, 0x1e, 0x3a, - 0x0e, 0xd9, 0xab, 0xf8, 0xa2, 0x5c, 0xd4, 0x1c, 0x53, 0x13, 0x33, 0x40, 0x32, 0xe9, 0xce, 0xec, - 0x2d, 0xe9, 0xd6, 0x7f, 0x96, 0x01, 0xc0, 0xa4, 0xed, 0x7a, 0xb6, 0xef, 0xd2, 0x1e, 0x5a, 0x86, - 0x19, 0x4a, 0xda, 0x6e, 0x28, 0x41, 0x85, 0x8a, 0x90, 0xe8, 0x2a, 0xbe, 0x88, 0x03, 0xaa, 0x31, - 0xc5, 0xa2, 0x17, 0x60, 0xaa, 0xcd, 0xa6, 0x23, 0xc3, 0xed, 0x17, 0x47, 0xdf, 0x39, 0xbe, 0x1a, - 0xa2, 0x22, 0xe1, 0x3f, 0xb1, 0x60, 0x88, 0x4e, 0x41, 0x6e, 0xdb, 0x76, 0x2c, 0xb9, 0x3f, 0xf7, - 0x06, 0x86, 0xfc, 0x9c, 0xed, 0x58, 0x37, 0x76, 0xca, 0xc5, 0x2a, 0x35, 0x1c, 0x73, 0x6b, 0xdd, - 0x68, 0x30, 0x00, 0xe6, 0xa4, 0xac, 0x94, 0xa2, 0xa4, 0x2e, 0x63, 0xa3, 0x2a, 0xa5, 0x30, 0xa9, - 0x63, 0x06, 0xd7, 0x7f, 0x95, 0x81, 0x19, 0xec, 0x36, 0x9b, 0x6e, 0xc7, 0xdf, 0x07, 0xdf, 0xfa, - 0x72, 0xcc, 0xb7, 0x3e, 0x31, 0xfa, 0xc2, 0x48, 0x55, 0x53, 0xcb, 0x82, 0x46, 0xa2, 0x2c, 0x78, - 0x6a, 0x7c, 0x11, 0xbb, 0x17, 0x04, 0xef, 0x6a, 0x50, 0x90, 0x94, 0xfb, 0xe0, 0xa6, 0x5f, 0x8a, - 0xbb, 0xe9, 0x47, 0xc7, 0x9e, 0x55, 0x8a, 0x5f, 0xfe, 0x41, 0x46, 0xcd, 0x86, 0x3b, 0xe2, 0x36, - 0x00, 0x55, 0x47, 0x42, 0xce, 0xe7, 0xf1, 0x31, 0x84, 0x2a, 0x1e, 0xa1, 0x5d, 0x84, 0x30, 0x1c, - 0x91, 0x81, 0x9e, 0x82, 0x59, 0xcf, 0xa7, 0x86, 0x4f, 0x1a, 0x3d, 0x79, 0xce, 0x3e, 0x15, 0xac, - 0x47, 0x4d, 0xc2, 0x6f, 0xec, 0x94, 0xe7, 0xd5, 0xe6, 0x08, 0x10, 0x56, 0x83, 0xd0, 0x15, 0x38, - 0xe6, 0x6d, 0xdb, 0xed, 0xab, 0x8e, 0xd1, 0x35, 0xec, 0xa6, 0xb1, 0xd9, 0x24, 0xa2, 0x35, 0xc2, - 0x0d, 0x61, 0xb6, 0x7a, 0x57, 0x7f, 0xa7, 0x7c, 0xac, 0x36, 0x8c, 0x00, 0x0f, 0x1f, 0xa7, 0xbf, - 0x95, 0x81, 0x62, 0xcc, 0x16, 0xee, 0xcc, 0x24, 0xac, 0x0d, 0x33, 0xa2, 0xe7, 0x13, 0x18, 0xc7, - 0xb9, 0xb1, 0x8d, 0x43, 0x4c, 0x5c, 0x6a, 0xa1, 0x0a, 0x59, 0x01, 0xf5, 0x70, 0x20, 0x46, 0xff, - 0xa3, 0x06, 0x47, 0x86, 0x8c, 0x40, 0x4b, 0x90, 0xe3, 0xcd, 0x5a, 0x2d, 0xde, 0x95, 0xe1, 0x85, - 0x2d, 0xc7, 0xa4, 0x2c, 0x60, 0xe6, 0x63, 0x5d, 0x40, 0xfd, 0x97, 0x19, 0x98, 0x96, 0x2d, 0xcd, - 0xdb, 0xef, 0x00, 0x5f, 0x8a, 0x39, 0xc0, 0xc7, 0xc7, 0xed, 0xd0, 0xa6, 0xfa, 0xbf, 0x7a, 0xc2, - 0xff, 0x3d, 0x39, 0xb6, 0x84, 0xdd, 0xdd, 0x9f, 0x05, 0x79, 0xd5, 0x2b, 0x8e, 0x5d, 0x01, 0x68, - 0xa3, 0x5c, 0x01, 0x64, 0x76, 0xbf, 0x02, 0xd0, 0xff, 0xa0, 0x01, 0x08, 0x31, 0xfb, 0xe0, 0x63, - 0xbf, 0x1e, 0xf7, 0xb1, 0x67, 0xc6, 0x5d, 0xb9, 0x14, 0x17, 0xeb, 0xc3, 0x71, 0xd9, 0x47, 0x57, - 0x4e, 0x4f, 0x9e, 0x9b, 0xfb, 0x93, 0x69, 0x89, 0x5a, 0x10, 0x2c, 0xc0, 0x61, 0x42, 0xb2, 0x0c, - 0x79, 0x4a, 0xea, 0x84, 0x12, 0xc7, 0x0c, 0x9a, 0x48, 0xaa, 0xfe, 0xc7, 0x01, 0x02, 0x87, 0x34, - 0xfa, 0x47, 0x6a, 0x05, 0xb9, 0x5f, 0xbf, 0x5d, 0x3b, 0x85, 0xae, 0xc3, 0x9c, 0x72, 0xe6, 0xb6, - 0x6a, 0xbc, 0x9f, 0x9f, 0xc4, 0xbe, 0x23, 0xc1, 0xe3, 0x10, 0x4b, 0xad, 0x71, 0x84, 0x3f, 0x8e, - 0x49, 0xd3, 0xff, 0x9c, 0x81, 0xa3, 0xc3, 0x06, 0x26, 0xe2, 0xd8, 0xec, 0x3e, 0xc4, 0xb1, 0x97, - 0x20, 0x67, 0xd9, 0xbc, 0x8f, 0x90, 0x1d, 0xf3, 0x80, 0x53, 0x73, 0xd5, 0xf3, 0x59, 0x66, 0x1e, - 0x1e, 0xf0, 0x55, 0x9b, 0x7a, 0x98, 0xf3, 0x45, 0xaf, 0xc2, 0xb4, 0xb8, 0xc8, 0xe3, 0xf7, 0x4f, - 0x63, 0x5d, 0xb5, 0x84, 0x2b, 0x25, 0x0d, 0x36, 0x3c, 0xe4, 0xc2, 0x40, 0xa5, 0x04, 0xfd, 0xbb, - 0x1a, 0x1c, 0x4a, 0x12, 0x23, 0x1d, 0xa6, 0x79, 0x91, 0x22, 0xba, 0x67, 0xb2, 0xb3, 0xce, 0x4b, - 0x18, 0x0f, 0x4b, 0x0c, 0x3a, 0x09, 0xb3, 0xb6, 0x33, 0xd8, 0xa3, 0xbb, 0xe0, 0x04, 0x3d, 0xba, - 0x00, 0x1b, 0xeb, 0xe6, 0x65, 0x77, 0xed, 0xe6, 0xbd, 0x9d, 0x81, 0xb9, 0xa8, 0x6b, 0xba, 0x33, - 0xa3, 0xf1, 0xb7, 0xb5, 0xc4, 0x41, 0x18, 0xbb, 0xae, 0x1e, 0xee, 0x2c, 0xc2, 0x4a, 0x73, 0x97, - 0xe3, 0xf0, 0x65, 0x80, 0xd0, 0x8a, 0x58, 0x01, 0xe0, 0x51, 0x33, 0x79, 0x97, 0x52, 0xa3, 0x26, - 0x66, 0x70, 0x86, 0xb6, 0xbc, 0xe0, 0x4a, 0x42, 0xa1, 0x57, 0x3d, 0x1f, 0x33, 0xb8, 0xfe, 0x5b, - 0xb6, 0xec, 0x9d, 0x4d, 0x71, 0x65, 0xc2, 0x4e, 0xfa, 0xed, 0x8f, 0x91, 0x56, 0x2c, 0x46, 0x8e, - 0x63, 0xe0, 0x11, 0x7d, 0x53, 0x23, 0x65, 0x33, 0x11, 0x29, 0x57, 0x27, 0x94, 0xb3, 0x7b, 0xbc, - 0xfc, 0x0b, 0x3b, 0x4a, 0x11, 0xf2, 0x7d, 0x88, 0x67, 0x66, 0x3c, 0x9e, 0x3d, 0x39, 0xd9, 0xfc, - 0x52, 0xa2, 0xda, 0xf7, 0x72, 0x70, 0x3c, 0x4a, 0x16, 0xe9, 0x94, 0xdc, 0x3c, 0x1d, 0x3c, 0x05, - 0x05, 0x8b, 0xa8, 0xa1, 0x41, 0x8c, 0x61, 0xa5, 0xf5, 0x6a, 0x08, 0xc6, 0x51, 0x1a, 0x74, 0x1d, - 0xa6, 0x9b, 0xc6, 0x26, 0xf3, 0x3e, 0x22, 0xc2, 0xac, 0x4f, 0x36, 0xab, 0x50, 0x5d, 0xd1, 0x81, - 0xf6, 0xce, 0x39, 0x3e, 0xed, 0x85, 0xbb, 0x28, 0x80, 0x58, 0xca, 0x44, 0x8f, 0x03, 0x18, 0x56, - 0xcb, 0xe6, 0x9b, 0x1d, 0x3c, 0x4a, 0xb8, 0x87, 0xd9, 0xf1, 0x59, 0x05, 0xbd, 0x11, 0xfb, 0x87, - 0x23, 0xf4, 0xe8, 0x41, 0xc8, 0x31, 0xff, 0x28, 0x4b, 0xf1, 0x52, 0xb0, 0x20, 0xcc, 0x77, 0xde, - 0x60, 0x65, 0x4e, 0xcf, 0x31, 0xd9, 0x6f, 0xcc, 0xa9, 0xd0, 0x0b, 0xcc, 0x87, 0xfa, 0x84, 0x76, - 0x8d, 0xa6, 0x6c, 0x4a, 0x8f, 0x7a, 0x77, 0x2b, 0x7d, 0xae, 0xe0, 0x81, 0x15, 0x37, 0x54, 0x0e, - 0x1a, 0x4b, 0x33, 0xdc, 0xe1, 0xe6, 0x93, 0x9d, 0xa0, 0x85, 0x47, 0xa1, 0x10, 0x59, 0x0d, 0x74, - 0x28, 0x72, 0x19, 0x2b, 0xee, 0x5f, 0x8f, 0xc2, 0x54, 0xd7, 0x68, 0x76, 0x64, 0x0a, 0x82, 0xc5, - 0x9f, 0x2f, 0x65, 0xce, 0x68, 0xfa, 0x8f, 0xb3, 0x71, 0x3b, 0xaf, 0xc9, 0xa3, 0x26, 0x6a, 0x07, - 0x69, 0xe5, 0x13, 0x1e, 0x35, 0x51, 0x74, 0x84, 0x9b, 0x24, 0xcb, 0x38, 0x29, 0x03, 0x9d, 0x89, - 0x3c, 0x5f, 0x11, 0x26, 0x75, 0x4f, 0xf2, 0xf9, 0xca, 0x8d, 0xe1, 0x4f, 0x59, 0x96, 0x20, 0xd7, - 0x76, 0xa9, 0xa8, 0x18, 0x8b, 0x91, 0x6b, 0x65, 0x97, 0xfa, 0x98, 0x63, 0xc6, 0xec, 0x91, 0xbd, - 0xa1, 0x41, 0xd1, 0x8b, 0x4c, 0xc0, 0x2b, 0x4d, 0x8d, 0x1d, 0x15, 0x86, 0x1a, 0x6f, 0xe4, 0xce, - 0x23, 0x2a, 0x06, 0xc7, 0xa5, 0xea, 0xef, 0x69, 0x80, 0x06, 0x7d, 0xd6, 0x9d, 0x19, 0x48, 0x3f, - 0x13, 0x2f, 0x6b, 0xf3, 0xd5, 0xc2, 0xd0, 0x5a, 0xf4, 0x8d, 0xc4, 0x94, 0x04, 0x01, 0x72, 0x83, - 0x47, 0x17, 0xea, 0x36, 0x4a, 0x1b, 0xff, 0x36, 0x2a, 0xf2, 0xce, 0x42, 0x5d, 0x46, 0x25, 0xd8, - 0xf3, 0x22, 0x52, 0xca, 0xfe, 0x04, 0x14, 0x91, 0x72, 0x32, 0xb7, 0xb1, 0x88, 0x8c, 0xb5, 0x12, - 0xd2, 0x82, 0xe2, 0xbf, 0x35, 0x38, 0x91, 0xf2, 0xa2, 0x66, 0x1f, 0x56, 0xd1, 0x8d, 0xad, 0xe2, - 0xa5, 0x71, 0xe7, 0x38, 0xa0, 0x7a, 0xea, 0x45, 0xcf, 0xbf, 0x34, 0xb8, 0x3b, 0x65, 0xcc, 0x3e, - 0xa4, 0x03, 0x4e, 0x3c, 0x1d, 0xb8, 0x70, 0xcb, 0xe6, 0x9b, 0x92, 0x19, 0xfc, 0x6d, 0x3a, 0x75, - 0xb6, 0x3c, 0x28, 0x6c, 0xc1, 0x9c, 0x7c, 0xb1, 0x82, 0x89, 0xaf, 0x9a, 0x8c, 0xa3, 0xc6, 0x38, - 0x95, 0x0e, 0xaf, 0x44, 0x78, 0xe1, 0x18, 0x67, 0xf4, 0x55, 0x98, 0xf1, 0xed, 0x16, 0x71, 0x3b, - 0xbe, 0xdc, 0xeb, 0x51, 0x85, 0x84, 0xad, 0x30, 0xc1, 0x06, 0x07, 0xfc, 0x62, 0xb1, 0x26, 0x3b, - 0x56, 0xac, 0xc9, 0xed, 0x29, 0xd6, 0x4c, 0xed, 0x39, 0xd6, 0x5c, 0x85, 0x13, 0x6d, 0x5e, 0xfe, - 0x53, 0x62, 0x5d, 0x26, 0x3e, 0xdb, 0x53, 0x59, 0xac, 0xcb, 0x67, 0x8e, 0x77, 0xf7, 0x77, 0xca, - 0x27, 0xd6, 0x86, 0x93, 0xe0, 0xb4, 0xb1, 0xa2, 0xa2, 0xf3, 0x88, 0xd9, 0xa1, 0x84, 0x17, 0x9e, - 0xb3, 0x41, 0x76, 0x21, 0x60, 0x58, 0x61, 0x51, 0x05, 0xc0, 0xdb, 0xb6, 0xdb, 0x1b, 0x84, 0xda, - 0x75, 0x51, 0x72, 0xcf, 0x8a, 0x6b, 0xae, 0x9a, 0x82, 0xe2, 0x08, 0x05, 0x7a, 0x00, 0xf2, 0xb2, - 0x1a, 0xbc, 0x5c, 0x2b, 0xe5, 0x39, 0x39, 0xbf, 0x18, 0xbe, 0x10, 0x00, 0x71, 0x88, 0x47, 0x4f, - 0xc0, 0xbc, 0xdb, 0x26, 0x62, 0x5b, 0x9e, 0xb7, 0xfd, 0xad, 0xcb, 0xb5, 0x12, 0xf0, 0x21, 0xfc, - 0xc5, 0xc0, 0x95, 0x38, 0x0a, 0x27, 0x69, 0xd1, 0x79, 0x40, 0x1d, 0x8f, 0x28, 0x32, 0x4c, 0x5a, - 0x6e, 0x97, 0x94, 0x0a, 0x9c, 0x03, 0x7f, 0x57, 0x75, 0x75, 0x00, 0x8b, 0x87, 0x8c, 0x40, 0x6b, - 0x30, 0x6f, 0xba, 0xad, 0x96, 0xed, 0xaf, 0x18, 0x8e, 0x65, 0x5b, 0x2c, 0x19, 0x9c, 0xe3, 0x8b, - 0x7b, 0x9f, 0x78, 0xf9, 0x16, 0x43, 0xdd, 0x18, 0x04, 0xe1, 0xe4, 0x70, 0xb6, 0x6a, 0x22, 0xa2, - 0xf0, 0xe7, 0x41, 0xc5, 0xf0, 0x72, 0x70, 0x5d, 0x41, 0x71, 0x84, 0x82, 0x77, 0xc6, 0x04, 0xea, - 0x13, 0xd1, 0x19, 0x93, 0x29, 0xdb, 0x70, 0x4f, 0xf1, 0x1f, 0x0d, 0x8a, 0xb1, 0xf7, 0x96, 0xfb, - 0xf2, 0xc6, 0xee, 0x19, 0x9e, 0xf4, 0xc4, 0x1d, 0x93, 0x3c, 0xc3, 0xd1, 0x4c, 0x25, 0x4e, 0x80, - 0x07, 0xc7, 0xb0, 0x2a, 0xc6, 0xeb, 0x39, 0x66, 0xc0, 0x22, 0x17, 0x56, 0x31, 0xb5, 0x10, 0x8c, - 0xa3, 0x34, 0xbc, 0x2b, 0x17, 0xc6, 0xe0, 0xd1, 0xbb, 0x72, 0xc1, 0x93, 0xb3, 0xcc, 0x4d, 0x9e, - 0x9c, 0x5d, 0x87, 0xa2, 0x1f, 0x5d, 0xd8, 0xf1, 0x2f, 0xc5, 0xe2, 0xef, 0x61, 0x55, 0xba, 0x19, - 0x03, 0xe3, 0xb8, 0x30, 0xfd, 0xed, 0x2c, 0xcc, 0xc5, 0x2e, 0x08, 0xee, 0xc8, 0x44, 0xf3, 0x1a, - 0x14, 0xad, 0xe8, 0xf3, 0x77, 0x19, 0x23, 0x26, 0x79, 0xfc, 0xc6, 0xd8, 0xc8, 0x07, 0xd4, 0x51, - 0x10, 0x8e, 0x0b, 0x42, 0x6f, 0x6a, 0x70, 0xb0, 0xe3, 0x11, 0x4b, 0x35, 0x6e, 0x83, 0x7c, 0xeb, - 0xe2, 0x64, 0xf9, 0xd6, 0xd5, 0x18, 0x4f, 0x91, 0xbe, 0xc6, 0x61, 0x38, 0x21, 0x57, 0xff, 0x79, - 0x16, 0x16, 0xd2, 0x59, 0xa0, 0x1a, 0x1c, 0xf3, 0xc4, 0x01, 0x22, 0x9e, 0xdb, 0xa1, 0x26, 0x09, - 0x42, 0x8a, 0x16, 0xbb, 0x87, 0x3e, 0x56, 0x1b, 0x46, 0x84, 0x87, 0x8f, 0x45, 0x2f, 0x42, 0x49, - 0x9d, 0xc6, 0x24, 0x5f, 0x61, 0xd8, 0xe1, 0xb3, 0x6b, 0x75, 0x80, 0x13, 0xac, 0x53, 0x39, 0x20, - 0x1f, 0x96, 0x06, 0x8e, 0x6a, 0x52, 0x8a, 0x38, 0xed, 0x27, 0xa5, 0x94, 0xa5, 0x95, 0x9b, 0xd0, - 0xe3, 0x9b, 0x72, 0x44, 0x9b, 0xb0, 0x10, 0x39, 0xe7, 0x49, 0x79, 0xc2, 0x35, 0xe8, 0x52, 0xde, - 0x42, 0x2d, 0x95, 0x12, 0xef, 0xc2, 0x45, 0xff, 0x40, 0x83, 0xc3, 0x72, 0xaf, 0x42, 0xa2, 0x7d, - 0xc8, 0x97, 0xed, 0x58, 0xbe, 0xfc, 0xcc, 0xd8, 0x36, 0x1a, 0x2a, 0x9d, 0x9a, 0x29, 0xff, 0x5d, - 0x83, 0x63, 0x03, 0xd4, 0xfb, 0x10, 0xe8, 0xb6, 0xe2, 0x81, 0x6e, 0xe5, 0x16, 0xcc, 0x31, 0x25, - 0xe6, 0xbd, 0x9e, 0x19, 0x32, 0xc3, 0x20, 0x18, 0x74, 0x8d, 0xa6, 0x48, 0x2a, 0x34, 0x9e, 0x99, - 0x28, 0x8d, 0x37, 0x24, 0x1c, 0x2b, 0x0a, 0x74, 0x1f, 0x4c, 0x6f, 0x76, 0xea, 0x75, 0xf9, 0xed, - 0x4d, 0x36, 0x2c, 0xb5, 0xaa, 0x1c, 0x8a, 0x25, 0x96, 0x05, 0x8d, 0xd7, 0x5c, 0xba, 0x4d, 0xa8, - 0xf0, 0x31, 0xd9, 0x30, 0x68, 0x3c, 0x2f, 0xc0, 0x38, 0xc0, 0xf3, 0x7d, 0xee, 0x39, 0x66, 0x29, - 0xc7, 0xd7, 0xe0, 0x96, 0xec, 0x73, 0xcf, 0x89, 0xee, 0x73, 0xcf, 0x61, 0xfb, 0xdc, 0x73, 0x4c, - 0xfd, 0xbf, 0x43, 0x57, 0xa1, 0xe7, 0x98, 0x7b, 0x68, 0x1e, 0xde, 0xce, 0x36, 0x8f, 0xea, 0x90, - 0xe5, 0x86, 0x77, 0xc8, 0x46, 0x6c, 0xe5, 0x45, 0x33, 0xf9, 0xe9, 0x3d, 0x67, 0xf2, 0x2f, 0x46, - 0x1a, 0x80, 0x33, 0x63, 0xd5, 0x2d, 0xca, 0x70, 0x06, 0x9b, 0x80, 0xfa, 0xef, 0xb2, 0x90, 0xf8, - 0x76, 0x04, 0x9d, 0x81, 0x39, 0xb6, 0xb2, 0xea, 0x3b, 0x95, 0xc4, 0xd3, 0xb6, 0xcb, 0x11, 0x1c, - 0x8e, 0x51, 0xb2, 0x48, 0x56, 0x30, 0x1c, 0xc7, 0xf5, 0x0d, 0xd1, 0xde, 0x12, 0xc7, 0xe7, 0x2b, - 0x93, 0x7e, 0xe1, 0x52, 0x39, 0x1b, 0xf2, 0x14, 0x8d, 0x59, 0x95, 0x03, 0x46, 0x30, 0x38, 0x2a, - 0x1a, 0xf9, 0x89, 0x06, 0xf1, 0xc5, 0x89, 0x95, 0xd8, 0x43, 0x63, 0x78, 0xe1, 0x49, 0x38, 0x94, - 0xd4, 0x75, 0x94, 0xb6, 0xe9, 0x24, 0x1d, 0xd7, 0x5f, 0x67, 0x20, 0xcf, 0xce, 0x30, 0x7f, 0x49, - 0xb7, 0x0f, 0x61, 0xc0, 0x88, 0x85, 0x81, 0x31, 0xd2, 0x24, 0xa5, 0x6c, 0x6a, 0xff, 0xc9, 0x4e, - 0xf4, 0x9f, 0xce, 0x4e, 0x22, 0x64, 0xf7, 0x16, 0xd4, 0x9f, 0x34, 0x28, 0x2a, 0xda, 0x7d, 0x88, - 0x30, 0xaf, 0xc4, 0x23, 0xcc, 0x63, 0x13, 0xcc, 0x2c, 0x25, 0xb2, 0x7c, 0x2b, 0x3a, 0xa3, 0x8f, - 0xe7, 0x31, 0x97, 0xfe, 0x66, 0x06, 0xe6, 0x13, 0x3b, 0x70, 0x67, 0x26, 0xff, 0x0f, 0xc9, 0xf7, - 0x94, 0x22, 0x80, 0xdc, 0x75, 0xb3, 0xb7, 0x94, 0xfc, 0xc2, 0xaa, 0xdd, 0x74, 0x7b, 0x3c, 0x3b, - 0x0e, 0xbe, 0x60, 0x15, 0x17, 0x56, 0x0a, 0x8c, 0xa3, 0x34, 0xd5, 0x8d, 0x77, 0x3e, 0x5c, 0x3c, - 0xf0, 0xde, 0x87, 0x8b, 0x07, 0xde, 0xff, 0x70, 0xf1, 0xc0, 0x37, 0xfb, 0x8b, 0xda, 0x3b, 0xfd, - 0x45, 0xed, 0xbd, 0xfe, 0xa2, 0xf6, 0x7e, 0x7f, 0x51, 0xfb, 0xa0, 0xbf, 0xa8, 0x7d, 0xff, 0xa3, - 0xc5, 0x03, 0x5f, 0x7b, 0x78, 0xd4, 0xaf, 0x9b, 0xff, 0x1f, 0x00, 0x00, 0xff, 0xff, 0x04, 0xb4, - 0xca, 0x6d, 0x10, 0x3d, 0x00, 0x00, -} - -func (m *DiscoveryInfo) Marshal() (dAtA []byte, err error) { +func (m *DiscoveryVendorProfileSpec) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) @@ -1844,64 +709,30 @@ func (m *DiscoveryInfo) Marshal() (dAtA []byte, err error) { return dAtA[:n], nil } -func (m *DiscoveryInfo) MarshalTo(dAtA []byte) (int, error) { +func (m *DiscoveryVendorProfileSpec) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } -func (m *DiscoveryInfo) MarshalToSizedBuffer(dAtA []byte) (int, error) { +func (m *DiscoveryVendorProfileSpec) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l - if len(m.SupportedEncodings) > 0 { - for iNdEx := len(m.SupportedEncodings) - 1; iNdEx >= 0; iNdEx-- { - i -= len(m.SupportedEncodings[iNdEx]) - copy(dAtA[i:], m.SupportedEncodings[iNdEx]) - i = encodeVarintGenerated(dAtA, i, uint64(len(m.SupportedEncodings[iNdEx]))) - i-- - dAtA[i] = 0x42 + { + size, err := m.Gnmi.MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err } + i -= size + i = encodeVarintGenerated(dAtA, i, uint64(size)) } - i -= len(m.SerialNumber) - copy(dAtA[i:], m.SerialNumber) - i = encodeVarintGenerated(dAtA, i, uint64(len(m.SerialNumber))) - i-- - dAtA[i] = 0x3a - i -= len(m.MacAddress) - copy(dAtA[i:], m.MacAddress) - i = encodeVarintGenerated(dAtA, i, uint64(len(m.MacAddress))) - i-- - dAtA[i] = 0x32 - i -= len(m.Platform) - copy(dAtA[i:], m.Platform) - i = encodeVarintGenerated(dAtA, i, uint64(len(m.Platform))) - i-- - dAtA[i] = 0x2a - i -= len(m.Hostname) - copy(dAtA[i:], m.Hostname) - i = encodeVarintGenerated(dAtA, i, uint64(len(m.Hostname))) - i-- - dAtA[i] = 0x22 - i -= len(m.Version) - copy(dAtA[i:], m.Version) - i = encodeVarintGenerated(dAtA, i, uint64(len(m.Version))) - i-- - dAtA[i] = 0x1a - i -= len(m.Provider) - copy(dAtA[i:], m.Provider) - i = encodeVarintGenerated(dAtA, i, uint64(len(m.Provider))) - i-- - dAtA[i] = 0x12 - i -= len(m.Protocol) - copy(dAtA[i:], m.Protocol) - i = encodeVarintGenerated(dAtA, i, uint64(len(m.Protocol))) i-- dAtA[i] = 0xa return len(dAtA) - i, nil } -func (m *DiscoveryParameters) Marshal() (dAtA []byte, err error) { +func (m *GnmiDiscoveryVendorProfileParameters) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) @@ -1911,45 +742,37 @@ func (m *DiscoveryParameters) Marshal() (dAtA []byte, err error) { return dAtA[:n], nil } -func (m *DiscoveryParameters) MarshalTo(dAtA []byte) (int, error) { +func (m *GnmiDiscoveryVendorProfileParameters) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } -func (m *DiscoveryParameters) MarshalToSizedBuffer(dAtA []byte) (int, error) { +func (m *GnmiDiscoveryVendorProfileParameters) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l - i = encodeVarintGenerated(dAtA, i, uint64(m.ConcurrentScans)) - i-- - dAtA[i] = 0x30 - { - size, err := m.Period.MarshalToSizedBuffer(dAtA[:i]) - if err != nil { - return 0, err + if m.PreserveNamespace != nil { + i-- + if *m.PreserveNamespace { + dAtA[i] = 1 + } else { + dAtA[i] = 0 } - i -= size - i = encodeVarintGenerated(dAtA, i, uint64(size)) + i-- + dAtA[i] = 0x28 } - i-- - dAtA[i] = 0x2a - if m.TargetTemplate != nil { - { - size, err := m.TargetTemplate.MarshalToSizedBuffer(dAtA[:i]) - if err != nil { - return 0, err - } - i -= size - i = encodeVarintGenerated(dAtA, i, uint64(size)) - } + if m.Encoding != nil { + i -= len(*m.Encoding) + copy(dAtA[i:], *m.Encoding) + i = encodeVarintGenerated(dAtA, i, uint64(len(*m.Encoding))) i-- dAtA[i] = 0x22 } - if len(m.TargetConnectionProfiles) > 0 { - for iNdEx := len(m.TargetConnectionProfiles) - 1; iNdEx >= 0; iNdEx-- { + if len(m.Paths) > 0 { + for iNdEx := len(m.Paths) - 1; iNdEx >= 0; iNdEx-- { { - size, err := m.TargetConnectionProfiles[iNdEx].MarshalToSizedBuffer(dAtA[:i]) + size, err := m.Paths[iNdEx].MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } @@ -1960,34 +783,22 @@ func (m *DiscoveryParameters) MarshalToSizedBuffer(dAtA []byte) (int, error) { dAtA[i] = 0x1a } } - if m.DiscoveryProfile != nil { - { - size, err := m.DiscoveryProfile.MarshalToSizedBuffer(dAtA[:i]) - if err != nil { - return 0, err - } - i -= size - i = encodeVarintGenerated(dAtA, i, uint64(size)) - } + if m.ModelMatch != nil { + i -= len(*m.ModelMatch) + copy(dAtA[i:], *m.ModelMatch) + i = encodeVarintGenerated(dAtA, i, uint64(len(*m.ModelMatch))) i-- dAtA[i] = 0x12 } - if m.DefaultSchema != nil { - { - size, err := m.DefaultSchema.MarshalToSizedBuffer(dAtA[:i]) - if err != nil { - return 0, err - } - i -= size - i = encodeVarintGenerated(dAtA, i, uint64(size)) - } - i-- - dAtA[i] = 0xa - } + i -= len(m.Organization) + copy(dAtA[i:], m.Organization) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Organization))) + i-- + dAtA[i] = 0xa return len(dAtA) - i, nil } -func (m *DiscoveryPathDefinition) Marshal() (dAtA []byte, err error) { +func (m *Proxy) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) @@ -1997,44 +808,30 @@ func (m *DiscoveryPathDefinition) Marshal() (dAtA []byte, err error) { return dAtA[:n], nil } -func (m *DiscoveryPathDefinition) MarshalTo(dAtA []byte) (int, error) { +func (m *Proxy) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } -func (m *DiscoveryPathDefinition) MarshalToSizedBuffer(dAtA []byte) (int, error) { +func (m *Proxy) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l - if m.Regex != nil { - i -= len(*m.Regex) - copy(dAtA[i:], *m.Regex) - i = encodeVarintGenerated(dAtA, i, uint64(len(*m.Regex))) - i-- - dAtA[i] = 0x22 - } - if m.Script != nil { - i -= len(*m.Script) - copy(dAtA[i:], *m.Script) - i = encodeVarintGenerated(dAtA, i, uint64(len(*m.Script))) - i-- - dAtA[i] = 0x1a - } - i -= len(m.Path) - copy(dAtA[i:], m.Path) - i = encodeVarintGenerated(dAtA, i, uint64(len(m.Path))) + i -= len(m.Credentials) + copy(dAtA[i:], m.Credentials) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Credentials))) i-- dAtA[i] = 0x12 - i -= len(m.Key) - copy(dAtA[i:], m.Key) - i = encodeVarintGenerated(dAtA, i, uint64(len(m.Key))) + i -= len(m.URL) + copy(dAtA[i:], m.URL) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.URL))) i-- dAtA[i] = 0xa return len(dAtA) - i, nil } -func (m *DiscoveryProfile) Marshal() (dAtA []byte, err error) { +func (m *Repository) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) @@ -2044,41 +841,52 @@ func (m *DiscoveryProfile) Marshal() (dAtA []byte, err error) { return dAtA[:n], nil } -func (m *DiscoveryProfile) MarshalTo(dAtA []byte) (int, error) { +func (m *Repository) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } -func (m *DiscoveryProfile) MarshalToSizedBuffer(dAtA []byte) (int, error) { +func (m *Repository) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l - if len(m.ConnectionProfiles) > 0 { - for iNdEx := len(m.ConnectionProfiles) - 1; iNdEx >= 0; iNdEx-- { - i -= len(m.ConnectionProfiles[iNdEx]) - copy(dAtA[i:], m.ConnectionProfiles[iNdEx]) - i = encodeVarintGenerated(dAtA, i, uint64(len(m.ConnectionProfiles[iNdEx]))) - i-- - dAtA[i] = 0x1a + i -= len(m.Ref) + copy(dAtA[i:], m.Ref) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Ref))) + i-- + dAtA[i] = 0x2a + i -= len(m.Kind) + copy(dAtA[i:], m.Kind) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Kind))) + i-- + dAtA[i] = 0x22 + if m.Proxy != nil { + { + size, err := m.Proxy.MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintGenerated(dAtA, i, uint64(size)) } - } - if m.TLSSecret != nil { - i -= len(*m.TLSSecret) - copy(dAtA[i:], *m.TLSSecret) - i = encodeVarintGenerated(dAtA, i, uint64(len(*m.TLSSecret))) i-- - dAtA[i] = 0x12 + dAtA[i] = 0x1a } i -= len(m.Credentials) copy(dAtA[i:], m.Credentials) i = encodeVarintGenerated(dAtA, i, uint64(len(m.Credentials))) i-- + dAtA[i] = 0x12 + i -= len(m.RepoURL) + copy(dAtA[i:], m.RepoURL) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.RepoURL))) + i-- dAtA[i] = 0xa return len(dAtA) - i, nil } -func (m *DiscoveryRule) Marshal() (dAtA []byte, err error) { +func (m *Rollout) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) @@ -2088,12 +896,12 @@ func (m *DiscoveryRule) Marshal() (dAtA []byte, err error) { return dAtA[:n], nil } -func (m *DiscoveryRule) MarshalTo(dAtA []byte) (int, error) { +func (m *Rollout) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } -func (m *DiscoveryRule) MarshalToSizedBuffer(dAtA []byte) (int, error) { +func (m *Rollout) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int @@ -2131,40 +939,7 @@ func (m *DiscoveryRule) MarshalToSizedBuffer(dAtA []byte) (int, error) { return len(dAtA) - i, nil } -func (m *DiscoveryRuleAddress) Marshal() (dAtA []byte, err error) { - size := m.Size() - dAtA = make([]byte, size) - n, err := m.MarshalToSizedBuffer(dAtA[:size]) - if err != nil { - return nil, err - } - return dAtA[:n], nil -} - -func (m *DiscoveryRuleAddress) MarshalTo(dAtA []byte) (int, error) { - size := m.Size() - return m.MarshalToSizedBuffer(dAtA[:size]) -} - -func (m *DiscoveryRuleAddress) MarshalToSizedBuffer(dAtA []byte) (int, error) { - i := len(dAtA) - _ = i - var l int - _ = l - i -= len(m.HostName) - copy(dAtA[i:], m.HostName) - i = encodeVarintGenerated(dAtA, i, uint64(len(m.HostName))) - i-- - dAtA[i] = 0x12 - i -= len(m.Address) - copy(dAtA[i:], m.Address) - i = encodeVarintGenerated(dAtA, i, uint64(len(m.Address))) - i-- - dAtA[i] = 0xa - return len(dAtA) - i, nil -} - -func (m *DiscoveryRuleList) Marshal() (dAtA []byte, err error) { +func (m *RolloutList) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) @@ -2174,12 +949,12 @@ func (m *DiscoveryRuleList) Marshal() (dAtA []byte, err error) { return dAtA[:n], nil } -func (m *DiscoveryRuleList) MarshalTo(dAtA []byte) (int, error) { +func (m *RolloutList) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } -func (m *DiscoveryRuleList) MarshalToSizedBuffer(dAtA []byte) (int, error) { +func (m *RolloutList) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int @@ -2211,7 +986,7 @@ func (m *DiscoveryRuleList) MarshalToSizedBuffer(dAtA []byte) (int, error) { return len(dAtA) - i, nil } -func (m *DiscoveryRulePrefix) Marshal() (dAtA []byte, err error) { +func (m *RolloutSpec) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) @@ -2221,34 +996,45 @@ func (m *DiscoveryRulePrefix) Marshal() (dAtA []byte, err error) { return dAtA[:n], nil } -func (m *DiscoveryRulePrefix) MarshalTo(dAtA []byte) (int, error) { +func (m *RolloutSpec) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } -func (m *DiscoveryRulePrefix) MarshalToSizedBuffer(dAtA []byte) (int, error) { +func (m *RolloutSpec) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l - if len(m.Excludes) > 0 { - for iNdEx := len(m.Excludes) - 1; iNdEx >= 0; iNdEx-- { - i -= len(m.Excludes[iNdEx]) - copy(dAtA[i:], m.Excludes[iNdEx]) - i = encodeVarintGenerated(dAtA, i, uint64(len(m.Excludes[iNdEx]))) - i-- - dAtA[i] = 0x12 + if m.SkipUnavailableTarget != nil { + i-- + if *m.SkipUnavailableTarget { + dAtA[i] = 1 + } else { + dAtA[i] = 0 } + i-- + dAtA[i] = 0x18 + } + i -= len(m.Strategy) + copy(dAtA[i:], m.Strategy) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Strategy))) + i-- + dAtA[i] = 0x12 + { + size, err := m.Repository.MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintGenerated(dAtA, i, uint64(size)) } - i -= len(m.Prefix) - copy(dAtA[i:], m.Prefix) - i = encodeVarintGenerated(dAtA, i, uint64(len(m.Prefix))) i-- dAtA[i] = 0xa return len(dAtA) - i, nil } -func (m *DiscoveryRuleSpec) Marshal() (dAtA []byte, err error) { +func (m *RolloutStatus) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) @@ -2258,59 +1044,20 @@ func (m *DiscoveryRuleSpec) Marshal() (dAtA []byte, err error) { return dAtA[:n], nil } -func (m *DiscoveryRuleSpec) MarshalTo(dAtA []byte) (int, error) { +func (m *RolloutStatus) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } -func (m *DiscoveryRuleSpec) MarshalToSizedBuffer(dAtA []byte) (int, error) { +func (m *RolloutStatus) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l - { - size, err := m.DiscoveryParameters.MarshalToSizedBuffer(dAtA[:i]) - if err != nil { - return 0, err - } - i -= size - i = encodeVarintGenerated(dAtA, i, uint64(size)) - } - i-- - dAtA[i] = 0x32 - i -= len(m.ServiceDomain) - copy(dAtA[i:], m.ServiceDomain) - i = encodeVarintGenerated(dAtA, i, uint64(len(m.ServiceDomain))) - i-- - dAtA[i] = 0x2a - if m.ServiceSelector != nil { - { - size, err := m.ServiceSelector.MarshalToSizedBuffer(dAtA[:i]) - if err != nil { - return 0, err - } - i -= size - i = encodeVarintGenerated(dAtA, i, uint64(size)) - } - i-- - dAtA[i] = 0x22 - } - if m.PodSelector != nil { - { - size, err := m.PodSelector.MarshalToSizedBuffer(dAtA[:i]) - if err != nil { - return 0, err - } - i -= size - i = encodeVarintGenerated(dAtA, i, uint64(size)) - } - i-- - dAtA[i] = 0x1a - } - if len(m.Addresses) > 0 { - for iNdEx := len(m.Addresses) - 1; iNdEx >= 0; iNdEx-- { + if len(m.Targets) > 0 { + for iNdEx := len(m.Targets) - 1; iNdEx >= 0; iNdEx-- { { - size, err := m.Addresses[iNdEx].MarshalToSizedBuffer(dAtA[:i]) + size, err := m.Targets[iNdEx].MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } @@ -2321,24 +1068,20 @@ func (m *DiscoveryRuleSpec) MarshalToSizedBuffer(dAtA []byte) (int, error) { dAtA[i] = 0x12 } } - if len(m.Prefixes) > 0 { - for iNdEx := len(m.Prefixes) - 1; iNdEx >= 0; iNdEx-- { - { - size, err := m.Prefixes[iNdEx].MarshalToSizedBuffer(dAtA[:i]) - if err != nil { - return 0, err - } - i -= size - i = encodeVarintGenerated(dAtA, i, uint64(size)) - } - i-- - dAtA[i] = 0xa + { + size, err := m.ConditionedStatus.MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err } + i -= size + i = encodeVarintGenerated(dAtA, i, uint64(size)) } + i-- + dAtA[i] = 0xa return len(dAtA) - i, nil } -func (m *DiscoveryRuleStatus) Marshal() (dAtA []byte, err error) { +func (m *RolloutTargetStatus) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) @@ -2348,28 +1091,16 @@ func (m *DiscoveryRuleStatus) Marshal() (dAtA []byte, err error) { return dAtA[:n], nil } -func (m *DiscoveryRuleStatus) MarshalTo(dAtA []byte) (int, error) { +func (m *RolloutTargetStatus) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } -func (m *DiscoveryRuleStatus) MarshalToSizedBuffer(dAtA []byte) (int, error) { +func (m *RolloutTargetStatus) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l - if m.StartTime != nil { - { - size, err := m.StartTime.MarshalToSizedBuffer(dAtA[:i]) - if err != nil { - return 0, err - } - i -= size - i = encodeVarintGenerated(dAtA, i, uint64(size)) - } - i-- - dAtA[i] = 0x12 - } { size, err := m.ConditionedStatus.MarshalToSizedBuffer(dAtA[:i]) if err != nil { @@ -2379,11 +1110,16 @@ func (m *DiscoveryRuleStatus) MarshalToSizedBuffer(dAtA []byte) (int, error) { i = encodeVarintGenerated(dAtA, i, uint64(size)) } i-- + dAtA[i] = 0x12 + i -= len(m.Name) + copy(dAtA[i:], m.Name) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Name))) + i-- dAtA[i] = 0xa return len(dAtA) - i, nil } -func (m *DiscoveryVendorProfile) Marshal() (dAtA []byte, err error) { +func (m *Schema) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) @@ -2393,16 +1129,26 @@ func (m *DiscoveryVendorProfile) Marshal() (dAtA []byte, err error) { return dAtA[:n], nil } -func (m *DiscoveryVendorProfile) MarshalTo(dAtA []byte) (int, error) { +func (m *Schema) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } -func (m *DiscoveryVendorProfile) MarshalToSizedBuffer(dAtA []byte) (int, error) { +func (m *Schema) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l + { + size, err := m.Status.MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintGenerated(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0x1a { size, err := m.Spec.MarshalToSizedBuffer(dAtA[:i]) if err != nil { @@ -2426,7 +1172,7 @@ func (m *DiscoveryVendorProfile) MarshalToSizedBuffer(dAtA []byte) (int, error) return len(dAtA) - i, nil } -func (m *DiscoveryVendorProfileList) Marshal() (dAtA []byte, err error) { +func (m *SchemaKey) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) @@ -2436,12 +1182,45 @@ func (m *DiscoveryVendorProfileList) Marshal() (dAtA []byte, err error) { return dAtA[:n], nil } -func (m *DiscoveryVendorProfileList) MarshalTo(dAtA []byte) (int, error) { +func (m *SchemaKey) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } -func (m *DiscoveryVendorProfileList) MarshalToSizedBuffer(dAtA []byte) (int, error) { +func (m *SchemaKey) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + i -= len(m.Version) + copy(dAtA[i:], m.Version) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Version))) + i-- + dAtA[i] = 0x12 + i -= len(m.Provider) + copy(dAtA[i:], m.Provider) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Provider))) + i-- + dAtA[i] = 0xa + return len(dAtA) - i, nil +} + +func (m *SchemaList) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *SchemaList) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *SchemaList) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int @@ -2473,7 +1252,7 @@ func (m *DiscoveryVendorProfileList) MarshalToSizedBuffer(dAtA []byte) (int, err return len(dAtA) - i, nil } -func (m *DiscoveryVendorProfileSpec) Marshal() (dAtA []byte, err error) { +func (m *SchemaRepositoryStatus) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) @@ -2483,30 +1262,30 @@ func (m *DiscoveryVendorProfileSpec) Marshal() (dAtA []byte, err error) { return dAtA[:n], nil } -func (m *DiscoveryVendorProfileSpec) MarshalTo(dAtA []byte) (int, error) { +func (m *SchemaRepositoryStatus) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } -func (m *DiscoveryVendorProfileSpec) MarshalToSizedBuffer(dAtA []byte) (int, error) { +func (m *SchemaRepositoryStatus) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l - { - size, err := m.Gnmi.MarshalToSizedBuffer(dAtA[:i]) - if err != nil { - return 0, err - } - i -= size - i = encodeVarintGenerated(dAtA, i, uint64(size)) - } + i -= len(m.Reference) + copy(dAtA[i:], m.Reference) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Reference))) + i-- + dAtA[i] = 0x12 + i -= len(m.RepoURL) + copy(dAtA[i:], m.RepoURL) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.RepoURL))) i-- dAtA[i] = 0xa return len(dAtA) - i, nil } -func (m *GnmiDiscoveryVendorProfileParameters) Marshal() (dAtA []byte, err error) { +func (m *SchemaSpec) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) @@ -2516,37 +1295,20 @@ func (m *GnmiDiscoveryVendorProfileParameters) Marshal() (dAtA []byte, err error return dAtA[:n], nil } -func (m *GnmiDiscoveryVendorProfileParameters) MarshalTo(dAtA []byte) (int, error) { +func (m *SchemaSpec) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } -func (m *GnmiDiscoveryVendorProfileParameters) MarshalToSizedBuffer(dAtA []byte) (int, error) { +func (m *SchemaSpec) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l - if m.PreserveNamespace != nil { - i-- - if *m.PreserveNamespace { - dAtA[i] = 1 - } else { - dAtA[i] = 0 - } - i-- - dAtA[i] = 0x28 - } - if m.Encoding != nil { - i -= len(*m.Encoding) - copy(dAtA[i:], *m.Encoding) - i = encodeVarintGenerated(dAtA, i, uint64(len(*m.Encoding))) - i-- - dAtA[i] = 0x22 - } - if len(m.Paths) > 0 { - for iNdEx := len(m.Paths) - 1; iNdEx >= 0; iNdEx-- { + if len(m.Repositories) > 0 { + for iNdEx := len(m.Repositories) - 1; iNdEx >= 0; iNdEx-- { { - size, err := m.Paths[iNdEx].MarshalToSizedBuffer(dAtA[:i]) + size, err := m.Repositories[iNdEx].MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } @@ -2557,22 +1319,20 @@ func (m *GnmiDiscoveryVendorProfileParameters) MarshalToSizedBuffer(dAtA []byte) dAtA[i] = 0x1a } } - if m.ModelMatch != nil { - i -= len(*m.ModelMatch) - copy(dAtA[i:], *m.ModelMatch) - i = encodeVarintGenerated(dAtA, i, uint64(len(*m.ModelMatch))) - i-- - dAtA[i] = 0x12 - } - i -= len(m.Organization) - copy(dAtA[i:], m.Organization) - i = encodeVarintGenerated(dAtA, i, uint64(len(m.Organization))) + i -= len(m.Version) + copy(dAtA[i:], m.Version) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Version))) + i-- + dAtA[i] = 0x12 + i -= len(m.Provider) + copy(dAtA[i:], m.Provider) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Provider))) i-- dAtA[i] = 0xa return len(dAtA) - i, nil } -func (m *Proxy) Marshal() (dAtA []byte, err error) { +func (m *SchemaSpecRepository) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) @@ -2582,30 +1342,54 @@ func (m *Proxy) Marshal() (dAtA []byte, err error) { return dAtA[:n], nil } -func (m *Proxy) MarshalTo(dAtA []byte) (int, error) { +func (m *SchemaSpecRepository) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } -func (m *Proxy) MarshalToSizedBuffer(dAtA []byte) (int, error) { +func (m *SchemaSpecRepository) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l - i -= len(m.Credentials) - copy(dAtA[i:], m.Credentials) - i = encodeVarintGenerated(dAtA, i, uint64(len(m.Credentials))) + { + size, err := m.Repository.MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintGenerated(dAtA, i, uint64(size)) + } i-- - dAtA[i] = 0x12 - i -= len(m.URL) - copy(dAtA[i:], m.URL) - i = encodeVarintGenerated(dAtA, i, uint64(len(m.URL))) + dAtA[i] = 0x42 + { + size, err := m.Schema.MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintGenerated(dAtA, i, uint64(size)) + } i-- - dAtA[i] = 0xa + dAtA[i] = 0x3a + if len(m.Dirs) > 0 { + for iNdEx := len(m.Dirs) - 1; iNdEx >= 0; iNdEx-- { + { + size, err := m.Dirs[iNdEx].MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintGenerated(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0x32 + } + } return len(dAtA) - i, nil } -func (m *Repository) Marshal() (dAtA []byte, err error) { +func (m *SchemaSpecSchema) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) @@ -2615,52 +1399,47 @@ func (m *Repository) Marshal() (dAtA []byte, err error) { return dAtA[:n], nil } -func (m *Repository) MarshalTo(dAtA []byte) (int, error) { +func (m *SchemaSpecSchema) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } -func (m *Repository) MarshalToSizedBuffer(dAtA []byte) (int, error) { +func (m *SchemaSpecSchema) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l - i -= len(m.Ref) - copy(dAtA[i:], m.Ref) - i = encodeVarintGenerated(dAtA, i, uint64(len(m.Ref))) - i-- - dAtA[i] = 0x2a - i -= len(m.Kind) - copy(dAtA[i:], m.Kind) - i = encodeVarintGenerated(dAtA, i, uint64(len(m.Kind))) - i-- - dAtA[i] = 0x22 - if m.Proxy != nil { - { - size, err := m.Proxy.MarshalToSizedBuffer(dAtA[:i]) - if err != nil { - return 0, err - } - i -= size - i = encodeVarintGenerated(dAtA, i, uint64(size)) + if len(m.Excludes) > 0 { + for iNdEx := len(m.Excludes) - 1; iNdEx >= 0; iNdEx-- { + i -= len(m.Excludes[iNdEx]) + copy(dAtA[i:], m.Excludes[iNdEx]) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Excludes[iNdEx]))) + i-- + dAtA[i] = 0x1a + } + } + if len(m.Includes) > 0 { + for iNdEx := len(m.Includes) - 1; iNdEx >= 0; iNdEx-- { + i -= len(m.Includes[iNdEx]) + copy(dAtA[i:], m.Includes[iNdEx]) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Includes[iNdEx]))) + i-- + dAtA[i] = 0x12 + } + } + if len(m.Models) > 0 { + for iNdEx := len(m.Models) - 1; iNdEx >= 0; iNdEx-- { + i -= len(m.Models[iNdEx]) + copy(dAtA[i:], m.Models[iNdEx]) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Models[iNdEx]))) + i-- + dAtA[i] = 0xa } - i-- - dAtA[i] = 0x1a } - i -= len(m.Credentials) - copy(dAtA[i:], m.Credentials) - i = encodeVarintGenerated(dAtA, i, uint64(len(m.Credentials))) - i-- - dAtA[i] = 0x12 - i -= len(m.RepoURL) - copy(dAtA[i:], m.RepoURL) - i = encodeVarintGenerated(dAtA, i, uint64(len(m.RepoURL))) - i-- - dAtA[i] = 0xa return len(dAtA) - i, nil } -func (m *Rollout) Marshal() (dAtA []byte, err error) { +func (m *SchemaStatus) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) @@ -2670,38 +1449,32 @@ func (m *Rollout) Marshal() (dAtA []byte, err error) { return dAtA[:n], nil } -func (m *Rollout) MarshalTo(dAtA []byte) (int, error) { +func (m *SchemaStatus) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } -func (m *Rollout) MarshalToSizedBuffer(dAtA []byte) (int, error) { +func (m *SchemaStatus) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l - { - size, err := m.Status.MarshalToSizedBuffer(dAtA[:i]) - if err != nil { - return 0, err - } - i -= size - i = encodeVarintGenerated(dAtA, i, uint64(size)) - } - i-- - dAtA[i] = 0x1a - { - size, err := m.Spec.MarshalToSizedBuffer(dAtA[:i]) - if err != nil { - return 0, err + if len(m.Repositories) > 0 { + for iNdEx := len(m.Repositories) - 1; iNdEx >= 0; iNdEx-- { + { + size, err := m.Repositories[iNdEx].MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintGenerated(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0x12 } - i -= size - i = encodeVarintGenerated(dAtA, i, uint64(size)) } - i-- - dAtA[i] = 0x12 { - size, err := m.ObjectMeta.MarshalToSizedBuffer(dAtA[:i]) + size, err := m.ConditionedStatus.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } @@ -2713,7 +1486,7 @@ func (m *Rollout) MarshalToSizedBuffer(dAtA []byte) (int, error) { return len(dAtA) - i, nil } -func (m *RolloutList) Marshal() (dAtA []byte, err error) { +func (m *SrcDstPath) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) @@ -2723,44 +1496,30 @@ func (m *RolloutList) Marshal() (dAtA []byte, err error) { return dAtA[:n], nil } -func (m *RolloutList) MarshalTo(dAtA []byte) (int, error) { +func (m *SrcDstPath) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } -func (m *RolloutList) MarshalToSizedBuffer(dAtA []byte) (int, error) { +func (m *SrcDstPath) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l - if len(m.Items) > 0 { - for iNdEx := len(m.Items) - 1; iNdEx >= 0; iNdEx-- { - { - size, err := m.Items[iNdEx].MarshalToSizedBuffer(dAtA[:i]) - if err != nil { - return 0, err - } - i -= size - i = encodeVarintGenerated(dAtA, i, uint64(size)) - } - i-- - dAtA[i] = 0x12 - } - } - { - size, err := m.ListMeta.MarshalToSizedBuffer(dAtA[:i]) - if err != nil { - return 0, err - } - i -= size - i = encodeVarintGenerated(dAtA, i, uint64(size)) - } + i -= len(m.Dst) + copy(dAtA[i:], m.Dst) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Dst))) + i-- + dAtA[i] = 0x12 + i -= len(m.Src) + copy(dAtA[i:], m.Src) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Src))) i-- dAtA[i] = 0xa return len(dAtA) - i, nil } -func (m *RolloutSpec) Marshal() (dAtA []byte, err error) { +func (m *Subscription) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) @@ -2770,33 +1529,38 @@ func (m *RolloutSpec) Marshal() (dAtA []byte, err error) { return dAtA[:n], nil } -func (m *RolloutSpec) MarshalTo(dAtA []byte) (int, error) { +func (m *Subscription) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } -func (m *RolloutSpec) MarshalToSizedBuffer(dAtA []byte) (int, error) { +func (m *Subscription) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l - if m.SkipUnavailableTarget != nil { - i-- - if *m.SkipUnavailableTarget { - dAtA[i] = 1 - } else { - dAtA[i] = 0 + { + size, err := m.Status.MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err } - i-- - dAtA[i] = 0x18 + i -= size + i = encodeVarintGenerated(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0x1a + { + size, err := m.Spec.MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintGenerated(dAtA, i, uint64(size)) } - i -= len(m.Strategy) - copy(dAtA[i:], m.Strategy) - i = encodeVarintGenerated(dAtA, i, uint64(len(m.Strategy))) i-- dAtA[i] = 0x12 { - size, err := m.Repository.MarshalToSizedBuffer(dAtA[:i]) + size, err := m.ObjectMeta.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } @@ -2808,7 +1572,7 @@ func (m *RolloutSpec) MarshalToSizedBuffer(dAtA []byte) (int, error) { return len(dAtA) - i, nil } -func (m *RolloutStatus) Marshal() (dAtA []byte, err error) { +func (m *SubscriptionList) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) @@ -2818,20 +1582,20 @@ func (m *RolloutStatus) Marshal() (dAtA []byte, err error) { return dAtA[:n], nil } -func (m *RolloutStatus) MarshalTo(dAtA []byte) (int, error) { +func (m *SubscriptionList) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } -func (m *RolloutStatus) MarshalToSizedBuffer(dAtA []byte) (int, error) { +func (m *SubscriptionList) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l - if len(m.Targets) > 0 { - for iNdEx := len(m.Targets) - 1; iNdEx >= 0; iNdEx-- { + if len(m.Items) > 0 { + for iNdEx := len(m.Items) - 1; iNdEx >= 0; iNdEx-- { { - size, err := m.Targets[iNdEx].MarshalToSizedBuffer(dAtA[:i]) + size, err := m.Items[iNdEx].MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } @@ -2843,7 +1607,7 @@ func (m *RolloutStatus) MarshalToSizedBuffer(dAtA []byte) (int, error) { } } { - size, err := m.ConditionedStatus.MarshalToSizedBuffer(dAtA[:i]) + size, err := m.ListMeta.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } @@ -2855,7 +1619,7 @@ func (m *RolloutStatus) MarshalToSizedBuffer(dAtA []byte) (int, error) { return len(dAtA) - i, nil } -func (m *RolloutTargetStatus) Marshal() (dAtA []byte, err error) { +func (m *SubscriptionParameters) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) @@ -2865,26 +1629,80 @@ func (m *RolloutTargetStatus) Marshal() (dAtA []byte, err error) { return dAtA[:n], nil } -func (m *RolloutTargetStatus) MarshalTo(dAtA []byte) (int, error) { +func (m *SubscriptionParameters) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } -func (m *RolloutTargetStatus) MarshalToSizedBuffer(dAtA []byte) (int, error) { +func (m *SubscriptionParameters) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l - { - size, err := m.ConditionedStatus.MarshalToSizedBuffer(dAtA[:i]) - if err != nil { - return 0, err + if len(m.Paths) > 0 { + for iNdEx := len(m.Paths) - 1; iNdEx >= 0; iNdEx-- { + i -= len(m.Paths[iNdEx]) + copy(dAtA[i:], m.Paths[iNdEx]) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Paths[iNdEx]))) + i-- + dAtA[i] = 0x3a } - i -= size - i = encodeVarintGenerated(dAtA, i, uint64(size)) } + if m.Interval != nil { + { + size, err := m.Interval.MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintGenerated(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0x32 + } + i -= len(m.Mode) + copy(dAtA[i:], m.Mode) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Mode))) i-- - dAtA[i] = 0x12 + dAtA[i] = 0x2a + if m.AdminState != nil { + i -= len(*m.AdminState) + copy(dAtA[i:], *m.AdminState) + i = encodeVarintGenerated(dAtA, i, uint64(len(*m.AdminState))) + i-- + dAtA[i] = 0x22 + } + if len(m.Labels) > 0 { + keysForLabels := make([]string, 0, len(m.Labels)) + for k := range m.Labels { + keysForLabels = append(keysForLabels, string(k)) + } + sort.Strings(keysForLabels) + for iNdEx := len(keysForLabels) - 1; iNdEx >= 0; iNdEx-- { + v := m.Labels[string(keysForLabels[iNdEx])] + baseI := i + i -= len(v) + copy(dAtA[i:], v) + i = encodeVarintGenerated(dAtA, i, uint64(len(v))) + i-- + dAtA[i] = 0x12 + i -= len(keysForLabels[iNdEx]) + copy(dAtA[i:], keysForLabels[iNdEx]) + i = encodeVarintGenerated(dAtA, i, uint64(len(keysForLabels[iNdEx]))) + i-- + dAtA[i] = 0xa + i = encodeVarintGenerated(dAtA, i, uint64(baseI-i)) + i-- + dAtA[i] = 0x1a + } + } + if m.Description != nil { + i -= len(*m.Description) + copy(dAtA[i:], *m.Description) + i = encodeVarintGenerated(dAtA, i, uint64(len(*m.Description))) + i-- + dAtA[i] = 0x12 + } i -= len(m.Name) copy(dAtA[i:], m.Name) i = encodeVarintGenerated(dAtA, i, uint64(len(m.Name))) @@ -2893,7 +1711,7 @@ func (m *RolloutTargetStatus) MarshalToSizedBuffer(dAtA []byte) (int, error) { return len(dAtA) - i, nil } -func (m *Schema) Marshal() (dAtA []byte, err error) { +func (m *SubscriptionSpec) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) @@ -2903,38 +1721,47 @@ func (m *Schema) Marshal() (dAtA []byte, err error) { return dAtA[:n], nil } -func (m *Schema) MarshalTo(dAtA []byte) (int, error) { +func (m *SubscriptionSpec) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } -func (m *Schema) MarshalToSizedBuffer(dAtA []byte) (int, error) { +func (m *SubscriptionSpec) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l - { - size, err := m.Status.MarshalToSizedBuffer(dAtA[:i]) - if err != nil { - return 0, err + if len(m.Subscriptions) > 0 { + for iNdEx := len(m.Subscriptions) - 1; iNdEx >= 0; iNdEx-- { + { + size, err := m.Subscriptions[iNdEx].MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintGenerated(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0x2a } - i -= size - i = encodeVarintGenerated(dAtA, i, uint64(size)) } - i-- - dAtA[i] = 0x1a - { - size, err := m.Spec.MarshalToSizedBuffer(dAtA[:i]) - if err != nil { - return 0, err - } - i -= size - i = encodeVarintGenerated(dAtA, i, uint64(size)) + if m.Encoding != nil { + i -= len(*m.Encoding) + copy(dAtA[i:], *m.Encoding) + i = encodeVarintGenerated(dAtA, i, uint64(len(*m.Encoding))) + i-- + dAtA[i] = 0x22 } + i = encodeVarintGenerated(dAtA, i, uint64(m.Port)) + i-- + dAtA[i] = 0x18 + i -= len(m.Protocol) + copy(dAtA[i:], m.Protocol) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Protocol))) i-- dAtA[i] = 0x12 { - size, err := m.ObjectMeta.MarshalToSizedBuffer(dAtA[:i]) + size, err := m.Target.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } @@ -2946,40 +1773,7 @@ func (m *Schema) MarshalToSizedBuffer(dAtA []byte) (int, error) { return len(dAtA) - i, nil } -func (m *SchemaKey) Marshal() (dAtA []byte, err error) { - size := m.Size() - dAtA = make([]byte, size) - n, err := m.MarshalToSizedBuffer(dAtA[:size]) - if err != nil { - return nil, err - } - return dAtA[:n], nil -} - -func (m *SchemaKey) MarshalTo(dAtA []byte) (int, error) { - size := m.Size() - return m.MarshalToSizedBuffer(dAtA[:size]) -} - -func (m *SchemaKey) MarshalToSizedBuffer(dAtA []byte) (int, error) { - i := len(dAtA) - _ = i - var l int - _ = l - i -= len(m.Version) - copy(dAtA[i:], m.Version) - i = encodeVarintGenerated(dAtA, i, uint64(len(m.Version))) - i-- - dAtA[i] = 0x12 - i -= len(m.Provider) - copy(dAtA[i:], m.Provider) - i = encodeVarintGenerated(dAtA, i, uint64(len(m.Provider))) - i-- - dAtA[i] = 0xa - return len(dAtA) - i, nil -} - -func (m *SchemaList) Marshal() (dAtA []byte, err error) { +func (m *SubscriptionStatus) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) @@ -2989,32 +1783,27 @@ func (m *SchemaList) Marshal() (dAtA []byte, err error) { return dAtA[:n], nil } -func (m *SchemaList) MarshalTo(dAtA []byte) (int, error) { +func (m *SubscriptionStatus) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } -func (m *SchemaList) MarshalToSizedBuffer(dAtA []byte) (int, error) { +func (m *SubscriptionStatus) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l - if len(m.Items) > 0 { - for iNdEx := len(m.Items) - 1; iNdEx >= 0; iNdEx-- { - { - size, err := m.Items[iNdEx].MarshalToSizedBuffer(dAtA[:i]) - if err != nil { - return 0, err - } - i -= size - i = encodeVarintGenerated(dAtA, i, uint64(size)) - } + if len(m.Targets) > 0 { + for iNdEx := len(m.Targets) - 1; iNdEx >= 0; iNdEx-- { + i -= len(m.Targets[iNdEx]) + copy(dAtA[i:], m.Targets[iNdEx]) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Targets[iNdEx]))) i-- dAtA[i] = 0x12 } } { - size, err := m.ListMeta.MarshalToSizedBuffer(dAtA[:i]) + size, err := m.ConditionedStatus.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } @@ -3026,7 +1815,7 @@ func (m *SchemaList) MarshalToSizedBuffer(dAtA []byte) (int, error) { return len(dAtA) - i, nil } -func (m *SchemaRepositoryStatus) Marshal() (dAtA []byte, err error) { +func (m *SubscriptionTarget) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) @@ -3036,77 +1825,32 @@ func (m *SchemaRepositoryStatus) Marshal() (dAtA []byte, err error) { return dAtA[:n], nil } -func (m *SchemaRepositoryStatus) MarshalTo(dAtA []byte) (int, error) { - size := m.Size() - return m.MarshalToSizedBuffer(dAtA[:size]) -} - -func (m *SchemaRepositoryStatus) MarshalToSizedBuffer(dAtA []byte) (int, error) { - i := len(dAtA) - _ = i - var l int - _ = l - i -= len(m.Reference) - copy(dAtA[i:], m.Reference) - i = encodeVarintGenerated(dAtA, i, uint64(len(m.Reference))) - i-- - dAtA[i] = 0x12 - i -= len(m.RepoURL) - copy(dAtA[i:], m.RepoURL) - i = encodeVarintGenerated(dAtA, i, uint64(len(m.RepoURL))) - i-- - dAtA[i] = 0xa - return len(dAtA) - i, nil -} - -func (m *SchemaSpec) Marshal() (dAtA []byte, err error) { - size := m.Size() - dAtA = make([]byte, size) - n, err := m.MarshalToSizedBuffer(dAtA[:size]) - if err != nil { - return nil, err - } - return dAtA[:n], nil -} - -func (m *SchemaSpec) MarshalTo(dAtA []byte) (int, error) { +func (m *SubscriptionTarget) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } -func (m *SchemaSpec) MarshalToSizedBuffer(dAtA []byte) (int, error) { +func (m *SubscriptionTarget) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l - if len(m.Repositories) > 0 { - for iNdEx := len(m.Repositories) - 1; iNdEx >= 0; iNdEx-- { - { - size, err := m.Repositories[iNdEx].MarshalToSizedBuffer(dAtA[:i]) - if err != nil { - return 0, err - } - i -= size - i = encodeVarintGenerated(dAtA, i, uint64(size)) + if m.TargetSelector != nil { + { + size, err := m.TargetSelector.MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err } - i-- - dAtA[i] = 0x1a + i -= size + i = encodeVarintGenerated(dAtA, i, uint64(size)) } + i-- + dAtA[i] = 0xa } - i -= len(m.Version) - copy(dAtA[i:], m.Version) - i = encodeVarintGenerated(dAtA, i, uint64(len(m.Version))) - i-- - dAtA[i] = 0x12 - i -= len(m.Provider) - copy(dAtA[i:], m.Provider) - i = encodeVarintGenerated(dAtA, i, uint64(len(m.Provider))) - i-- - dAtA[i] = 0xa return len(dAtA) - i, nil } -func (m *SchemaSpecRepository) Marshal() (dAtA []byte, err error) { +func (m *TargetConnectionProfile) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) @@ -3116,18 +1860,18 @@ func (m *SchemaSpecRepository) Marshal() (dAtA []byte, err error) { return dAtA[:n], nil } -func (m *SchemaSpecRepository) MarshalTo(dAtA []byte) (int, error) { +func (m *TargetConnectionProfile) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } -func (m *SchemaSpecRepository) MarshalToSizedBuffer(dAtA []byte) (int, error) { +func (m *TargetConnectionProfile) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l { - size, err := m.Repository.MarshalToSizedBuffer(dAtA[:i]) + size, err := m.Spec.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } @@ -3135,9 +1879,9 @@ func (m *SchemaSpecRepository) MarshalToSizedBuffer(dAtA []byte) (int, error) { i = encodeVarintGenerated(dAtA, i, uint64(size)) } i-- - dAtA[i] = 0x42 + dAtA[i] = 0x12 { - size, err := m.Schema.MarshalToSizedBuffer(dAtA[:i]) + size, err := m.ObjectMeta.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } @@ -3145,25 +1889,11 @@ func (m *SchemaSpecRepository) MarshalToSizedBuffer(dAtA []byte) (int, error) { i = encodeVarintGenerated(dAtA, i, uint64(size)) } i-- - dAtA[i] = 0x3a - if len(m.Dirs) > 0 { - for iNdEx := len(m.Dirs) - 1; iNdEx >= 0; iNdEx-- { - { - size, err := m.Dirs[iNdEx].MarshalToSizedBuffer(dAtA[:i]) - if err != nil { - return 0, err - } - i -= size - i = encodeVarintGenerated(dAtA, i, uint64(size)) - } - i-- - dAtA[i] = 0x32 - } - } + dAtA[i] = 0xa return len(dAtA) - i, nil } -func (m *SchemaSpecSchema) Marshal() (dAtA []byte, err error) { +func (m *TargetConnectionProfileList) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) @@ -3173,47 +1903,44 @@ func (m *SchemaSpecSchema) Marshal() (dAtA []byte, err error) { return dAtA[:n], nil } -func (m *SchemaSpecSchema) MarshalTo(dAtA []byte) (int, error) { +func (m *TargetConnectionProfileList) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } -func (m *SchemaSpecSchema) MarshalToSizedBuffer(dAtA []byte) (int, error) { +func (m *TargetConnectionProfileList) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l - if len(m.Excludes) > 0 { - for iNdEx := len(m.Excludes) - 1; iNdEx >= 0; iNdEx-- { - i -= len(m.Excludes[iNdEx]) - copy(dAtA[i:], m.Excludes[iNdEx]) - i = encodeVarintGenerated(dAtA, i, uint64(len(m.Excludes[iNdEx]))) - i-- - dAtA[i] = 0x1a - } - } - if len(m.Includes) > 0 { - for iNdEx := len(m.Includes) - 1; iNdEx >= 0; iNdEx-- { - i -= len(m.Includes[iNdEx]) - copy(dAtA[i:], m.Includes[iNdEx]) - i = encodeVarintGenerated(dAtA, i, uint64(len(m.Includes[iNdEx]))) + if len(m.Items) > 0 { + for iNdEx := len(m.Items) - 1; iNdEx >= 0; iNdEx-- { + { + size, err := m.Items[iNdEx].MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintGenerated(dAtA, i, uint64(size)) + } i-- dAtA[i] = 0x12 } } - if len(m.Models) > 0 { - for iNdEx := len(m.Models) - 1; iNdEx >= 0; iNdEx-- { - i -= len(m.Models[iNdEx]) - copy(dAtA[i:], m.Models[iNdEx]) - i = encodeVarintGenerated(dAtA, i, uint64(len(m.Models[iNdEx]))) - i-- - dAtA[i] = 0xa + { + size, err := m.ListMeta.MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err } + i -= size + i = encodeVarintGenerated(dAtA, i, uint64(size)) } + i-- + dAtA[i] = 0xa return len(dAtA) - i, nil } -func (m *SchemaStatus) Marshal() (dAtA []byte, err error) { +func (m *TargetConnectionProfileSpec) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) @@ -3223,32 +1950,114 @@ func (m *SchemaStatus) Marshal() (dAtA []byte, err error) { return dAtA[:n], nil } -func (m *SchemaStatus) MarshalTo(dAtA []byte) (int, error) { +func (m *TargetConnectionProfileSpec) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } -func (m *SchemaStatus) MarshalToSizedBuffer(dAtA []byte) (int, error) { +func (m *TargetConnectionProfileSpec) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l - if len(m.Repositories) > 0 { - for iNdEx := len(m.Repositories) - 1; iNdEx >= 0; iNdEx-- { - { - size, err := m.Repositories[iNdEx].MarshalToSizedBuffer(dAtA[:i]) - if err != nil { - return 0, err - } - i -= size - i = encodeVarintGenerated(dAtA, i, uint64(size)) - } - i-- - dAtA[i] = 0x12 + if m.TargetName != nil { + i -= len(*m.TargetName) + copy(dAtA[i:], *m.TargetName) + i = encodeVarintGenerated(dAtA, i, uint64(len(*m.TargetName))) + i-- + dAtA[i] = 0x6a + } + if m.CommitCandidate != nil { + i -= len(*m.CommitCandidate) + copy(dAtA[i:], *m.CommitCandidate) + i = encodeVarintGenerated(dAtA, i, uint64(len(*m.CommitCandidate))) + i-- + dAtA[i] = 0x62 + } + if m.UseOperationRemove != nil { + i-- + if *m.UseOperationRemove { + dAtA[i] = 1 + } else { + dAtA[i] = 0 + } + i-- + dAtA[i] = 0x58 + } + if m.OperationWithNS != nil { + i-- + if *m.OperationWithNS { + dAtA[i] = 1 + } else { + dAtA[i] = 0 + } + i-- + dAtA[i] = 0x50 + } + if m.IncludeNS != nil { + i-- + if *m.IncludeNS { + dAtA[i] = 1 + } else { + dAtA[i] = 0 + } + i-- + dAtA[i] = 0x48 + } + if m.SkipVerify != nil { + i-- + if *m.SkipVerify { + dAtA[i] = 1 + } else { + dAtA[i] = 0 + } + i-- + dAtA[i] = 0x40 + } + if m.Insecure != nil { + i-- + if *m.Insecure { + dAtA[i] = 1 + } else { + dAtA[i] = 0 + } + i-- + dAtA[i] = 0x38 + } + if m.PreferredNetconfVersion != nil { + i -= len(*m.PreferredNetconfVersion) + copy(dAtA[i:], *m.PreferredNetconfVersion) + i = encodeVarintGenerated(dAtA, i, uint64(len(*m.PreferredNetconfVersion))) + i-- + dAtA[i] = 0x32 + } + if m.Encoding != nil { + i -= len(*m.Encoding) + copy(dAtA[i:], *m.Encoding) + i = encodeVarintGenerated(dAtA, i, uint64(len(*m.Encoding))) + i-- + dAtA[i] = 0x2a + } + i = encodeVarintGenerated(dAtA, i, uint64(m.Port)) + i-- + dAtA[i] = 0x20 + i -= len(m.Protocol) + copy(dAtA[i:], m.Protocol) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Protocol))) + i-- + dAtA[i] = 0x1a + { + size, err := m.Timeout.MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err } + i -= size + i = encodeVarintGenerated(dAtA, i, uint64(size)) } + i-- + dAtA[i] = 0x12 { - size, err := m.ConditionedStatus.MarshalToSizedBuffer(dAtA[:i]) + size, err := m.ConnectRetry.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } @@ -3260,7 +2069,7 @@ func (m *SchemaStatus) MarshalToSizedBuffer(dAtA []byte) (int, error) { return len(dAtA) - i, nil } -func (m *SrcDstPath) Marshal() (dAtA []byte, err error) { +func (m *TargetProfile) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) @@ -3270,30 +2079,44 @@ func (m *SrcDstPath) Marshal() (dAtA []byte, err error) { return dAtA[:n], nil } -func (m *SrcDstPath) MarshalTo(dAtA []byte) (int, error) { +func (m *TargetProfile) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } -func (m *SrcDstPath) MarshalToSizedBuffer(dAtA []byte) (int, error) { +func (m *TargetProfile) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l - i -= len(m.Dst) - copy(dAtA[i:], m.Dst) - i = encodeVarintGenerated(dAtA, i, uint64(len(m.Dst))) + if m.SyncProfile != nil { + i -= len(*m.SyncProfile) + copy(dAtA[i:], *m.SyncProfile) + i = encodeVarintGenerated(dAtA, i, uint64(len(*m.SyncProfile))) + i-- + dAtA[i] = 0x22 + } + i -= len(m.ConnectionProfile) + copy(dAtA[i:], m.ConnectionProfile) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.ConnectionProfile))) i-- - dAtA[i] = 0x12 - i -= len(m.Src) - copy(dAtA[i:], m.Src) - i = encodeVarintGenerated(dAtA, i, uint64(len(m.Src))) + dAtA[i] = 0x1a + if m.TLSSecret != nil { + i -= len(*m.TLSSecret) + copy(dAtA[i:], *m.TLSSecret) + i = encodeVarintGenerated(dAtA, i, uint64(len(*m.TLSSecret))) + i-- + dAtA[i] = 0x12 + } + i -= len(m.Credentials) + copy(dAtA[i:], m.Credentials) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Credentials))) i-- dAtA[i] = 0xa return len(dAtA) - i, nil } -func (m *Subscription) Marshal() (dAtA []byte, err error) { +func (m *TargetSyncProfile) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) @@ -3303,26 +2126,16 @@ func (m *Subscription) Marshal() (dAtA []byte, err error) { return dAtA[:n], nil } -func (m *Subscription) MarshalTo(dAtA []byte) (int, error) { +func (m *TargetSyncProfile) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } -func (m *Subscription) MarshalToSizedBuffer(dAtA []byte) (int, error) { +func (m *TargetSyncProfile) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l - { - size, err := m.Status.MarshalToSizedBuffer(dAtA[:i]) - if err != nil { - return 0, err - } - i -= size - i = encodeVarintGenerated(dAtA, i, uint64(size)) - } - i-- - dAtA[i] = 0x1a { size, err := m.Spec.MarshalToSizedBuffer(dAtA[:i]) if err != nil { @@ -3346,7 +2159,7 @@ func (m *Subscription) MarshalToSizedBuffer(dAtA []byte) (int, error) { return len(dAtA) - i, nil } -func (m *SubscriptionList) Marshal() (dAtA []byte, err error) { +func (m *TargetSyncProfileList) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) @@ -3356,12 +2169,12 @@ func (m *SubscriptionList) Marshal() (dAtA []byte, err error) { return dAtA[:n], nil } -func (m *SubscriptionList) MarshalTo(dAtA []byte) (int, error) { +func (m *TargetSyncProfileList) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } -func (m *SubscriptionList) MarshalToSizedBuffer(dAtA []byte) (int, error) { +func (m *TargetSyncProfileList) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int @@ -3393,7 +2206,7 @@ func (m *SubscriptionList) MarshalToSizedBuffer(dAtA []byte) (int, error) { return len(dAtA) - i, nil } -func (m *SubscriptionParameters) Marshal() (dAtA []byte, err error) { +func (m *TargetSyncProfileSpec) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) @@ -3403,89 +2216,48 @@ func (m *SubscriptionParameters) Marshal() (dAtA []byte, err error) { return dAtA[:n], nil } -func (m *SubscriptionParameters) MarshalTo(dAtA []byte) (int, error) { +func (m *TargetSyncProfileSpec) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } -func (m *SubscriptionParameters) MarshalToSizedBuffer(dAtA []byte) (int, error) { +func (m *TargetSyncProfileSpec) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l - if len(m.Paths) > 0 { - for iNdEx := len(m.Paths) - 1; iNdEx >= 0; iNdEx-- { - i -= len(m.Paths[iNdEx]) - copy(dAtA[i:], m.Paths[iNdEx]) - i = encodeVarintGenerated(dAtA, i, uint64(len(m.Paths[iNdEx]))) - i-- - dAtA[i] = 0x3a - } - } - if m.Interval != nil { - { - size, err := m.Interval.MarshalToSizedBuffer(dAtA[:i]) - if err != nil { - return 0, err + if len(m.Sync) > 0 { + for iNdEx := len(m.Sync) - 1; iNdEx >= 0; iNdEx-- { + { + size, err := m.Sync[iNdEx].MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintGenerated(dAtA, i, uint64(size)) } - i -= size - i = encodeVarintGenerated(dAtA, i, uint64(size)) - } - i-- - dAtA[i] = 0x32 - } - i -= len(m.Mode) - copy(dAtA[i:], m.Mode) - i = encodeVarintGenerated(dAtA, i, uint64(len(m.Mode))) - i-- - dAtA[i] = 0x2a - if m.AdminState != nil { - i -= len(*m.AdminState) - copy(dAtA[i:], *m.AdminState) - i = encodeVarintGenerated(dAtA, i, uint64(len(*m.AdminState))) - i-- - dAtA[i] = 0x22 - } - if len(m.Labels) > 0 { - keysForLabels := make([]string, 0, len(m.Labels)) - for k := range m.Labels { - keysForLabels = append(keysForLabels, string(k)) - } - github_com_gogo_protobuf_sortkeys.Strings(keysForLabels) - for iNdEx := len(keysForLabels) - 1; iNdEx >= 0; iNdEx-- { - v := m.Labels[string(keysForLabels[iNdEx])] - baseI := i - i -= len(v) - copy(dAtA[i:], v) - i = encodeVarintGenerated(dAtA, i, uint64(len(v))) i-- - dAtA[i] = 0x12 - i -= len(keysForLabels[iNdEx]) - copy(dAtA[i:], keysForLabels[iNdEx]) - i = encodeVarintGenerated(dAtA, i, uint64(len(keysForLabels[iNdEx]))) - i-- - dAtA[i] = 0xa - i = encodeVarintGenerated(dAtA, i, uint64(baseI-i)) - i-- - dAtA[i] = 0x1a + dAtA[i] = 0x22 } } - if m.Description != nil { - i -= len(*m.Description) - copy(dAtA[i:], *m.Description) - i = encodeVarintGenerated(dAtA, i, uint64(len(*m.Description))) - i-- - dAtA[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(m.Workers)) + i-- + dAtA[i] = 0x18 + i = encodeVarintGenerated(dAtA, i, uint64(m.Buffer)) + i-- + dAtA[i] = 0x10 + i-- + if m.Validate { + dAtA[i] = 1 + } else { + dAtA[i] = 0 } - i -= len(m.Name) - copy(dAtA[i:], m.Name) - i = encodeVarintGenerated(dAtA, i, uint64(len(m.Name))) i-- - dAtA[i] = 0xa + dAtA[i] = 0x8 return len(dAtA) - i, nil } -func (m *SubscriptionSpec) Marshal() (dAtA []byte, err error) { +func (m *TargetSyncProfileSync) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) @@ -3495,36 +2267,46 @@ func (m *SubscriptionSpec) Marshal() (dAtA []byte, err error) { return dAtA[:n], nil } -func (m *SubscriptionSpec) MarshalTo(dAtA []byte) (int, error) { +func (m *TargetSyncProfileSync) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } -func (m *SubscriptionSpec) MarshalToSizedBuffer(dAtA []byte) (int, error) { +func (m *TargetSyncProfileSync) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l - if len(m.Subscriptions) > 0 { - for iNdEx := len(m.Subscriptions) - 1; iNdEx >= 0; iNdEx-- { - { - size, err := m.Subscriptions[iNdEx].MarshalToSizedBuffer(dAtA[:i]) - if err != nil { - return 0, err - } - i -= size - i = encodeVarintGenerated(dAtA, i, uint64(size)) - } - i-- - dAtA[i] = 0x2a + { + size, err := m.Interval.MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err } + i -= size + i = encodeVarintGenerated(dAtA, i, uint64(size)) } + i-- + dAtA[i] = 0x3a if m.Encoding != nil { i -= len(*m.Encoding) copy(dAtA[i:], *m.Encoding) i = encodeVarintGenerated(dAtA, i, uint64(len(*m.Encoding))) i-- - dAtA[i] = 0x22 + dAtA[i] = 0x32 + } + i -= len(m.Mode) + copy(dAtA[i:], m.Mode) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Mode))) + i-- + dAtA[i] = 0x2a + if len(m.Paths) > 0 { + for iNdEx := len(m.Paths) - 1; iNdEx >= 0; iNdEx-- { + i -= len(m.Paths[iNdEx]) + copy(dAtA[i:], m.Paths[iNdEx]) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Paths[iNdEx]))) + i-- + dAtA[i] = 0x22 + } } i = encodeVarintGenerated(dAtA, i, uint64(m.Port)) i-- @@ -3534,20 +2316,15 @@ func (m *SubscriptionSpec) MarshalToSizedBuffer(dAtA []byte) (int, error) { i = encodeVarintGenerated(dAtA, i, uint64(len(m.Protocol))) i-- dAtA[i] = 0x12 - { - size, err := m.Target.MarshalToSizedBuffer(dAtA[:i]) - if err != nil { - return 0, err - } - i -= size - i = encodeVarintGenerated(dAtA, i, uint64(size)) - } + i -= len(m.Name) + copy(dAtA[i:], m.Name) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Name))) i-- dAtA[i] = 0xa return len(dAtA) - i, nil } -func (m *SubscriptionStatus) Marshal() (dAtA []byte, err error) { +func (m *TargetTemplate) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) @@ -3557,74 +2334,73 @@ func (m *SubscriptionStatus) Marshal() (dAtA []byte, err error) { return dAtA[:n], nil } -func (m *SubscriptionStatus) MarshalTo(dAtA []byte) (int, error) { +func (m *TargetTemplate) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } -func (m *SubscriptionStatus) MarshalToSizedBuffer(dAtA []byte) (int, error) { +func (m *TargetTemplate) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l - if len(m.Targets) > 0 { - for iNdEx := len(m.Targets) - 1; iNdEx >= 0; iNdEx-- { - i -= len(m.Targets[iNdEx]) - copy(dAtA[i:], m.Targets[iNdEx]) - i = encodeVarintGenerated(dAtA, i, uint64(len(m.Targets[iNdEx]))) + if len(m.Labels) > 0 { + keysForLabels := make([]string, 0, len(m.Labels)) + for k := range m.Labels { + keysForLabels = append(keysForLabels, string(k)) + } + sort.Strings(keysForLabels) + for iNdEx := len(keysForLabels) - 1; iNdEx >= 0; iNdEx-- { + v := m.Labels[string(keysForLabels[iNdEx])] + baseI := i + i -= len(v) + copy(dAtA[i:], v) + i = encodeVarintGenerated(dAtA, i, uint64(len(v))) i-- dAtA[i] = 0x12 + i -= len(keysForLabels[iNdEx]) + copy(dAtA[i:], keysForLabels[iNdEx]) + i = encodeVarintGenerated(dAtA, i, uint64(len(keysForLabels[iNdEx]))) + i-- + dAtA[i] = 0xa + i = encodeVarintGenerated(dAtA, i, uint64(baseI-i)) + i-- + dAtA[i] = 0x1a } } - { - size, err := m.ConditionedStatus.MarshalToSizedBuffer(dAtA[:i]) - if err != nil { - return 0, err + if len(m.Annotations) > 0 { + keysForAnnotations := make([]string, 0, len(m.Annotations)) + for k := range m.Annotations { + keysForAnnotations = append(keysForAnnotations, string(k)) + } + sort.Strings(keysForAnnotations) + for iNdEx := len(keysForAnnotations) - 1; iNdEx >= 0; iNdEx-- { + v := m.Annotations[string(keysForAnnotations[iNdEx])] + baseI := i + i -= len(v) + copy(dAtA[i:], v) + i = encodeVarintGenerated(dAtA, i, uint64(len(v))) + i-- + dAtA[i] = 0x12 + i -= len(keysForAnnotations[iNdEx]) + copy(dAtA[i:], keysForAnnotations[iNdEx]) + i = encodeVarintGenerated(dAtA, i, uint64(len(keysForAnnotations[iNdEx]))) + i-- + dAtA[i] = 0xa + i = encodeVarintGenerated(dAtA, i, uint64(baseI-i)) + i-- + dAtA[i] = 0x12 } - i -= size - i = encodeVarintGenerated(dAtA, i, uint64(size)) - } - i-- - dAtA[i] = 0xa - return len(dAtA) - i, nil -} - -func (m *SubscriptionTarget) Marshal() (dAtA []byte, err error) { - size := m.Size() - dAtA = make([]byte, size) - n, err := m.MarshalToSizedBuffer(dAtA[:size]) - if err != nil { - return nil, err - } - return dAtA[:n], nil -} - -func (m *SubscriptionTarget) MarshalTo(dAtA []byte) (int, error) { - size := m.Size() - return m.MarshalToSizedBuffer(dAtA[:size]) -} - -func (m *SubscriptionTarget) MarshalToSizedBuffer(dAtA []byte) (int, error) { - i := len(dAtA) - _ = i - var l int - _ = l - if m.TargetSelector != nil { - { - size, err := m.TargetSelector.MarshalToSizedBuffer(dAtA[:i]) - if err != nil { - return 0, err - } - i -= size - i = encodeVarintGenerated(dAtA, i, uint64(size)) - } - i-- - dAtA[i] = 0xa } + i -= len(m.NameTemplate) + copy(dAtA[i:], m.NameTemplate) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.NameTemplate))) + i-- + dAtA[i] = 0xa return len(dAtA) - i, nil } -func (m *Target) Marshal() (dAtA []byte, err error) { +func (m *Workspace) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) @@ -3634,12 +2410,12 @@ func (m *Target) Marshal() (dAtA []byte, err error) { return dAtA[:n], nil } -func (m *Target) MarshalTo(dAtA []byte) (int, error) { +func (m *Workspace) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } -func (m *Target) MarshalToSizedBuffer(dAtA []byte) (int, error) { +func (m *Workspace) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int @@ -3677,50 +2453,7 @@ func (m *Target) MarshalToSizedBuffer(dAtA []byte) (int, error) { return len(dAtA) - i, nil } -func (m *TargetConnectionProfile) Marshal() (dAtA []byte, err error) { - size := m.Size() - dAtA = make([]byte, size) - n, err := m.MarshalToSizedBuffer(dAtA[:size]) - if err != nil { - return nil, err - } - return dAtA[:n], nil -} - -func (m *TargetConnectionProfile) MarshalTo(dAtA []byte) (int, error) { - size := m.Size() - return m.MarshalToSizedBuffer(dAtA[:size]) -} - -func (m *TargetConnectionProfile) MarshalToSizedBuffer(dAtA []byte) (int, error) { - i := len(dAtA) - _ = i - var l int - _ = l - { - size, err := m.Spec.MarshalToSizedBuffer(dAtA[:i]) - if err != nil { - return 0, err - } - i -= size - i = encodeVarintGenerated(dAtA, i, uint64(size)) - } - i-- - dAtA[i] = 0x12 - { - size, err := m.ObjectMeta.MarshalToSizedBuffer(dAtA[:i]) - if err != nil { - return 0, err - } - i -= size - i = encodeVarintGenerated(dAtA, i, uint64(size)) - } - i-- - dAtA[i] = 0xa - return len(dAtA) - i, nil -} - -func (m *TargetConnectionProfileList) Marshal() (dAtA []byte, err error) { +func (m *WorkspaceList) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) @@ -3730,12 +2463,12 @@ func (m *TargetConnectionProfileList) Marshal() (dAtA []byte, err error) { return dAtA[:n], nil } -func (m *TargetConnectionProfileList) MarshalTo(dAtA []byte) (int, error) { +func (m *WorkspaceList) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } -func (m *TargetConnectionProfileList) MarshalToSizedBuffer(dAtA []byte) (int, error) { +func (m *WorkspaceList) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int @@ -3767,7 +2500,7 @@ func (m *TargetConnectionProfileList) MarshalToSizedBuffer(dAtA []byte) (int, er return len(dAtA) - i, nil } -func (m *TargetConnectionProfileSpec) Marshal() (dAtA []byte, err error) { +func (m *WorkspaceSpec) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) @@ -3777,114 +2510,18 @@ func (m *TargetConnectionProfileSpec) Marshal() (dAtA []byte, err error) { return dAtA[:n], nil } -func (m *TargetConnectionProfileSpec) MarshalTo(dAtA []byte) (int, error) { +func (m *WorkspaceSpec) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } -func (m *TargetConnectionProfileSpec) MarshalToSizedBuffer(dAtA []byte) (int, error) { +func (m *WorkspaceSpec) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l - if m.TargetName != nil { - i -= len(*m.TargetName) - copy(dAtA[i:], *m.TargetName) - i = encodeVarintGenerated(dAtA, i, uint64(len(*m.TargetName))) - i-- - dAtA[i] = 0x6a - } - if m.CommitCandidate != nil { - i -= len(*m.CommitCandidate) - copy(dAtA[i:], *m.CommitCandidate) - i = encodeVarintGenerated(dAtA, i, uint64(len(*m.CommitCandidate))) - i-- - dAtA[i] = 0x62 - } - if m.UseOperationRemove != nil { - i-- - if *m.UseOperationRemove { - dAtA[i] = 1 - } else { - dAtA[i] = 0 - } - i-- - dAtA[i] = 0x58 - } - if m.OperationWithNS != nil { - i-- - if *m.OperationWithNS { - dAtA[i] = 1 - } else { - dAtA[i] = 0 - } - i-- - dAtA[i] = 0x50 - } - if m.IncludeNS != nil { - i-- - if *m.IncludeNS { - dAtA[i] = 1 - } else { - dAtA[i] = 0 - } - i-- - dAtA[i] = 0x48 - } - if m.SkipVerify != nil { - i-- - if *m.SkipVerify { - dAtA[i] = 1 - } else { - dAtA[i] = 0 - } - i-- - dAtA[i] = 0x40 - } - if m.Insecure != nil { - i-- - if *m.Insecure { - dAtA[i] = 1 - } else { - dAtA[i] = 0 - } - i-- - dAtA[i] = 0x38 - } - if m.PreferredNetconfVersion != nil { - i -= len(*m.PreferredNetconfVersion) - copy(dAtA[i:], *m.PreferredNetconfVersion) - i = encodeVarintGenerated(dAtA, i, uint64(len(*m.PreferredNetconfVersion))) - i-- - dAtA[i] = 0x32 - } - if m.Encoding != nil { - i -= len(*m.Encoding) - copy(dAtA[i:], *m.Encoding) - i = encodeVarintGenerated(dAtA, i, uint64(len(*m.Encoding))) - i-- - dAtA[i] = 0x2a - } - i = encodeVarintGenerated(dAtA, i, uint64(m.Port)) - i-- - dAtA[i] = 0x20 - i -= len(m.Protocol) - copy(dAtA[i:], m.Protocol) - i = encodeVarintGenerated(dAtA, i, uint64(len(m.Protocol))) - i-- - dAtA[i] = 0x1a - { - size, err := m.Timeout.MarshalToSizedBuffer(dAtA[:i]) - if err != nil { - return 0, err - } - i -= size - i = encodeVarintGenerated(dAtA, i, uint64(size)) - } - i-- - dAtA[i] = 0x12 { - size, err := m.ConnectRetry.MarshalToSizedBuffer(dAtA[:i]) + size, err := m.Repository.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } @@ -3896,7 +2533,7 @@ func (m *TargetConnectionProfileSpec) MarshalToSizedBuffer(dAtA []byte) (int, er return len(dAtA) - i, nil } -func (m *TargetList) Marshal() (dAtA []byte, err error) { +func (m *WorkspaceStatus) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) @@ -3906,32 +2543,32 @@ func (m *TargetList) Marshal() (dAtA []byte, err error) { return dAtA[:n], nil } -func (m *TargetList) MarshalTo(dAtA []byte) (int, error) { +func (m *WorkspaceStatus) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } -func (m *TargetList) MarshalToSizedBuffer(dAtA []byte) (int, error) { +func (m *WorkspaceStatus) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l - if len(m.Items) > 0 { - for iNdEx := len(m.Items) - 1; iNdEx >= 0; iNdEx-- { - { - size, err := m.Items[iNdEx].MarshalToSizedBuffer(dAtA[:i]) - if err != nil { - return 0, err - } - i -= size - i = encodeVarintGenerated(dAtA, i, uint64(size)) - } - i-- - dAtA[i] = 0x12 - } + if m.DeployedRef != nil { + i -= len(*m.DeployedRef) + copy(dAtA[i:], *m.DeployedRef) + i = encodeVarintGenerated(dAtA, i, uint64(len(*m.DeployedRef))) + i-- + dAtA[i] = 0x1a + } + if m.Kind != nil { + i -= len(*m.Kind) + copy(dAtA[i:], *m.Kind) + i = encodeVarintGenerated(dAtA, i, uint64(len(*m.Kind))) + i-- + dAtA[i] = 0x12 } { - size, err := m.ListMeta.MarshalToSizedBuffer(dAtA[:i]) + size, err := m.ConditionedStatus.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } @@ -3943,765 +2580,638 @@ func (m *TargetList) MarshalToSizedBuffer(dAtA []byte) (int, error) { return len(dAtA) - i, nil } -func (m *TargetProfile) Marshal() (dAtA []byte, err error) { - size := m.Size() - dAtA = make([]byte, size) - n, err := m.MarshalToSizedBuffer(dAtA[:size]) - if err != nil { - return nil, err +func encodeVarintGenerated(dAtA []byte, offset int, v uint64) int { + offset -= sovGenerated(v) + base := offset + for v >= 1<<7 { + dAtA[offset] = uint8(v&0x7f | 0x80) + v >>= 7 + offset++ } - return dAtA[:n], nil -} - -func (m *TargetProfile) MarshalTo(dAtA []byte) (int, error) { - size := m.Size() - return m.MarshalToSizedBuffer(dAtA[:size]) + dAtA[offset] = uint8(v) + return base } - -func (m *TargetProfile) MarshalToSizedBuffer(dAtA []byte) (int, error) { - i := len(dAtA) - _ = i +func (m *DiscoveryParameters) Size() (n int) { + if m == nil { + return 0 + } var l int _ = l - if m.SyncProfile != nil { - i -= len(*m.SyncProfile) - copy(dAtA[i:], *m.SyncProfile) - i = encodeVarintGenerated(dAtA, i, uint64(len(*m.SyncProfile))) - i-- - dAtA[i] = 0x22 + if m.DefaultSchema != nil { + l = m.DefaultSchema.Size() + n += 1 + l + sovGenerated(uint64(l)) } - i -= len(m.ConnectionProfile) - copy(dAtA[i:], m.ConnectionProfile) - i = encodeVarintGenerated(dAtA, i, uint64(len(m.ConnectionProfile))) - i-- - dAtA[i] = 0x1a - if m.TLSSecret != nil { - i -= len(*m.TLSSecret) - copy(dAtA[i:], *m.TLSSecret) - i = encodeVarintGenerated(dAtA, i, uint64(len(*m.TLSSecret))) - i-- - dAtA[i] = 0x12 + if m.DiscoveryProfile != nil { + l = m.DiscoveryProfile.Size() + n += 1 + l + sovGenerated(uint64(l)) } - i -= len(m.Credentials) - copy(dAtA[i:], m.Credentials) - i = encodeVarintGenerated(dAtA, i, uint64(len(m.Credentials))) - i-- - dAtA[i] = 0xa - return len(dAtA) - i, nil -} - -func (m *TargetSpec) Marshal() (dAtA []byte, err error) { - size := m.Size() - dAtA = make([]byte, size) - n, err := m.MarshalToSizedBuffer(dAtA[:size]) - if err != nil { - return nil, err + if len(m.TargetConnectionProfiles) > 0 { + for _, e := range m.TargetConnectionProfiles { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } } - return dAtA[:n], nil -} - -func (m *TargetSpec) MarshalTo(dAtA []byte) (int, error) { - size := m.Size() - return m.MarshalToSizedBuffer(dAtA[:size]) + if m.TargetTemplate != nil { + l = m.TargetTemplate.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + l = m.Period.Size() + n += 1 + l + sovGenerated(uint64(l)) + n += 1 + sovGenerated(uint64(m.ConcurrentScans)) + return n } -func (m *TargetSpec) MarshalToSizedBuffer(dAtA []byte) (int, error) { - i := len(dAtA) - _ = i +func (m *DiscoveryPathDefinition) Size() (n int) { + if m == nil { + return 0 + } var l int _ = l - { - size, err := m.TargetProfile.MarshalToSizedBuffer(dAtA[:i]) - if err != nil { - return 0, err - } - i -= size - i = encodeVarintGenerated(dAtA, i, uint64(size)) + l = len(m.Key) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.Path) + n += 1 + l + sovGenerated(uint64(l)) + if m.Script != nil { + l = len(*m.Script) + n += 1 + l + sovGenerated(uint64(l)) } - i-- - dAtA[i] = 0x1a - i -= len(m.Address) - copy(dAtA[i:], m.Address) - i = encodeVarintGenerated(dAtA, i, uint64(len(m.Address))) - i-- - dAtA[i] = 0x12 - i -= len(m.Provider) - copy(dAtA[i:], m.Provider) - i = encodeVarintGenerated(dAtA, i, uint64(len(m.Provider))) - i-- - dAtA[i] = 0xa - return len(dAtA) - i, nil -} - -func (m *TargetStatus) Marshal() (dAtA []byte, err error) { - size := m.Size() - dAtA = make([]byte, size) - n, err := m.MarshalToSizedBuffer(dAtA[:size]) - if err != nil { - return nil, err + if m.Regex != nil { + l = len(*m.Regex) + n += 1 + l + sovGenerated(uint64(l)) } - return dAtA[:n], nil -} - -func (m *TargetStatus) MarshalTo(dAtA []byte) (int, error) { - size := m.Size() - return m.MarshalToSizedBuffer(dAtA[:size]) + return n } -func (m *TargetStatus) MarshalToSizedBuffer(dAtA []byte) (int, error) { - i := len(dAtA) - _ = i +func (m *DiscoveryProfile) Size() (n int) { + if m == nil { + return 0 + } var l int _ = l - if m.UsedReferences != nil { - { - size, err := m.UsedReferences.MarshalToSizedBuffer(dAtA[:i]) - if err != nil { - return 0, err - } - i -= size - i = encodeVarintGenerated(dAtA, i, uint64(size)) - } - i-- - dAtA[i] = 0x1a - } - if m.DiscoveryInfo != nil { - { - size, err := m.DiscoveryInfo.MarshalToSizedBuffer(dAtA[:i]) - if err != nil { - return 0, err - } - i -= size - i = encodeVarintGenerated(dAtA, i, uint64(size)) - } - i-- - dAtA[i] = 0x12 + l = len(m.Credentials) + n += 1 + l + sovGenerated(uint64(l)) + if m.TLSSecret != nil { + l = len(*m.TLSSecret) + n += 1 + l + sovGenerated(uint64(l)) } - { - size, err := m.ConditionedStatus.MarshalToSizedBuffer(dAtA[:i]) - if err != nil { - return 0, err + if len(m.ConnectionProfiles) > 0 { + for _, s := range m.ConnectionProfiles { + l = len(s) + n += 1 + l + sovGenerated(uint64(l)) } - i -= size - i = encodeVarintGenerated(dAtA, i, uint64(size)) } - i-- - dAtA[i] = 0xa - return len(dAtA) - i, nil + return n } -func (m *TargetStatusUsedReferences) Marshal() (dAtA []byte, err error) { - size := m.Size() - dAtA = make([]byte, size) - n, err := m.MarshalToSizedBuffer(dAtA[:size]) - if err != nil { - return nil, err +func (m *DiscoveryRule) Size() (n int) { + if m == nil { + return 0 } - return dAtA[:n], nil -} - -func (m *TargetStatusUsedReferences) MarshalTo(dAtA []byte) (int, error) { - size := m.Size() - return m.MarshalToSizedBuffer(dAtA[:size]) + var l int + _ = l + l = m.ObjectMeta.Size() + n += 1 + l + sovGenerated(uint64(l)) + l = m.Spec.Size() + n += 1 + l + sovGenerated(uint64(l)) + l = m.Status.Size() + n += 1 + l + sovGenerated(uint64(l)) + return n } -func (m *TargetStatusUsedReferences) MarshalToSizedBuffer(dAtA []byte) (int, error) { - i := len(dAtA) - _ = i +func (m *DiscoveryRuleAddress) Size() (n int) { + if m == nil { + return 0 + } var l int _ = l - i -= len(m.SyncProfileResourceVersion) - copy(dAtA[i:], m.SyncProfileResourceVersion) - i = encodeVarintGenerated(dAtA, i, uint64(len(m.SyncProfileResourceVersion))) - i-- - dAtA[i] = 0x22 - i -= len(m.ConnectionProfileResourceVersion) - copy(dAtA[i:], m.ConnectionProfileResourceVersion) - i = encodeVarintGenerated(dAtA, i, uint64(len(m.ConnectionProfileResourceVersion))) - i-- - dAtA[i] = 0x1a - i -= len(m.TLSSecretResourceVersion) - copy(dAtA[i:], m.TLSSecretResourceVersion) - i = encodeVarintGenerated(dAtA, i, uint64(len(m.TLSSecretResourceVersion))) - i-- - dAtA[i] = 0x12 - i -= len(m.SecretResourceVersion) - copy(dAtA[i:], m.SecretResourceVersion) - i = encodeVarintGenerated(dAtA, i, uint64(len(m.SecretResourceVersion))) - i-- - dAtA[i] = 0xa - return len(dAtA) - i, nil + l = len(m.Address) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.HostName) + n += 1 + l + sovGenerated(uint64(l)) + return n } -func (m *TargetSyncProfile) Marshal() (dAtA []byte, err error) { - size := m.Size() - dAtA = make([]byte, size) - n, err := m.MarshalToSizedBuffer(dAtA[:size]) - if err != nil { - return nil, err +func (m *DiscoveryRuleList) Size() (n int) { + if m == nil { + return 0 } - return dAtA[:n], nil + var l int + _ = l + l = m.ListMeta.Size() + n += 1 + l + sovGenerated(uint64(l)) + if len(m.Items) > 0 { + for _, e := range m.Items { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + } + return n } -func (m *TargetSyncProfile) MarshalTo(dAtA []byte) (int, error) { - size := m.Size() - return m.MarshalToSizedBuffer(dAtA[:size]) +func (m *DiscoveryRulePrefix) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + l = len(m.Prefix) + n += 1 + l + sovGenerated(uint64(l)) + if len(m.Excludes) > 0 { + for _, s := range m.Excludes { + l = len(s) + n += 1 + l + sovGenerated(uint64(l)) + } + } + return n } -func (m *TargetSyncProfile) MarshalToSizedBuffer(dAtA []byte) (int, error) { - i := len(dAtA) - _ = i +func (m *DiscoveryRuleSpec) Size() (n int) { + if m == nil { + return 0 + } var l int _ = l - { - size, err := m.Spec.MarshalToSizedBuffer(dAtA[:i]) - if err != nil { - return 0, err + if len(m.Prefixes) > 0 { + for _, e := range m.Prefixes { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) } - i -= size - i = encodeVarintGenerated(dAtA, i, uint64(size)) } - i-- - dAtA[i] = 0x12 - { - size, err := m.ObjectMeta.MarshalToSizedBuffer(dAtA[:i]) - if err != nil { - return 0, err + if len(m.Addresses) > 0 { + for _, e := range m.Addresses { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) } - i -= size - i = encodeVarintGenerated(dAtA, i, uint64(size)) } - i-- - dAtA[i] = 0xa - return len(dAtA) - i, nil + if m.PodSelector != nil { + l = m.PodSelector.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + if m.ServiceSelector != nil { + l = m.ServiceSelector.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + l = len(m.ServiceDomain) + n += 1 + l + sovGenerated(uint64(l)) + l = m.DiscoveryParameters.Size() + n += 1 + l + sovGenerated(uint64(l)) + return n } -func (m *TargetSyncProfileList) Marshal() (dAtA []byte, err error) { - size := m.Size() - dAtA = make([]byte, size) - n, err := m.MarshalToSizedBuffer(dAtA[:size]) - if err != nil { - return nil, err +func (m *DiscoveryRuleStatus) Size() (n int) { + if m == nil { + return 0 } - return dAtA[:n], nil + var l int + _ = l + l = m.ConditionedStatus.Size() + n += 1 + l + sovGenerated(uint64(l)) + if m.StartTime != nil { + l = m.StartTime.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + return n } -func (m *TargetSyncProfileList) MarshalTo(dAtA []byte) (int, error) { - size := m.Size() - return m.MarshalToSizedBuffer(dAtA[:size]) +func (m *DiscoveryVendorProfile) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + l = m.ObjectMeta.Size() + n += 1 + l + sovGenerated(uint64(l)) + l = m.Spec.Size() + n += 1 + l + sovGenerated(uint64(l)) + return n } -func (m *TargetSyncProfileList) MarshalToSizedBuffer(dAtA []byte) (int, error) { - i := len(dAtA) - _ = i +func (m *DiscoveryVendorProfileList) Size() (n int) { + if m == nil { + return 0 + } var l int _ = l + l = m.ListMeta.Size() + n += 1 + l + sovGenerated(uint64(l)) if len(m.Items) > 0 { - for iNdEx := len(m.Items) - 1; iNdEx >= 0; iNdEx-- { - { - size, err := m.Items[iNdEx].MarshalToSizedBuffer(dAtA[:i]) - if err != nil { - return 0, err - } - i -= size - i = encodeVarintGenerated(dAtA, i, uint64(size)) - } - i-- - dAtA[i] = 0x12 + for _, e := range m.Items { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) } } - { - size, err := m.ListMeta.MarshalToSizedBuffer(dAtA[:i]) - if err != nil { - return 0, err - } - i -= size - i = encodeVarintGenerated(dAtA, i, uint64(size)) + return n +} + +func (m *DiscoveryVendorProfileSpec) Size() (n int) { + if m == nil { + return 0 } - i-- - dAtA[i] = 0xa - return len(dAtA) - i, nil + var l int + _ = l + l = m.Gnmi.Size() + n += 1 + l + sovGenerated(uint64(l)) + return n } -func (m *TargetSyncProfileSpec) Marshal() (dAtA []byte, err error) { - size := m.Size() - dAtA = make([]byte, size) - n, err := m.MarshalToSizedBuffer(dAtA[:size]) - if err != nil { - return nil, err +func (m *GnmiDiscoveryVendorProfileParameters) Size() (n int) { + if m == nil { + return 0 } - return dAtA[:n], nil + var l int + _ = l + l = len(m.Organization) + n += 1 + l + sovGenerated(uint64(l)) + if m.ModelMatch != nil { + l = len(*m.ModelMatch) + n += 1 + l + sovGenerated(uint64(l)) + } + if len(m.Paths) > 0 { + for _, e := range m.Paths { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + } + if m.Encoding != nil { + l = len(*m.Encoding) + n += 1 + l + sovGenerated(uint64(l)) + } + if m.PreserveNamespace != nil { + n += 2 + } + return n } -func (m *TargetSyncProfileSpec) MarshalTo(dAtA []byte) (int, error) { - size := m.Size() - return m.MarshalToSizedBuffer(dAtA[:size]) +func (m *Proxy) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + l = len(m.URL) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.Credentials) + n += 1 + l + sovGenerated(uint64(l)) + return n } -func (m *TargetSyncProfileSpec) MarshalToSizedBuffer(dAtA []byte) (int, error) { - i := len(dAtA) - _ = i +func (m *Repository) Size() (n int) { + if m == nil { + return 0 + } var l int _ = l - if len(m.Sync) > 0 { - for iNdEx := len(m.Sync) - 1; iNdEx >= 0; iNdEx-- { - { - size, err := m.Sync[iNdEx].MarshalToSizedBuffer(dAtA[:i]) - if err != nil { - return 0, err - } - i -= size - i = encodeVarintGenerated(dAtA, i, uint64(size)) - } - i-- - dAtA[i] = 0x22 - } + l = len(m.RepoURL) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.Credentials) + n += 1 + l + sovGenerated(uint64(l)) + if m.Proxy != nil { + l = m.Proxy.Size() + n += 1 + l + sovGenerated(uint64(l)) } - i = encodeVarintGenerated(dAtA, i, uint64(m.Workers)) - i-- - dAtA[i] = 0x18 - i = encodeVarintGenerated(dAtA, i, uint64(m.Buffer)) - i-- - dAtA[i] = 0x10 - i-- - if m.Validate { - dAtA[i] = 1 - } else { - dAtA[i] = 0 + l = len(m.Kind) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.Ref) + n += 1 + l + sovGenerated(uint64(l)) + return n +} + +func (m *Rollout) Size() (n int) { + if m == nil { + return 0 } - i-- - dAtA[i] = 0x8 - return len(dAtA) - i, nil + var l int + _ = l + l = m.ObjectMeta.Size() + n += 1 + l + sovGenerated(uint64(l)) + l = m.Spec.Size() + n += 1 + l + sovGenerated(uint64(l)) + l = m.Status.Size() + n += 1 + l + sovGenerated(uint64(l)) + return n } -func (m *TargetSyncProfileSync) Marshal() (dAtA []byte, err error) { - size := m.Size() - dAtA = make([]byte, size) - n, err := m.MarshalToSizedBuffer(dAtA[:size]) - if err != nil { - return nil, err +func (m *RolloutList) Size() (n int) { + if m == nil { + return 0 } - return dAtA[:n], nil + var l int + _ = l + l = m.ListMeta.Size() + n += 1 + l + sovGenerated(uint64(l)) + if len(m.Items) > 0 { + for _, e := range m.Items { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + } + return n } -func (m *TargetSyncProfileSync) MarshalTo(dAtA []byte) (int, error) { - size := m.Size() - return m.MarshalToSizedBuffer(dAtA[:size]) +func (m *RolloutSpec) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + l = m.Repository.Size() + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.Strategy) + n += 1 + l + sovGenerated(uint64(l)) + if m.SkipUnavailableTarget != nil { + n += 2 + } + return n } -func (m *TargetSyncProfileSync) MarshalToSizedBuffer(dAtA []byte) (int, error) { - i := len(dAtA) - _ = i +func (m *RolloutStatus) Size() (n int) { + if m == nil { + return 0 + } var l int _ = l - { - size, err := m.Interval.MarshalToSizedBuffer(dAtA[:i]) - if err != nil { - return 0, err + l = m.ConditionedStatus.Size() + n += 1 + l + sovGenerated(uint64(l)) + if len(m.Targets) > 0 { + for _, e := range m.Targets { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) } - i -= size - i = encodeVarintGenerated(dAtA, i, uint64(size)) } - i-- - dAtA[i] = 0x3a - if m.Encoding != nil { - i -= len(*m.Encoding) - copy(dAtA[i:], *m.Encoding) - i = encodeVarintGenerated(dAtA, i, uint64(len(*m.Encoding))) - i-- - dAtA[i] = 0x32 - } - i -= len(m.Mode) - copy(dAtA[i:], m.Mode) - i = encodeVarintGenerated(dAtA, i, uint64(len(m.Mode))) - i-- - dAtA[i] = 0x2a - if len(m.Paths) > 0 { - for iNdEx := len(m.Paths) - 1; iNdEx >= 0; iNdEx-- { - i -= len(m.Paths[iNdEx]) - copy(dAtA[i:], m.Paths[iNdEx]) - i = encodeVarintGenerated(dAtA, i, uint64(len(m.Paths[iNdEx]))) - i-- - dAtA[i] = 0x22 - } + return n +} + +func (m *RolloutTargetStatus) Size() (n int) { + if m == nil { + return 0 } - i = encodeVarintGenerated(dAtA, i, uint64(m.Port)) - i-- - dAtA[i] = 0x18 - i -= len(m.Protocol) - copy(dAtA[i:], m.Protocol) - i = encodeVarintGenerated(dAtA, i, uint64(len(m.Protocol))) - i-- - dAtA[i] = 0x12 - i -= len(m.Name) - copy(dAtA[i:], m.Name) - i = encodeVarintGenerated(dAtA, i, uint64(len(m.Name))) - i-- - dAtA[i] = 0xa - return len(dAtA) - i, nil + var l int + _ = l + l = len(m.Name) + n += 1 + l + sovGenerated(uint64(l)) + l = m.ConditionedStatus.Size() + n += 1 + l + sovGenerated(uint64(l)) + return n } -func (m *TargetTemplate) Marshal() (dAtA []byte, err error) { - size := m.Size() - dAtA = make([]byte, size) - n, err := m.MarshalToSizedBuffer(dAtA[:size]) - if err != nil { - return nil, err +func (m *Schema) Size() (n int) { + if m == nil { + return 0 } - return dAtA[:n], nil + var l int + _ = l + l = m.ObjectMeta.Size() + n += 1 + l + sovGenerated(uint64(l)) + l = m.Spec.Size() + n += 1 + l + sovGenerated(uint64(l)) + l = m.Status.Size() + n += 1 + l + sovGenerated(uint64(l)) + return n } -func (m *TargetTemplate) MarshalTo(dAtA []byte) (int, error) { - size := m.Size() - return m.MarshalToSizedBuffer(dAtA[:size]) +func (m *SchemaKey) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + l = len(m.Provider) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.Version) + n += 1 + l + sovGenerated(uint64(l)) + return n } -func (m *TargetTemplate) MarshalToSizedBuffer(dAtA []byte) (int, error) { - i := len(dAtA) - _ = i +func (m *SchemaList) Size() (n int) { + if m == nil { + return 0 + } var l int _ = l - if len(m.Labels) > 0 { - keysForLabels := make([]string, 0, len(m.Labels)) - for k := range m.Labels { - keysForLabels = append(keysForLabels, string(k)) - } - github_com_gogo_protobuf_sortkeys.Strings(keysForLabels) - for iNdEx := len(keysForLabels) - 1; iNdEx >= 0; iNdEx-- { - v := m.Labels[string(keysForLabels[iNdEx])] - baseI := i - i -= len(v) - copy(dAtA[i:], v) - i = encodeVarintGenerated(dAtA, i, uint64(len(v))) - i-- - dAtA[i] = 0x12 - i -= len(keysForLabels[iNdEx]) - copy(dAtA[i:], keysForLabels[iNdEx]) - i = encodeVarintGenerated(dAtA, i, uint64(len(keysForLabels[iNdEx]))) - i-- - dAtA[i] = 0xa - i = encodeVarintGenerated(dAtA, i, uint64(baseI-i)) - i-- - dAtA[i] = 0x1a + l = m.ListMeta.Size() + n += 1 + l + sovGenerated(uint64(l)) + if len(m.Items) > 0 { + for _, e := range m.Items { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) } } - if len(m.Annotations) > 0 { - keysForAnnotations := make([]string, 0, len(m.Annotations)) - for k := range m.Annotations { - keysForAnnotations = append(keysForAnnotations, string(k)) - } - github_com_gogo_protobuf_sortkeys.Strings(keysForAnnotations) - for iNdEx := len(keysForAnnotations) - 1; iNdEx >= 0; iNdEx-- { - v := m.Annotations[string(keysForAnnotations[iNdEx])] - baseI := i - i -= len(v) - copy(dAtA[i:], v) - i = encodeVarintGenerated(dAtA, i, uint64(len(v))) - i-- - dAtA[i] = 0x12 - i -= len(keysForAnnotations[iNdEx]) - copy(dAtA[i:], keysForAnnotations[iNdEx]) - i = encodeVarintGenerated(dAtA, i, uint64(len(keysForAnnotations[iNdEx]))) - i-- - dAtA[i] = 0xa - i = encodeVarintGenerated(dAtA, i, uint64(baseI-i)) - i-- - dAtA[i] = 0x12 - } + return n +} + +func (m *SchemaRepositoryStatus) Size() (n int) { + if m == nil { + return 0 } - i -= len(m.NameTemplate) - copy(dAtA[i:], m.NameTemplate) - i = encodeVarintGenerated(dAtA, i, uint64(len(m.NameTemplate))) - i-- - dAtA[i] = 0xa - return len(dAtA) - i, nil + var l int + _ = l + l = len(m.RepoURL) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.Reference) + n += 1 + l + sovGenerated(uint64(l)) + return n } -func (m *Workspace) Marshal() (dAtA []byte, err error) { - size := m.Size() - dAtA = make([]byte, size) - n, err := m.MarshalToSizedBuffer(dAtA[:size]) - if err != nil { - return nil, err +func (m *SchemaSpec) Size() (n int) { + if m == nil { + return 0 } - return dAtA[:n], nil + var l int + _ = l + l = len(m.Provider) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.Version) + n += 1 + l + sovGenerated(uint64(l)) + if len(m.Repositories) > 0 { + for _, e := range m.Repositories { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + } + return n } -func (m *Workspace) MarshalTo(dAtA []byte) (int, error) { - size := m.Size() - return m.MarshalToSizedBuffer(dAtA[:size]) +func (m *SchemaSpecRepository) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + if len(m.Dirs) > 0 { + for _, e := range m.Dirs { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + } + l = m.Schema.Size() + n += 1 + l + sovGenerated(uint64(l)) + l = m.Repository.Size() + n += 1 + l + sovGenerated(uint64(l)) + return n } -func (m *Workspace) MarshalToSizedBuffer(dAtA []byte) (int, error) { - i := len(dAtA) - _ = i +func (m *SchemaSpecSchema) Size() (n int) { + if m == nil { + return 0 + } var l int _ = l - { - size, err := m.Status.MarshalToSizedBuffer(dAtA[:i]) - if err != nil { - return 0, err + if len(m.Models) > 0 { + for _, s := range m.Models { + l = len(s) + n += 1 + l + sovGenerated(uint64(l)) } - i -= size - i = encodeVarintGenerated(dAtA, i, uint64(size)) } - i-- - dAtA[i] = 0x1a - { - size, err := m.Spec.MarshalToSizedBuffer(dAtA[:i]) - if err != nil { - return 0, err + if len(m.Includes) > 0 { + for _, s := range m.Includes { + l = len(s) + n += 1 + l + sovGenerated(uint64(l)) } - i -= size - i = encodeVarintGenerated(dAtA, i, uint64(size)) } - i-- - dAtA[i] = 0x12 - { - size, err := m.ObjectMeta.MarshalToSizedBuffer(dAtA[:i]) - if err != nil { - return 0, err + if len(m.Excludes) > 0 { + for _, s := range m.Excludes { + l = len(s) + n += 1 + l + sovGenerated(uint64(l)) } - i -= size - i = encodeVarintGenerated(dAtA, i, uint64(size)) } - i-- - dAtA[i] = 0xa - return len(dAtA) - i, nil + return n } -func (m *WorkspaceList) Marshal() (dAtA []byte, err error) { - size := m.Size() - dAtA = make([]byte, size) - n, err := m.MarshalToSizedBuffer(dAtA[:size]) - if err != nil { - return nil, err +func (m *SchemaStatus) Size() (n int) { + if m == nil { + return 0 } - return dAtA[:n], nil -} - -func (m *WorkspaceList) MarshalTo(dAtA []byte) (int, error) { - size := m.Size() - return m.MarshalToSizedBuffer(dAtA[:size]) -} - -func (m *WorkspaceList) MarshalToSizedBuffer(dAtA []byte) (int, error) { - i := len(dAtA) - _ = i var l int _ = l - if len(m.Items) > 0 { - for iNdEx := len(m.Items) - 1; iNdEx >= 0; iNdEx-- { - { - size, err := m.Items[iNdEx].MarshalToSizedBuffer(dAtA[:i]) - if err != nil { - return 0, err - } - i -= size - i = encodeVarintGenerated(dAtA, i, uint64(size)) - } - i-- - dAtA[i] = 0x12 - } - } - { - size, err := m.ListMeta.MarshalToSizedBuffer(dAtA[:i]) - if err != nil { - return 0, err + l = m.ConditionedStatus.Size() + n += 1 + l + sovGenerated(uint64(l)) + if len(m.Repositories) > 0 { + for _, e := range m.Repositories { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) } - i -= size - i = encodeVarintGenerated(dAtA, i, uint64(size)) } - i-- - dAtA[i] = 0xa - return len(dAtA) - i, nil + return n } -func (m *WorkspaceSpec) Marshal() (dAtA []byte, err error) { - size := m.Size() - dAtA = make([]byte, size) - n, err := m.MarshalToSizedBuffer(dAtA[:size]) - if err != nil { - return nil, err +func (m *SrcDstPath) Size() (n int) { + if m == nil { + return 0 } - return dAtA[:n], nil -} - -func (m *WorkspaceSpec) MarshalTo(dAtA []byte) (int, error) { - size := m.Size() - return m.MarshalToSizedBuffer(dAtA[:size]) -} - -func (m *WorkspaceSpec) MarshalToSizedBuffer(dAtA []byte) (int, error) { - i := len(dAtA) - _ = i var l int _ = l - { - size, err := m.Repository.MarshalToSizedBuffer(dAtA[:i]) - if err != nil { - return 0, err - } - i -= size - i = encodeVarintGenerated(dAtA, i, uint64(size)) - } - i-- - dAtA[i] = 0xa - return len(dAtA) - i, nil + l = len(m.Src) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.Dst) + n += 1 + l + sovGenerated(uint64(l)) + return n } -func (m *WorkspaceStatus) Marshal() (dAtA []byte, err error) { - size := m.Size() - dAtA = make([]byte, size) - n, err := m.MarshalToSizedBuffer(dAtA[:size]) - if err != nil { - return nil, err +func (m *Subscription) Size() (n int) { + if m == nil { + return 0 } - return dAtA[:n], nil -} - -func (m *WorkspaceStatus) MarshalTo(dAtA []byte) (int, error) { - size := m.Size() - return m.MarshalToSizedBuffer(dAtA[:size]) -} - -func (m *WorkspaceStatus) MarshalToSizedBuffer(dAtA []byte) (int, error) { - i := len(dAtA) - _ = i var l int _ = l - if m.DeployedRef != nil { - i -= len(*m.DeployedRef) - copy(dAtA[i:], *m.DeployedRef) - i = encodeVarintGenerated(dAtA, i, uint64(len(*m.DeployedRef))) - i-- - dAtA[i] = 0x1a - } - if m.Kind != nil { - i -= len(*m.Kind) - copy(dAtA[i:], *m.Kind) - i = encodeVarintGenerated(dAtA, i, uint64(len(*m.Kind))) - i-- - dAtA[i] = 0x12 - } - { - size, err := m.ConditionedStatus.MarshalToSizedBuffer(dAtA[:i]) - if err != nil { - return 0, err - } - i -= size - i = encodeVarintGenerated(dAtA, i, uint64(size)) - } - i-- - dAtA[i] = 0xa - return len(dAtA) - i, nil + l = m.ObjectMeta.Size() + n += 1 + l + sovGenerated(uint64(l)) + l = m.Spec.Size() + n += 1 + l + sovGenerated(uint64(l)) + l = m.Status.Size() + n += 1 + l + sovGenerated(uint64(l)) + return n } -func encodeVarintGenerated(dAtA []byte, offset int, v uint64) int { - offset -= sovGenerated(v) - base := offset - for v >= 1<<7 { - dAtA[offset] = uint8(v&0x7f | 0x80) - v >>= 7 - offset++ - } - dAtA[offset] = uint8(v) - return base -} -func (m *DiscoveryInfo) Size() (n int) { +func (m *SubscriptionList) Size() (n int) { if m == nil { return 0 } var l int _ = l - l = len(m.Protocol) - n += 1 + l + sovGenerated(uint64(l)) - l = len(m.Provider) - n += 1 + l + sovGenerated(uint64(l)) - l = len(m.Version) - n += 1 + l + sovGenerated(uint64(l)) - l = len(m.Hostname) - n += 1 + l + sovGenerated(uint64(l)) - l = len(m.Platform) - n += 1 + l + sovGenerated(uint64(l)) - l = len(m.MacAddress) - n += 1 + l + sovGenerated(uint64(l)) - l = len(m.SerialNumber) + l = m.ListMeta.Size() n += 1 + l + sovGenerated(uint64(l)) - if len(m.SupportedEncodings) > 0 { - for _, s := range m.SupportedEncodings { - l = len(s) + if len(m.Items) > 0 { + for _, e := range m.Items { + l = e.Size() n += 1 + l + sovGenerated(uint64(l)) } } return n } -func (m *DiscoveryParameters) Size() (n int) { +func (m *SubscriptionParameters) Size() (n int) { if m == nil { return 0 } var l int _ = l - if m.DefaultSchema != nil { - l = m.DefaultSchema.Size() - n += 1 + l + sovGenerated(uint64(l)) - } - if m.DiscoveryProfile != nil { - l = m.DiscoveryProfile.Size() + l = len(m.Name) + n += 1 + l + sovGenerated(uint64(l)) + if m.Description != nil { + l = len(*m.Description) n += 1 + l + sovGenerated(uint64(l)) } - if len(m.TargetConnectionProfiles) > 0 { - for _, e := range m.TargetConnectionProfiles { - l = e.Size() - n += 1 + l + sovGenerated(uint64(l)) + if len(m.Labels) > 0 { + for k, v := range m.Labels { + _ = k + _ = v + mapEntrySize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + len(v) + sovGenerated(uint64(len(v))) + n += mapEntrySize + 1 + sovGenerated(uint64(mapEntrySize)) } } - if m.TargetTemplate != nil { - l = m.TargetTemplate.Size() + if m.AdminState != nil { + l = len(*m.AdminState) n += 1 + l + sovGenerated(uint64(l)) } - l = m.Period.Size() + l = len(m.Mode) n += 1 + l + sovGenerated(uint64(l)) - n += 1 + sovGenerated(uint64(m.ConcurrentScans)) + if m.Interval != nil { + l = m.Interval.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + if len(m.Paths) > 0 { + for _, s := range m.Paths { + l = len(s) + n += 1 + l + sovGenerated(uint64(l)) + } + } return n } -func (m *DiscoveryPathDefinition) Size() (n int) { +func (m *SubscriptionSpec) Size() (n int) { if m == nil { return 0 } var l int _ = l - l = len(m.Key) + l = m.Target.Size() n += 1 + l + sovGenerated(uint64(l)) - l = len(m.Path) + l = len(m.Protocol) n += 1 + l + sovGenerated(uint64(l)) - if m.Script != nil { - l = len(*m.Script) + n += 1 + sovGenerated(uint64(m.Port)) + if m.Encoding != nil { + l = len(*m.Encoding) n += 1 + l + sovGenerated(uint64(l)) } - if m.Regex != nil { - l = len(*m.Regex) - n += 1 + l + sovGenerated(uint64(l)) + if len(m.Subscriptions) > 0 { + for _, e := range m.Subscriptions { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } } return n } -func (m *DiscoveryProfile) Size() (n int) { +func (m *SubscriptionStatus) Size() (n int) { if m == nil { return 0 } var l int _ = l - l = len(m.Credentials) + l = m.ConditionedStatus.Size() n += 1 + l + sovGenerated(uint64(l)) - if m.TLSSecret != nil { - l = len(*m.TLSSecret) - n += 1 + l + sovGenerated(uint64(l)) - } - if len(m.ConnectionProfiles) > 0 { - for _, s := range m.ConnectionProfiles { + if len(m.Targets) > 0 { + for _, s := range m.Targets { l = len(s) n += 1 + l + sovGenerated(uint64(l)) } @@ -4709,35 +3219,33 @@ func (m *DiscoveryProfile) Size() (n int) { return n } -func (m *DiscoveryRule) Size() (n int) { +func (m *SubscriptionTarget) Size() (n int) { if m == nil { return 0 } var l int _ = l - l = m.ObjectMeta.Size() - n += 1 + l + sovGenerated(uint64(l)) - l = m.Spec.Size() - n += 1 + l + sovGenerated(uint64(l)) - l = m.Status.Size() - n += 1 + l + sovGenerated(uint64(l)) + if m.TargetSelector != nil { + l = m.TargetSelector.Size() + n += 1 + l + sovGenerated(uint64(l)) + } return n } -func (m *DiscoveryRuleAddress) Size() (n int) { +func (m *TargetConnectionProfile) Size() (n int) { if m == nil { return 0 } var l int _ = l - l = len(m.Address) + l = m.ObjectMeta.Size() n += 1 + l + sovGenerated(uint64(l)) - l = len(m.HostName) + l = m.Spec.Size() n += 1 + l + sovGenerated(uint64(l)) return n } -func (m *DiscoveryRuleList) Size() (n int) { +func (m *TargetConnectionProfileList) Size() (n int) { if m == nil { return 0 } @@ -4754,72 +3262,75 @@ func (m *DiscoveryRuleList) Size() (n int) { return n } -func (m *DiscoveryRulePrefix) Size() (n int) { +func (m *TargetConnectionProfileSpec) Size() (n int) { if m == nil { return 0 } var l int _ = l - l = len(m.Prefix) + l = m.ConnectRetry.Size() n += 1 + l + sovGenerated(uint64(l)) - if len(m.Excludes) > 0 { - for _, s := range m.Excludes { - l = len(s) - n += 1 + l + sovGenerated(uint64(l)) - } - } - return n -} - -func (m *DiscoveryRuleSpec) Size() (n int) { - if m == nil { - return 0 + l = m.Timeout.Size() + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.Protocol) + n += 1 + l + sovGenerated(uint64(l)) + n += 1 + sovGenerated(uint64(m.Port)) + if m.Encoding != nil { + l = len(*m.Encoding) + n += 1 + l + sovGenerated(uint64(l)) } - var l int - _ = l - if len(m.Prefixes) > 0 { - for _, e := range m.Prefixes { - l = e.Size() - n += 1 + l + sovGenerated(uint64(l)) - } + if m.PreferredNetconfVersion != nil { + l = len(*m.PreferredNetconfVersion) + n += 1 + l + sovGenerated(uint64(l)) } - if len(m.Addresses) > 0 { - for _, e := range m.Addresses { - l = e.Size() - n += 1 + l + sovGenerated(uint64(l)) - } + if m.Insecure != nil { + n += 2 } - if m.PodSelector != nil { - l = m.PodSelector.Size() + if m.SkipVerify != nil { + n += 2 + } + if m.IncludeNS != nil { + n += 2 + } + if m.OperationWithNS != nil { + n += 2 + } + if m.UseOperationRemove != nil { + n += 2 + } + if m.CommitCandidate != nil { + l = len(*m.CommitCandidate) n += 1 + l + sovGenerated(uint64(l)) } - if m.ServiceSelector != nil { - l = m.ServiceSelector.Size() + if m.TargetName != nil { + l = len(*m.TargetName) n += 1 + l + sovGenerated(uint64(l)) } - l = len(m.ServiceDomain) - n += 1 + l + sovGenerated(uint64(l)) - l = m.DiscoveryParameters.Size() - n += 1 + l + sovGenerated(uint64(l)) return n } -func (m *DiscoveryRuleStatus) Size() (n int) { +func (m *TargetProfile) Size() (n int) { if m == nil { return 0 } var l int _ = l - l = m.ConditionedStatus.Size() + l = len(m.Credentials) n += 1 + l + sovGenerated(uint64(l)) - if m.StartTime != nil { - l = m.StartTime.Size() + if m.TLSSecret != nil { + l = len(*m.TLSSecret) + n += 1 + l + sovGenerated(uint64(l)) + } + l = len(m.ConnectionProfile) + n += 1 + l + sovGenerated(uint64(l)) + if m.SyncProfile != nil { + l = len(*m.SyncProfile) n += 1 + l + sovGenerated(uint64(l)) } return n } -func (m *DiscoveryVendorProfile) Size() (n int) { +func (m *TargetSyncProfile) Size() (n int) { if m == nil { return 0 } @@ -4832,7 +3343,7 @@ func (m *DiscoveryVendorProfile) Size() (n int) { return n } -func (m *DiscoveryVendorProfileList) Size() (n int) { +func (m *TargetSyncProfileList) Size() (n int) { if m == nil { return 0 } @@ -4849,80 +3360,80 @@ func (m *DiscoveryVendorProfileList) Size() (n int) { return n } -func (m *DiscoveryVendorProfileSpec) Size() (n int) { +func (m *TargetSyncProfileSpec) Size() (n int) { if m == nil { return 0 } var l int _ = l - l = m.Gnmi.Size() - n += 1 + l + sovGenerated(uint64(l)) + n += 2 + n += 1 + sovGenerated(uint64(m.Buffer)) + n += 1 + sovGenerated(uint64(m.Workers)) + if len(m.Sync) > 0 { + for _, e := range m.Sync { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + } return n } -func (m *GnmiDiscoveryVendorProfileParameters) Size() (n int) { +func (m *TargetSyncProfileSync) Size() (n int) { if m == nil { return 0 } var l int _ = l - l = len(m.Organization) + l = len(m.Name) n += 1 + l + sovGenerated(uint64(l)) - if m.ModelMatch != nil { - l = len(*m.ModelMatch) - n += 1 + l + sovGenerated(uint64(l)) - } + l = len(m.Protocol) + n += 1 + l + sovGenerated(uint64(l)) + n += 1 + sovGenerated(uint64(m.Port)) if len(m.Paths) > 0 { - for _, e := range m.Paths { - l = e.Size() + for _, s := range m.Paths { + l = len(s) n += 1 + l + sovGenerated(uint64(l)) } } + l = len(m.Mode) + n += 1 + l + sovGenerated(uint64(l)) if m.Encoding != nil { l = len(*m.Encoding) n += 1 + l + sovGenerated(uint64(l)) } - if m.PreserveNamespace != nil { - n += 2 - } - return n -} - -func (m *Proxy) Size() (n int) { - if m == nil { - return 0 - } - var l int - _ = l - l = len(m.URL) - n += 1 + l + sovGenerated(uint64(l)) - l = len(m.Credentials) + l = m.Interval.Size() n += 1 + l + sovGenerated(uint64(l)) return n } -func (m *Repository) Size() (n int) { +func (m *TargetTemplate) Size() (n int) { if m == nil { return 0 } var l int _ = l - l = len(m.RepoURL) - n += 1 + l + sovGenerated(uint64(l)) - l = len(m.Credentials) + l = len(m.NameTemplate) n += 1 + l + sovGenerated(uint64(l)) - if m.Proxy != nil { - l = m.Proxy.Size() - n += 1 + l + sovGenerated(uint64(l)) + if len(m.Annotations) > 0 { + for k, v := range m.Annotations { + _ = k + _ = v + mapEntrySize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + len(v) + sovGenerated(uint64(len(v))) + n += mapEntrySize + 1 + sovGenerated(uint64(mapEntrySize)) + } + } + if len(m.Labels) > 0 { + for k, v := range m.Labels { + _ = k + _ = v + mapEntrySize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + len(v) + sovGenerated(uint64(len(v))) + n += mapEntrySize + 1 + sovGenerated(uint64(mapEntrySize)) + } } - l = len(m.Kind) - n += 1 + l + sovGenerated(uint64(l)) - l = len(m.Ref) - n += 1 + l + sovGenerated(uint64(l)) return n } -func (m *Rollout) Size() (n int) { +func (m *Workspace) Size() (n int) { if m == nil { return 0 } @@ -4937,7 +3448,7 @@ func (m *Rollout) Size() (n int) { return n } -func (m *RolloutList) Size() (n int) { +func (m *WorkspaceList) Size() (n int) { if m == nil { return 0 } @@ -4954,7 +3465,7 @@ func (m *RolloutList) Size() (n int) { return n } -func (m *RolloutSpec) Size() (n int) { +func (m *WorkspaceSpec) Size() (n int) { if m == nil { return 0 } @@ -4962,15 +3473,10 @@ func (m *RolloutSpec) Size() (n int) { _ = l l = m.Repository.Size() n += 1 + l + sovGenerated(uint64(l)) - l = len(m.Strategy) - n += 1 + l + sovGenerated(uint64(l)) - if m.SkipUnavailableTarget != nil { - n += 2 - } return n } -func (m *RolloutStatus) Size() (n int) { +func (m *WorkspaceStatus) Size() (n int) { if m == nil { return 0 } @@ -4978,2327 +3484,733 @@ func (m *RolloutStatus) Size() (n int) { _ = l l = m.ConditionedStatus.Size() n += 1 + l + sovGenerated(uint64(l)) - if len(m.Targets) > 0 { - for _, e := range m.Targets { - l = e.Size() - n += 1 + l + sovGenerated(uint64(l)) - } + if m.Kind != nil { + l = len(*m.Kind) + n += 1 + l + sovGenerated(uint64(l)) } - return n -} - -func (m *RolloutTargetStatus) Size() (n int) { - if m == nil { - return 0 + if m.DeployedRef != nil { + l = len(*m.DeployedRef) + n += 1 + l + sovGenerated(uint64(l)) } - var l int - _ = l - l = len(m.Name) - n += 1 + l + sovGenerated(uint64(l)) - l = m.ConditionedStatus.Size() - n += 1 + l + sovGenerated(uint64(l)) return n } -func (m *Schema) Size() (n int) { - if m == nil { - return 0 - } - var l int - _ = l - l = m.ObjectMeta.Size() - n += 1 + l + sovGenerated(uint64(l)) - l = m.Spec.Size() - n += 1 + l + sovGenerated(uint64(l)) - l = m.Status.Size() - n += 1 + l + sovGenerated(uint64(l)) - return n +func sovGenerated(x uint64) (n int) { + return (math_bits.Len64(x|1) + 6) / 7 } - -func (m *SchemaKey) Size() (n int) { - if m == nil { - return 0 - } - var l int - _ = l - l = len(m.Provider) - n += 1 + l + sovGenerated(uint64(l)) - l = len(m.Version) - n += 1 + l + sovGenerated(uint64(l)) - return n +func sozGenerated(x uint64) (n int) { + return sovGenerated(uint64((x << 1) ^ uint64((int64(x) >> 63)))) } - -func (m *SchemaList) Size() (n int) { - if m == nil { - return 0 +func (this *DiscoveryParameters) String() string { + if this == nil { + return "nil" } - var l int - _ = l - l = m.ListMeta.Size() - n += 1 + l + sovGenerated(uint64(l)) - if len(m.Items) > 0 { - for _, e := range m.Items { - l = e.Size() - n += 1 + l + sovGenerated(uint64(l)) - } + repeatedStringForTargetConnectionProfiles := "[]TargetProfile{" + for _, f := range this.TargetConnectionProfiles { + repeatedStringForTargetConnectionProfiles += strings.Replace(strings.Replace(f.String(), "TargetProfile", "TargetProfile", 1), `&`, ``, 1) + "," } - return n + repeatedStringForTargetConnectionProfiles += "}" + s := strings.Join([]string{`&DiscoveryParameters{`, + `DefaultSchema:` + strings.Replace(this.DefaultSchema.String(), "SchemaKey", "SchemaKey", 1) + `,`, + `DiscoveryProfile:` + strings.Replace(this.DiscoveryProfile.String(), "DiscoveryProfile", "DiscoveryProfile", 1) + `,`, + `TargetConnectionProfiles:` + repeatedStringForTargetConnectionProfiles + `,`, + `TargetTemplate:` + strings.Replace(this.TargetTemplate.String(), "TargetTemplate", "TargetTemplate", 1) + `,`, + `Period:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Period), "Duration", "v1.Duration", 1), `&`, ``, 1) + `,`, + `ConcurrentScans:` + fmt.Sprintf("%v", this.ConcurrentScans) + `,`, + `}`, + }, "") + return s } - -func (m *SchemaRepositoryStatus) Size() (n int) { - if m == nil { - return 0 +func (this *DiscoveryPathDefinition) String() string { + if this == nil { + return "nil" } - var l int - _ = l - l = len(m.RepoURL) - n += 1 + l + sovGenerated(uint64(l)) - l = len(m.Reference) - n += 1 + l + sovGenerated(uint64(l)) - return n -} - -func (m *SchemaSpec) Size() (n int) { - if m == nil { - return 0 - } - var l int - _ = l - l = len(m.Provider) - n += 1 + l + sovGenerated(uint64(l)) - l = len(m.Version) - n += 1 + l + sovGenerated(uint64(l)) - if len(m.Repositories) > 0 { - for _, e := range m.Repositories { - l = e.Size() - n += 1 + l + sovGenerated(uint64(l)) - } - } - return n + s := strings.Join([]string{`&DiscoveryPathDefinition{`, + `Key:` + fmt.Sprintf("%v", this.Key) + `,`, + `Path:` + fmt.Sprintf("%v", this.Path) + `,`, + `Script:` + valueToStringGenerated(this.Script) + `,`, + `Regex:` + valueToStringGenerated(this.Regex) + `,`, + `}`, + }, "") + return s } - -func (m *SchemaSpecRepository) Size() (n int) { - if m == nil { - return 0 +func (this *DiscoveryProfile) String() string { + if this == nil { + return "nil" } - var l int - _ = l - if len(m.Dirs) > 0 { - for _, e := range m.Dirs { - l = e.Size() - n += 1 + l + sovGenerated(uint64(l)) - } + s := strings.Join([]string{`&DiscoveryProfile{`, + `Credentials:` + fmt.Sprintf("%v", this.Credentials) + `,`, + `TLSSecret:` + valueToStringGenerated(this.TLSSecret) + `,`, + `ConnectionProfiles:` + fmt.Sprintf("%v", this.ConnectionProfiles) + `,`, + `}`, + }, "") + return s +} +func (this *DiscoveryRule) String() string { + if this == nil { + return "nil" } - l = m.Schema.Size() - n += 1 + l + sovGenerated(uint64(l)) - l = m.Repository.Size() - n += 1 + l + sovGenerated(uint64(l)) - return n + s := strings.Join([]string{`&DiscoveryRule{`, + `ObjectMeta:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ObjectMeta), "ObjectMeta", "v1.ObjectMeta", 1), `&`, ``, 1) + `,`, + `Spec:` + strings.Replace(strings.Replace(this.Spec.String(), "DiscoveryRuleSpec", "DiscoveryRuleSpec", 1), `&`, ``, 1) + `,`, + `Status:` + strings.Replace(strings.Replace(this.Status.String(), "DiscoveryRuleStatus", "DiscoveryRuleStatus", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s } - -func (m *SchemaSpecSchema) Size() (n int) { - if m == nil { - return 0 +func (this *DiscoveryRuleAddress) String() string { + if this == nil { + return "nil" } - var l int - _ = l - if len(m.Models) > 0 { - for _, s := range m.Models { - l = len(s) - n += 1 + l + sovGenerated(uint64(l)) - } + s := strings.Join([]string{`&DiscoveryRuleAddress{`, + `Address:` + fmt.Sprintf("%v", this.Address) + `,`, + `HostName:` + fmt.Sprintf("%v", this.HostName) + `,`, + `}`, + }, "") + return s +} +func (this *DiscoveryRuleList) String() string { + if this == nil { + return "nil" } - if len(m.Includes) > 0 { - for _, s := range m.Includes { - l = len(s) - n += 1 + l + sovGenerated(uint64(l)) - } + repeatedStringForItems := "[]DiscoveryRule{" + for _, f := range this.Items { + repeatedStringForItems += strings.Replace(strings.Replace(f.String(), "DiscoveryRule", "DiscoveryRule", 1), `&`, ``, 1) + "," } - if len(m.Excludes) > 0 { - for _, s := range m.Excludes { - l = len(s) - n += 1 + l + sovGenerated(uint64(l)) - } + repeatedStringForItems += "}" + s := strings.Join([]string{`&DiscoveryRuleList{`, + `ListMeta:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ListMeta), "ListMeta", "v1.ListMeta", 1), `&`, ``, 1) + `,`, + `Items:` + repeatedStringForItems + `,`, + `}`, + }, "") + return s +} +func (this *DiscoveryRulePrefix) String() string { + if this == nil { + return "nil" } - return n + s := strings.Join([]string{`&DiscoveryRulePrefix{`, + `Prefix:` + fmt.Sprintf("%v", this.Prefix) + `,`, + `Excludes:` + fmt.Sprintf("%v", this.Excludes) + `,`, + `}`, + }, "") + return s } - -func (m *SchemaStatus) Size() (n int) { - if m == nil { - return 0 +func (this *DiscoveryRuleSpec) String() string { + if this == nil { + return "nil" } - var l int - _ = l - l = m.ConditionedStatus.Size() - n += 1 + l + sovGenerated(uint64(l)) - if len(m.Repositories) > 0 { - for _, e := range m.Repositories { - l = e.Size() - n += 1 + l + sovGenerated(uint64(l)) - } + repeatedStringForPrefixes := "[]DiscoveryRulePrefix{" + for _, f := range this.Prefixes { + repeatedStringForPrefixes += strings.Replace(strings.Replace(f.String(), "DiscoveryRulePrefix", "DiscoveryRulePrefix", 1), `&`, ``, 1) + "," } - return n + repeatedStringForPrefixes += "}" + repeatedStringForAddresses := "[]DiscoveryRuleAddress{" + for _, f := range this.Addresses { + repeatedStringForAddresses += strings.Replace(strings.Replace(f.String(), "DiscoveryRuleAddress", "DiscoveryRuleAddress", 1), `&`, ``, 1) + "," + } + repeatedStringForAddresses += "}" + s := strings.Join([]string{`&DiscoveryRuleSpec{`, + `Prefixes:` + repeatedStringForPrefixes + `,`, + `Addresses:` + repeatedStringForAddresses + `,`, + `PodSelector:` + strings.Replace(fmt.Sprintf("%v", this.PodSelector), "LabelSelector", "v1.LabelSelector", 1) + `,`, + `ServiceSelector:` + strings.Replace(fmt.Sprintf("%v", this.ServiceSelector), "LabelSelector", "v1.LabelSelector", 1) + `,`, + `ServiceDomain:` + fmt.Sprintf("%v", this.ServiceDomain) + `,`, + `DiscoveryParameters:` + strings.Replace(strings.Replace(this.DiscoveryParameters.String(), "DiscoveryParameters", "DiscoveryParameters", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s } - -func (m *SrcDstPath) Size() (n int) { - if m == nil { - return 0 +func (this *DiscoveryRuleStatus) String() string { + if this == nil { + return "nil" } - var l int - _ = l - l = len(m.Src) - n += 1 + l + sovGenerated(uint64(l)) - l = len(m.Dst) - n += 1 + l + sovGenerated(uint64(l)) - return n + s := strings.Join([]string{`&DiscoveryRuleStatus{`, + `ConditionedStatus:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ConditionedStatus), "ConditionedStatus", "v1alpha1.ConditionedStatus", 1), `&`, ``, 1) + `,`, + `StartTime:` + strings.Replace(fmt.Sprintf("%v", this.StartTime), "Time", "v1.Time", 1) + `,`, + `}`, + }, "") + return s } - -func (m *Subscription) Size() (n int) { - if m == nil { - return 0 +func (this *DiscoveryVendorProfile) String() string { + if this == nil { + return "nil" } - var l int - _ = l - l = m.ObjectMeta.Size() - n += 1 + l + sovGenerated(uint64(l)) - l = m.Spec.Size() - n += 1 + l + sovGenerated(uint64(l)) - l = m.Status.Size() - n += 1 + l + sovGenerated(uint64(l)) - return n + s := strings.Join([]string{`&DiscoveryVendorProfile{`, + `ObjectMeta:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ObjectMeta), "ObjectMeta", "v1.ObjectMeta", 1), `&`, ``, 1) + `,`, + `Spec:` + strings.Replace(strings.Replace(this.Spec.String(), "DiscoveryVendorProfileSpec", "DiscoveryVendorProfileSpec", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s } - -func (m *SubscriptionList) Size() (n int) { - if m == nil { - return 0 +func (this *DiscoveryVendorProfileList) String() string { + if this == nil { + return "nil" } - var l int - _ = l - l = m.ListMeta.Size() - n += 1 + l + sovGenerated(uint64(l)) - if len(m.Items) > 0 { - for _, e := range m.Items { - l = e.Size() - n += 1 + l + sovGenerated(uint64(l)) - } + repeatedStringForItems := "[]DiscoveryVendorProfile{" + for _, f := range this.Items { + repeatedStringForItems += strings.Replace(strings.Replace(f.String(), "DiscoveryVendorProfile", "DiscoveryVendorProfile", 1), `&`, ``, 1) + "," } - return n + repeatedStringForItems += "}" + s := strings.Join([]string{`&DiscoveryVendorProfileList{`, + `ListMeta:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ListMeta), "ListMeta", "v1.ListMeta", 1), `&`, ``, 1) + `,`, + `Items:` + repeatedStringForItems + `,`, + `}`, + }, "") + return s } - -func (m *SubscriptionParameters) Size() (n int) { - if m == nil { - return 0 +func (this *DiscoveryVendorProfileSpec) String() string { + if this == nil { + return "nil" } - var l int - _ = l - l = len(m.Name) - n += 1 + l + sovGenerated(uint64(l)) - if m.Description != nil { - l = len(*m.Description) - n += 1 + l + sovGenerated(uint64(l)) + s := strings.Join([]string{`&DiscoveryVendorProfileSpec{`, + `Gnmi:` + strings.Replace(strings.Replace(this.Gnmi.String(), "GnmiDiscoveryVendorProfileParameters", "GnmiDiscoveryVendorProfileParameters", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func (this *GnmiDiscoveryVendorProfileParameters) String() string { + if this == nil { + return "nil" } - if len(m.Labels) > 0 { - for k, v := range m.Labels { - _ = k - _ = v - mapEntrySize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + len(v) + sovGenerated(uint64(len(v))) - n += mapEntrySize + 1 + sovGenerated(uint64(mapEntrySize)) - } + repeatedStringForPaths := "[]DiscoveryPathDefinition{" + for _, f := range this.Paths { + repeatedStringForPaths += strings.Replace(strings.Replace(f.String(), "DiscoveryPathDefinition", "DiscoveryPathDefinition", 1), `&`, ``, 1) + "," } - if m.AdminState != nil { - l = len(*m.AdminState) - n += 1 + l + sovGenerated(uint64(l)) + repeatedStringForPaths += "}" + s := strings.Join([]string{`&GnmiDiscoveryVendorProfileParameters{`, + `Organization:` + fmt.Sprintf("%v", this.Organization) + `,`, + `ModelMatch:` + valueToStringGenerated(this.ModelMatch) + `,`, + `Paths:` + repeatedStringForPaths + `,`, + `Encoding:` + valueToStringGenerated(this.Encoding) + `,`, + `PreserveNamespace:` + valueToStringGenerated(this.PreserveNamespace) + `,`, + `}`, + }, "") + return s +} +func (this *Proxy) String() string { + if this == nil { + return "nil" } - l = len(m.Mode) - n += 1 + l + sovGenerated(uint64(l)) - if m.Interval != nil { - l = m.Interval.Size() - n += 1 + l + sovGenerated(uint64(l)) + s := strings.Join([]string{`&Proxy{`, + `URL:` + fmt.Sprintf("%v", this.URL) + `,`, + `Credentials:` + fmt.Sprintf("%v", this.Credentials) + `,`, + `}`, + }, "") + return s +} +func (this *Repository) String() string { + if this == nil { + return "nil" } - if len(m.Paths) > 0 { - for _, s := range m.Paths { - l = len(s) - n += 1 + l + sovGenerated(uint64(l)) - } + s := strings.Join([]string{`&Repository{`, + `RepoURL:` + fmt.Sprintf("%v", this.RepoURL) + `,`, + `Credentials:` + fmt.Sprintf("%v", this.Credentials) + `,`, + `Proxy:` + strings.Replace(this.Proxy.String(), "Proxy", "Proxy", 1) + `,`, + `Kind:` + fmt.Sprintf("%v", this.Kind) + `,`, + `Ref:` + fmt.Sprintf("%v", this.Ref) + `,`, + `}`, + }, "") + return s +} +func (this *Rollout) String() string { + if this == nil { + return "nil" } - return n + s := strings.Join([]string{`&Rollout{`, + `ObjectMeta:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ObjectMeta), "ObjectMeta", "v1.ObjectMeta", 1), `&`, ``, 1) + `,`, + `Spec:` + strings.Replace(strings.Replace(this.Spec.String(), "RolloutSpec", "RolloutSpec", 1), `&`, ``, 1) + `,`, + `Status:` + strings.Replace(strings.Replace(this.Status.String(), "RolloutStatus", "RolloutStatus", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s } - -func (m *SubscriptionSpec) Size() (n int) { - if m == nil { - return 0 +func (this *RolloutList) String() string { + if this == nil { + return "nil" } - var l int - _ = l - l = m.Target.Size() - n += 1 + l + sovGenerated(uint64(l)) - l = len(m.Protocol) - n += 1 + l + sovGenerated(uint64(l)) - n += 1 + sovGenerated(uint64(m.Port)) - if m.Encoding != nil { - l = len(*m.Encoding) - n += 1 + l + sovGenerated(uint64(l)) + repeatedStringForItems := "[]Rollout{" + for _, f := range this.Items { + repeatedStringForItems += strings.Replace(strings.Replace(f.String(), "Rollout", "Rollout", 1), `&`, ``, 1) + "," } - if len(m.Subscriptions) > 0 { - for _, e := range m.Subscriptions { - l = e.Size() - n += 1 + l + sovGenerated(uint64(l)) - } + repeatedStringForItems += "}" + s := strings.Join([]string{`&RolloutList{`, + `ListMeta:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ListMeta), "ListMeta", "v1.ListMeta", 1), `&`, ``, 1) + `,`, + `Items:` + repeatedStringForItems + `,`, + `}`, + }, "") + return s +} +func (this *RolloutSpec) String() string { + if this == nil { + return "nil" } - return n + s := strings.Join([]string{`&RolloutSpec{`, + `Repository:` + strings.Replace(strings.Replace(this.Repository.String(), "Repository", "Repository", 1), `&`, ``, 1) + `,`, + `Strategy:` + fmt.Sprintf("%v", this.Strategy) + `,`, + `SkipUnavailableTarget:` + valueToStringGenerated(this.SkipUnavailableTarget) + `,`, + `}`, + }, "") + return s } - -func (m *SubscriptionStatus) Size() (n int) { - if m == nil { - return 0 +func (this *RolloutStatus) String() string { + if this == nil { + return "nil" } - var l int - _ = l - l = m.ConditionedStatus.Size() - n += 1 + l + sovGenerated(uint64(l)) - if len(m.Targets) > 0 { - for _, s := range m.Targets { - l = len(s) - n += 1 + l + sovGenerated(uint64(l)) - } + repeatedStringForTargets := "[]RolloutTargetStatus{" + for _, f := range this.Targets { + repeatedStringForTargets += strings.Replace(strings.Replace(f.String(), "RolloutTargetStatus", "RolloutTargetStatus", 1), `&`, ``, 1) + "," } - return n + repeatedStringForTargets += "}" + s := strings.Join([]string{`&RolloutStatus{`, + `ConditionedStatus:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ConditionedStatus), "ConditionedStatus", "v1alpha1.ConditionedStatus", 1), `&`, ``, 1) + `,`, + `Targets:` + repeatedStringForTargets + `,`, + `}`, + }, "") + return s } - -func (m *SubscriptionTarget) Size() (n int) { - if m == nil { - return 0 - } - var l int - _ = l - if m.TargetSelector != nil { - l = m.TargetSelector.Size() - n += 1 + l + sovGenerated(uint64(l)) +func (this *RolloutTargetStatus) String() string { + if this == nil { + return "nil" } - return n + s := strings.Join([]string{`&RolloutTargetStatus{`, + `Name:` + fmt.Sprintf("%v", this.Name) + `,`, + `ConditionedStatus:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ConditionedStatus), "ConditionedStatus", "v1alpha1.ConditionedStatus", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s } - -func (m *Target) Size() (n int) { - if m == nil { - return 0 +func (this *Schema) String() string { + if this == nil { + return "nil" } - var l int - _ = l - l = m.ObjectMeta.Size() - n += 1 + l + sovGenerated(uint64(l)) - l = m.Spec.Size() - n += 1 + l + sovGenerated(uint64(l)) - l = m.Status.Size() - n += 1 + l + sovGenerated(uint64(l)) - return n + s := strings.Join([]string{`&Schema{`, + `ObjectMeta:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ObjectMeta), "ObjectMeta", "v1.ObjectMeta", 1), `&`, ``, 1) + `,`, + `Spec:` + strings.Replace(strings.Replace(this.Spec.String(), "SchemaSpec", "SchemaSpec", 1), `&`, ``, 1) + `,`, + `Status:` + strings.Replace(strings.Replace(this.Status.String(), "SchemaStatus", "SchemaStatus", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s } - -func (m *TargetConnectionProfile) Size() (n int) { - if m == nil { - return 0 +func (this *SchemaKey) String() string { + if this == nil { + return "nil" } - var l int - _ = l - l = m.ObjectMeta.Size() - n += 1 + l + sovGenerated(uint64(l)) - l = m.Spec.Size() - n += 1 + l + sovGenerated(uint64(l)) - return n + s := strings.Join([]string{`&SchemaKey{`, + `Provider:` + fmt.Sprintf("%v", this.Provider) + `,`, + `Version:` + fmt.Sprintf("%v", this.Version) + `,`, + `}`, + }, "") + return s } - -func (m *TargetConnectionProfileList) Size() (n int) { - if m == nil { - return 0 +func (this *SchemaList) String() string { + if this == nil { + return "nil" } - var l int - _ = l - l = m.ListMeta.Size() - n += 1 + l + sovGenerated(uint64(l)) - if len(m.Items) > 0 { - for _, e := range m.Items { - l = e.Size() - n += 1 + l + sovGenerated(uint64(l)) - } + repeatedStringForItems := "[]Schema{" + for _, f := range this.Items { + repeatedStringForItems += strings.Replace(strings.Replace(f.String(), "Schema", "Schema", 1), `&`, ``, 1) + "," } - return n + repeatedStringForItems += "}" + s := strings.Join([]string{`&SchemaList{`, + `ListMeta:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ListMeta), "ListMeta", "v1.ListMeta", 1), `&`, ``, 1) + `,`, + `Items:` + repeatedStringForItems + `,`, + `}`, + }, "") + return s } - -func (m *TargetConnectionProfileSpec) Size() (n int) { - if m == nil { - return 0 - } - var l int - _ = l - l = m.ConnectRetry.Size() - n += 1 + l + sovGenerated(uint64(l)) - l = m.Timeout.Size() - n += 1 + l + sovGenerated(uint64(l)) - l = len(m.Protocol) - n += 1 + l + sovGenerated(uint64(l)) - n += 1 + sovGenerated(uint64(m.Port)) - if m.Encoding != nil { - l = len(*m.Encoding) - n += 1 + l + sovGenerated(uint64(l)) +func (this *SchemaRepositoryStatus) String() string { + if this == nil { + return "nil" } - if m.PreferredNetconfVersion != nil { - l = len(*m.PreferredNetconfVersion) - n += 1 + l + sovGenerated(uint64(l)) + s := strings.Join([]string{`&SchemaRepositoryStatus{`, + `RepoURL:` + fmt.Sprintf("%v", this.RepoURL) + `,`, + `Reference:` + fmt.Sprintf("%v", this.Reference) + `,`, + `}`, + }, "") + return s +} +func (this *SchemaSpec) String() string { + if this == nil { + return "nil" } - if m.Insecure != nil { - n += 2 + repeatedStringForRepositories := "[]*SchemaSpecRepository{" + for _, f := range this.Repositories { + repeatedStringForRepositories += strings.Replace(f.String(), "SchemaSpecRepository", "SchemaSpecRepository", 1) + "," } - if m.SkipVerify != nil { - n += 2 - } - if m.IncludeNS != nil { - n += 2 + repeatedStringForRepositories += "}" + s := strings.Join([]string{`&SchemaSpec{`, + `Provider:` + fmt.Sprintf("%v", this.Provider) + `,`, + `Version:` + fmt.Sprintf("%v", this.Version) + `,`, + `Repositories:` + repeatedStringForRepositories + `,`, + `}`, + }, "") + return s +} +func (this *SchemaSpecRepository) String() string { + if this == nil { + return "nil" } - if m.OperationWithNS != nil { - n += 2 + repeatedStringForDirs := "[]SrcDstPath{" + for _, f := range this.Dirs { + repeatedStringForDirs += strings.Replace(strings.Replace(f.String(), "SrcDstPath", "SrcDstPath", 1), `&`, ``, 1) + "," } - if m.UseOperationRemove != nil { - n += 2 + repeatedStringForDirs += "}" + s := strings.Join([]string{`&SchemaSpecRepository{`, + `Dirs:` + repeatedStringForDirs + `,`, + `Schema:` + strings.Replace(strings.Replace(this.Schema.String(), "SchemaSpecSchema", "SchemaSpecSchema", 1), `&`, ``, 1) + `,`, + `Repository:` + strings.Replace(strings.Replace(this.Repository.String(), "Repository", "Repository", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func (this *SchemaSpecSchema) String() string { + if this == nil { + return "nil" } - if m.CommitCandidate != nil { - l = len(*m.CommitCandidate) - n += 1 + l + sovGenerated(uint64(l)) + s := strings.Join([]string{`&SchemaSpecSchema{`, + `Models:` + fmt.Sprintf("%v", this.Models) + `,`, + `Includes:` + fmt.Sprintf("%v", this.Includes) + `,`, + `Excludes:` + fmt.Sprintf("%v", this.Excludes) + `,`, + `}`, + }, "") + return s +} +func (this *SchemaStatus) String() string { + if this == nil { + return "nil" } - if m.TargetName != nil { - l = len(*m.TargetName) - n += 1 + l + sovGenerated(uint64(l)) + repeatedStringForRepositories := "[]SchemaRepositoryStatus{" + for _, f := range this.Repositories { + repeatedStringForRepositories += strings.Replace(strings.Replace(f.String(), "SchemaRepositoryStatus", "SchemaRepositoryStatus", 1), `&`, ``, 1) + "," } - return n + repeatedStringForRepositories += "}" + s := strings.Join([]string{`&SchemaStatus{`, + `ConditionedStatus:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ConditionedStatus), "ConditionedStatus", "v1alpha1.ConditionedStatus", 1), `&`, ``, 1) + `,`, + `Repositories:` + repeatedStringForRepositories + `,`, + `}`, + }, "") + return s } - -func (m *TargetList) Size() (n int) { - if m == nil { - return 0 - } - var l int - _ = l - l = m.ListMeta.Size() - n += 1 + l + sovGenerated(uint64(l)) - if len(m.Items) > 0 { - for _, e := range m.Items { - l = e.Size() - n += 1 + l + sovGenerated(uint64(l)) - } +func (this *SrcDstPath) String() string { + if this == nil { + return "nil" } - return n + s := strings.Join([]string{`&SrcDstPath{`, + `Src:` + fmt.Sprintf("%v", this.Src) + `,`, + `Dst:` + fmt.Sprintf("%v", this.Dst) + `,`, + `}`, + }, "") + return s } - -func (m *TargetProfile) Size() (n int) { - if m == nil { - return 0 +func (this *Subscription) String() string { + if this == nil { + return "nil" } - var l int - _ = l - l = len(m.Credentials) - n += 1 + l + sovGenerated(uint64(l)) - if m.TLSSecret != nil { - l = len(*m.TLSSecret) - n += 1 + l + sovGenerated(uint64(l)) + s := strings.Join([]string{`&Subscription{`, + `ObjectMeta:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ObjectMeta), "ObjectMeta", "v1.ObjectMeta", 1), `&`, ``, 1) + `,`, + `Spec:` + strings.Replace(strings.Replace(this.Spec.String(), "SubscriptionSpec", "SubscriptionSpec", 1), `&`, ``, 1) + `,`, + `Status:` + strings.Replace(strings.Replace(this.Status.String(), "SubscriptionStatus", "SubscriptionStatus", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func (this *SubscriptionList) String() string { + if this == nil { + return "nil" } - l = len(m.ConnectionProfile) - n += 1 + l + sovGenerated(uint64(l)) - if m.SyncProfile != nil { - l = len(*m.SyncProfile) - n += 1 + l + sovGenerated(uint64(l)) + repeatedStringForItems := "[]Subscription{" + for _, f := range this.Items { + repeatedStringForItems += strings.Replace(strings.Replace(f.String(), "Subscription", "Subscription", 1), `&`, ``, 1) + "," } - return n + repeatedStringForItems += "}" + s := strings.Join([]string{`&SubscriptionList{`, + `ListMeta:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ListMeta), "ListMeta", "v1.ListMeta", 1), `&`, ``, 1) + `,`, + `Items:` + repeatedStringForItems + `,`, + `}`, + }, "") + return s } - -func (m *TargetSpec) Size() (n int) { - if m == nil { - return 0 +func (this *SubscriptionParameters) String() string { + if this == nil { + return "nil" } - var l int - _ = l - l = len(m.Provider) - n += 1 + l + sovGenerated(uint64(l)) - l = len(m.Address) - n += 1 + l + sovGenerated(uint64(l)) - l = m.TargetProfile.Size() - n += 1 + l + sovGenerated(uint64(l)) - return n + keysForLabels := make([]string, 0, len(this.Labels)) + for k := range this.Labels { + keysForLabels = append(keysForLabels, k) + } + sort.Strings(keysForLabels) + mapStringForLabels := "map[string]string{" + for _, k := range keysForLabels { + mapStringForLabels += fmt.Sprintf("%v: %v,", k, this.Labels[k]) + } + mapStringForLabels += "}" + s := strings.Join([]string{`&SubscriptionParameters{`, + `Name:` + fmt.Sprintf("%v", this.Name) + `,`, + `Description:` + valueToStringGenerated(this.Description) + `,`, + `Labels:` + mapStringForLabels + `,`, + `AdminState:` + valueToStringGenerated(this.AdminState) + `,`, + `Mode:` + fmt.Sprintf("%v", this.Mode) + `,`, + `Interval:` + strings.Replace(fmt.Sprintf("%v", this.Interval), "Duration", "v1.Duration", 1) + `,`, + `Paths:` + fmt.Sprintf("%v", this.Paths) + `,`, + `}`, + }, "") + return s } - -func (m *TargetStatus) Size() (n int) { - if m == nil { - return 0 +func (this *SubscriptionSpec) String() string { + if this == nil { + return "nil" } - var l int - _ = l - l = m.ConditionedStatus.Size() - n += 1 + l + sovGenerated(uint64(l)) - if m.DiscoveryInfo != nil { - l = m.DiscoveryInfo.Size() - n += 1 + l + sovGenerated(uint64(l)) + repeatedStringForSubscriptions := "[]SubscriptionParameters{" + for _, f := range this.Subscriptions { + repeatedStringForSubscriptions += strings.Replace(strings.Replace(f.String(), "SubscriptionParameters", "SubscriptionParameters", 1), `&`, ``, 1) + "," } - if m.UsedReferences != nil { - l = m.UsedReferences.Size() - n += 1 + l + sovGenerated(uint64(l)) + repeatedStringForSubscriptions += "}" + s := strings.Join([]string{`&SubscriptionSpec{`, + `Target:` + strings.Replace(strings.Replace(this.Target.String(), "SubscriptionTarget", "SubscriptionTarget", 1), `&`, ``, 1) + `,`, + `Protocol:` + fmt.Sprintf("%v", this.Protocol) + `,`, + `Port:` + fmt.Sprintf("%v", this.Port) + `,`, + `Encoding:` + valueToStringGenerated(this.Encoding) + `,`, + `Subscriptions:` + repeatedStringForSubscriptions + `,`, + `}`, + }, "") + return s +} +func (this *SubscriptionStatus) String() string { + if this == nil { + return "nil" } - return n + s := strings.Join([]string{`&SubscriptionStatus{`, + `ConditionedStatus:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ConditionedStatus), "ConditionedStatus", "v1alpha1.ConditionedStatus", 1), `&`, ``, 1) + `,`, + `Targets:` + fmt.Sprintf("%v", this.Targets) + `,`, + `}`, + }, "") + return s } - -func (m *TargetStatusUsedReferences) Size() (n int) { - if m == nil { - return 0 +func (this *SubscriptionTarget) String() string { + if this == nil { + return "nil" } - var l int - _ = l - l = len(m.SecretResourceVersion) - n += 1 + l + sovGenerated(uint64(l)) - l = len(m.TLSSecretResourceVersion) - n += 1 + l + sovGenerated(uint64(l)) - l = len(m.ConnectionProfileResourceVersion) - n += 1 + l + sovGenerated(uint64(l)) - l = len(m.SyncProfileResourceVersion) - n += 1 + l + sovGenerated(uint64(l)) - return n + s := strings.Join([]string{`&SubscriptionTarget{`, + `TargetSelector:` + strings.Replace(fmt.Sprintf("%v", this.TargetSelector), "LabelSelector", "v1.LabelSelector", 1) + `,`, + `}`, + }, "") + return s } - -func (m *TargetSyncProfile) Size() (n int) { - if m == nil { - return 0 +func (this *TargetConnectionProfile) String() string { + if this == nil { + return "nil" } - var l int - _ = l - l = m.ObjectMeta.Size() - n += 1 + l + sovGenerated(uint64(l)) - l = m.Spec.Size() - n += 1 + l + sovGenerated(uint64(l)) - return n + s := strings.Join([]string{`&TargetConnectionProfile{`, + `ObjectMeta:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ObjectMeta), "ObjectMeta", "v1.ObjectMeta", 1), `&`, ``, 1) + `,`, + `Spec:` + strings.Replace(strings.Replace(this.Spec.String(), "TargetConnectionProfileSpec", "TargetConnectionProfileSpec", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s } - -func (m *TargetSyncProfileList) Size() (n int) { - if m == nil { - return 0 +func (this *TargetConnectionProfileList) String() string { + if this == nil { + return "nil" } - var l int - _ = l - l = m.ListMeta.Size() - n += 1 + l + sovGenerated(uint64(l)) - if len(m.Items) > 0 { - for _, e := range m.Items { - l = e.Size() - n += 1 + l + sovGenerated(uint64(l)) - } + repeatedStringForItems := "[]TargetConnectionProfile{" + for _, f := range this.Items { + repeatedStringForItems += strings.Replace(strings.Replace(f.String(), "TargetConnectionProfile", "TargetConnectionProfile", 1), `&`, ``, 1) + "," } - return n -} - -func (m *TargetSyncProfileSpec) Size() (n int) { - if m == nil { - return 0 - } - var l int - _ = l - n += 2 - n += 1 + sovGenerated(uint64(m.Buffer)) - n += 1 + sovGenerated(uint64(m.Workers)) - if len(m.Sync) > 0 { - for _, e := range m.Sync { - l = e.Size() - n += 1 + l + sovGenerated(uint64(l)) - } - } - return n -} - -func (m *TargetSyncProfileSync) Size() (n int) { - if m == nil { - return 0 - } - var l int - _ = l - l = len(m.Name) - n += 1 + l + sovGenerated(uint64(l)) - l = len(m.Protocol) - n += 1 + l + sovGenerated(uint64(l)) - n += 1 + sovGenerated(uint64(m.Port)) - if len(m.Paths) > 0 { - for _, s := range m.Paths { - l = len(s) - n += 1 + l + sovGenerated(uint64(l)) - } - } - l = len(m.Mode) - n += 1 + l + sovGenerated(uint64(l)) - if m.Encoding != nil { - l = len(*m.Encoding) - n += 1 + l + sovGenerated(uint64(l)) - } - l = m.Interval.Size() - n += 1 + l + sovGenerated(uint64(l)) - return n -} - -func (m *TargetTemplate) Size() (n int) { - if m == nil { - return 0 - } - var l int - _ = l - l = len(m.NameTemplate) - n += 1 + l + sovGenerated(uint64(l)) - if len(m.Annotations) > 0 { - for k, v := range m.Annotations { - _ = k - _ = v - mapEntrySize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + len(v) + sovGenerated(uint64(len(v))) - n += mapEntrySize + 1 + sovGenerated(uint64(mapEntrySize)) - } - } - if len(m.Labels) > 0 { - for k, v := range m.Labels { - _ = k - _ = v - mapEntrySize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + len(v) + sovGenerated(uint64(len(v))) - n += mapEntrySize + 1 + sovGenerated(uint64(mapEntrySize)) - } - } - return n -} - -func (m *Workspace) Size() (n int) { - if m == nil { - return 0 - } - var l int - _ = l - l = m.ObjectMeta.Size() - n += 1 + l + sovGenerated(uint64(l)) - l = m.Spec.Size() - n += 1 + l + sovGenerated(uint64(l)) - l = m.Status.Size() - n += 1 + l + sovGenerated(uint64(l)) - return n -} - -func (m *WorkspaceList) Size() (n int) { - if m == nil { - return 0 - } - var l int - _ = l - l = m.ListMeta.Size() - n += 1 + l + sovGenerated(uint64(l)) - if len(m.Items) > 0 { - for _, e := range m.Items { - l = e.Size() - n += 1 + l + sovGenerated(uint64(l)) - } - } - return n -} - -func (m *WorkspaceSpec) Size() (n int) { - if m == nil { - return 0 - } - var l int - _ = l - l = m.Repository.Size() - n += 1 + l + sovGenerated(uint64(l)) - return n -} - -func (m *WorkspaceStatus) Size() (n int) { - if m == nil { - return 0 - } - var l int - _ = l - l = m.ConditionedStatus.Size() - n += 1 + l + sovGenerated(uint64(l)) - if m.Kind != nil { - l = len(*m.Kind) - n += 1 + l + sovGenerated(uint64(l)) - } - if m.DeployedRef != nil { - l = len(*m.DeployedRef) - n += 1 + l + sovGenerated(uint64(l)) - } - return n -} - -func sovGenerated(x uint64) (n int) { - return (math_bits.Len64(x|1) + 6) / 7 -} -func sozGenerated(x uint64) (n int) { - return sovGenerated(uint64((x << 1) ^ uint64((int64(x) >> 63)))) -} -func (this *DiscoveryInfo) String() string { - if this == nil { - return "nil" - } - s := strings.Join([]string{`&DiscoveryInfo{`, - `Protocol:` + fmt.Sprintf("%v", this.Protocol) + `,`, - `Provider:` + fmt.Sprintf("%v", this.Provider) + `,`, - `Version:` + fmt.Sprintf("%v", this.Version) + `,`, - `HostName:` + fmt.Sprintf("%v", this.Hostname) + `,`, - `Platform:` + fmt.Sprintf("%v", this.Platform) + `,`, - `MacAddress:` + fmt.Sprintf("%v", this.MacAddress) + `,`, - `SerialNumber:` + fmt.Sprintf("%v", this.SerialNumber) + `,`, - `SupportedEncodings:` + fmt.Sprintf("%v", this.SupportedEncodings) + `,`, - `}`, - }, "") - return s -} -func (this *DiscoveryParameters) String() string { - if this == nil { - return "nil" - } - repeatedStringForTargetConnectionProfiles := "[]TargetProfile{" - for _, f := range this.TargetConnectionProfiles { - repeatedStringForTargetConnectionProfiles += strings.Replace(strings.Replace(f.String(), "TargetProfile", "TargetProfile", 1), `&`, ``, 1) + "," - } - repeatedStringForTargetConnectionProfiles += "}" - s := strings.Join([]string{`&DiscoveryParameters{`, - `DefaultSchema:` + strings.Replace(this.DefaultSchema.String(), "SchemaKey", "SchemaKey", 1) + `,`, - `DiscoveryProfile:` + strings.Replace(this.DiscoveryProfile.String(), "DiscoveryProfile", "DiscoveryProfile", 1) + `,`, - `TargetConnectionProfiles:` + repeatedStringForTargetConnectionProfiles + `,`, - `TargetTemplate:` + strings.Replace(this.TargetTemplate.String(), "TargetTemplate", "TargetTemplate", 1) + `,`, - `Period:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Period), "Duration", "v1.Duration", 1), `&`, ``, 1) + `,`, - `ConcurrentScans:` + fmt.Sprintf("%v", this.ConcurrentScans) + `,`, + repeatedStringForItems += "}" + s := strings.Join([]string{`&TargetConnectionProfileList{`, + `ListMeta:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ListMeta), "ListMeta", "v1.ListMeta", 1), `&`, ``, 1) + `,`, + `Items:` + repeatedStringForItems + `,`, `}`, }, "") return s } -func (this *DiscoveryPathDefinition) String() string { +func (this *TargetConnectionProfileSpec) String() string { if this == nil { return "nil" } - s := strings.Join([]string{`&DiscoveryPathDefinition{`, - `Key:` + fmt.Sprintf("%v", this.Key) + `,`, - `Path:` + fmt.Sprintf("%v", this.Path) + `,`, - `Script:` + valueToStringGenerated(this.Script) + `,`, - `Regex:` + valueToStringGenerated(this.Regex) + `,`, + s := strings.Join([]string{`&TargetConnectionProfileSpec{`, + `ConnectRetry:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ConnectRetry), "Duration", "v1.Duration", 1), `&`, ``, 1) + `,`, + `Timeout:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Timeout), "Duration", "v1.Duration", 1), `&`, ``, 1) + `,`, + `Protocol:` + fmt.Sprintf("%v", this.Protocol) + `,`, + `Port:` + fmt.Sprintf("%v", this.Port) + `,`, + `Encoding:` + valueToStringGenerated(this.Encoding) + `,`, + `PreferredNetconfVersion:` + valueToStringGenerated(this.PreferredNetconfVersion) + `,`, + `Insecure:` + valueToStringGenerated(this.Insecure) + `,`, + `SkipVerify:` + valueToStringGenerated(this.SkipVerify) + `,`, + `IncludeNS:` + valueToStringGenerated(this.IncludeNS) + `,`, + `OperationWithNS:` + valueToStringGenerated(this.OperationWithNS) + `,`, + `UseOperationRemove:` + valueToStringGenerated(this.UseOperationRemove) + `,`, + `CommitCandidate:` + valueToStringGenerated(this.CommitCandidate) + `,`, + `TargetName:` + valueToStringGenerated(this.TargetName) + `,`, `}`, }, "") return s } -func (this *DiscoveryProfile) String() string { +func (this *TargetProfile) String() string { if this == nil { return "nil" } - s := strings.Join([]string{`&DiscoveryProfile{`, + s := strings.Join([]string{`&TargetProfile{`, `Credentials:` + fmt.Sprintf("%v", this.Credentials) + `,`, `TLSSecret:` + valueToStringGenerated(this.TLSSecret) + `,`, - `ConnectionProfiles:` + fmt.Sprintf("%v", this.ConnectionProfiles) + `,`, + `ConnectionProfile:` + fmt.Sprintf("%v", this.ConnectionProfile) + `,`, + `SyncProfile:` + valueToStringGenerated(this.SyncProfile) + `,`, `}`, }, "") return s } -func (this *DiscoveryRule) String() string { +func (this *TargetSyncProfile) String() string { if this == nil { return "nil" } - s := strings.Join([]string{`&DiscoveryRule{`, + s := strings.Join([]string{`&TargetSyncProfile{`, `ObjectMeta:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ObjectMeta), "ObjectMeta", "v1.ObjectMeta", 1), `&`, ``, 1) + `,`, - `Spec:` + strings.Replace(strings.Replace(this.Spec.String(), "DiscoveryRuleSpec", "DiscoveryRuleSpec", 1), `&`, ``, 1) + `,`, - `Status:` + strings.Replace(strings.Replace(this.Status.String(), "DiscoveryRuleStatus", "DiscoveryRuleStatus", 1), `&`, ``, 1) + `,`, - `}`, - }, "") - return s -} -func (this *DiscoveryRuleAddress) String() string { - if this == nil { - return "nil" - } - s := strings.Join([]string{`&DiscoveryRuleAddress{`, - `Address:` + fmt.Sprintf("%v", this.Address) + `,`, - `HostName:` + fmt.Sprintf("%v", this.HostName) + `,`, + `Spec:` + strings.Replace(strings.Replace(this.Spec.String(), "TargetSyncProfileSpec", "TargetSyncProfileSpec", 1), `&`, ``, 1) + `,`, `}`, }, "") return s } -func (this *DiscoveryRuleList) String() string { +func (this *TargetSyncProfileList) String() string { if this == nil { return "nil" } - repeatedStringForItems := "[]DiscoveryRule{" + repeatedStringForItems := "[]TargetSyncProfile{" for _, f := range this.Items { - repeatedStringForItems += strings.Replace(strings.Replace(f.String(), "DiscoveryRule", "DiscoveryRule", 1), `&`, ``, 1) + "," + repeatedStringForItems += strings.Replace(strings.Replace(f.String(), "TargetSyncProfile", "TargetSyncProfile", 1), `&`, ``, 1) + "," } repeatedStringForItems += "}" - s := strings.Join([]string{`&DiscoveryRuleList{`, + s := strings.Join([]string{`&TargetSyncProfileList{`, `ListMeta:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ListMeta), "ListMeta", "v1.ListMeta", 1), `&`, ``, 1) + `,`, `Items:` + repeatedStringForItems + `,`, `}`, }, "") return s } -func (this *DiscoveryRulePrefix) String() string { - if this == nil { - return "nil" - } - s := strings.Join([]string{`&DiscoveryRulePrefix{`, - `Prefix:` + fmt.Sprintf("%v", this.Prefix) + `,`, - `Excludes:` + fmt.Sprintf("%v", this.Excludes) + `,`, - `}`, - }, "") - return s -} -func (this *DiscoveryRuleSpec) String() string { +func (this *TargetSyncProfileSpec) String() string { if this == nil { return "nil" } - repeatedStringForPrefixes := "[]DiscoveryRulePrefix{" - for _, f := range this.Prefixes { - repeatedStringForPrefixes += strings.Replace(strings.Replace(f.String(), "DiscoveryRulePrefix", "DiscoveryRulePrefix", 1), `&`, ``, 1) + "," - } - repeatedStringForPrefixes += "}" - repeatedStringForAddresses := "[]DiscoveryRuleAddress{" - for _, f := range this.Addresses { - repeatedStringForAddresses += strings.Replace(strings.Replace(f.String(), "DiscoveryRuleAddress", "DiscoveryRuleAddress", 1), `&`, ``, 1) + "," - } - repeatedStringForAddresses += "}" - s := strings.Join([]string{`&DiscoveryRuleSpec{`, - `Prefixes:` + repeatedStringForPrefixes + `,`, - `Addresses:` + repeatedStringForAddresses + `,`, - `PodSelector:` + strings.Replace(fmt.Sprintf("%v", this.PodSelector), "LabelSelector", "v1.LabelSelector", 1) + `,`, - `ServiceSelector:` + strings.Replace(fmt.Sprintf("%v", this.ServiceSelector), "LabelSelector", "v1.LabelSelector", 1) + `,`, - `ServiceDomain:` + fmt.Sprintf("%v", this.ServiceDomain) + `,`, - `DiscoveryParameters:` + strings.Replace(strings.Replace(this.DiscoveryParameters.String(), "DiscoveryParameters", "DiscoveryParameters", 1), `&`, ``, 1) + `,`, - `}`, - }, "") - return s -} -func (this *DiscoveryRuleStatus) String() string { - if this == nil { - return "nil" - } - s := strings.Join([]string{`&DiscoveryRuleStatus{`, - `ConditionedStatus:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ConditionedStatus), "ConditionedStatus", "v1alpha1.ConditionedStatus", 1), `&`, ``, 1) + `,`, - `StartTime:` + strings.Replace(fmt.Sprintf("%v", this.StartTime), "Time", "v1.Time", 1) + `,`, - `}`, - }, "") - return s -} -func (this *DiscoveryVendorProfile) String() string { - if this == nil { - return "nil" - } - s := strings.Join([]string{`&DiscoveryVendorProfile{`, - `ObjectMeta:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ObjectMeta), "ObjectMeta", "v1.ObjectMeta", 1), `&`, ``, 1) + `,`, - `Spec:` + strings.Replace(strings.Replace(this.Spec.String(), "DiscoveryVendorProfileSpec", "DiscoveryVendorProfileSpec", 1), `&`, ``, 1) + `,`, - `}`, - }, "") - return s -} -func (this *DiscoveryVendorProfileList) String() string { - if this == nil { - return "nil" - } - repeatedStringForItems := "[]DiscoveryVendorProfile{" - for _, f := range this.Items { - repeatedStringForItems += strings.Replace(strings.Replace(f.String(), "DiscoveryVendorProfile", "DiscoveryVendorProfile", 1), `&`, ``, 1) + "," - } - repeatedStringForItems += "}" - s := strings.Join([]string{`&DiscoveryVendorProfileList{`, - `ListMeta:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ListMeta), "ListMeta", "v1.ListMeta", 1), `&`, ``, 1) + `,`, - `Items:` + repeatedStringForItems + `,`, - `}`, - }, "") - return s -} -func (this *DiscoveryVendorProfileSpec) String() string { - if this == nil { - return "nil" - } - s := strings.Join([]string{`&DiscoveryVendorProfileSpec{`, - `Gnmi:` + strings.Replace(strings.Replace(this.Gnmi.String(), "GnmiDiscoveryVendorProfileParameters", "GnmiDiscoveryVendorProfileParameters", 1), `&`, ``, 1) + `,`, - `}`, - }, "") - return s -} -func (this *GnmiDiscoveryVendorProfileParameters) String() string { - if this == nil { - return "nil" - } - repeatedStringForPaths := "[]DiscoveryPathDefinition{" - for _, f := range this.Paths { - repeatedStringForPaths += strings.Replace(strings.Replace(f.String(), "DiscoveryPathDefinition", "DiscoveryPathDefinition", 1), `&`, ``, 1) + "," - } - repeatedStringForPaths += "}" - s := strings.Join([]string{`&GnmiDiscoveryVendorProfileParameters{`, - `Organization:` + fmt.Sprintf("%v", this.Organization) + `,`, - `ModelMatch:` + valueToStringGenerated(this.ModelMatch) + `,`, - `Paths:` + repeatedStringForPaths + `,`, - `Encoding:` + valueToStringGenerated(this.Encoding) + `,`, - `PreserveNamespace:` + valueToStringGenerated(this.PreserveNamespace) + `,`, - `}`, - }, "") - return s -} -func (this *Proxy) String() string { - if this == nil { - return "nil" - } - s := strings.Join([]string{`&Proxy{`, - `URL:` + fmt.Sprintf("%v", this.URL) + `,`, - `Credentials:` + fmt.Sprintf("%v", this.Credentials) + `,`, - `}`, - }, "") - return s -} -func (this *Repository) String() string { - if this == nil { - return "nil" - } - s := strings.Join([]string{`&Repository{`, - `RepositoryURL:` + fmt.Sprintf("%v", this.RepoURL) + `,`, - `Credentials:` + fmt.Sprintf("%v", this.Credentials) + `,`, - `Proxy:` + strings.Replace(this.Proxy.String(), "Proxy", "Proxy", 1) + `,`, - `Kind:` + fmt.Sprintf("%v", this.Kind) + `,`, - `Ref:` + fmt.Sprintf("%v", this.Ref) + `,`, - `}`, - }, "") - return s -} -func (this *Rollout) String() string { - if this == nil { - return "nil" - } - s := strings.Join([]string{`&Rollout{`, - `ObjectMeta:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ObjectMeta), "ObjectMeta", "v1.ObjectMeta", 1), `&`, ``, 1) + `,`, - `Spec:` + strings.Replace(strings.Replace(this.Spec.String(), "RolloutSpec", "RolloutSpec", 1), `&`, ``, 1) + `,`, - `Status:` + strings.Replace(strings.Replace(this.Status.String(), "RolloutStatus", "RolloutStatus", 1), `&`, ``, 1) + `,`, - `}`, - }, "") - return s -} -func (this *RolloutList) String() string { - if this == nil { - return "nil" - } - repeatedStringForItems := "[]Rollout{" - for _, f := range this.Items { - repeatedStringForItems += strings.Replace(strings.Replace(f.String(), "Rollout", "Rollout", 1), `&`, ``, 1) + "," - } - repeatedStringForItems += "}" - s := strings.Join([]string{`&RolloutList{`, - `ListMeta:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ListMeta), "ListMeta", "v1.ListMeta", 1), `&`, ``, 1) + `,`, - `Items:` + repeatedStringForItems + `,`, - `}`, - }, "") - return s -} -func (this *RolloutSpec) String() string { - if this == nil { - return "nil" - } - s := strings.Join([]string{`&RolloutSpec{`, - `Repository:` + strings.Replace(strings.Replace(this.Repository.String(), "Repository", "Repository", 1), `&`, ``, 1) + `,`, - `Strategy:` + fmt.Sprintf("%v", this.Strategy) + `,`, - `SkipUnavailableTarget:` + valueToStringGenerated(this.SkipUnavailableTarget) + `,`, - `}`, - }, "") - return s -} -func (this *RolloutStatus) String() string { - if this == nil { - return "nil" - } - repeatedStringForTargets := "[]RolloutTargetStatus{" - for _, f := range this.Targets { - repeatedStringForTargets += strings.Replace(strings.Replace(f.String(), "RolloutTargetStatus", "RolloutTargetStatus", 1), `&`, ``, 1) + "," - } - repeatedStringForTargets += "}" - s := strings.Join([]string{`&RolloutStatus{`, - `ConditionedStatus:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ConditionedStatus), "ConditionedStatus", "v1alpha1.ConditionedStatus", 1), `&`, ``, 1) + `,`, - `Targets:` + repeatedStringForTargets + `,`, - `}`, - }, "") - return s -} -func (this *RolloutTargetStatus) String() string { - if this == nil { - return "nil" - } - s := strings.Join([]string{`&RolloutTargetStatus{`, - `Name:` + fmt.Sprintf("%v", this.Name) + `,`, - `ConditionedStatus:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ConditionedStatus), "ConditionedStatus", "v1alpha1.ConditionedStatus", 1), `&`, ``, 1) + `,`, - `}`, - }, "") - return s -} -func (this *Schema) String() string { - if this == nil { - return "nil" - } - s := strings.Join([]string{`&Schema{`, - `ObjectMeta:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ObjectMeta), "ObjectMeta", "v1.ObjectMeta", 1), `&`, ``, 1) + `,`, - `Spec:` + strings.Replace(strings.Replace(this.Spec.String(), "SchemaSpec", "SchemaSpec", 1), `&`, ``, 1) + `,`, - `Status:` + strings.Replace(strings.Replace(this.Status.String(), "SchemaStatus", "SchemaStatus", 1), `&`, ``, 1) + `,`, - `}`, - }, "") - return s -} -func (this *SchemaKey) String() string { - if this == nil { - return "nil" - } - s := strings.Join([]string{`&SchemaKey{`, - `Provider:` + fmt.Sprintf("%v", this.Provider) + `,`, - `Version:` + fmt.Sprintf("%v", this.Version) + `,`, - `}`, - }, "") - return s -} -func (this *SchemaList) String() string { - if this == nil { - return "nil" - } - repeatedStringForItems := "[]Schema{" - for _, f := range this.Items { - repeatedStringForItems += strings.Replace(strings.Replace(f.String(), "Schema", "Schema", 1), `&`, ``, 1) + "," - } - repeatedStringForItems += "}" - s := strings.Join([]string{`&SchemaList{`, - `ListMeta:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ListMeta), "ListMeta", "v1.ListMeta", 1), `&`, ``, 1) + `,`, - `Items:` + repeatedStringForItems + `,`, - `}`, - }, "") - return s -} -func (this *SchemaRepositoryStatus) String() string { - if this == nil { - return "nil" - } - s := strings.Join([]string{`&SchemaRepositoryStatus{`, - `RepoURL:` + fmt.Sprintf("%v", this.RepoURL) + `,`, - `Reference:` + fmt.Sprintf("%v", this.Reference) + `,`, - `}`, - }, "") - return s -} -func (this *SchemaSpec) String() string { - if this == nil { - return "nil" - } - repeatedStringForRepositories := "[]*SchemaSpecRepository{" - for _, f := range this.Repositories { - repeatedStringForRepositories += strings.Replace(f.String(), "SchemaSpecRepository", "SchemaSpecRepository", 1) + "," - } - repeatedStringForRepositories += "}" - s := strings.Join([]string{`&SchemaSpec{`, - `Provider:` + fmt.Sprintf("%v", this.Provider) + `,`, - `Version:` + fmt.Sprintf("%v", this.Version) + `,`, - `Repositories:` + repeatedStringForRepositories + `,`, - `}`, - }, "") - return s -} -func (this *SchemaSpecRepository) String() string { - if this == nil { - return "nil" - } - repeatedStringForDirs := "[]SrcDstPath{" - for _, f := range this.Dirs { - repeatedStringForDirs += strings.Replace(strings.Replace(f.String(), "SrcDstPath", "SrcDstPath", 1), `&`, ``, 1) + "," - } - repeatedStringForDirs += "}" - s := strings.Join([]string{`&SchemaSpecRepository{`, - `Dirs:` + repeatedStringForDirs + `,`, - `Schema:` + strings.Replace(strings.Replace(this.Schema.String(), "SchemaSpecSchema", "SchemaSpecSchema", 1), `&`, ``, 1) + `,`, - `Repository:` + strings.Replace(strings.Replace(this.Repository.String(), "Repository", "Repository", 1), `&`, ``, 1) + `,`, - `}`, - }, "") - return s -} -func (this *SchemaSpecSchema) String() string { - if this == nil { - return "nil" - } - s := strings.Join([]string{`&SchemaSpecSchema{`, - `Models:` + fmt.Sprintf("%v", this.Models) + `,`, - `Includes:` + fmt.Sprintf("%v", this.Includes) + `,`, - `Excludes:` + fmt.Sprintf("%v", this.Excludes) + `,`, - `}`, - }, "") - return s -} -func (this *SchemaStatus) String() string { - if this == nil { - return "nil" - } - repeatedStringForRepositories := "[]SchemaRepositoryStatus{" - for _, f := range this.Repositories { - repeatedStringForRepositories += strings.Replace(strings.Replace(f.String(), "SchemaRepositoryStatus", "SchemaRepositoryStatus", 1), `&`, ``, 1) + "," - } - repeatedStringForRepositories += "}" - s := strings.Join([]string{`&SchemaStatus{`, - `ConditionedStatus:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ConditionedStatus), "ConditionedStatus", "v1alpha1.ConditionedStatus", 1), `&`, ``, 1) + `,`, - `Repositories:` + repeatedStringForRepositories + `,`, - `}`, - }, "") - return s -} -func (this *SrcDstPath) String() string { - if this == nil { - return "nil" - } - s := strings.Join([]string{`&SrcDstPath{`, - `Src:` + fmt.Sprintf("%v", this.Src) + `,`, - `Dst:` + fmt.Sprintf("%v", this.Dst) + `,`, - `}`, - }, "") - return s -} -func (this *Subscription) String() string { - if this == nil { - return "nil" - } - s := strings.Join([]string{`&Subscription{`, - `ObjectMeta:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ObjectMeta), "ObjectMeta", "v1.ObjectMeta", 1), `&`, ``, 1) + `,`, - `Spec:` + strings.Replace(strings.Replace(this.Spec.String(), "SubscriptionSpec", "SubscriptionSpec", 1), `&`, ``, 1) + `,`, - `Status:` + strings.Replace(strings.Replace(this.Status.String(), "SubscriptionStatus", "SubscriptionStatus", 1), `&`, ``, 1) + `,`, - `}`, - }, "") - return s -} -func (this *SubscriptionList) String() string { - if this == nil { - return "nil" - } - repeatedStringForItems := "[]Subscription{" - for _, f := range this.Items { - repeatedStringForItems += strings.Replace(strings.Replace(f.String(), "Subscription", "Subscription", 1), `&`, ``, 1) + "," - } - repeatedStringForItems += "}" - s := strings.Join([]string{`&SubscriptionList{`, - `ListMeta:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ListMeta), "ListMeta", "v1.ListMeta", 1), `&`, ``, 1) + `,`, - `Items:` + repeatedStringForItems + `,`, - `}`, - }, "") - return s -} -func (this *SubscriptionParameters) String() string { - if this == nil { - return "nil" - } - keysForLabels := make([]string, 0, len(this.Labels)) - for k := range this.Labels { - keysForLabels = append(keysForLabels, k) - } - github_com_gogo_protobuf_sortkeys.Strings(keysForLabels) - mapStringForLabels := "map[string]string{" - for _, k := range keysForLabels { - mapStringForLabels += fmt.Sprintf("%v: %v,", k, this.Labels[k]) - } - mapStringForLabels += "}" - s := strings.Join([]string{`&SubscriptionParameters{`, - `Name:` + fmt.Sprintf("%v", this.Name) + `,`, - `Description:` + valueToStringGenerated(this.Description) + `,`, - `Labels:` + mapStringForLabels + `,`, - `AdminState:` + valueToStringGenerated(this.AdminState) + `,`, - `Mode:` + fmt.Sprintf("%v", this.Mode) + `,`, - `Interval:` + strings.Replace(fmt.Sprintf("%v", this.Interval), "Duration", "v1.Duration", 1) + `,`, - `Paths:` + fmt.Sprintf("%v", this.Paths) + `,`, - `}`, - }, "") - return s -} -func (this *SubscriptionSpec) String() string { - if this == nil { - return "nil" - } - repeatedStringForSubscriptions := "[]SubscriptionParameters{" - for _, f := range this.Subscriptions { - repeatedStringForSubscriptions += strings.Replace(strings.Replace(f.String(), "SubscriptionParameters", "SubscriptionParameters", 1), `&`, ``, 1) + "," - } - repeatedStringForSubscriptions += "}" - s := strings.Join([]string{`&SubscriptionSpec{`, - `Target:` + strings.Replace(strings.Replace(this.Target.String(), "SubscriptionTarget", "SubscriptionTarget", 1), `&`, ``, 1) + `,`, - `Protocol:` + fmt.Sprintf("%v", this.Protocol) + `,`, - `Port:` + fmt.Sprintf("%v", this.Port) + `,`, - `Encoding:` + valueToStringGenerated(this.Encoding) + `,`, - `Subscriptions:` + repeatedStringForSubscriptions + `,`, - `}`, - }, "") - return s -} -func (this *SubscriptionStatus) String() string { - if this == nil { - return "nil" - } - s := strings.Join([]string{`&SubscriptionStatus{`, - `ConditionedStatus:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ConditionedStatus), "ConditionedStatus", "v1alpha1.ConditionedStatus", 1), `&`, ``, 1) + `,`, - `Targets:` + fmt.Sprintf("%v", this.Targets) + `,`, - `}`, - }, "") - return s -} -func (this *SubscriptionTarget) String() string { - if this == nil { - return "nil" - } - s := strings.Join([]string{`&SubscriptionTarget{`, - `TargetSelector:` + strings.Replace(fmt.Sprintf("%v", this.TargetSelector), "LabelSelector", "v1.LabelSelector", 1) + `,`, - `}`, - }, "") - return s -} -func (this *Target) String() string { - if this == nil { - return "nil" - } - s := strings.Join([]string{`&Target{`, - `ObjectMeta:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ObjectMeta), "ObjectMeta", "v1.ObjectMeta", 1), `&`, ``, 1) + `,`, - `Spec:` + strings.Replace(strings.Replace(this.Spec.String(), "TargetSpec", "TargetSpec", 1), `&`, ``, 1) + `,`, - `Status:` + strings.Replace(strings.Replace(this.Status.String(), "TargetStatus", "TargetStatus", 1), `&`, ``, 1) + `,`, - `}`, - }, "") - return s -} -func (this *TargetConnectionProfile) String() string { - if this == nil { - return "nil" - } - s := strings.Join([]string{`&TargetConnectionProfile{`, - `ObjectMeta:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ObjectMeta), "ObjectMeta", "v1.ObjectMeta", 1), `&`, ``, 1) + `,`, - `Spec:` + strings.Replace(strings.Replace(this.Spec.String(), "TargetConnectionProfileSpec", "TargetConnectionProfileSpec", 1), `&`, ``, 1) + `,`, - `}`, - }, "") - return s -} -func (this *TargetConnectionProfileList) String() string { - if this == nil { - return "nil" - } - repeatedStringForItems := "[]TargetConnectionProfile{" - for _, f := range this.Items { - repeatedStringForItems += strings.Replace(strings.Replace(f.String(), "TargetConnectionProfile", "TargetConnectionProfile", 1), `&`, ``, 1) + "," - } - repeatedStringForItems += "}" - s := strings.Join([]string{`&TargetConnectionProfileList{`, - `ListMeta:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ListMeta), "ListMeta", "v1.ListMeta", 1), `&`, ``, 1) + `,`, - `Items:` + repeatedStringForItems + `,`, - `}`, - }, "") - return s -} -func (this *TargetConnectionProfileSpec) String() string { - if this == nil { - return "nil" - } - s := strings.Join([]string{`&TargetConnectionProfileSpec{`, - `ConnectRetry:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ConnectRetry), "Duration", "v1.Duration", 1), `&`, ``, 1) + `,`, - `Timeout:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Timeout), "Duration", "v1.Duration", 1), `&`, ``, 1) + `,`, - `Protocol:` + fmt.Sprintf("%v", this.Protocol) + `,`, - `Port:` + fmt.Sprintf("%v", this.Port) + `,`, - `Encoding:` + valueToStringGenerated(this.Encoding) + `,`, - `PreferredNetconfVersion:` + valueToStringGenerated(this.PreferredNetconfVersion) + `,`, - `Insecure:` + valueToStringGenerated(this.Insecure) + `,`, - `SkipVerify:` + valueToStringGenerated(this.SkipVerify) + `,`, - `IncludeNS:` + valueToStringGenerated(this.IncludeNS) + `,`, - `OperationWithNS:` + valueToStringGenerated(this.OperationWithNS) + `,`, - `UseOperationRemove:` + valueToStringGenerated(this.UseOperationRemove) + `,`, - `CommitCandidate:` + valueToStringGenerated(this.CommitCandidate) + `,`, - `TargetName:` + valueToStringGenerated(this.TargetName) + `,`, - `}`, - }, "") - return s -} -func (this *TargetList) String() string { - if this == nil { - return "nil" - } - repeatedStringForItems := "[]Target{" - for _, f := range this.Items { - repeatedStringForItems += strings.Replace(strings.Replace(f.String(), "Target", "Target", 1), `&`, ``, 1) + "," - } - repeatedStringForItems += "}" - s := strings.Join([]string{`&TargetList{`, - `ListMeta:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ListMeta), "ListMeta", "v1.ListMeta", 1), `&`, ``, 1) + `,`, - `Items:` + repeatedStringForItems + `,`, - `}`, - }, "") - return s -} -func (this *TargetProfile) String() string { - if this == nil { - return "nil" - } - s := strings.Join([]string{`&TargetProfile{`, - `Credentials:` + fmt.Sprintf("%v", this.Credentials) + `,`, - `TLSSecret:` + valueToStringGenerated(this.TLSSecret) + `,`, - `ConnectionProfile:` + fmt.Sprintf("%v", this.ConnectionProfile) + `,`, - `SyncProfile:` + valueToStringGenerated(this.SyncProfile) + `,`, - `}`, - }, "") - return s -} -func (this *TargetSpec) String() string { - if this == nil { - return "nil" - } - s := strings.Join([]string{`&TargetSpec{`, - `Provider:` + fmt.Sprintf("%v", this.Provider) + `,`, - `Address:` + fmt.Sprintf("%v", this.Address) + `,`, - `TargetProfile:` + strings.Replace(strings.Replace(this.TargetProfile.String(), "TargetProfile", "TargetProfile", 1), `&`, ``, 1) + `,`, - `}`, - }, "") - return s -} -func (this *TargetStatus) String() string { - if this == nil { - return "nil" - } - s := strings.Join([]string{`&TargetStatus{`, - `ConditionedStatus:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ConditionedStatus), "ConditionedStatus", "v1alpha1.ConditionedStatus", 1), `&`, ``, 1) + `,`, - `DiscoveryInfo:` + strings.Replace(this.DiscoveryInfo.String(), "DiscoveryInfo", "DiscoveryInfo", 1) + `,`, - `UsedReferences:` + strings.Replace(this.UsedReferences.String(), "TargetStatusUsedReferences", "TargetStatusUsedReferences", 1) + `,`, - `}`, - }, "") - return s -} -func (this *TargetStatusUsedReferences) String() string { - if this == nil { - return "nil" - } - s := strings.Join([]string{`&TargetStatusUsedReferences{`, - `SecretResourceVersion:` + fmt.Sprintf("%v", this.SecretResourceVersion) + `,`, - `TLSSecretResourceVersion:` + fmt.Sprintf("%v", this.TLSSecretResourceVersion) + `,`, - `ConnectionProfileResourceVersion:` + fmt.Sprintf("%v", this.ConnectionProfileResourceVersion) + `,`, - `SyncProfileResourceVersion:` + fmt.Sprintf("%v", this.SyncProfileResourceVersion) + `,`, - `}`, - }, "") - return s -} -func (this *TargetSyncProfile) String() string { - if this == nil { - return "nil" - } - s := strings.Join([]string{`&TargetSyncProfile{`, - `ObjectMeta:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ObjectMeta), "ObjectMeta", "v1.ObjectMeta", 1), `&`, ``, 1) + `,`, - `Spec:` + strings.Replace(strings.Replace(this.Spec.String(), "TargetSyncProfileSpec", "TargetSyncProfileSpec", 1), `&`, ``, 1) + `,`, - `}`, - }, "") - return s -} -func (this *TargetSyncProfileList) String() string { - if this == nil { - return "nil" - } - repeatedStringForItems := "[]TargetSyncProfile{" - for _, f := range this.Items { - repeatedStringForItems += strings.Replace(strings.Replace(f.String(), "TargetSyncProfile", "TargetSyncProfile", 1), `&`, ``, 1) + "," - } - repeatedStringForItems += "}" - s := strings.Join([]string{`&TargetSyncProfileList{`, - `ListMeta:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ListMeta), "ListMeta", "v1.ListMeta", 1), `&`, ``, 1) + `,`, - `Items:` + repeatedStringForItems + `,`, - `}`, - }, "") - return s -} -func (this *TargetSyncProfileSpec) String() string { - if this == nil { - return "nil" - } - repeatedStringForSync := "[]TargetSyncProfileSync{" - for _, f := range this.Sync { - repeatedStringForSync += strings.Replace(strings.Replace(f.String(), "TargetSyncProfileSync", "TargetSyncProfileSync", 1), `&`, ``, 1) + "," - } - repeatedStringForSync += "}" - s := strings.Join([]string{`&TargetSyncProfileSpec{`, - `Validate:` + fmt.Sprintf("%v", this.Validate) + `,`, - `Buffer:` + fmt.Sprintf("%v", this.Buffer) + `,`, - `Workers:` + fmt.Sprintf("%v", this.Workers) + `,`, - `Sync:` + repeatedStringForSync + `,`, - `}`, - }, "") - return s -} -func (this *TargetSyncProfileSync) String() string { - if this == nil { - return "nil" - } - s := strings.Join([]string{`&TargetSyncProfileSync{`, - `Name:` + fmt.Sprintf("%v", this.Name) + `,`, - `Protocol:` + fmt.Sprintf("%v", this.Protocol) + `,`, - `Port:` + fmt.Sprintf("%v", this.Port) + `,`, - `Paths:` + fmt.Sprintf("%v", this.Paths) + `,`, - `Mode:` + fmt.Sprintf("%v", this.Mode) + `,`, - `Encoding:` + valueToStringGenerated(this.Encoding) + `,`, - `Interval:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Interval), "Duration", "v1.Duration", 1), `&`, ``, 1) + `,`, - `}`, - }, "") - return s -} -func (this *TargetTemplate) String() string { - if this == nil { - return "nil" - } - keysForAnnotations := make([]string, 0, len(this.Annotations)) - for k := range this.Annotations { - keysForAnnotations = append(keysForAnnotations, k) - } - github_com_gogo_protobuf_sortkeys.Strings(keysForAnnotations) - mapStringForAnnotations := "map[string]string{" - for _, k := range keysForAnnotations { - mapStringForAnnotations += fmt.Sprintf("%v: %v,", k, this.Annotations[k]) - } - mapStringForAnnotations += "}" - keysForLabels := make([]string, 0, len(this.Labels)) - for k := range this.Labels { - keysForLabels = append(keysForLabels, k) - } - github_com_gogo_protobuf_sortkeys.Strings(keysForLabels) - mapStringForLabels := "map[string]string{" - for _, k := range keysForLabels { - mapStringForLabels += fmt.Sprintf("%v: %v,", k, this.Labels[k]) - } - mapStringForLabels += "}" - s := strings.Join([]string{`&TargetTemplate{`, - `NameTemplate:` + fmt.Sprintf("%v", this.NameTemplate) + `,`, - `Annotations:` + mapStringForAnnotations + `,`, - `Labels:` + mapStringForLabels + `,`, - `}`, - }, "") - return s -} -func (this *Workspace) String() string { - if this == nil { - return "nil" - } - s := strings.Join([]string{`&Workspace{`, - `ObjectMeta:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ObjectMeta), "ObjectMeta", "v1.ObjectMeta", 1), `&`, ``, 1) + `,`, - `Spec:` + strings.Replace(strings.Replace(this.Spec.String(), "WorkspaceSpec", "WorkspaceSpec", 1), `&`, ``, 1) + `,`, - `Status:` + strings.Replace(strings.Replace(this.Status.String(), "WorkspaceStatus", "WorkspaceStatus", 1), `&`, ``, 1) + `,`, - `}`, - }, "") - return s -} -func (this *WorkspaceList) String() string { - if this == nil { - return "nil" - } - repeatedStringForItems := "[]Workspace{" - for _, f := range this.Items { - repeatedStringForItems += strings.Replace(strings.Replace(f.String(), "Workspace", "Workspace", 1), `&`, ``, 1) + "," - } - repeatedStringForItems += "}" - s := strings.Join([]string{`&WorkspaceList{`, - `ListMeta:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ListMeta), "ListMeta", "v1.ListMeta", 1), `&`, ``, 1) + `,`, - `Items:` + repeatedStringForItems + `,`, - `}`, - }, "") - return s -} -func (this *WorkspaceSpec) String() string { - if this == nil { - return "nil" - } - s := strings.Join([]string{`&WorkspaceSpec{`, - `Repository:` + strings.Replace(strings.Replace(this.Repository.String(), "Repository", "Repository", 1), `&`, ``, 1) + `,`, - `}`, - }, "") - return s -} -func (this *WorkspaceStatus) String() string { - if this == nil { - return "nil" - } - s := strings.Join([]string{`&WorkspaceStatus{`, - `ConditionedStatus:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ConditionedStatus), "ConditionedStatus", "v1alpha1.ConditionedStatus", 1), `&`, ``, 1) + `,`, - `Kind:` + valueToStringGenerated(this.Kind) + `,`, - `DeployedRef:` + valueToStringGenerated(this.DeployedRef) + `,`, - `}`, - }, "") - return s -} -func valueToStringGenerated(v interface{}) string { - rv := reflect.ValueOf(v) - if rv.IsNil() { - return "nil" - } - pv := reflect.Indirect(rv).Interface() - return fmt.Sprintf("*%v", pv) -} -func (m *DiscoveryInfo) Unmarshal(dAtA []byte) error { - l := len(dAtA) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - wire |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: DiscoveryInfo: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: DiscoveryInfo: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Protocol", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - stringLen |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex < 0 { - return ErrInvalidLengthGenerated - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Protocol = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex - case 2: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Provider", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - stringLen |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex < 0 { - return ErrInvalidLengthGenerated - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Provider = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex - case 3: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Version", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - stringLen |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex < 0 { - return ErrInvalidLengthGenerated - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Version = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex - case 4: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field HostName", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - stringLen |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex < 0 { - return ErrInvalidLengthGenerated - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Hostname = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex - case 5: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Platform", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - stringLen |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex < 0 { - return ErrInvalidLengthGenerated - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Platform = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex - case 6: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field MacAddress", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - stringLen |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex < 0 { - return ErrInvalidLengthGenerated - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.MacAddress = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex - case 7: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field SerialNumber", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - stringLen |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex < 0 { - return ErrInvalidLengthGenerated - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.SerialNumber = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex - case 8: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field SupportedEncodings", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - stringLen |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex < 0 { - return ErrInvalidLengthGenerated - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.SupportedEncodings = append(m.SupportedEncodings, string(dAtA[iNdEx:postIndex])) - iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipGenerated(dAtA[iNdEx:]) - if err != nil { - return err - } - if (skippy < 0) || (iNdEx+skippy) < 0 { - return ErrInvalidLengthGenerated - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *DiscoveryParameters) Unmarshal(dAtA []byte) error { - l := len(dAtA) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - wire |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: DiscoveryParameters: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: DiscoveryParameters: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field DefaultSchema", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - msglen |= int(b&0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + msglen - if postIndex < 0 { - return ErrInvalidLengthGenerated - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - if m.DefaultSchema == nil { - m.DefaultSchema = &SchemaKey{} - } - if err := m.DefaultSchema.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - case 2: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field DiscoveryProfile", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - msglen |= int(b&0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + msglen - if postIndex < 0 { - return ErrInvalidLengthGenerated - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - if m.DiscoveryProfile == nil { - m.DiscoveryProfile = &DiscoveryProfile{} - } - if err := m.DiscoveryProfile.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - case 3: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field TargetConnectionProfiles", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - msglen |= int(b&0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + msglen - if postIndex < 0 { - return ErrInvalidLengthGenerated - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.TargetConnectionProfiles = append(m.TargetConnectionProfiles, TargetProfile{}) - if err := m.TargetConnectionProfiles[len(m.TargetConnectionProfiles)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - case 4: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field TargetTemplate", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - msglen |= int(b&0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + msglen - if postIndex < 0 { - return ErrInvalidLengthGenerated - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - if m.TargetTemplate == nil { - m.TargetTemplate = &TargetTemplate{} - } - if err := m.TargetTemplate.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - case 5: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Period", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - msglen |= int(b&0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + msglen - if postIndex < 0 { - return ErrInvalidLengthGenerated - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - if err := m.Period.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - case 6: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field ConcurrentScans", wireType) - } - m.ConcurrentScans = 0 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - m.ConcurrentScans |= int64(b&0x7F) << shift - if b < 0x80 { - break - } - } - default: - iNdEx = preIndex - skippy, err := skipGenerated(dAtA[iNdEx:]) - if err != nil { - return err - } - if (skippy < 0) || (iNdEx+skippy) < 0 { - return ErrInvalidLengthGenerated - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *DiscoveryPathDefinition) Unmarshal(dAtA []byte) error { - l := len(dAtA) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - wire |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: DiscoveryPathDefinition: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: DiscoveryPathDefinition: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Key", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - stringLen |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex < 0 { - return ErrInvalidLengthGenerated - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Key = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex - case 2: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Path", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - stringLen |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex < 0 { - return ErrInvalidLengthGenerated - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Path = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex - case 3: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Script", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - stringLen |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex < 0 { - return ErrInvalidLengthGenerated - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - s := string(dAtA[iNdEx:postIndex]) - m.Script = &s - iNdEx = postIndex - case 4: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Regex", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - stringLen |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex < 0 { - return ErrInvalidLengthGenerated - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - s := string(dAtA[iNdEx:postIndex]) - m.Regex = &s - iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipGenerated(dAtA[iNdEx:]) - if err != nil { - return err - } - if (skippy < 0) || (iNdEx+skippy) < 0 { - return ErrInvalidLengthGenerated - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *DiscoveryProfile) Unmarshal(dAtA []byte) error { - l := len(dAtA) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - wire |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: DiscoveryProfile: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: DiscoveryProfile: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Credentials", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - stringLen |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex < 0 { - return ErrInvalidLengthGenerated - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Credentials = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex - case 2: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field TLSSecret", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - stringLen |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex < 0 { - return ErrInvalidLengthGenerated - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - s := string(dAtA[iNdEx:postIndex]) - m.TLSSecret = &s - iNdEx = postIndex - case 3: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ConnectionProfiles", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - stringLen |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex < 0 { - return ErrInvalidLengthGenerated - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.ConnectionProfiles = append(m.ConnectionProfiles, string(dAtA[iNdEx:postIndex])) - iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipGenerated(dAtA[iNdEx:]) - if err != nil { - return err - } - if (skippy < 0) || (iNdEx+skippy) < 0 { - return ErrInvalidLengthGenerated - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } + repeatedStringForSync := "[]TargetSyncProfileSync{" + for _, f := range this.Sync { + repeatedStringForSync += strings.Replace(strings.Replace(f.String(), "TargetSyncProfileSync", "TargetSyncProfileSync", 1), `&`, ``, 1) + "," } - - if iNdEx > l { - return io.ErrUnexpectedEOF + repeatedStringForSync += "}" + s := strings.Join([]string{`&TargetSyncProfileSpec{`, + `Validate:` + fmt.Sprintf("%v", this.Validate) + `,`, + `Buffer:` + fmt.Sprintf("%v", this.Buffer) + `,`, + `Workers:` + fmt.Sprintf("%v", this.Workers) + `,`, + `Sync:` + repeatedStringForSync + `,`, + `}`, + }, "") + return s +} +func (this *TargetSyncProfileSync) String() string { + if this == nil { + return "nil" } - return nil + s := strings.Join([]string{`&TargetSyncProfileSync{`, + `Name:` + fmt.Sprintf("%v", this.Name) + `,`, + `Protocol:` + fmt.Sprintf("%v", this.Protocol) + `,`, + `Port:` + fmt.Sprintf("%v", this.Port) + `,`, + `Paths:` + fmt.Sprintf("%v", this.Paths) + `,`, + `Mode:` + fmt.Sprintf("%v", this.Mode) + `,`, + `Encoding:` + valueToStringGenerated(this.Encoding) + `,`, + `Interval:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Interval), "Duration", "v1.Duration", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s } -func (m *DiscoveryRule) Unmarshal(dAtA []byte) error { +func (this *TargetTemplate) String() string { + if this == nil { + return "nil" + } + keysForAnnotations := make([]string, 0, len(this.Annotations)) + for k := range this.Annotations { + keysForAnnotations = append(keysForAnnotations, k) + } + sort.Strings(keysForAnnotations) + mapStringForAnnotations := "map[string]string{" + for _, k := range keysForAnnotations { + mapStringForAnnotations += fmt.Sprintf("%v: %v,", k, this.Annotations[k]) + } + mapStringForAnnotations += "}" + keysForLabels := make([]string, 0, len(this.Labels)) + for k := range this.Labels { + keysForLabels = append(keysForLabels, k) + } + sort.Strings(keysForLabels) + mapStringForLabels := "map[string]string{" + for _, k := range keysForLabels { + mapStringForLabels += fmt.Sprintf("%v: %v,", k, this.Labels[k]) + } + mapStringForLabels += "}" + s := strings.Join([]string{`&TargetTemplate{`, + `NameTemplate:` + fmt.Sprintf("%v", this.NameTemplate) + `,`, + `Annotations:` + mapStringForAnnotations + `,`, + `Labels:` + mapStringForLabels + `,`, + `}`, + }, "") + return s +} +func (this *Workspace) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&Workspace{`, + `ObjectMeta:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ObjectMeta), "ObjectMeta", "v1.ObjectMeta", 1), `&`, ``, 1) + `,`, + `Spec:` + strings.Replace(strings.Replace(this.Spec.String(), "WorkspaceSpec", "WorkspaceSpec", 1), `&`, ``, 1) + `,`, + `Status:` + strings.Replace(strings.Replace(this.Status.String(), "WorkspaceStatus", "WorkspaceStatus", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func (this *WorkspaceList) String() string { + if this == nil { + return "nil" + } + repeatedStringForItems := "[]Workspace{" + for _, f := range this.Items { + repeatedStringForItems += strings.Replace(strings.Replace(f.String(), "Workspace", "Workspace", 1), `&`, ``, 1) + "," + } + repeatedStringForItems += "}" + s := strings.Join([]string{`&WorkspaceList{`, + `ListMeta:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ListMeta), "ListMeta", "v1.ListMeta", 1), `&`, ``, 1) + `,`, + `Items:` + repeatedStringForItems + `,`, + `}`, + }, "") + return s +} +func (this *WorkspaceSpec) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&WorkspaceSpec{`, + `Repository:` + strings.Replace(strings.Replace(this.Repository.String(), "Repository", "Repository", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func (this *WorkspaceStatus) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&WorkspaceStatus{`, + `ConditionedStatus:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ConditionedStatus), "ConditionedStatus", "v1alpha1.ConditionedStatus", 1), `&`, ``, 1) + `,`, + `Kind:` + valueToStringGenerated(this.Kind) + `,`, + `DeployedRef:` + valueToStringGenerated(this.DeployedRef) + `,`, + `}`, + }, "") + return s +} +func valueToStringGenerated(v interface{}) string { + rv := reflect.ValueOf(v) + if rv.IsNil() { + return "nil" + } + pv := reflect.Indirect(rv).Interface() + return fmt.Sprintf("*%v", pv) +} +func (m *DiscoveryParameters) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -7321,15 +4233,15 @@ func (m *DiscoveryRule) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: DiscoveryRule: wiretype end group for non-group") + return fmt.Errorf("proto: DiscoveryParameters: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: DiscoveryRule: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: DiscoveryParameters: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field DefaultSchema", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -7356,46 +4268,16 @@ func (m *DiscoveryRule) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - case 2: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Spec", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - msglen |= int(b&0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + msglen - if postIndex < 0 { - return ErrInvalidLengthGenerated - } - if postIndex > l { - return io.ErrUnexpectedEOF + if m.DefaultSchema == nil { + m.DefaultSchema = &SchemaKey{} } - if err := m.Spec.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + if err := m.DefaultSchema.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex - case 3: + case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field DiscoveryProfile", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -7422,97 +4304,18 @@ func (m *DiscoveryRule) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Status.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err + if m.DiscoveryProfile == nil { + m.DiscoveryProfile = &DiscoveryProfile{} } - iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipGenerated(dAtA[iNdEx:]) - if err != nil { + if err := m.DiscoveryProfile.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } - if (skippy < 0) || (iNdEx+skippy) < 0 { - return ErrInvalidLengthGenerated - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *DiscoveryRuleAddress) Unmarshal(dAtA []byte) error { - l := len(dAtA) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - wire |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: DiscoveryRuleAddress: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: DiscoveryRuleAddress: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Address", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - stringLen |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex < 0 { - return ErrInvalidLengthGenerated - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Address = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex - case 2: + case 3: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field HostName", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field TargetConnectionProfiles", wireType) } - var stringLen uint64 + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -7522,77 +4325,29 @@ func (m *DiscoveryRuleAddress) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - stringLen |= uint64(b&0x7F) << shift + msglen |= int(b&0x7F) << shift if b < 0x80 { break } } - intStringLen := int(stringLen) - if intStringLen < 0 { + if msglen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + intStringLen + postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthGenerated } if postIndex > l { return io.ErrUnexpectedEOF } - m.HostName = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipGenerated(dAtA[iNdEx:]) - if err != nil { + m.TargetConnectionProfiles = append(m.TargetConnectionProfiles, TargetProfile{}) + if err := m.TargetConnectionProfiles[len(m.TargetConnectionProfiles)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } - if (skippy < 0) || (iNdEx+skippy) < 0 { - return ErrInvalidLengthGenerated - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *DiscoveryRuleList) Unmarshal(dAtA []byte) error { - l := len(dAtA) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - wire |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: DiscoveryRuleList: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: DiscoveryRuleList: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: + iNdEx = postIndex + case 4: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ListMeta", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field TargetTemplate", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -7619,13 +4374,16 @@ func (m *DiscoveryRuleList) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + if m.TargetTemplate == nil { + m.TargetTemplate = &TargetTemplate{} + } + if err := m.TargetTemplate.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex - case 2: + case 5: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Period", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -7652,11 +4410,29 @@ func (m *DiscoveryRuleList) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Items = append(m.Items, DiscoveryRule{}) - if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + if err := m.Period.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex + case 6: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field ConcurrentScans", wireType) + } + m.ConcurrentScans = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.ConcurrentScans |= int64(b&0x7F) << shift + if b < 0x80 { + break + } + } default: iNdEx = preIndex skippy, err := skipGenerated(dAtA[iNdEx:]) @@ -7678,7 +4454,7 @@ func (m *DiscoveryRuleList) Unmarshal(dAtA []byte) error { } return nil } -func (m *DiscoveryRulePrefix) Unmarshal(dAtA []byte) error { +func (m *DiscoveryPathDefinition) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -7701,15 +4477,15 @@ func (m *DiscoveryRulePrefix) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: DiscoveryRulePrefix: wiretype end group for non-group") + return fmt.Errorf("proto: DiscoveryPathDefinition: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: DiscoveryRulePrefix: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: DiscoveryPathDefinition: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Prefix", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Key", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -7737,11 +4513,11 @@ func (m *DiscoveryRulePrefix) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Prefix = string(dAtA[iNdEx:postIndex]) + m.Key = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Excludes", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Path", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -7769,63 +4545,13 @@ func (m *DiscoveryRulePrefix) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Excludes = append(m.Excludes, string(dAtA[iNdEx:postIndex])) + m.Path = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipGenerated(dAtA[iNdEx:]) - if err != nil { - return err - } - if (skippy < 0) || (iNdEx+skippy) < 0 { - return ErrInvalidLengthGenerated - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *DiscoveryRuleSpec) Unmarshal(dAtA []byte) error { - l := len(dAtA) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - wire |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: DiscoveryRuleSpec: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: DiscoveryRuleSpec: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: + case 3: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Prefixes", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Script", wireType) } - var msglen int + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -7835,31 +4561,30 @@ func (m *DiscoveryRuleSpec) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - msglen |= int(b&0x7F) << shift + stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { + intStringLen := int(stringLen) + if intStringLen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + msglen + postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthGenerated } if postIndex > l { return io.ErrUnexpectedEOF } - m.Prefixes = append(m.Prefixes, DiscoveryRulePrefix{}) - if err := m.Prefixes[len(m.Prefixes)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } + s := string(dAtA[iNdEx:postIndex]) + m.Script = &s iNdEx = postIndex - case 2: + case 4: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Addresses", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Regex", wireType) } - var msglen int + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -7869,67 +4594,80 @@ func (m *DiscoveryRuleSpec) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - msglen |= int(b&0x7F) << shift + stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { + intStringLen := int(stringLen) + if intStringLen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + msglen + postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthGenerated } if postIndex > l { return io.ErrUnexpectedEOF } - m.Addresses = append(m.Addresses, DiscoveryRuleAddress{}) - if err := m.Addresses[len(m.Addresses)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } + s := string(dAtA[iNdEx:postIndex]) + m.Regex = &s iNdEx = postIndex - case 3: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field PodSelector", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - msglen |= int(b&0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthGenerated + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err } - postIndex := iNdEx + msglen - if postIndex < 0 { + if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthGenerated } - if postIndex > l { + if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } - if m.PodSelector == nil { - m.PodSelector = &v1.LabelSelector{} + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *DiscoveryProfile) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated } - if err := m.PodSelector.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break } - iNdEx = postIndex - case 4: + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: DiscoveryProfile: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: DiscoveryProfile: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ServiceSelector", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Credentials", wireType) } - var msglen int + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -7939,31 +4677,27 @@ func (m *DiscoveryRuleSpec) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - msglen |= int(b&0x7F) << shift + stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { + intStringLen := int(stringLen) + if intStringLen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + msglen + postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthGenerated } if postIndex > l { return io.ErrUnexpectedEOF } - if m.ServiceSelector == nil { - m.ServiceSelector = &v1.LabelSelector{} - } - if err := m.ServiceSelector.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } + m.Credentials = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex - case 5: + case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ServiceDomain", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field TLSSecret", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -7991,13 +4725,14 @@ func (m *DiscoveryRuleSpec) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.ServiceDomain = string(dAtA[iNdEx:postIndex]) + s := string(dAtA[iNdEx:postIndex]) + m.TLSSecret = &s iNdEx = postIndex - case 6: + case 3: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field DiscoveryParameters", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field ConnectionProfiles", wireType) } - var msglen int + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -8007,24 +4742,23 @@ func (m *DiscoveryRuleSpec) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - msglen |= int(b&0x7F) << shift + stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { + intStringLen := int(stringLen) + if intStringLen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + msglen + postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthGenerated } if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.DiscoveryParameters.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } + m.ConnectionProfiles = append(m.ConnectionProfiles, string(dAtA[iNdEx:postIndex])) iNdEx = postIndex default: iNdEx = preIndex @@ -8047,7 +4781,7 @@ func (m *DiscoveryRuleSpec) Unmarshal(dAtA []byte) error { } return nil } -func (m *DiscoveryRuleStatus) Unmarshal(dAtA []byte) error { +func (m *DiscoveryRule) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -8070,15 +4804,15 @@ func (m *DiscoveryRuleStatus) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: DiscoveryRuleStatus: wiretype end group for non-group") + return fmt.Errorf("proto: DiscoveryRule: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: DiscoveryRuleStatus: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: DiscoveryRule: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ConditionedStatus", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -8105,13 +4839,13 @@ func (m *DiscoveryRuleStatus) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ConditionedStatus.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field StartTime", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Spec", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -8138,10 +4872,40 @@ func (m *DiscoveryRuleStatus) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if m.StartTime == nil { - m.StartTime = &v1.Time{} + if err := m.Spec.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err } - if err := m.StartTime.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return ErrInvalidLengthGenerated + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.Status.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -8166,7 +4930,7 @@ func (m *DiscoveryRuleStatus) Unmarshal(dAtA []byte) error { } return nil } -func (m *DiscoveryVendorProfile) Unmarshal(dAtA []byte) error { +func (m *DiscoveryRuleAddress) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -8189,17 +4953,17 @@ func (m *DiscoveryVendorProfile) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: DiscoveryVendorProfile: wiretype end group for non-group") + return fmt.Errorf("proto: DiscoveryRuleAddress: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: DiscoveryVendorProfile: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: DiscoveryRuleAddress: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Address", wireType) } - var msglen int + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -8209,30 +4973,29 @@ func (m *DiscoveryVendorProfile) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - msglen |= int(b&0x7F) << shift + stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { + intStringLen := int(stringLen) + if intStringLen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + msglen + postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthGenerated } if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } + m.Address = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Spec", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field HostName", wireType) } - var msglen int + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -8242,24 +5005,23 @@ func (m *DiscoveryVendorProfile) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - msglen |= int(b&0x7F) << shift + stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { + intStringLen := int(stringLen) + if intStringLen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + msglen + postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthGenerated } if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Spec.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } + m.HostName = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex @@ -8282,7 +5044,7 @@ func (m *DiscoveryVendorProfile) Unmarshal(dAtA []byte) error { } return nil } -func (m *DiscoveryVendorProfileList) Unmarshal(dAtA []byte) error { +func (m *DiscoveryRuleList) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -8305,10 +5067,10 @@ func (m *DiscoveryVendorProfileList) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: DiscoveryVendorProfileList: wiretype end group for non-group") + return fmt.Errorf("proto: DiscoveryRuleList: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: DiscoveryVendorProfileList: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: DiscoveryRuleList: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: @@ -8373,7 +5135,7 @@ func (m *DiscoveryVendorProfileList) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Items = append(m.Items, DiscoveryVendorProfile{}) + m.Items = append(m.Items, DiscoveryRule{}) if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } @@ -8399,7 +5161,7 @@ func (m *DiscoveryVendorProfileList) Unmarshal(dAtA []byte) error { } return nil } -func (m *DiscoveryVendorProfileSpec) Unmarshal(dAtA []byte) error { +func (m *DiscoveryRulePrefix) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -8422,17 +5184,17 @@ func (m *DiscoveryVendorProfileSpec) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: DiscoveryVendorProfileSpec: wiretype end group for non-group") + return fmt.Errorf("proto: DiscoveryRulePrefix: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: DiscoveryVendorProfileSpec: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: DiscoveryRulePrefix: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Gnmi", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Prefix", wireType) } - var msglen int + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -8442,24 +5204,55 @@ func (m *DiscoveryVendorProfileSpec) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - msglen |= int(b&0x7F) << shift + stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { + intStringLen := int(stringLen) + if intStringLen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + msglen + postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthGenerated } if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Gnmi.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err + m.Prefix = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Excludes", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return ErrInvalidLengthGenerated + } + if postIndex > l { + return io.ErrUnexpectedEOF } + m.Excludes = append(m.Excludes, string(dAtA[iNdEx:postIndex])) iNdEx = postIndex default: iNdEx = preIndex @@ -8482,7 +5275,7 @@ func (m *DiscoveryVendorProfileSpec) Unmarshal(dAtA []byte) error { } return nil } -func (m *GnmiDiscoveryVendorProfileParameters) Unmarshal(dAtA []byte) error { +func (m *DiscoveryRuleSpec) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -8505,17 +5298,17 @@ func (m *GnmiDiscoveryVendorProfileParameters) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: GnmiDiscoveryVendorProfileParameters: wiretype end group for non-group") + return fmt.Errorf("proto: DiscoveryRuleSpec: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: GnmiDiscoveryVendorProfileParameters: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: DiscoveryRuleSpec: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Organization", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Prefixes", wireType) } - var stringLen uint64 + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -8525,29 +5318,65 @@ func (m *GnmiDiscoveryVendorProfileParameters) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - stringLen |= uint64(b&0x7F) << shift + msglen |= int(b&0x7F) << shift if b < 0x80 { break } } - intStringLen := int(stringLen) - if intStringLen < 0 { + if msglen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + intStringLen + postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthGenerated } if postIndex > l { return io.ErrUnexpectedEOF } - m.Organization = string(dAtA[iNdEx:postIndex]) + m.Prefixes = append(m.Prefixes, DiscoveryRulePrefix{}) + if err := m.Prefixes[len(m.Prefixes)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } iNdEx = postIndex case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ModelMatch", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Addresses", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return ErrInvalidLengthGenerated + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Addresses = append(m.Addresses, DiscoveryRuleAddress{}) + if err := m.Addresses[len(m.Addresses)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field PodSelector", wireType) } - var stringLen uint64 + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -8557,28 +5386,31 @@ func (m *GnmiDiscoveryVendorProfileParameters) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - stringLen |= uint64(b&0x7F) << shift + msglen |= int(b&0x7F) << shift if b < 0x80 { break } } - intStringLen := int(stringLen) - if intStringLen < 0 { + if msglen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + intStringLen + postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthGenerated } if postIndex > l { return io.ErrUnexpectedEOF } - s := string(dAtA[iNdEx:postIndex]) - m.ModelMatch = &s + if m.PodSelector == nil { + m.PodSelector = &v1.LabelSelector{} + } + if err := m.PodSelector.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } iNdEx = postIndex - case 3: + case 4: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Paths", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field ServiceSelector", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -8605,14 +5437,16 @@ func (m *GnmiDiscoveryVendorProfileParameters) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Paths = append(m.Paths, DiscoveryPathDefinition{}) - if err := m.Paths[len(m.Paths)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + if m.ServiceSelector == nil { + m.ServiceSelector = &v1.LabelSelector{} + } + if err := m.ServiceSelector.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex - case 4: + case 5: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Encoding", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field ServiceDomain", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -8640,14 +5474,13 @@ func (m *GnmiDiscoveryVendorProfileParameters) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - s := Encoding(dAtA[iNdEx:postIndex]) - m.Encoding = &s + m.ServiceDomain = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex - case 5: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field PreserveNamespace", wireType) + case 6: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field DiscoveryParameters", wireType) } - var v int + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -8657,13 +5490,25 @@ func (m *GnmiDiscoveryVendorProfileParameters) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - v |= int(b&0x7F) << shift + msglen |= int(b&0x7F) << shift if b < 0x80 { break } } - b := bool(v != 0) - m.PreserveNamespace = &b + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return ErrInvalidLengthGenerated + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.DiscoveryParameters.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipGenerated(dAtA[iNdEx:]) @@ -8685,7 +5530,7 @@ func (m *GnmiDiscoveryVendorProfileParameters) Unmarshal(dAtA []byte) error { } return nil } -func (m *Proxy) Unmarshal(dAtA []byte) error { +func (m *DiscoveryRuleStatus) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -8708,17 +5553,17 @@ func (m *Proxy) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: Proxy: wiretype end group for non-group") + return fmt.Errorf("proto: DiscoveryRuleStatus: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: Proxy: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: DiscoveryRuleStatus: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field URL", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field ConditionedStatus", wireType) } - var stringLen uint64 + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -8728,29 +5573,30 @@ func (m *Proxy) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - stringLen |= uint64(b&0x7F) << shift + msglen |= int(b&0x7F) << shift if b < 0x80 { break } } - intStringLen := int(stringLen) - if intStringLen < 0 { + if msglen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + intStringLen + postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthGenerated } if postIndex > l { return io.ErrUnexpectedEOF } - m.URL = string(dAtA[iNdEx:postIndex]) + if err := m.ConditionedStatus.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } iNdEx = postIndex case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Credentials", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field StartTime", wireType) } - var stringLen uint64 + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -8760,23 +5606,27 @@ func (m *Proxy) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - stringLen |= uint64(b&0x7F) << shift + msglen |= int(b&0x7F) << shift if b < 0x80 { break } } - intStringLen := int(stringLen) - if intStringLen < 0 { + if msglen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + intStringLen + postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthGenerated } if postIndex > l { return io.ErrUnexpectedEOF } - m.Credentials = string(dAtA[iNdEx:postIndex]) + if m.StartTime == nil { + m.StartTime = &v1.Time{} + } + if err := m.StartTime.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } iNdEx = postIndex default: iNdEx = preIndex @@ -8799,7 +5649,7 @@ func (m *Proxy) Unmarshal(dAtA []byte) error { } return nil } -func (m *Repository) Unmarshal(dAtA []byte) error { +func (m *DiscoveryVendorProfile) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -8822,17 +5672,17 @@ func (m *Repository) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: Repository: wiretype end group for non-group") + return fmt.Errorf("proto: DiscoveryVendorProfile: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: Repository: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: DiscoveryVendorProfile: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field RepositoryURL", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType) } - var stringLen uint64 + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -8842,29 +5692,30 @@ func (m *Repository) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - stringLen |= uint64(b&0x7F) << shift + msglen |= int(b&0x7F) << shift if b < 0x80 { break } } - intStringLen := int(stringLen) - if intStringLen < 0 { + if msglen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + intStringLen + postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthGenerated } if postIndex > l { return io.ErrUnexpectedEOF } - m.RepoURL = string(dAtA[iNdEx:postIndex]) + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } iNdEx = postIndex case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Credentials", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Spec", wireType) } - var stringLen uint64 + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -8874,27 +5725,78 @@ func (m *Repository) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - stringLen |= uint64(b&0x7F) << shift + msglen |= int(b&0x7F) << shift if b < 0x80 { break } } - intStringLen := int(stringLen) - if intStringLen < 0 { + if msglen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + intStringLen + postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthGenerated } if postIndex > l { return io.ErrUnexpectedEOF } - m.Credentials = string(dAtA[iNdEx:postIndex]) + if err := m.Spec.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } iNdEx = postIndex - case 3: + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *DiscoveryVendorProfileList) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: DiscoveryVendorProfileList: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: DiscoveryVendorProfileList: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Proxy", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field ListMeta", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -8921,18 +5823,15 @@ func (m *Repository) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if m.Proxy == nil { - m.Proxy = &Proxy{} - } - if err := m.Proxy.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex - case 4: + case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Kind", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType) } - var stringLen uint64 + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -8942,29 +5841,81 @@ func (m *Repository) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - stringLen |= uint64(b&0x7F) << shift + msglen |= int(b&0x7F) << shift if b < 0x80 { break } } - intStringLen := int(stringLen) - if intStringLen < 0 { + if msglen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + intStringLen + postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthGenerated } if postIndex > l { return io.ErrUnexpectedEOF } - m.Kind = BranchTagKind(dAtA[iNdEx:postIndex]) + m.Items = append(m.Items, DiscoveryVendorProfile{}) + if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } iNdEx = postIndex - case 5: + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *DiscoveryVendorProfileSpec) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: DiscoveryVendorProfileSpec: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: DiscoveryVendorProfileSpec: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Ref", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Gnmi", wireType) } - var stringLen uint64 + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -8974,23 +5925,24 @@ func (m *Repository) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - stringLen |= uint64(b&0x7F) << shift + msglen |= int(b&0x7F) << shift if b < 0x80 { break } } - intStringLen := int(stringLen) - if intStringLen < 0 { + if msglen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + intStringLen + postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthGenerated } if postIndex > l { return io.ErrUnexpectedEOF } - m.Ref = string(dAtA[iNdEx:postIndex]) + if err := m.Gnmi.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } iNdEx = postIndex default: iNdEx = preIndex @@ -9013,7 +5965,7 @@ func (m *Repository) Unmarshal(dAtA []byte) error { } return nil } -func (m *Rollout) Unmarshal(dAtA []byte) error { +func (m *GnmiDiscoveryVendorProfileParameters) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -9036,17 +5988,17 @@ func (m *Rollout) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: Rollout: wiretype end group for non-group") + return fmt.Errorf("proto: GnmiDiscoveryVendorProfileParameters: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: Rollout: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: GnmiDiscoveryVendorProfileParameters: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Organization", wireType) } - var msglen int + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -9056,30 +6008,29 @@ func (m *Rollout) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - msglen |= int(b&0x7F) << shift + stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { + intStringLen := int(stringLen) + if intStringLen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + msglen + postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthGenerated } if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } + m.Organization = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Spec", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field ModelMatch", wireType) } - var msglen int + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -9089,28 +6040,28 @@ func (m *Rollout) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - msglen |= int(b&0x7F) << shift + stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { + intStringLen := int(stringLen) + if intStringLen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + msglen + postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthGenerated } if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Spec.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } + s := string(dAtA[iNdEx:postIndex]) + m.ModelMatch = &s iNdEx = postIndex case 3: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Paths", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -9137,65 +6088,16 @@ func (m *Rollout) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Status.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + m.Paths = append(m.Paths, DiscoveryPathDefinition{}) + if err := m.Paths[len(m.Paths)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipGenerated(dAtA[iNdEx:]) - if err != nil { - return err - } - if (skippy < 0) || (iNdEx+skippy) < 0 { - return ErrInvalidLengthGenerated - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *RolloutList) Unmarshal(dAtA []byte) error { - l := len(dAtA) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - wire |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: RolloutList: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: RolloutList: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: + case 4: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ListMeta", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Encoding", wireType) } - var msglen int + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -9205,30 +6107,30 @@ func (m *RolloutList) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - msglen |= int(b&0x7F) << shift + stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { + intStringLen := int(stringLen) + if intStringLen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + msglen + postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthGenerated } if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } + s := Encoding(dAtA[iNdEx:postIndex]) + m.Encoding = &s iNdEx = postIndex - case 2: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType) + case 5: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field PreserveNamespace", wireType) } - var msglen int + var v int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -9238,26 +6140,13 @@ func (m *RolloutList) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - msglen |= int(b&0x7F) << shift + v |= int(b&0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + msglen - if postIndex < 0 { - return ErrInvalidLengthGenerated - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Items = append(m.Items, Rollout{}) - if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex + b := bool(v != 0) + m.PreserveNamespace = &b default: iNdEx = preIndex skippy, err := skipGenerated(dAtA[iNdEx:]) @@ -9279,7 +6168,7 @@ func (m *RolloutList) Unmarshal(dAtA []byte) error { } return nil } -func (m *RolloutSpec) Unmarshal(dAtA []byte) error { +func (m *Proxy) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -9302,17 +6191,17 @@ func (m *RolloutSpec) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: RolloutSpec: wiretype end group for non-group") + return fmt.Errorf("proto: Proxy: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: RolloutSpec: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: Proxy: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Repository", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field URL", wireType) } - var msglen int + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -9322,28 +6211,27 @@ func (m *RolloutSpec) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - msglen |= int(b&0x7F) << shift + stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { + intStringLen := int(stringLen) + if intStringLen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + msglen + postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthGenerated } if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Repository.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } + m.URL = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Strategy", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Credentials", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -9371,29 +6259,8 @@ func (m *RolloutSpec) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Strategy = RolloutStrategy(dAtA[iNdEx:postIndex]) + m.Credentials = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex - case 3: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field SkipUnavailableTarget", wireType) - } - var v int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - v |= int(b&0x7F) << shift - if b < 0x80 { - break - } - } - b := bool(v != 0) - m.SkipUnavailableTarget = &b default: iNdEx = preIndex skippy, err := skipGenerated(dAtA[iNdEx:]) @@ -9415,7 +6282,7 @@ func (m *RolloutSpec) Unmarshal(dAtA []byte) error { } return nil } -func (m *RolloutStatus) Unmarshal(dAtA []byte) error { +func (m *Repository) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -9438,17 +6305,17 @@ func (m *RolloutStatus) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: RolloutStatus: wiretype end group for non-group") + return fmt.Errorf("proto: Repository: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: RolloutStatus: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: Repository: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ConditionedStatus", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field RepoURL", wireType) } - var msglen int + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -9458,28 +6325,59 @@ func (m *RolloutStatus) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - msglen |= int(b&0x7F) << shift + stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { + intStringLen := int(stringLen) + if intStringLen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + msglen + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return ErrInvalidLengthGenerated + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.RepoURL = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Credentials", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthGenerated } if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ConditionedStatus.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } + m.Credentials = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex - case 2: + case 3: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Targets", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Proxy", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -9506,64 +6404,16 @@ func (m *RolloutStatus) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Targets = append(m.Targets, RolloutTargetStatus{}) - if err := m.Targets[len(m.Targets)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err + if m.Proxy == nil { + m.Proxy = &Proxy{} } - iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipGenerated(dAtA[iNdEx:]) - if err != nil { + if err := m.Proxy.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } - if (skippy < 0) || (iNdEx+skippy) < 0 { - return ErrInvalidLengthGenerated - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *RolloutTargetStatus) Unmarshal(dAtA []byte) error { - l := len(dAtA) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - wire |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: RolloutTargetStatus: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: RolloutTargetStatus: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: + iNdEx = postIndex + case 4: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Kind", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -9591,13 +6441,13 @@ func (m *RolloutTargetStatus) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Name = string(dAtA[iNdEx:postIndex]) + m.Kind = BranchTagKind(dAtA[iNdEx:postIndex]) iNdEx = postIndex - case 2: + case 5: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ConditionedStatus", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Ref", wireType) } - var msglen int + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -9607,24 +6457,23 @@ func (m *RolloutTargetStatus) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - msglen |= int(b&0x7F) << shift + stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { + intStringLen := int(stringLen) + if intStringLen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + msglen + postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthGenerated } if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ConditionedStatus.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } + m.Ref = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex @@ -9647,7 +6496,7 @@ func (m *RolloutTargetStatus) Unmarshal(dAtA []byte) error { } return nil } -func (m *Schema) Unmarshal(dAtA []byte) error { +func (m *Rollout) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -9670,10 +6519,10 @@ func (m *Schema) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: Schema: wiretype end group for non-group") + return fmt.Errorf("proto: Rollout: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: Schema: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: Rollout: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: @@ -9796,7 +6645,7 @@ func (m *Schema) Unmarshal(dAtA []byte) error { } return nil } -func (m *SchemaKey) Unmarshal(dAtA []byte) error { +func (m *RolloutList) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -9819,17 +6668,17 @@ func (m *SchemaKey) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: SchemaKey: wiretype end group for non-group") + return fmt.Errorf("proto: RolloutList: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: SchemaKey: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: RolloutList: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Provider", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field ListMeta", wireType) } - var stringLen uint64 + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -9839,29 +6688,30 @@ func (m *SchemaKey) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - stringLen |= uint64(b&0x7F) << shift + msglen |= int(b&0x7F) << shift if b < 0x80 { break } } - intStringLen := int(stringLen) - if intStringLen < 0 { + if msglen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + intStringLen + postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthGenerated } if postIndex > l { return io.ErrUnexpectedEOF } - m.Provider = string(dAtA[iNdEx:postIndex]) + if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } iNdEx = postIndex case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Version", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType) } - var stringLen uint64 + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -9871,23 +6721,25 @@ func (m *SchemaKey) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - stringLen |= uint64(b&0x7F) << shift + msglen |= int(b&0x7F) << shift if b < 0x80 { break } } - intStringLen := int(stringLen) - if intStringLen < 0 { + if msglen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + intStringLen + postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthGenerated } if postIndex > l { return io.ErrUnexpectedEOF } - m.Version = string(dAtA[iNdEx:postIndex]) + m.Items = append(m.Items, Rollout{}) + if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } iNdEx = postIndex default: iNdEx = preIndex @@ -9910,7 +6762,7 @@ func (m *SchemaKey) Unmarshal(dAtA []byte) error { } return nil } -func (m *SchemaList) Unmarshal(dAtA []byte) error { +func (m *RolloutSpec) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -9933,15 +6785,15 @@ func (m *SchemaList) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: SchemaList: wiretype end group for non-group") + return fmt.Errorf("proto: RolloutSpec: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: SchemaList: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: RolloutSpec: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ListMeta", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Repository", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -9968,15 +6820,15 @@ func (m *SchemaList) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + if err := m.Repository.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Strategy", wireType) } - var msglen int + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -9986,26 +6838,45 @@ func (m *SchemaList) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - msglen |= int(b&0x7F) << shift + stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { + intStringLen := int(stringLen) + if intStringLen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + msglen + postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthGenerated } if postIndex > l { return io.ErrUnexpectedEOF } - m.Items = append(m.Items, Schema{}) - if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } + m.Strategy = RolloutStrategy(dAtA[iNdEx:postIndex]) iNdEx = postIndex + case 3: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field SkipUnavailableTarget", wireType) + } + var v int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + b := bool(v != 0) + m.SkipUnavailableTarget = &b default: iNdEx = preIndex skippy, err := skipGenerated(dAtA[iNdEx:]) @@ -10027,7 +6898,7 @@ func (m *SchemaList) Unmarshal(dAtA []byte) error { } return nil } -func (m *SchemaRepositoryStatus) Unmarshal(dAtA []byte) error { +func (m *RolloutStatus) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -10050,17 +6921,17 @@ func (m *SchemaRepositoryStatus) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: SchemaRepositoryStatus: wiretype end group for non-group") + return fmt.Errorf("proto: RolloutStatus: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: SchemaRepositoryStatus: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: RolloutStatus: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field RepoURL", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field ConditionedStatus", wireType) } - var stringLen uint64 + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -10070,29 +6941,30 @@ func (m *SchemaRepositoryStatus) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - stringLen |= uint64(b&0x7F) << shift + msglen |= int(b&0x7F) << shift if b < 0x80 { break } } - intStringLen := int(stringLen) - if intStringLen < 0 { + if msglen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + intStringLen + postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthGenerated } if postIndex > l { return io.ErrUnexpectedEOF } - m.RepoURL = string(dAtA[iNdEx:postIndex]) + if err := m.ConditionedStatus.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } iNdEx = postIndex case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Reference", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Targets", wireType) } - var stringLen uint64 + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -10102,23 +6974,25 @@ func (m *SchemaRepositoryStatus) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - stringLen |= uint64(b&0x7F) << shift + msglen |= int(b&0x7F) << shift if b < 0x80 { break } } - intStringLen := int(stringLen) - if intStringLen < 0 { + if msglen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + intStringLen + postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthGenerated } if postIndex > l { return io.ErrUnexpectedEOF } - m.Reference = string(dAtA[iNdEx:postIndex]) + m.Targets = append(m.Targets, RolloutTargetStatus{}) + if err := m.Targets[len(m.Targets)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } iNdEx = postIndex default: iNdEx = preIndex @@ -10141,7 +7015,7 @@ func (m *SchemaRepositoryStatus) Unmarshal(dAtA []byte) error { } return nil } -func (m *SchemaSpec) Unmarshal(dAtA []byte) error { +func (m *RolloutTargetStatus) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -10164,47 +7038,15 @@ func (m *SchemaSpec) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: SchemaSpec: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: SchemaSpec: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Provider", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - stringLen |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex < 0 { - return ErrInvalidLengthGenerated - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Provider = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex - case 2: + return fmt.Errorf("proto: RolloutTargetStatus: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: RolloutTargetStatus: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Version", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -10232,11 +7074,11 @@ func (m *SchemaSpec) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Version = string(dAtA[iNdEx:postIndex]) + m.Name = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex - case 3: + case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Repositories", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field ConditionedStatus", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -10263,8 +7105,7 @@ func (m *SchemaSpec) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Repositories = append(m.Repositories, &SchemaSpecRepository{}) - if err := m.Repositories[len(m.Repositories)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + if err := m.ConditionedStatus.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -10289,7 +7130,7 @@ func (m *SchemaSpec) Unmarshal(dAtA []byte) error { } return nil } -func (m *SchemaSpecRepository) Unmarshal(dAtA []byte) error { +func (m *Schema) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -10312,15 +7153,15 @@ func (m *SchemaSpecRepository) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: SchemaSpecRepository: wiretype end group for non-group") + return fmt.Errorf("proto: Schema: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: SchemaSpecRepository: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: Schema: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { - case 6: + case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Dirs", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -10347,14 +7188,13 @@ func (m *SchemaSpecRepository) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Dirs = append(m.Dirs, SrcDstPath{}) - if err := m.Dirs[len(m.Dirs)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex - case 7: + case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Schema", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Spec", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -10381,13 +7221,13 @@ func (m *SchemaSpecRepository) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Schema.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + if err := m.Spec.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex - case 8: + case 3: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Repository", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -10414,7 +7254,7 @@ func (m *SchemaSpecRepository) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Repository.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + if err := m.Status.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -10439,7 +7279,7 @@ func (m *SchemaSpecRepository) Unmarshal(dAtA []byte) error { } return nil } -func (m *SchemaSpecSchema) Unmarshal(dAtA []byte) error { +func (m *SchemaKey) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -10462,15 +7302,15 @@ func (m *SchemaSpecSchema) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: SchemaSpecSchema: wiretype end group for non-group") + return fmt.Errorf("proto: SchemaKey: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: SchemaSpecSchema: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: SchemaKey: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Models", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Provider", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -10498,43 +7338,11 @@ func (m *SchemaSpecSchema) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Models = append(m.Models, string(dAtA[iNdEx:postIndex])) + m.Provider = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Includes", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - stringLen |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex < 0 { - return ErrInvalidLengthGenerated - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Includes = append(m.Includes, string(dAtA[iNdEx:postIndex])) - iNdEx = postIndex - case 3: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Excludes", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Version", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -10562,7 +7370,7 @@ func (m *SchemaSpecSchema) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Excludes = append(m.Excludes, string(dAtA[iNdEx:postIndex])) + m.Version = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex @@ -10585,7 +7393,7 @@ func (m *SchemaSpecSchema) Unmarshal(dAtA []byte) error { } return nil } -func (m *SchemaStatus) Unmarshal(dAtA []byte) error { +func (m *SchemaList) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -10608,15 +7416,15 @@ func (m *SchemaStatus) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: SchemaStatus: wiretype end group for non-group") + return fmt.Errorf("proto: SchemaList: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: SchemaStatus: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: SchemaList: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ConditionedStatus", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field ListMeta", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -10643,13 +7451,13 @@ func (m *SchemaStatus) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ConditionedStatus.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Repositories", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -10676,8 +7484,8 @@ func (m *SchemaStatus) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Repositories = append(m.Repositories, SchemaRepositoryStatus{}) - if err := m.Repositories[len(m.Repositories)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + m.Items = append(m.Items, Schema{}) + if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -10702,7 +7510,7 @@ func (m *SchemaStatus) Unmarshal(dAtA []byte) error { } return nil } -func (m *SrcDstPath) Unmarshal(dAtA []byte) error { +func (m *SchemaRepositoryStatus) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -10725,15 +7533,15 @@ func (m *SrcDstPath) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: SrcDstPath: wiretype end group for non-group") + return fmt.Errorf("proto: SchemaRepositoryStatus: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: SrcDstPath: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: SchemaRepositoryStatus: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Src", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field RepoURL", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -10761,11 +7569,11 @@ func (m *SrcDstPath) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Src = string(dAtA[iNdEx:postIndex]) + m.RepoURL = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Dst", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Reference", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -10793,7 +7601,7 @@ func (m *SrcDstPath) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Dst = string(dAtA[iNdEx:postIndex]) + m.Reference = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex @@ -10816,7 +7624,7 @@ func (m *SrcDstPath) Unmarshal(dAtA []byte) error { } return nil } -func (m *Subscription) Unmarshal(dAtA []byte) error { +func (m *SchemaSpec) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -10839,17 +7647,17 @@ func (m *Subscription) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: Subscription: wiretype end group for non-group") + return fmt.Errorf("proto: SchemaSpec: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: Subscription: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: SchemaSpec: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Provider", wireType) } - var msglen int + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -10859,146 +7667,29 @@ func (m *Subscription) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - msglen |= int(b&0x7F) << shift + stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { + intStringLen := int(stringLen) + if intStringLen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + msglen + postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthGenerated } if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } + m.Provider = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Spec", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - msglen |= int(b&0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + msglen - if postIndex < 0 { - return ErrInvalidLengthGenerated - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - if err := m.Spec.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - case 3: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - msglen |= int(b&0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + msglen - if postIndex < 0 { - return ErrInvalidLengthGenerated - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - if err := m.Status.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipGenerated(dAtA[iNdEx:]) - if err != nil { - return err - } - if (skippy < 0) || (iNdEx+skippy) < 0 { - return ErrInvalidLengthGenerated - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *SubscriptionList) Unmarshal(dAtA []byte) error { - l := len(dAtA) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - wire |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: SubscriptionList: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: SubscriptionList: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ListMeta", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Version", wireType) } - var msglen int + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -11008,28 +7699,27 @@ func (m *SubscriptionList) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - msglen |= int(b&0x7F) << shift + stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { + intStringLen := int(stringLen) + if intStringLen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + msglen + postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthGenerated } if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } + m.Version = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex - case 2: + case 3: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Repositories", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -11056,8 +7746,8 @@ func (m *SubscriptionList) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Items = append(m.Items, Subscription{}) - if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + m.Repositories = append(m.Repositories, &SchemaSpecRepository{}) + if err := m.Repositories[len(m.Repositories)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -11082,7 +7772,7 @@ func (m *SubscriptionList) Unmarshal(dAtA []byte) error { } return nil } -func (m *SubscriptionParameters) Unmarshal(dAtA []byte) error { +func (m *SchemaSpecRepository) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -11105,17 +7795,17 @@ func (m *SubscriptionParameters) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: SubscriptionParameters: wiretype end group for non-group") + return fmt.Errorf("proto: SchemaSpecRepository: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: SubscriptionParameters: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: SchemaSpecRepository: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { - case 1: + case 6: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Dirs", wireType) } - var stringLen uint64 + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -11125,29 +7815,31 @@ func (m *SubscriptionParameters) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - stringLen |= uint64(b&0x7F) << shift + msglen |= int(b&0x7F) << shift if b < 0x80 { break } } - intStringLen := int(stringLen) - if intStringLen < 0 { + if msglen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + intStringLen + postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthGenerated } if postIndex > l { return io.ErrUnexpectedEOF } - m.Name = string(dAtA[iNdEx:postIndex]) + m.Dirs = append(m.Dirs, SrcDstPath{}) + if err := m.Dirs[len(m.Dirs)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } iNdEx = postIndex - case 2: + case 7: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Description", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Schema", wireType) } - var stringLen uint64 + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -11157,28 +7849,28 @@ func (m *SubscriptionParameters) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - stringLen |= uint64(b&0x7F) << shift + msglen |= int(b&0x7F) << shift if b < 0x80 { break } } - intStringLen := int(stringLen) - if intStringLen < 0 { + if msglen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + intStringLen + postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthGenerated } if postIndex > l { return io.ErrUnexpectedEOF } - s := string(dAtA[iNdEx:postIndex]) - m.Description = &s + if err := m.Schema.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } iNdEx = postIndex - case 3: + case 8: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Labels", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Repository", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -11205,140 +7897,63 @@ func (m *SubscriptionParameters) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if m.Labels == nil { - m.Labels = make(map[string]string) - } - var mapkey string - var mapvalue string - for iNdEx < postIndex { - entryPreIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - wire |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - if fieldNum == 1 { - var stringLenmapkey uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - stringLenmapkey |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - intStringLenmapkey := int(stringLenmapkey) - if intStringLenmapkey < 0 { - return ErrInvalidLengthGenerated - } - postStringIndexmapkey := iNdEx + intStringLenmapkey - if postStringIndexmapkey < 0 { - return ErrInvalidLengthGenerated - } - if postStringIndexmapkey > l { - return io.ErrUnexpectedEOF - } - mapkey = string(dAtA[iNdEx:postStringIndexmapkey]) - iNdEx = postStringIndexmapkey - } else if fieldNum == 2 { - var stringLenmapvalue uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - stringLenmapvalue |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - intStringLenmapvalue := int(stringLenmapvalue) - if intStringLenmapvalue < 0 { - return ErrInvalidLengthGenerated - } - postStringIndexmapvalue := iNdEx + intStringLenmapvalue - if postStringIndexmapvalue < 0 { - return ErrInvalidLengthGenerated - } - if postStringIndexmapvalue > l { - return io.ErrUnexpectedEOF - } - mapvalue = string(dAtA[iNdEx:postStringIndexmapvalue]) - iNdEx = postStringIndexmapvalue - } else { - iNdEx = entryPreIndex - skippy, err := skipGenerated(dAtA[iNdEx:]) - if err != nil { - return err - } - if (skippy < 0) || (iNdEx+skippy) < 0 { - return ErrInvalidLengthGenerated - } - if (iNdEx + skippy) > postIndex { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } + if err := m.Repository.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err } - m.Labels[mapkey] = mapvalue iNdEx = postIndex - case 4: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field AdminState", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - stringLen |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err } - intStringLen := int(stringLen) - if intStringLen < 0 { + if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + intStringLen - if postIndex < 0 { - return ErrInvalidLengthGenerated + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF } - if postIndex > l { + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *SchemaSpecSchema) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { return io.ErrUnexpectedEOF } - s := AdminState(dAtA[iNdEx:postIndex]) - m.AdminState = &s - iNdEx = postIndex - case 5: + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: SchemaSpecSchema: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: SchemaSpecSchema: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Mode", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Models", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -11366,13 +7981,13 @@ func (m *SubscriptionParameters) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Mode = SyncMode(dAtA[iNdEx:postIndex]) + m.Models = append(m.Models, string(dAtA[iNdEx:postIndex])) iNdEx = postIndex - case 6: + case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Interval", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Includes", wireType) } - var msglen int + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -11382,31 +7997,27 @@ func (m *SubscriptionParameters) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - msglen |= int(b&0x7F) << shift + stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { + intStringLen := int(stringLen) + if intStringLen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + msglen + postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthGenerated } if postIndex > l { return io.ErrUnexpectedEOF } - if m.Interval == nil { - m.Interval = &v1.Duration{} - } - if err := m.Interval.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } + m.Includes = append(m.Includes, string(dAtA[iNdEx:postIndex])) iNdEx = postIndex - case 7: + case 3: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Paths", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Excludes", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -11434,7 +8045,7 @@ func (m *SubscriptionParameters) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Paths = append(m.Paths, string(dAtA[iNdEx:postIndex])) + m.Excludes = append(m.Excludes, string(dAtA[iNdEx:postIndex])) iNdEx = postIndex default: iNdEx = preIndex @@ -11457,7 +8068,7 @@ func (m *SubscriptionParameters) Unmarshal(dAtA []byte) error { } return nil } -func (m *SubscriptionSpec) Unmarshal(dAtA []byte) error { +func (m *SchemaStatus) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -11480,15 +8091,15 @@ func (m *SubscriptionSpec) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: SubscriptionSpec: wiretype end group for non-group") + return fmt.Errorf("proto: SchemaStatus: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: SubscriptionSpec: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: SchemaStatus: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Target", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field ConditionedStatus", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -11515,15 +8126,15 @@ func (m *SubscriptionSpec) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Target.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + if err := m.ConditionedStatus.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Protocol", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Repositories", wireType) } - var stringLen uint64 + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -11533,46 +8144,79 @@ func (m *SubscriptionSpec) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - stringLen |= uint64(b&0x7F) << shift + msglen |= int(b&0x7F) << shift if b < 0x80 { break } } - intStringLen := int(stringLen) - if intStringLen < 0 { + if msglen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + intStringLen + postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthGenerated } if postIndex > l { return io.ErrUnexpectedEOF } - m.Protocol = Protocol(dAtA[iNdEx:postIndex]) + m.Repositories = append(m.Repositories, SchemaRepositoryStatus{}) + if err := m.Repositories[len(m.Repositories)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } iNdEx = postIndex - case 3: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field Port", wireType) + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err } - m.Port = 0 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - m.Port |= uint32(b&0x7F) << shift - if b < 0x80 { - break - } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return ErrInvalidLengthGenerated } - case 4: + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *SrcDstPath) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: SrcDstPath: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: SrcDstPath: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Encoding", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Src", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -11600,14 +8244,13 @@ func (m *SubscriptionSpec) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - s := Encoding(dAtA[iNdEx:postIndex]) - m.Encoding = &s + m.Src = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex - case 5: + case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Subscriptions", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Dst", wireType) } - var msglen int + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -11617,25 +8260,23 @@ func (m *SubscriptionSpec) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - msglen |= int(b&0x7F) << shift + stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { + intStringLen := int(stringLen) + if intStringLen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + msglen + postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthGenerated } if postIndex > l { return io.ErrUnexpectedEOF } - m.Subscriptions = append(m.Subscriptions, SubscriptionParameters{}) - if err := m.Subscriptions[len(m.Subscriptions)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } + m.Dst = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex @@ -11658,7 +8299,7 @@ func (m *SubscriptionSpec) Unmarshal(dAtA []byte) error { } return nil } -func (m *SubscriptionStatus) Unmarshal(dAtA []byte) error { +func (m *Subscription) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -11681,15 +8322,15 @@ func (m *SubscriptionStatus) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: SubscriptionStatus: wiretype end group for non-group") + return fmt.Errorf("proto: Subscription: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: SubscriptionStatus: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: Subscription: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ConditionedStatus", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -11716,15 +8357,15 @@ func (m *SubscriptionStatus) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ConditionedStatus.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Targets", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Spec", wireType) } - var stringLen uint64 + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -11734,77 +8375,28 @@ func (m *SubscriptionStatus) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - stringLen |= uint64(b&0x7F) << shift + msglen |= int(b&0x7F) << shift if b < 0x80 { break } } - intStringLen := int(stringLen) - if intStringLen < 0 { + if msglen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + intStringLen + postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthGenerated } if postIndex > l { return io.ErrUnexpectedEOF } - m.Targets = append(m.Targets, string(dAtA[iNdEx:postIndex])) - iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipGenerated(dAtA[iNdEx:]) - if err != nil { + if err := m.Spec.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } - if (skippy < 0) || (iNdEx+skippy) < 0 { - return ErrInvalidLengthGenerated - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *SubscriptionTarget) Unmarshal(dAtA []byte) error { - l := len(dAtA) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - wire |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: SubscriptionTarget: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: SubscriptionTarget: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: + iNdEx = postIndex + case 3: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field TargetSelector", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -11831,10 +8423,7 @@ func (m *SubscriptionTarget) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if m.TargetSelector == nil { - m.TargetSelector = &v1.LabelSelector{} - } - if err := m.TargetSelector.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + if err := m.Status.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -11859,7 +8448,7 @@ func (m *SubscriptionTarget) Unmarshal(dAtA []byte) error { } return nil } -func (m *Target) Unmarshal(dAtA []byte) error { +func (m *SubscriptionList) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -11869,61 +8458,28 @@ func (m *Target) Unmarshal(dAtA []byte) error { if shift >= 64 { return ErrIntOverflowGenerated } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - wire |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: Target: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: Target: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - msglen |= int(b&0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + msglen - if postIndex < 0 { - return ErrInvalidLengthGenerated - } - if postIndex > l { + if iNdEx >= l { return io.ErrUnexpectedEOF } - if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break } - iNdEx = postIndex - case 2: + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: SubscriptionList: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: SubscriptionList: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Spec", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field ListMeta", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -11950,13 +8506,13 @@ func (m *Target) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Spec.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex - case 3: + case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -11983,7 +8539,8 @@ func (m *Target) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Status.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + m.Items = append(m.Items, Subscription{}) + if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -12008,7 +8565,7 @@ func (m *Target) Unmarshal(dAtA []byte) error { } return nil } -func (m *TargetConnectionProfile) Unmarshal(dAtA []byte) error { +func (m *SubscriptionParameters) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -12031,17 +8588,17 @@ func (m *TargetConnectionProfile) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: TargetConnectionProfile: wiretype end group for non-group") + return fmt.Errorf("proto: SubscriptionParameters: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: TargetConnectionProfile: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: SubscriptionParameters: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType) } - var msglen int + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -12051,28 +8608,60 @@ func (m *TargetConnectionProfile) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - msglen |= int(b&0x7F) << shift + stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { + intStringLen := int(stringLen) + if intStringLen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + msglen + postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthGenerated } if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } + m.Name = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Spec", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Description", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return ErrInvalidLengthGenerated + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + s := string(dAtA[iNdEx:postIndex]) + m.Description = &s + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Labels", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -12099,63 +8688,172 @@ func (m *TargetConnectionProfile) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Spec.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err + if m.Labels == nil { + m.Labels = make(map[string]string) + } + var mapkey string + var mapvalue string + for iNdEx < postIndex { + entryPreIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + if fieldNum == 1 { + var stringLenmapkey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLenmapkey |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLenmapkey := int(stringLenmapkey) + if intStringLenmapkey < 0 { + return ErrInvalidLengthGenerated + } + postStringIndexmapkey := iNdEx + intStringLenmapkey + if postStringIndexmapkey < 0 { + return ErrInvalidLengthGenerated + } + if postStringIndexmapkey > l { + return io.ErrUnexpectedEOF + } + mapkey = string(dAtA[iNdEx:postStringIndexmapkey]) + iNdEx = postStringIndexmapkey + } else if fieldNum == 2 { + var stringLenmapvalue uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLenmapvalue |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLenmapvalue := int(stringLenmapvalue) + if intStringLenmapvalue < 0 { + return ErrInvalidLengthGenerated + } + postStringIndexmapvalue := iNdEx + intStringLenmapvalue + if postStringIndexmapvalue < 0 { + return ErrInvalidLengthGenerated + } + if postStringIndexmapvalue > l { + return io.ErrUnexpectedEOF + } + mapvalue = string(dAtA[iNdEx:postStringIndexmapvalue]) + iNdEx = postStringIndexmapvalue + } else { + iNdEx = entryPreIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > postIndex { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } } + m.Labels[mapkey] = mapvalue iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipGenerated(dAtA[iNdEx:]) - if err != nil { - return err + case 4: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field AdminState", wireType) } - if (skippy < 0) || (iNdEx+skippy) < 0 { + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { return ErrInvalidLengthGenerated } - if (iNdEx + skippy) > l { + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return ErrInvalidLengthGenerated + } + if postIndex > l { return io.ErrUnexpectedEOF } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *TargetConnectionProfileList) Unmarshal(dAtA []byte) error { - l := len(dAtA) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated + s := AdminState(dAtA[iNdEx:postIndex]) + m.AdminState = &s + iNdEx = postIndex + case 5: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Mode", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } } - if iNdEx >= l { - return io.ErrUnexpectedEOF + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated } - b := dAtA[iNdEx] - iNdEx++ - wire |= uint64(b&0x7F) << shift - if b < 0x80 { - break + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return ErrInvalidLengthGenerated } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: TargetConnectionProfileList: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: TargetConnectionProfileList: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Mode = SyncMode(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 6: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ListMeta", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Interval", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -12182,15 +8880,18 @@ func (m *TargetConnectionProfileList) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + if m.Interval == nil { + m.Interval = &v1.Duration{} + } + if err := m.Interval.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex - case 2: + case 7: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Paths", wireType) } - var msglen int + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -12200,25 +8901,23 @@ func (m *TargetConnectionProfileList) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - msglen |= int(b&0x7F) << shift + stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { + intStringLen := int(stringLen) + if intStringLen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + msglen + postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthGenerated } if postIndex > l { return io.ErrUnexpectedEOF } - m.Items = append(m.Items, TargetConnectionProfile{}) - if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } + m.Paths = append(m.Paths, string(dAtA[iNdEx:postIndex])) iNdEx = postIndex default: iNdEx = preIndex @@ -12241,7 +8940,7 @@ func (m *TargetConnectionProfileList) Unmarshal(dAtA []byte) error { } return nil } -func (m *TargetConnectionProfileSpec) Unmarshal(dAtA []byte) error { +func (m *SubscriptionSpec) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -12264,15 +8963,15 @@ func (m *TargetConnectionProfileSpec) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: TargetConnectionProfileSpec: wiretype end group for non-group") + return fmt.Errorf("proto: SubscriptionSpec: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: TargetConnectionProfileSpec: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: SubscriptionSpec: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ConnectRetry", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Target", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -12299,44 +8998,11 @@ func (m *TargetConnectionProfileSpec) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ConnectRetry.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + if err := m.Target.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex case 2: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Timeout", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - msglen |= int(b&0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + msglen - if postIndex < 0 { - return ErrInvalidLengthGenerated - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - if err := m.Timeout.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - case 3: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Protocol", wireType) } @@ -12368,7 +9034,7 @@ func (m *TargetConnectionProfileSpec) Unmarshal(dAtA []byte) error { } m.Protocol = Protocol(dAtA[iNdEx:postIndex]) iNdEx = postIndex - case 4: + case 3: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field Port", wireType) } @@ -12387,7 +9053,7 @@ func (m *TargetConnectionProfileSpec) Unmarshal(dAtA []byte) error { break } } - case 5: + case 4: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Encoding", wireType) } @@ -12420,11 +9086,11 @@ func (m *TargetConnectionProfileSpec) Unmarshal(dAtA []byte) error { s := Encoding(dAtA[iNdEx:postIndex]) m.Encoding = &s iNdEx = postIndex - case 6: + case 5: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field PreferredNetconfVersion", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Subscriptions", wireType) } - var stringLen uint64 + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -12434,93 +9100,81 @@ func (m *TargetConnectionProfileSpec) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - stringLen |= uint64(b&0x7F) << shift + msglen |= int(b&0x7F) << shift if b < 0x80 { break } } - intStringLen := int(stringLen) - if intStringLen < 0 { + if msglen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + intStringLen + postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthGenerated } if postIndex > l { return io.ErrUnexpectedEOF } - s := string(dAtA[iNdEx:postIndex]) - m.PreferredNetconfVersion = &s + m.Subscriptions = append(m.Subscriptions, SubscriptionParameters{}) + if err := m.Subscriptions[len(m.Subscriptions)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } iNdEx = postIndex - case 7: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field Insecure", wireType) + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err } - var v int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - v |= int(b&0x7F) << shift - if b < 0x80 { - break - } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return ErrInvalidLengthGenerated } - b := bool(v != 0) - m.Insecure = &b - case 8: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field SkipVerify", wireType) + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF } - var v int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - v |= int(b&0x7F) << shift - if b < 0x80 { - break - } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *SubscriptionStatus) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated } - b := bool(v != 0) - m.SkipVerify = &b - case 9: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field IncludeNS", wireType) + if iNdEx >= l { + return io.ErrUnexpectedEOF } - var v int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - v |= int(b&0x7F) << shift - if b < 0x80 { - break - } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break } - b := bool(v != 0) - m.IncludeNS = &b - case 10: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field OperationWithNS", wireType) + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: SubscriptionStatus: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: SubscriptionStatus: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ConditionedStatus", wireType) } - var v int + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -12530,37 +9184,28 @@ func (m *TargetConnectionProfileSpec) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - v |= int(b&0x7F) << shift + msglen |= int(b&0x7F) << shift if b < 0x80 { break } } - b := bool(v != 0) - m.OperationWithNS = &b - case 11: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field UseOperationRemove", wireType) + if msglen < 0 { + return ErrInvalidLengthGenerated } - var v int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - v |= int(b&0x7F) << shift - if b < 0x80 { - break - } + postIndex := iNdEx + msglen + if postIndex < 0 { + return ErrInvalidLengthGenerated } - b := bool(v != 0) - m.UseOperationRemove = &b - case 12: + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.ConditionedStatus.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field CommitCandidate", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Targets", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -12588,14 +9233,63 @@ func (m *TargetConnectionProfileSpec) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - s := CommitCandidate(dAtA[iNdEx:postIndex]) - m.CommitCandidate = &s + m.Targets = append(m.Targets, string(dAtA[iNdEx:postIndex])) iNdEx = postIndex - case 13: + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *SubscriptionTarget) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: SubscriptionTarget: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: SubscriptionTarget: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field TargetName", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field TargetSelector", wireType) } - var stringLen uint64 + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -12605,24 +9299,27 @@ func (m *TargetConnectionProfileSpec) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - stringLen |= uint64(b&0x7F) << shift + msglen |= int(b&0x7F) << shift if b < 0x80 { break } } - intStringLen := int(stringLen) - if intStringLen < 0 { + if msglen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + intStringLen + postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthGenerated } if postIndex > l { return io.ErrUnexpectedEOF } - s := string(dAtA[iNdEx:postIndex]) - m.TargetName = &s + if m.TargetSelector == nil { + m.TargetSelector = &v1.LabelSelector{} + } + if err := m.TargetSelector.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } iNdEx = postIndex default: iNdEx = preIndex @@ -12645,7 +9342,7 @@ func (m *TargetConnectionProfileSpec) Unmarshal(dAtA []byte) error { } return nil } -func (m *TargetList) Unmarshal(dAtA []byte) error { +func (m *TargetConnectionProfile) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -12668,15 +9365,15 @@ func (m *TargetList) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: TargetList: wiretype end group for non-group") + return fmt.Errorf("proto: TargetConnectionProfile: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: TargetList: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: TargetConnectionProfile: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ListMeta", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -12703,13 +9400,13 @@ func (m *TargetList) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Spec", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -12736,8 +9433,7 @@ func (m *TargetList) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Items = append(m.Items, Target{}) - if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + if err := m.Spec.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -12762,7 +9458,7 @@ func (m *TargetList) Unmarshal(dAtA []byte) error { } return nil } -func (m *TargetProfile) Unmarshal(dAtA []byte) error { +func (m *TargetConnectionProfileList) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -12785,17 +9481,17 @@ func (m *TargetProfile) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: TargetProfile: wiretype end group for non-group") + return fmt.Errorf("proto: TargetConnectionProfileList: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: TargetProfile: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: TargetConnectionProfileList: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Credentials", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field ListMeta", wireType) } - var stringLen uint64 + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -12805,29 +9501,30 @@ func (m *TargetProfile) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - stringLen |= uint64(b&0x7F) << shift + msglen |= int(b&0x7F) << shift if b < 0x80 { break } } - intStringLen := int(stringLen) - if intStringLen < 0 { + if msglen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + intStringLen + postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthGenerated } if postIndex > l { return io.ErrUnexpectedEOF } - m.Credentials = string(dAtA[iNdEx:postIndex]) + if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } iNdEx = postIndex case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field TLSSecret", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType) } - var stringLen uint64 + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -12837,30 +9534,81 @@ func (m *TargetProfile) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - stringLen |= uint64(b&0x7F) << shift + msglen |= int(b&0x7F) << shift if b < 0x80 { break } } - intStringLen := int(stringLen) - if intStringLen < 0 { + if msglen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + intStringLen + postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthGenerated } if postIndex > l { return io.ErrUnexpectedEOF } - s := string(dAtA[iNdEx:postIndex]) - m.TLSSecret = &s + m.Items = append(m.Items, TargetConnectionProfile{}) + if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } iNdEx = postIndex - case 3: + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *TargetConnectionProfileSpec) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: TargetConnectionProfileSpec: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: TargetConnectionProfileSpec: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ConnectionProfile", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field ConnectRetry", wireType) } - var stringLen uint64 + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -12870,29 +9618,30 @@ func (m *TargetProfile) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - stringLen |= uint64(b&0x7F) << shift + msglen |= int(b&0x7F) << shift if b < 0x80 { break } } - intStringLen := int(stringLen) - if intStringLen < 0 { + if msglen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + intStringLen + postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthGenerated } if postIndex > l { return io.ErrUnexpectedEOF } - m.ConnectionProfile = string(dAtA[iNdEx:postIndex]) + if err := m.ConnectRetry.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } iNdEx = postIndex - case 4: + case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field SyncProfile", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Timeout", wireType) } - var stringLen uint64 + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -12902,78 +9651,28 @@ func (m *TargetProfile) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - stringLen |= uint64(b&0x7F) << shift + msglen |= int(b&0x7F) << shift if b < 0x80 { break } } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex < 0 { - return ErrInvalidLengthGenerated - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - s := string(dAtA[iNdEx:postIndex]) - m.SyncProfile = &s - iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipGenerated(dAtA[iNdEx:]) - if err != nil { - return err - } - if (skippy < 0) || (iNdEx+skippy) < 0 { + if msglen < 0 { return ErrInvalidLengthGenerated } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *TargetSpec) Unmarshal(dAtA []byte) error { - l := len(dAtA) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated + postIndex := iNdEx + msglen + if postIndex < 0 { + return ErrInvalidLengthGenerated } - if iNdEx >= l { + if postIndex > l { return io.ErrUnexpectedEOF } - b := dAtA[iNdEx] - iNdEx++ - wire |= uint64(b&0x7F) << shift - if b < 0x80 { - break + if err := m.Timeout.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: TargetSpec: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: TargetSpec: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: + iNdEx = postIndex + case 3: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Provider", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Protocol", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -13001,11 +9700,30 @@ func (m *TargetSpec) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Provider = string(dAtA[iNdEx:postIndex]) + m.Protocol = Protocol(dAtA[iNdEx:postIndex]) iNdEx = postIndex - case 2: + case 4: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Port", wireType) + } + m.Port = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.Port |= uint32(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 5: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Address", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Encoding", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -13033,13 +9751,14 @@ func (m *TargetSpec) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Address = string(dAtA[iNdEx:postIndex]) + s := Encoding(dAtA[iNdEx:postIndex]) + m.Encoding = &s iNdEx = postIndex - case 3: + case 6: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field TargetProfile", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field PreferredNetconfVersion", wireType) } - var msglen int + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -13049,80 +9768,72 @@ func (m *TargetSpec) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - msglen |= int(b&0x7F) << shift + stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { + intStringLen := int(stringLen) + if intStringLen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + msglen + postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthGenerated } if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.TargetProfile.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } + s := string(dAtA[iNdEx:postIndex]) + m.PreferredNetconfVersion = &s iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipGenerated(dAtA[iNdEx:]) - if err != nil { - return err - } - if (skippy < 0) || (iNdEx+skippy) < 0 { - return ErrInvalidLengthGenerated - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF + case 7: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Insecure", wireType) } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *TargetStatus) Unmarshal(dAtA []byte) error { - l := len(dAtA) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated + var v int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= int(b&0x7F) << shift + if b < 0x80 { + break + } } - if iNdEx >= l { - return io.ErrUnexpectedEOF + b := bool(v != 0) + m.Insecure = &b + case 8: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field SkipVerify", wireType) } - b := dAtA[iNdEx] - iNdEx++ - wire |= uint64(b&0x7F) << shift - if b < 0x80 { - break + var v int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= int(b&0x7F) << shift + if b < 0x80 { + break + } } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: TargetStatus: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: TargetStatus: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ConditionedStatus", wireType) + b := bool(v != 0) + m.SkipVerify = &b + case 9: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field IncludeNS", wireType) } - var msglen int + var v int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -13132,30 +9843,60 @@ func (m *TargetStatus) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - msglen |= int(b&0x7F) << shift + v |= int(b&0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { - return ErrInvalidLengthGenerated + b := bool(v != 0) + m.IncludeNS = &b + case 10: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field OperationWithNS", wireType) } - postIndex := iNdEx + msglen - if postIndex < 0 { - return ErrInvalidLengthGenerated + var v int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= int(b&0x7F) << shift + if b < 0x80 { + break + } } - if postIndex > l { - return io.ErrUnexpectedEOF + b := bool(v != 0) + m.OperationWithNS = &b + case 11: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field UseOperationRemove", wireType) } - if err := m.ConditionedStatus.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err + var v int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= int(b&0x7F) << shift + if b < 0x80 { + break + } } - iNdEx = postIndex - case 2: + b := bool(v != 0) + m.UseOperationRemove = &b + case 12: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field DiscoveryInfo", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field CommitCandidate", wireType) } - var msglen int + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -13165,33 +9906,30 @@ func (m *TargetStatus) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - msglen |= int(b&0x7F) << shift + stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { + intStringLen := int(stringLen) + if intStringLen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + msglen + postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthGenerated } if postIndex > l { return io.ErrUnexpectedEOF } - if m.DiscoveryInfo == nil { - m.DiscoveryInfo = &DiscoveryInfo{} - } - if err := m.DiscoveryInfo.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } + s := CommitCandidate(dAtA[iNdEx:postIndex]) + m.CommitCandidate = &s iNdEx = postIndex - case 3: + case 13: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field UsedReferences", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field TargetName", wireType) } - var msglen int + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -13201,27 +9939,24 @@ func (m *TargetStatus) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - msglen |= int(b&0x7F) << shift + stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { + intStringLen := int(stringLen) + if intStringLen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + msglen + postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthGenerated } if postIndex > l { return io.ErrUnexpectedEOF } - if m.UsedReferences == nil { - m.UsedReferences = &TargetStatusUsedReferences{} - } - if err := m.UsedReferences.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } + s := string(dAtA[iNdEx:postIndex]) + m.TargetName = &s iNdEx = postIndex default: iNdEx = preIndex @@ -13244,7 +9979,7 @@ func (m *TargetStatus) Unmarshal(dAtA []byte) error { } return nil } -func (m *TargetStatusUsedReferences) Unmarshal(dAtA []byte) error { +func (m *TargetProfile) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -13267,15 +10002,15 @@ func (m *TargetStatusUsedReferences) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: TargetStatusUsedReferences: wiretype end group for non-group") + return fmt.Errorf("proto: TargetProfile: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: TargetStatusUsedReferences: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: TargetProfile: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field SecretResourceVersion", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Credentials", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -13303,11 +10038,11 @@ func (m *TargetStatusUsedReferences) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.SecretResourceVersion = string(dAtA[iNdEx:postIndex]) + m.Credentials = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field TLSSecretResourceVersion", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field TLSSecret", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -13335,11 +10070,12 @@ func (m *TargetStatusUsedReferences) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.TLSSecretResourceVersion = string(dAtA[iNdEx:postIndex]) + s := string(dAtA[iNdEx:postIndex]) + m.TLSSecret = &s iNdEx = postIndex case 3: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ConnectionProfileResourceVersion", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field ConnectionProfile", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -13367,11 +10103,11 @@ func (m *TargetStatusUsedReferences) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.ConnectionProfileResourceVersion = string(dAtA[iNdEx:postIndex]) + m.ConnectionProfile = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 4: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field SyncProfileResourceVersion", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field SyncProfile", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -13399,7 +10135,8 @@ func (m *TargetStatusUsedReferences) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.SyncProfileResourceVersion = string(dAtA[iNdEx:postIndex]) + s := string(dAtA[iNdEx:postIndex]) + m.SyncProfile = &s iNdEx = postIndex default: iNdEx = preIndex diff --git a/apis/inv/v1alpha1/generated.proto b/apis/inv/v1alpha1/generated.proto index f523837d..7a1b208c 100644 --- a/apis/inv/v1alpha1/generated.proto +++ b/apis/inv/v1alpha1/generated.proto @@ -26,32 +26,6 @@ import "k8s.io/apimachinery/pkg/runtime/schema/generated.proto"; // Package-wide variables from generator "generated". option go_package = "github.com/sdcio/config-server/apis/inv/v1alpha1"; -message DiscoveryInfo { - // Protocol used for discovery - optional string protocol = 1; - - // Type associated with the target - optional string provider = 2; - - // Version associated with the target - optional string version = 3; - - // HostName associated with the target - optional string hostname = 4; - - // Platform associated with the target - optional string platform = 5; - - // MacAddress associated with the target - optional string macAddress = 6; - - // SerialNumber associated with the target - optional string serialNumber = 7; - - // Supported Encodings of the target - repeated string supportedEncodings = 8; -} - message DiscoveryParameters { // DefaultSchema define the default schema used to connect to a target // Indicates that discovery is disable; cannot be used for prefix based discovery rules @@ -62,6 +36,7 @@ message DiscoveryParameters { // TargetConnectionProfiles define the profile the discovery controller uses to create targets // once discovered + // +listType=atomic repeated TargetProfile targetConnectionProfiles = 3; // TargetTemplate defines the template the discovery controller uses to create the targets as a result of the discovery @@ -97,6 +72,7 @@ message DiscoveryProfile { // ConnectionProfiles define the list of profiles the discovery controller uses to discover the target. // The order in which they are specified is the order in which discovery is executed. + // +listType=atomic repeated string connectionProfiles = 3; } @@ -139,15 +115,18 @@ message DiscoveryRulePrefix { optional string prefix = 1; // IP Prefixes to be excluded + // +listType=atomic repeated string excludes = 2; } // DiscoveryRuleSpec defines the desired state of DiscoveryRule message DiscoveryRuleSpec { // IP Prefixes for which this discovery rule applies + // +listType=atomic repeated DiscoveryRulePrefix prefixes = 1; // IP Prefixes for which this discovery rule applies + // +listType=atomic repeated DiscoveryRuleAddress addresses = 2; // PodSelector defines the pod selector for which this discovery rule applies @@ -210,6 +189,7 @@ message GnmiDiscoveryVendorProfileParameters { optional string modelMatch = 2; // Paths DiscoveryPaths `json:"paths" protobuf:"bytes,3,opt,name=paths"` + // +listType=atomic repeated DiscoveryPathDefinition paths = 3; // +kubebuilder:validation:XValidation:rule="self == oldSelf",message="encoding is immutable" @@ -224,14 +204,14 @@ message GnmiDiscoveryVendorProfileParameters { message Proxy { // URL specifies the base URL of the HTTP/HTTPS proxy server. - optional string URL = 1; + optional string url = 1; // Credentials defines the name of the secret that holds the credentials to connect to the proxy server optional string credentials = 2; } message Repository { - // RepositoryURL specifies the base URL for a given repository + // RepoURL specifies the base URL for a given repository optional string repoURL = 1; // Credentials defines the name of the secret that holds the credentials to connect to the repo @@ -293,6 +273,7 @@ message RolloutStatus { optional .github.com.sdcio.config_server.apis.condition.v1alpha1.ConditionedStatus conditionedStatus = 1; // Targets defines the status of the rollout on the respective target + // +listType=atomic repeated RolloutTargetStatus targets = 2; } @@ -363,6 +344,7 @@ message SchemaSpec { // +kubebuilder:validation:MinItems:=1 // +kubebuilder:validation:MaxItems:=10 // Repositories define the repositories used for building the provider schema + // +listType=atomic repeated SchemaSpecRepository repositories = 3; } @@ -372,6 +354,7 @@ message SchemaSpecRepository { // +kubebuilder:validation:MaxItems=10 // Dirs defines the list of directories that identified the provider schema in src/dst pairs // relative within the repository + // +listType=atomic repeated SrcDstPath dirs = 6; // Schema provides the details of which files must be used for the models and which files/directories @@ -382,14 +365,17 @@ message SchemaSpecRepository { message SchemaSpecSchema { // +kubebuilder:validation:MaxItems=64 // Models defines the list of files/directories to be used as a model + // +listType=atomic repeated string models = 1; // +kubebuilder:validation:MaxItems=64 // Excludes defines the list of files/directories to be excluded + // +listType=atomic repeated string includes = 2; // +kubebuilder:validation:MaxItems=64 // Excludes defines the list of files/directories to be excluded + // +listType=atomic repeated string excludes = 3; } @@ -399,6 +385,7 @@ message SchemaStatus { optional .github.com.sdcio.config_server.apis.condition.v1alpha1.ConditionedStatus conditionedStatus = 1; // SchemaRepositoryStatus provides the array of repositories + // +listType=atomic repeated SchemaRepositoryStatus repositories = 2; } @@ -471,6 +458,7 @@ message SubscriptionParameters { optional .k8s.io.apimachinery.pkg.apis.meta.v1.Duration interval = 6; // +kubebuilder:validation:MaxItems=128 + // +listType=atomic repeated string paths = 7; } @@ -492,6 +480,7 @@ message SubscriptionSpec { // +kubebuilder:validation:MaxItems=128 // +kubebuilder:validation:Optional + // +listType=atomic repeated SubscriptionParameters subscriptions = 5; } @@ -500,6 +489,7 @@ message SubscriptionStatus { optional .github.com.sdcio.config_server.apis.condition.v1alpha1.ConditionedStatus conditionedStatus = 1; // Targets defines the list of targets this resource applies to + // +listType=atomic repeated string targets = 2; } @@ -508,30 +498,6 @@ message SubscriptionTarget { optional .k8s.io.apimachinery.pkg.apis.meta.v1.LabelSelector targetSelector = 1; } -// +kubebuilder:object:root=true -// +genclient -// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object -// +kubebuilder:object:root=true -// +kubebuilder:subresource:status -// +kubebuilder:printcolumn:name="READY",type="string",JSONPath=".status.conditions[?(@.type=='Ready')].status" -// +kubebuilder:printcolumn:name="REASON",type="string",JSONPath=".status.conditions[?(@.type=='Ready')].message" -// +kubebuilder:printcolumn:name="PROVIDER",type="string",JSONPath=".spec.provider" -// +kubebuilder:printcolumn:name="VERSION",type="string",JSONPath=".status.discoveryInfo.version" -// +kubebuilder:printcolumn:name="ADDRESS",type="string",JSONPath=".spec.address" -// +kubebuilder:printcolumn:name="PLATFORM",type="string",JSONPath=".status.discoveryInfo.platform" -// +kubebuilder:printcolumn:name="SERIALNUMBER",type="string",JSONPath=".status.discoveryInfo.serialNumber" -// +kubebuilder:printcolumn:name="MACADDRESS",type="string",JSONPath=".status.discoveryInfo.macAddress" -// +kubebuilder:resource:categories={sdc,inv} -// Target is the Schema for the Target API -// +k8s:openapi-gen=true -message Target { - optional .k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1; - - optional TargetSpec spec = 2; - - optional TargetStatus status = 3; -} - // +kubebuilder:object:root=true // +genclient // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object @@ -619,15 +585,6 @@ message TargetConnectionProfileSpec { optional string targetName = 13; } -// +kubebuilder:object:root=true -// TargetList contains a list of Targets -// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object -message TargetList { - optional .k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta metadata = 1; - - repeated Target items = 2; -} - message TargetProfile { // Credentials defines the name of the secret that holds the credentials to connect to the target optional string credentials = 1; @@ -642,40 +599,6 @@ message TargetProfile { optional string syncProfile = 4; } -// TargetSpec defines the desired state of Target -message TargetSpec { - // Provider specifies the provider using this target. - optional string provider = 1; - - // Address defines the address to connect to the target - optional string address = 2; - - // TargetProfile defines the Credentials/TLSSecret and sync/connectivity profile to connect to the target - optional TargetProfile targetProfile = 3; -} - -// TargetStatus defines the observed state of Target -message TargetStatus { - // ConditionedStatus provides the status of the Target using conditions - optional .github.com.sdcio.config_server.apis.condition.v1alpha1.ConditionedStatus conditionedStatus = 1; - - // Discovery info defines the information retrieved during discovery - optional DiscoveryInfo discoveryInfo = 2; - - // UsedReferences track the resource used to reconcile the cr - optional TargetStatusUsedReferences usedReferences = 3; -} - -message TargetStatusUsedReferences { - optional string secretResourceVersion = 1; - - optional string tlsSecretResourceVersion = 2; - - optional string connectionProfileResourceVersion = 3; - - optional string syncProfileResourceVersion = 4; -} - // +kubebuilder:object:root=true // +genclient // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object @@ -721,6 +644,7 @@ message TargetSyncProfileSpec { // +kubebuilder:validation:MaxItems=10 // +kubebuilder:validation:Optional // +kubebuilder:validation:XValidation:rule="oldSelf.all(x, x in self)",message="sync may only be added" + // +listType=atomic repeated TargetSyncProfileSync sync = 4; } @@ -737,6 +661,7 @@ message TargetSyncProfileSync { optional uint32 port = 3; // +kubebuilder:validation:MaxItems=10 + // +listType=atomic repeated string paths = 4; // +kubebuilder:validation:Enum=unknown;onChange;sample;once;get; diff --git a/apis/inv/v1alpha1/generated.protomessage.pb.go b/apis/inv/v1alpha1/generated.protomessage.pb.go new file mode 100644 index 00000000..4efc85f4 --- /dev/null +++ b/apis/inv/v1alpha1/generated.protomessage.pb.go @@ -0,0 +1,118 @@ +//go:build kubernetes_protomessage_one_more_release +// +build kubernetes_protomessage_one_more_release + +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +// Code generated by go-to-protobuf. DO NOT EDIT. + +package v1alpha1 + +func (*DiscoveryParameters) ProtoMessage() {} + +func (*DiscoveryPathDefinition) ProtoMessage() {} + +func (*DiscoveryProfile) ProtoMessage() {} + +func (*DiscoveryRule) ProtoMessage() {} + +func (*DiscoveryRuleAddress) ProtoMessage() {} + +func (*DiscoveryRuleList) ProtoMessage() {} + +func (*DiscoveryRulePrefix) ProtoMessage() {} + +func (*DiscoveryRuleSpec) ProtoMessage() {} + +func (*DiscoveryRuleStatus) ProtoMessage() {} + +func (*DiscoveryVendorProfile) ProtoMessage() {} + +func (*DiscoveryVendorProfileList) ProtoMessage() {} + +func (*DiscoveryVendorProfileSpec) ProtoMessage() {} + +func (*GnmiDiscoveryVendorProfileParameters) ProtoMessage() {} + +func (*Proxy) ProtoMessage() {} + +func (*Repository) ProtoMessage() {} + +func (*Rollout) ProtoMessage() {} + +func (*RolloutList) ProtoMessage() {} + +func (*RolloutSpec) ProtoMessage() {} + +func (*RolloutStatus) ProtoMessage() {} + +func (*RolloutTargetStatus) ProtoMessage() {} + +func (*Schema) ProtoMessage() {} + +func (*SchemaKey) ProtoMessage() {} + +func (*SchemaList) ProtoMessage() {} + +func (*SchemaRepositoryStatus) ProtoMessage() {} + +func (*SchemaSpec) ProtoMessage() {} + +func (*SchemaSpecRepository) ProtoMessage() {} + +func (*SchemaSpecSchema) ProtoMessage() {} + +func (*SchemaStatus) ProtoMessage() {} + +func (*SrcDstPath) ProtoMessage() {} + +func (*Subscription) ProtoMessage() {} + +func (*SubscriptionList) ProtoMessage() {} + +func (*SubscriptionParameters) ProtoMessage() {} + +func (*SubscriptionSpec) ProtoMessage() {} + +func (*SubscriptionStatus) ProtoMessage() {} + +func (*SubscriptionTarget) ProtoMessage() {} + +func (*TargetConnectionProfile) ProtoMessage() {} + +func (*TargetConnectionProfileList) ProtoMessage() {} + +func (*TargetConnectionProfileSpec) ProtoMessage() {} + +func (*TargetProfile) ProtoMessage() {} + +func (*TargetSyncProfile) ProtoMessage() {} + +func (*TargetSyncProfileList) ProtoMessage() {} + +func (*TargetSyncProfileSpec) ProtoMessage() {} + +func (*TargetSyncProfileSync) ProtoMessage() {} + +func (*TargetTemplate) ProtoMessage() {} + +func (*Workspace) ProtoMessage() {} + +func (*WorkspaceList) ProtoMessage() {} + +func (*WorkspaceSpec) ProtoMessage() {} + +func (*WorkspaceStatus) ProtoMessage() {} diff --git a/apis/inv/v1alpha1/target_helpers.go b/apis/inv/v1alpha1/target_helpers.go index e9dff6a6..7c459179 100644 --- a/apis/inv/v1alpha1/target_helpers.go +++ b/apis/inv/v1alpha1/target_helpers.go @@ -16,6 +16,7 @@ limitations under the License. package v1alpha1 +/* import ( "fmt" strings "strings" @@ -149,3 +150,4 @@ func BuildTarget(meta metav1.ObjectMeta, spec TargetSpec, status TargetStatus) * Status: status, } } +*/ diff --git a/apis/inv/v1alpha1/target_types.go b/apis/inv/v1alpha1/target_types.go index e5207cf8..c3de4648 100644 --- a/apis/inv/v1alpha1/target_types.go +++ b/apis/inv/v1alpha1/target_types.go @@ -16,6 +16,7 @@ limitations under the License. package v1alpha1 +/* import ( "reflect" @@ -107,7 +108,7 @@ type TargetList struct { } func init() { - localSchemeBuilder.Register(&Target{}, &TargetList{}) + //localSchemeBuilder.Register(&Target{}, &TargetList{}) } var ( @@ -116,3 +117,4 @@ var ( TargetKindAPIVersion = TargetKind + "." + SchemeGroupVersion.String() TargetGroupVersionKind = SchemeGroupVersion.WithKind(TargetKind) ) +*/ diff --git a/apis/inv/v1alpha1/targetconnprofile_types.go b/apis/inv/v1alpha1/targetconnprofile_types.go index 8c2581c0..6890be32 100644 --- a/apis/inv/v1alpha1/targetconnprofile_types.go +++ b/apis/inv/v1alpha1/targetconnprofile_types.go @@ -156,6 +156,6 @@ func init() { var ( TargetConnectionProfileKind = reflect.TypeOf(TargetConnectionProfile{}).Name() TargetConnectionProfileGroupKind = schema.GroupKind{Group: SchemeGroupVersion.Group, Kind: TargetConnectionProfileKind}.String() - TargetConnectionProfileKindAPIVersion = TargetKind + "." + SchemeGroupVersion.String() + TargetConnectionProfileKindAPIVersion = TargetConnectionProfileKind + "." + SchemeGroupVersion.String() TargetConnectionProfileGroupVersionKind = SchemeGroupVersion.WithKind(TargetConnectionProfileKind) ) diff --git a/apis/inv/v1alpha1/targetsyncprofile_types.go b/apis/inv/v1alpha1/targetsyncprofile_types.go index 7ce79d71..f6d28ece 100644 --- a/apis/inv/v1alpha1/targetsyncprofile_types.go +++ b/apis/inv/v1alpha1/targetsyncprofile_types.go @@ -111,6 +111,6 @@ func init() { var ( TargetSyncProfileKind = reflect.TypeOf(TargetSyncProfile{}).Name() TargetSyncProfileGroupKind = schema.GroupKind{Group: SchemeGroupVersion.Group, Kind: TargetSyncProfileKind}.String() - TargetSyncProfileKindAPIVersion = TargetKind + "." + SchemeGroupVersion.String() + TargetSyncProfileKindAPIVersion = TargetSyncProfileKind + "." + SchemeGroupVersion.String() TargetSyncProfileGroupVersionKind = SchemeGroupVersion.WithKind(TargetSyncProfileKind) ) diff --git a/apis/inv/v1alpha1/zz_generated.deepcopy.go b/apis/inv/v1alpha1/zz_generated.deepcopy.go index 4d2b728c..d99e8115 100644 --- a/apis/inv/v1alpha1/zz_generated.deepcopy.go +++ b/apis/inv/v1alpha1/zz_generated.deepcopy.go @@ -25,27 +25,6 @@ import ( runtime "k8s.io/apimachinery/pkg/runtime" ) -// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *DiscoveryInfo) DeepCopyInto(out *DiscoveryInfo) { - *out = *in - if in.SupportedEncodings != nil { - in, out := &in.SupportedEncodings, &out.SupportedEncodings - *out = make([]string, len(*in)) - copy(*out, *in) - } - return -} - -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DiscoveryInfo. -func (in *DiscoveryInfo) DeepCopy() *DiscoveryInfo { - if in == nil { - return nil - } - out := new(DiscoveryInfo) - in.DeepCopyInto(out) - return out -} - // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *DiscoveryParameters) DeepCopyInto(out *DiscoveryParameters) { *out = *in @@ -959,34 +938,6 @@ func (in *SubscriptionTarget) DeepCopy() *SubscriptionTarget { return out } -// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *Target) DeepCopyInto(out *Target) { - *out = *in - out.TypeMeta = in.TypeMeta - in.ObjectMeta.DeepCopyInto(&out.ObjectMeta) - in.Spec.DeepCopyInto(&out.Spec) - in.Status.DeepCopyInto(&out.Status) - return -} - -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Target. -func (in *Target) DeepCopy() *Target { - if in == nil { - return nil - } - out := new(Target) - in.DeepCopyInto(out) - return out -} - -// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. -func (in *Target) DeepCopyObject() runtime.Object { - if c := in.DeepCopy(); c != nil { - return c - } - return nil -} - // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *TargetConnectionProfile) DeepCopyInto(out *TargetConnectionProfile) { *out = *in @@ -1110,39 +1061,6 @@ func (in *TargetConnectionProfileSpec) DeepCopy() *TargetConnectionProfileSpec { return out } -// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *TargetList) DeepCopyInto(out *TargetList) { - *out = *in - out.TypeMeta = in.TypeMeta - in.ListMeta.DeepCopyInto(&out.ListMeta) - if in.Items != nil { - in, out := &in.Items, &out.Items - *out = make([]Target, len(*in)) - for i := range *in { - (*in)[i].DeepCopyInto(&(*out)[i]) - } - } - return -} - -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new TargetList. -func (in *TargetList) DeepCopy() *TargetList { - if in == nil { - return nil - } - out := new(TargetList) - in.DeepCopyInto(out) - return out -} - -// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. -func (in *TargetList) DeepCopyObject() runtime.Object { - if c := in.DeepCopy(); c != nil { - return c - } - return nil -} - // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *TargetProfile) DeepCopyInto(out *TargetProfile) { *out = *in @@ -1169,66 +1087,6 @@ func (in *TargetProfile) DeepCopy() *TargetProfile { return out } -// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *TargetSpec) DeepCopyInto(out *TargetSpec) { - *out = *in - in.TargetProfile.DeepCopyInto(&out.TargetProfile) - return -} - -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new TargetSpec. -func (in *TargetSpec) DeepCopy() *TargetSpec { - if in == nil { - return nil - } - out := new(TargetSpec) - in.DeepCopyInto(out) - return out -} - -// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *TargetStatus) DeepCopyInto(out *TargetStatus) { - *out = *in - in.ConditionedStatus.DeepCopyInto(&out.ConditionedStatus) - if in.DiscoveryInfo != nil { - in, out := &in.DiscoveryInfo, &out.DiscoveryInfo - *out = new(DiscoveryInfo) - (*in).DeepCopyInto(*out) - } - if in.UsedReferences != nil { - in, out := &in.UsedReferences, &out.UsedReferences - *out = new(TargetStatusUsedReferences) - **out = **in - } - return -} - -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new TargetStatus. -func (in *TargetStatus) DeepCopy() *TargetStatus { - if in == nil { - return nil - } - out := new(TargetStatus) - in.DeepCopyInto(out) - return out -} - -// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *TargetStatusUsedReferences) DeepCopyInto(out *TargetStatusUsedReferences) { - *out = *in - return -} - -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new TargetStatusUsedReferences. -func (in *TargetStatusUsedReferences) DeepCopy() *TargetStatusUsedReferences { - if in == nil { - return nil - } - out := new(TargetStatusUsedReferences) - in.DeepCopyInto(out) - return out -} - // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *TargetSyncProfile) DeepCopyInto(out *TargetSyncProfile) { *out = *in diff --git a/artifacts/in/configmap-input-vars.yaml b/artifacts/in/configmap-input-vars.yaml index fef462d7..dd94988c 100644 --- a/artifacts/in/configmap-input-vars.yaml +++ b/artifacts/in/configmap-input-vars.yaml @@ -5,5 +5,5 @@ metadata: data: sdcApiServerImage: europe-docker.pkg.dev/srlinux/eu.gcr.io/sdc-apiserver:latest sdcControllerImage: europe-docker.pkg.dev/srlinux/eu.gcr.io/sdc-controller:latest - dataServerImage: ghcr.io/sdcio/data-server:v0.0.66 + dataServerImage: ghcr.io/sdcio/data-server:v0.0.67 diff --git a/artifacts/inv.sdcio.dev_targets.yaml b/artifacts/inv.sdcio.dev_targets.yaml deleted file mode 100644 index ca896dc5..00000000 --- a/artifacts/inv.sdcio.dev_targets.yaml +++ /dev/null @@ -1,211 +0,0 @@ ---- -apiVersion: apiextensions.k8s.io/v1 -kind: CustomResourceDefinition -metadata: - annotations: - controller-gen.kubebuilder.io/version: v0.20.0 - name: targets.inv.sdcio.dev -spec: - group: inv.sdcio.dev - names: - categories: - - sdc - - inv - kind: Target - listKind: TargetList - plural: targets - singular: target - scope: Namespaced - versions: - - additionalPrinterColumns: - - jsonPath: .status.conditions[?(@.type=='Ready')].status - name: READY - type: string - - jsonPath: .status.conditions[?(@.type=='Ready')].message - name: REASON - type: string - - jsonPath: .spec.provider - name: PROVIDER - type: string - - jsonPath: .status.discoveryInfo.version - name: VERSION - type: string - - jsonPath: .spec.address - name: ADDRESS - type: string - - jsonPath: .status.discoveryInfo.platform - name: PLATFORM - type: string - - jsonPath: .status.discoveryInfo.serialNumber - name: SERIALNUMBER - type: string - - jsonPath: .status.discoveryInfo.macAddress - name: MACADDRESS - type: string - name: v1alpha1 - schema: - openAPIV3Schema: - description: Target is the Schema for the Target API - properties: - apiVersion: - description: |- - APIVersion defines the versioned schema of this representation of an object. - Servers should convert recognized schemas to the latest internal value, and - may reject unrecognized values. - More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources - type: string - kind: - description: |- - Kind is a string value representing the REST resource this object represents. - Servers may infer this from the endpoint the client submits requests to. - Cannot be updated. - In CamelCase. - More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds - type: string - metadata: - type: object - spec: - description: TargetSpec defines the desired state of Target - properties: - address: - description: Address defines the address to connect to the target - type: string - connectionProfile: - description: ConnectionProfile define the profile used to connect - to the target once discovered - type: string - credentials: - description: Credentials defines the name of the secret that holds - the credentials to connect to the target - type: string - provider: - description: Provider specifies the provider using this target. - type: string - syncProfile: - description: SyncProfile define the profile used to sync to the target - config once discovered - type: string - tlsSecret: - description: TLSSecret defines the name of the TLS secret to connect - to the target if mtls is used - type: string - required: - - address - - connectionProfile - - credentials - - provider - type: object - status: - description: TargetStatus defines the observed state of Target - properties: - conditions: - description: Conditions of the resource. - items: - properties: - lastTransitionTime: - description: |- - lastTransitionTime is the last time the condition transitioned from one status to another. - This should be when the underlying condition changed. If that is not known, then using the time when the API field changed is acceptable. - format: date-time - type: string - message: - description: |- - message is a human readable message indicating details about the transition. - This may be an empty string. - maxLength: 32768 - type: string - observedGeneration: - description: |- - observedGeneration represents the .metadata.generation that the condition was set based upon. - For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date - with respect to the current state of the instance. - format: int64 - minimum: 0 - type: integer - reason: - description: |- - reason contains a programmatic identifier indicating the reason for the condition's last transition. - Producers of specific condition types may define expected values and meanings for this field, - and whether the values are considered a guaranteed API. - The value should be a CamelCase string. - This field may not be empty. - maxLength: 1024 - minLength: 1 - pattern: ^[A-Za-z]([A-Za-z0-9_,:]*[A-Za-z0-9_])?$ - type: string - status: - description: status of the condition, one of True, False, Unknown. - enum: - - "True" - - "False" - - Unknown - type: string - type: - description: type of condition in CamelCase or in foo.example.com/CamelCase. - maxLength: 316 - pattern: ^([a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*/)?(([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9])$ - type: string - required: - - lastTransitionTime - - message - - reason - - status - - type - type: object - type: array - x-kubernetes-list-map-keys: - - type - x-kubernetes-list-type: map - discoveryInfo: - description: Discovery info defines the information retrieved during - discovery - properties: - hostname: - description: HostName associated with the target - type: string - macAddress: - description: MacAddress associated with the target - type: string - platform: - description: Platform associated with the target - type: string - protocol: - description: Protocol used for discovery - type: string - provider: - description: Type associated with the target - type: string - serialNumber: - description: SerialNumber associated with the target - type: string - supportedEncodings: - description: Supported Encodings of the target - items: - type: string - type: array - version: - description: Version associated with the target - type: string - type: object - usedReferences: - description: UsedReferences track the resource used to reconcile the - cr - properties: - connectionProfileResourceVersion: - type: string - secretResourceVersion: - type: string - syncProfileResourceVersion: - type: string - tlsSecretResourceVersion: - type: string - required: - - connectionProfileResourceVersion - - syncProfileResourceVersion - type: object - type: object - type: object - served: true - storage: true - subresources: - status: {} diff --git a/artifacts/rbac-cluster-role-api-server.yaml b/artifacts/rbac-cluster-role-api-server.yaml index e43d38da..037ee431 100644 --- a/artifacts/rbac-cluster-role-api-server.yaml +++ b/artifacts/rbac-cluster-role-api-server.yaml @@ -15,6 +15,6 @@ rules: - apiGroups: ["flowcontrol.apiserver.k8s.io"] resources: ["flowschemas", "prioritylevelconfigurations"] verbs: ["get", "watch", "list"] -- apiGroups: ["inv.sdcio.dev"] +- apiGroups: ["config.sdcio.dev"] resources: ["targets", "targets/status"] verbs: ["get", "watch", "list"] diff --git a/artifacts/rbac-cluster-role-controller.yaml b/artifacts/rbac-cluster-role-controller.yaml index 09fdb9e2..6ca7e1e3 100644 --- a/artifacts/rbac-cluster-role-controller.yaml +++ b/artifacts/rbac-cluster-role-controller.yaml @@ -24,7 +24,7 @@ rules: - apiGroups: ["config.sdcio.dev"] resources: ["deviations", "deviations/status"] verbs: ["get", "watch", "list", "create", "update", "patch", "delete"] -- apiGroups: ["inv.sdcio.dev"] +- apiGroups: ["config.sdcio.dev"] resources: ["targets", "targets/status"] verbs: ["get", "watch", "list", "create", "update", "patch", "delete"] - apiGroups: ["inv.sdcio.dev"] diff --git a/artifacts/rbac-cluster-role-data-server-controller.yaml b/artifacts/rbac-cluster-role-data-server-controller.yaml index 5a1bfc5b..c4989d32 100644 --- a/artifacts/rbac-cluster-role-data-server-controller.yaml +++ b/artifacts/rbac-cluster-role-data-server-controller.yaml @@ -24,7 +24,7 @@ rules: - apiGroups: ["config.sdcio.dev"] resources: ["deviations", "deviations/status"] verbs: ["get", "watch", "list", "create", "update", "patch", "delete"] -- apiGroups: ["inv.sdcio.dev"] +- apiGroups: ["config.sdcio.dev"] resources: ["targets", "targets/status"] verbs: ["get", "watch", "list", "create", "update", "patch", "delete"] - apiGroups: ["inv.sdcio.dev"] diff --git a/go.mod b/go.mod index 968c8669..ba391e67 100644 --- a/go.mod +++ b/go.mod @@ -5,7 +5,6 @@ go 1.25.0 require ( github.com/dgraph-io/badger/v4 v4.9.1 github.com/go-git/go-git/v5 v5.16.5 - github.com/gogo/protobuf v1.3.2 github.com/google/go-cmp v0.7.0 github.com/google/uuid v1.6.0 github.com/henderiw/apiserver-builder v0.0.6 @@ -94,6 +93,7 @@ require ( github.com/go-openapi/swag/typeutils v0.25.4 // indirect github.com/go-openapi/swag/yamlutils v0.25.4 // indirect github.com/go-redis/redis/v8 v8.11.5 // indirect + github.com/gogo/protobuf v1.3.2 // indirect github.com/golang/glog v1.2.5 // indirect github.com/golang/groupcache v0.0.0-20241129210726-2c02b8208cf8 // indirect github.com/golang/protobuf v1.5.4 // indirect diff --git a/pkg/discovery/discoveryrule/children.go b/pkg/discovery/discoveryrule/children.go index 8d6dd72b..9208fd6b 100644 --- a/pkg/discovery/discoveryrule/children.go +++ b/pkg/discovery/discoveryrule/children.go @@ -44,7 +44,7 @@ func (r *dr) deleteUnWantedTargets(ctx context.Context) error { client.MatchingLabels{invv1alpha1.LabelKeyDiscoveryRule: r.cfg.CR.GetName()}, } - targetList := &invv1alpha1.TargetList{} + targetList := &configv1alpha1.TargetList{} if err := r.client.List(ctx, targetList, opts...); err != nil { return err } diff --git a/pkg/discovery/discoveryrule/deviation.go b/pkg/discovery/discoveryrule/deviation.go index e3eb8f19..8fec297b 100644 --- a/pkg/discovery/discoveryrule/deviation.go +++ b/pkg/discovery/discoveryrule/deviation.go @@ -22,7 +22,6 @@ import ( "github.com/henderiw/logger/log" "github.com/sdcio/config-server/apis/config" configv1alpha1 "github.com/sdcio/config-server/apis/config/v1alpha1" - invv1alpha1 "github.com/sdcio/config-server/apis/inv/v1alpha1" "github.com/sdcio/config-server/pkg/reconcilers/resource" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/apimachinery/pkg/runtime/schema" @@ -30,7 +29,7 @@ import ( "k8s.io/utils/ptr" ) -func (r *dr) applyTargetDeviationCR(ctx context.Context, target *invv1alpha1.Target) error { +func (r *dr) applyTargetDeviationCR(ctx context.Context, target *configv1alpha1.Target) error { newUnManagedConfigCR, err := r.newDeviationCR(ctx, target) if err != nil { return err @@ -54,7 +53,7 @@ func (r *dr) applyTargetDeviationCR(ctx context.Context, target *invv1alpha1.Tar return nil } -func (r *dr) newDeviationCR(_ context.Context, target *invv1alpha1.Target) (*configv1alpha1.Deviation, error) { +func (r *dr) newDeviationCR(_ context.Context, target *configv1alpha1.Target) (*configv1alpha1.Deviation, error) { labels, err := r.cfg.CR.GetDiscoveryParameters().GetTargetLabels(r.cfg.CR.GetName()) if err != nil { return nil, err diff --git a/pkg/discovery/discoveryrule/discover_gnmi.go b/pkg/discovery/discoveryrule/discover_gnmi.go index 8e3328cd..46117014 100644 --- a/pkg/discovery/discoveryrule/discover_gnmi.go +++ b/pkg/discovery/discoveryrule/discover_gnmi.go @@ -32,6 +32,7 @@ import ( "github.com/openconfig/gnmic/pkg/api" "github.com/openconfig/gnmic/pkg/api/path" "github.com/openconfig/gnmic/pkg/api/target" + configv1alpha1 "github.com/sdcio/config-server/apis/config/v1alpha1" invv1alpha1 "github.com/sdcio/config-server/apis/inv/v1alpha1" "go.starlark.net/starlark" "go.starlark.net/syntax" @@ -133,7 +134,7 @@ func (r *Discoverer) GetProvider() string { return r.Provider } -func (r *Discoverer) Discover(ctx context.Context, t *target.Target) (*invv1alpha1.DiscoveryInfo, error) { +func (r *Discoverer) Discover(ctx context.Context, t *target.Target) (*configv1alpha1.DiscoveryInfo, error) { var req *gnmi.GetRequest var err error switch r.DiscoveryParameters.GetEncoding() { @@ -200,10 +201,10 @@ func (r *Discoverer) parseDiscoveryInformation( pathMap map[string]invv1alpha1.DiscoveryPathDefinition, capRsp *gnmi.CapabilityResponse, getRsp *gnmi.GetResponse, -) (*invv1alpha1.DiscoveryInfo, error) { +) (*configv1alpha1.DiscoveryInfo, error) { log := log.FromContext(ctx).With("provider", r.Provider) - di := &invv1alpha1.DiscoveryInfo{ + di := &configv1alpha1.DiscoveryInfo{ Protocol: string(invv1alpha1.Protocol_GNMI), Provider: r.Provider, SupportedEncodings: make([]string, 0, len(capRsp.GetSupportedEncodings())), diff --git a/pkg/discovery/discoveryrule/discover_gnmi_discovery_test.go b/pkg/discovery/discoveryrule/discover_gnmi_discovery_test.go index dba54ad4..968c4373 100644 --- a/pkg/discovery/discoveryrule/discover_gnmi_discovery_test.go +++ b/pkg/discovery/discoveryrule/discover_gnmi_discovery_test.go @@ -22,7 +22,7 @@ import ( "testing" "github.com/openconfig/gnmi/proto/gnmi" - invv1alpha1 "github.com/sdcio/config-server/apis/inv/v1alpha1" + configv1alpha1 "github.com/sdcio/config-server/apis/config/v1alpha1" ) func TestParseDiscoveryInformation(t *testing.T) { @@ -30,14 +30,14 @@ func TestParseDiscoveryInformation(t *testing.T) { capabilityFile string provider string getResponse func() *gnmi.GetResponse - expectedResult *invv1alpha1.DiscoveryInfo + expectedResult *configv1alpha1.DiscoveryInfo expectError bool }{ "NokiaSRL": { capabilityFile: "data/nokia-srl-capabilities.json", provider: "srl.nokia.sdcio.dev", getResponse: getSRLResponse, - expectedResult: &invv1alpha1.DiscoveryInfo{ + expectedResult: &configv1alpha1.DiscoveryInfo{ Protocol: "gnmi", Provider: "srl.nokia.sdcio.dev", Version: "24.3.2", @@ -52,7 +52,7 @@ func TestParseDiscoveryInformation(t *testing.T) { capabilityFile: "data/arista-capabilities.json", provider: "eos.arista.sdcio.dev", getResponse: getAristaResponse, - expectedResult: &invv1alpha1.DiscoveryInfo{ + expectedResult: &configv1alpha1.DiscoveryInfo{ Protocol: "gnmi", Provider: "eos.arista.sdcio.dev", Version: "4.33.1F", @@ -67,7 +67,7 @@ func TestParseDiscoveryInformation(t *testing.T) { capabilityFile: "data/cisco-capabilities.json", provider: "iosxr.cisco.sdcio.dev", getResponse: getCiscoResponse, - expectedResult: &invv1alpha1.DiscoveryInfo{ + expectedResult: &configv1alpha1.DiscoveryInfo{ Protocol: "gnmi", Provider: "iosxr.cisco.sdcio.dev", Version: "24.4.1.26I", diff --git a/pkg/discovery/discoveryrule/discover_none.go b/pkg/discovery/discoveryrule/discover_none.go index aab0a27a..c56e4eff 100644 --- a/pkg/discovery/discoveryrule/discover_none.go +++ b/pkg/discovery/discoveryrule/discover_none.go @@ -20,6 +20,7 @@ import ( "context" "github.com/henderiw/logger/log" + configv1alpha1 "github.com/sdcio/config-server/apis/config/v1alpha1" invv1alpha1 "github.com/sdcio/config-server/apis/inv/v1alpha1" ) @@ -32,7 +33,7 @@ func (r *dr) discoverWithNone(ctx context.Context, h *hostInfo, connProfile *inv // h.Address, // r.cfg.TargetConnectionProfiles[0].Connectionprofile.Spec.Port, //) - di := &invv1alpha1.DiscoveryInfo{ + di := &configv1alpha1.DiscoveryInfo{ Protocol: "static", Provider: provider, Version: version, diff --git a/pkg/discovery/discoveryrule/target.go b/pkg/discovery/discoveryrule/target.go index 54c35b85..7d38e0f5 100644 --- a/pkg/discovery/discoveryrule/target.go +++ b/pkg/discovery/discoveryrule/target.go @@ -25,6 +25,7 @@ import ( "github.com/henderiw/logger/log" //condv1alpha1 "github.com/sdcio/config-server/apis/condition/v1alpha1" + configv1alpha1 "github.com/sdcio/config-server/apis/config/v1alpha1" invv1alpha1 "github.com/sdcio/config-server/apis/inv/v1alpha1" invv1alpha1apply "github.com/sdcio/config-server/pkg/generated/applyconfiguration/inv/v1alpha1" "github.com/sdcio/config-server/pkg/reconcilers/resource" @@ -40,7 +41,7 @@ const ( reconcilerName = "DiscoveryController" ) -func (r *dr) createTarget(ctx context.Context, provider, address string, di *invv1alpha1.DiscoveryInfo) error { +func (r *dr) createTarget(ctx context.Context, provider, address string, di *configv1alpha1.DiscoveryInfo) error { log := log.FromContext(ctx) if err := r.children.Create(ctx, storebackend.ToKey(getTargetName(di.Hostname)), ""); err != nil { return err @@ -62,7 +63,7 @@ func (r *dr) createTarget(ctx context.Context, provider, address string, di *inv } targetKey := newTarget.GetNamespacedName() - target := &invv1alpha1.Target{} + target := &configv1alpha1.Target{} if err := r.client.Get(ctx, targetKey, target); err != nil { log.Info("cannot get target", "error", err) return err @@ -75,8 +76,8 @@ func (r *dr) createTarget(ctx context.Context, provider, address string, di *inv return nil } -func (r *dr) newTarget(_ context.Context, providerName, address string, di *invv1alpha1.DiscoveryInfo) (*invv1alpha1.Target, error) { - targetSpec := invv1alpha1.TargetSpec{ +func (r *dr) newTarget(_ context.Context, providerName, address string, di *configv1alpha1.DiscoveryInfo) (*configv1alpha1.Target, error) { + targetSpec := configv1alpha1.TargetSpec{ Provider: providerName, Address: address, TargetProfile: invv1alpha1.TargetProfile{ @@ -95,7 +96,7 @@ func (r *dr) newTarget(_ context.Context, providerName, address string, di *invv return nil, err } - return invv1alpha1.BuildTarget( + return configv1alpha1.BuildTarget( metav1.ObjectMeta{ Name: getTargetName(di.Hostname), Namespace: r.cfg.CR.GetNamespace(), @@ -114,7 +115,7 @@ func (r *dr) newTarget(_ context.Context, providerName, address string, di *invv }}, }, targetSpec, - invv1alpha1.TargetStatus{ + configv1alpha1.TargetStatus{ DiscoveryInfo: di, }, ), nil @@ -122,12 +123,12 @@ func (r *dr) newTarget(_ context.Context, providerName, address string, di *invv // w/o seperated discovery info -func (r *dr) applyTarget(ctx context.Context, newTarget *invv1alpha1.Target) error { +func (r *dr) applyTarget(ctx context.Context, newTarget *configv1alpha1.Target) error { //di := newTarget.Status.DiscoveryInfo.DeepCopy() log := log.FromContext(ctx).With("targetName", newTarget.Name, "address", newTarget.Spec.Address) // Check if the target already exists - target := &invv1alpha1.Target{} + target := &configv1alpha1.Target{} if err := r.client.Get(ctx, types.NamespacedName{ Namespace: newTarget.Namespace, Name: newTarget.Name, @@ -145,8 +146,8 @@ func (r *dr) applyTarget(ctx context.Context, newTarget *invv1alpha1.Target) err time.Sleep(500 * time.Millisecond) } - newCond := invv1alpha1.DiscoveryReady() - oldCond := target.GetCondition(invv1alpha1.ConditionTypeDiscoveryReady) + newCond := configv1alpha1.TargetDiscoveryReady() + oldCond := target.GetCondition(configv1alpha1.ConditionTypeTargetDiscoveryReady) if newCond.Equal(oldCond) && equality.Semantic.DeepEqual(newTarget.Spec, target.Spec) && @@ -182,7 +183,7 @@ func (r *dr) applyTarget(ctx context.Context, newTarget *invv1alpha1.Target) err return nil } -func discoveryInfoToApply(di *invv1alpha1.DiscoveryInfo) *invv1alpha1apply.DiscoveryInfoApplyConfiguration { +func discoveryInfoToApply(di *configv1alpha1.DiscoveryInfo) *invv1alpha1apply.DiscoveryInfoApplyConfiguration { if di == nil { return nil } diff --git a/pkg/generated/applyconfiguration/config/v1alpha1/configsetspec.go b/pkg/generated/applyconfiguration/config/v1alpha1/configsetspec.go index 59b0ff2b..1ca6dfb7 100644 --- a/pkg/generated/applyconfiguration/config/v1alpha1/configsetspec.go +++ b/pkg/generated/applyconfiguration/config/v1alpha1/configsetspec.go @@ -23,7 +23,7 @@ package v1alpha1 // ConfigSetSpec defines the desired state of Config type ConfigSetSpecApplyConfiguration struct { // Targets defines the targets on which this configSet applies - Target *TargetApplyConfiguration `json:"target,omitempty"` + Target *ConfigSetTargetApplyConfiguration `json:"target,omitempty"` // Lifecycle determines the lifecycle policies the resource e.g. delete is orphan or delete // will follow Lifecycle *LifecycleApplyConfiguration `json:"lifecycle,omitempty"` @@ -44,7 +44,7 @@ func ConfigSetSpec() *ConfigSetSpecApplyConfiguration { // WithTarget sets the Target field in the declarative configuration to the given value // and returns the receiver, so that objects can be built by chaining "With" function invocations. // If called multiple times, the Target field is set to the value of the last call. -func (b *ConfigSetSpecApplyConfiguration) WithTarget(value *TargetApplyConfiguration) *ConfigSetSpecApplyConfiguration { +func (b *ConfigSetSpecApplyConfiguration) WithTarget(value *ConfigSetTargetApplyConfiguration) *ConfigSetSpecApplyConfiguration { b.Target = value return b } diff --git a/pkg/generated/applyconfiguration/config/v1alpha1/configsetstatus.go b/pkg/generated/applyconfiguration/config/v1alpha1/configsetstatus.go index b6a52e7c..5b53aa7b 100644 --- a/pkg/generated/applyconfiguration/config/v1alpha1/configsetstatus.go +++ b/pkg/generated/applyconfiguration/config/v1alpha1/configsetstatus.go @@ -30,7 +30,7 @@ type ConfigSetStatusApplyConfiguration struct { // if the condition is true the other attributes in the status are meaningful conditionv1alpha1.ConditionedStatus `json:",inline"` // Targets defines the status of the configSet resource on the respective target - Targets []TargetStatusApplyConfiguration `json:"targets,omitempty"` + Targets []ConfigSetTargetStatusApplyConfiguration `json:"targets,omitempty"` } // ConfigSetStatusApplyConfiguration constructs a declarative configuration of the ConfigSetStatus type for use with @@ -52,7 +52,7 @@ func (b *ConfigSetStatusApplyConfiguration) WithConditions(values ...conditionv1 // WithTargets adds the given value to the Targets field in the declarative configuration // and returns the receiver, so that objects can be build by chaining "With" function invocations. // If called multiple times, values provided by each call will be appended to the Targets field. -func (b *ConfigSetStatusApplyConfiguration) WithTargets(values ...*TargetStatusApplyConfiguration) *ConfigSetStatusApplyConfiguration { +func (b *ConfigSetStatusApplyConfiguration) WithTargets(values ...*ConfigSetTargetStatusApplyConfiguration) *ConfigSetStatusApplyConfiguration { for i := range values { if values[i] == nil { panic("nil value passed to WithTargets") diff --git a/pkg/generated/applyconfiguration/config/v1alpha1/configsettarget.go b/pkg/generated/applyconfiguration/config/v1alpha1/configsettarget.go new file mode 100644 index 00000000..8e8dbd13 --- /dev/null +++ b/pkg/generated/applyconfiguration/config/v1alpha1/configsettarget.go @@ -0,0 +1,43 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ +// Code generated by applyconfiguration-gen. DO NOT EDIT. + +package v1alpha1 + +import ( + v1 "k8s.io/client-go/applyconfigurations/meta/v1" +) + +// ConfigSetTargetApplyConfiguration represents a declarative configuration of the ConfigSetTarget type for use +// with apply. +type ConfigSetTargetApplyConfiguration struct { + // TargetSelector defines the selector used to select the targets to which the config applies + TargetSelector *v1.LabelSelectorApplyConfiguration `json:"targetSelector,omitempty"` +} + +// ConfigSetTargetApplyConfiguration constructs a declarative configuration of the ConfigSetTarget type for use with +// apply. +func ConfigSetTarget() *ConfigSetTargetApplyConfiguration { + return &ConfigSetTargetApplyConfiguration{} +} + +// WithTargetSelector sets the TargetSelector field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the TargetSelector field is set to the value of the last call. +func (b *ConfigSetTargetApplyConfiguration) WithTargetSelector(value *v1.LabelSelectorApplyConfiguration) *ConfigSetTargetApplyConfiguration { + b.TargetSelector = value + return b +} diff --git a/pkg/generated/applyconfiguration/config/v1alpha1/configsettargetstatus.go b/pkg/generated/applyconfiguration/config/v1alpha1/configsettargetstatus.go new file mode 100644 index 00000000..d30dd4ff --- /dev/null +++ b/pkg/generated/applyconfiguration/config/v1alpha1/configsettargetstatus.go @@ -0,0 +1,46 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ +// Code generated by applyconfiguration-gen. DO NOT EDIT. + +package v1alpha1 + +import ( + conditionv1alpha1 "github.com/sdcio/config-server/apis/condition/v1alpha1" +) + +// ConfigSetTargetStatusApplyConfiguration represents a declarative configuration of the ConfigSetTargetStatus type for use +// with apply. +type ConfigSetTargetStatusApplyConfiguration struct { + Name *string `json:"name,omitempty"` + // right now we assume the namespace of the config and target are aligned + // NameSpace string `json:"namespace" protobuf:"bytes,2,opt,name=name"` + // Condition of the configCR status + conditionv1alpha1.Condition `json:",inline"` +} + +// ConfigSetTargetStatusApplyConfiguration constructs a declarative configuration of the ConfigSetTargetStatus type for use with +// apply. +func ConfigSetTargetStatus() *ConfigSetTargetStatusApplyConfiguration { + return &ConfigSetTargetStatusApplyConfiguration{} +} + +// WithName sets the Name field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Name field is set to the value of the last call. +func (b *ConfigSetTargetStatusApplyConfiguration) WithName(value string) *ConfigSetTargetStatusApplyConfiguration { + b.Name = &value + return b +} diff --git a/pkg/generated/applyconfiguration/config/v1alpha1/discoveryinfo.go b/pkg/generated/applyconfiguration/config/v1alpha1/discoveryinfo.go new file mode 100644 index 00000000..7096908d --- /dev/null +++ b/pkg/generated/applyconfiguration/config/v1alpha1/discoveryinfo.go @@ -0,0 +1,111 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ +// Code generated by applyconfiguration-gen. DO NOT EDIT. + +package v1alpha1 + +// DiscoveryInfoApplyConfiguration represents a declarative configuration of the DiscoveryInfo type for use +// with apply. +type DiscoveryInfoApplyConfiguration struct { + // Protocol used for discovery + Protocol *string `json:"protocol,omitempty"` + // Type associated with the target + Provider *string `json:"provider,omitempty"` + // Version associated with the target + Version *string `json:"version,omitempty"` + // Hostname associated with the target + Hostname *string `json:"hostname,omitempty"` + // Platform associated with the target + Platform *string `json:"platform,omitempty"` + // MacAddress associated with the target + MacAddress *string `json:"macAddress,omitempty"` + // SerialNumber associated with the target + SerialNumber *string `json:"serialNumber,omitempty"` + // Supported Encodings of the target + SupportedEncodings []string `json:"supportedEncodings,omitempty"` +} + +// DiscoveryInfoApplyConfiguration constructs a declarative configuration of the DiscoveryInfo type for use with +// apply. +func DiscoveryInfo() *DiscoveryInfoApplyConfiguration { + return &DiscoveryInfoApplyConfiguration{} +} + +// WithProtocol sets the Protocol field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Protocol field is set to the value of the last call. +func (b *DiscoveryInfoApplyConfiguration) WithProtocol(value string) *DiscoveryInfoApplyConfiguration { + b.Protocol = &value + return b +} + +// WithProvider sets the Provider field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Provider field is set to the value of the last call. +func (b *DiscoveryInfoApplyConfiguration) WithProvider(value string) *DiscoveryInfoApplyConfiguration { + b.Provider = &value + return b +} + +// WithVersion sets the Version field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Version field is set to the value of the last call. +func (b *DiscoveryInfoApplyConfiguration) WithVersion(value string) *DiscoveryInfoApplyConfiguration { + b.Version = &value + return b +} + +// WithHostname sets the Hostname field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Hostname field is set to the value of the last call. +func (b *DiscoveryInfoApplyConfiguration) WithHostname(value string) *DiscoveryInfoApplyConfiguration { + b.Hostname = &value + return b +} + +// WithPlatform sets the Platform field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Platform field is set to the value of the last call. +func (b *DiscoveryInfoApplyConfiguration) WithPlatform(value string) *DiscoveryInfoApplyConfiguration { + b.Platform = &value + return b +} + +// WithMacAddress sets the MacAddress field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the MacAddress field is set to the value of the last call. +func (b *DiscoveryInfoApplyConfiguration) WithMacAddress(value string) *DiscoveryInfoApplyConfiguration { + b.MacAddress = &value + return b +} + +// WithSerialNumber sets the SerialNumber field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the SerialNumber field is set to the value of the last call. +func (b *DiscoveryInfoApplyConfiguration) WithSerialNumber(value string) *DiscoveryInfoApplyConfiguration { + b.SerialNumber = &value + return b +} + +// WithSupportedEncodings adds the given value to the SupportedEncodings field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, values provided by each call will be appended to the SupportedEncodings field. +func (b *DiscoveryInfoApplyConfiguration) WithSupportedEncodings(values ...string) *DiscoveryInfoApplyConfiguration { + for i := range values { + b.SupportedEncodings = append(b.SupportedEncodings, values[i]) + } + return b +} diff --git a/pkg/generated/applyconfiguration/config/v1alpha1/target.go b/pkg/generated/applyconfiguration/config/v1alpha1/target.go index 995ff82b..36d91e10 100644 --- a/pkg/generated/applyconfiguration/config/v1alpha1/target.go +++ b/pkg/generated/applyconfiguration/config/v1alpha1/target.go @@ -18,26 +18,227 @@ limitations under the License. package v1alpha1 import ( + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + types "k8s.io/apimachinery/pkg/types" v1 "k8s.io/client-go/applyconfigurations/meta/v1" ) // TargetApplyConfiguration represents a declarative configuration of the Target type for use // with apply. +// +// Target is the Schema for the Target API type TargetApplyConfiguration struct { - // TargetSelector defines the selector used to select the targets to which the config applies - TargetSelector *v1.LabelSelectorApplyConfiguration `json:"targetSelector,omitempty"` + v1.TypeMetaApplyConfiguration `json:",inline"` + *v1.ObjectMetaApplyConfiguration `json:"metadata,omitempty"` + Spec *TargetSpecApplyConfiguration `json:"spec,omitempty"` + Status *TargetStatusApplyConfiguration `json:"status,omitempty"` } -// TargetApplyConfiguration constructs a declarative configuration of the Target type for use with +// Target constructs a declarative configuration of the Target type for use with // apply. -func Target() *TargetApplyConfiguration { - return &TargetApplyConfiguration{} +func Target(name, namespace string) *TargetApplyConfiguration { + b := &TargetApplyConfiguration{} + b.WithName(name) + b.WithNamespace(namespace) + b.WithKind("Target") + b.WithAPIVersion("config.sdcio.dev/v1alpha1") + return b +} + +func (b TargetApplyConfiguration) IsApplyConfiguration() {} + +// WithKind sets the Kind field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Kind field is set to the value of the last call. +func (b *TargetApplyConfiguration) WithKind(value string) *TargetApplyConfiguration { + b.TypeMetaApplyConfiguration.Kind = &value + return b +} + +// WithAPIVersion sets the APIVersion field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the APIVersion field is set to the value of the last call. +func (b *TargetApplyConfiguration) WithAPIVersion(value string) *TargetApplyConfiguration { + b.TypeMetaApplyConfiguration.APIVersion = &value + return b +} + +// WithName sets the Name field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Name field is set to the value of the last call. +func (b *TargetApplyConfiguration) WithName(value string) *TargetApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.Name = &value + return b +} + +// WithGenerateName sets the GenerateName field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the GenerateName field is set to the value of the last call. +func (b *TargetApplyConfiguration) WithGenerateName(value string) *TargetApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.GenerateName = &value + return b +} + +// WithNamespace sets the Namespace field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Namespace field is set to the value of the last call. +func (b *TargetApplyConfiguration) WithNamespace(value string) *TargetApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.Namespace = &value + return b +} + +// WithUID sets the UID field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the UID field is set to the value of the last call. +func (b *TargetApplyConfiguration) WithUID(value types.UID) *TargetApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.UID = &value + return b +} + +// WithResourceVersion sets the ResourceVersion field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the ResourceVersion field is set to the value of the last call. +func (b *TargetApplyConfiguration) WithResourceVersion(value string) *TargetApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.ResourceVersion = &value + return b +} + +// WithGeneration sets the Generation field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Generation field is set to the value of the last call. +func (b *TargetApplyConfiguration) WithGeneration(value int64) *TargetApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.Generation = &value + return b +} + +// WithCreationTimestamp sets the CreationTimestamp field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the CreationTimestamp field is set to the value of the last call. +func (b *TargetApplyConfiguration) WithCreationTimestamp(value metav1.Time) *TargetApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.CreationTimestamp = &value + return b +} + +// WithDeletionTimestamp sets the DeletionTimestamp field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the DeletionTimestamp field is set to the value of the last call. +func (b *TargetApplyConfiguration) WithDeletionTimestamp(value metav1.Time) *TargetApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.DeletionTimestamp = &value + return b +} + +// WithDeletionGracePeriodSeconds sets the DeletionGracePeriodSeconds field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the DeletionGracePeriodSeconds field is set to the value of the last call. +func (b *TargetApplyConfiguration) WithDeletionGracePeriodSeconds(value int64) *TargetApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.DeletionGracePeriodSeconds = &value + return b +} + +// WithLabels puts the entries into the Labels field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, the entries provided by each call will be put on the Labels field, +// overwriting an existing map entries in Labels field with the same key. +func (b *TargetApplyConfiguration) WithLabels(entries map[string]string) *TargetApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + if b.ObjectMetaApplyConfiguration.Labels == nil && len(entries) > 0 { + b.ObjectMetaApplyConfiguration.Labels = make(map[string]string, len(entries)) + } + for k, v := range entries { + b.ObjectMetaApplyConfiguration.Labels[k] = v + } + return b +} + +// WithAnnotations puts the entries into the Annotations field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, the entries provided by each call will be put on the Annotations field, +// overwriting an existing map entries in Annotations field with the same key. +func (b *TargetApplyConfiguration) WithAnnotations(entries map[string]string) *TargetApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + if b.ObjectMetaApplyConfiguration.Annotations == nil && len(entries) > 0 { + b.ObjectMetaApplyConfiguration.Annotations = make(map[string]string, len(entries)) + } + for k, v := range entries { + b.ObjectMetaApplyConfiguration.Annotations[k] = v + } + return b +} + +// WithOwnerReferences adds the given value to the OwnerReferences field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, values provided by each call will be appended to the OwnerReferences field. +func (b *TargetApplyConfiguration) WithOwnerReferences(values ...*v1.OwnerReferenceApplyConfiguration) *TargetApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + for i := range values { + if values[i] == nil { + panic("nil value passed to WithOwnerReferences") + } + b.ObjectMetaApplyConfiguration.OwnerReferences = append(b.ObjectMetaApplyConfiguration.OwnerReferences, *values[i]) + } + return b +} + +// WithFinalizers adds the given value to the Finalizers field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, values provided by each call will be appended to the Finalizers field. +func (b *TargetApplyConfiguration) WithFinalizers(values ...string) *TargetApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + for i := range values { + b.ObjectMetaApplyConfiguration.Finalizers = append(b.ObjectMetaApplyConfiguration.Finalizers, values[i]) + } + return b +} + +func (b *TargetApplyConfiguration) ensureObjectMetaApplyConfigurationExists() { + if b.ObjectMetaApplyConfiguration == nil { + b.ObjectMetaApplyConfiguration = &v1.ObjectMetaApplyConfiguration{} + } +} + +// WithSpec sets the Spec field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Spec field is set to the value of the last call. +func (b *TargetApplyConfiguration) WithSpec(value *TargetSpecApplyConfiguration) *TargetApplyConfiguration { + b.Spec = value + return b } -// WithTargetSelector sets the TargetSelector field in the declarative configuration to the given value +// WithStatus sets the Status field in the declarative configuration to the given value // and returns the receiver, so that objects can be built by chaining "With" function invocations. -// If called multiple times, the TargetSelector field is set to the value of the last call. -func (b *TargetApplyConfiguration) WithTargetSelector(value *v1.LabelSelectorApplyConfiguration) *TargetApplyConfiguration { - b.TargetSelector = value +// If called multiple times, the Status field is set to the value of the last call. +func (b *TargetApplyConfiguration) WithStatus(value *TargetStatusApplyConfiguration) *TargetApplyConfiguration { + b.Status = value return b } + +// GetKind retrieves the value of the Kind field in the declarative configuration. +func (b *TargetApplyConfiguration) GetKind() *string { + return b.TypeMetaApplyConfiguration.Kind +} + +// GetAPIVersion retrieves the value of the APIVersion field in the declarative configuration. +func (b *TargetApplyConfiguration) GetAPIVersion() *string { + return b.TypeMetaApplyConfiguration.APIVersion +} + +// GetName retrieves the value of the Name field in the declarative configuration. +func (b *TargetApplyConfiguration) GetName() *string { + b.ensureObjectMetaApplyConfigurationExists() + return b.ObjectMetaApplyConfiguration.Name +} + +// GetNamespace retrieves the value of the Namespace field in the declarative configuration. +func (b *TargetApplyConfiguration) GetNamespace() *string { + b.ensureObjectMetaApplyConfigurationExists() + return b.ObjectMetaApplyConfiguration.Namespace +} diff --git a/pkg/generated/applyconfiguration/config/v1alpha1/targetspec.go b/pkg/generated/applyconfiguration/config/v1alpha1/targetspec.go new file mode 100644 index 00000000..3660fc70 --- /dev/null +++ b/pkg/generated/applyconfiguration/config/v1alpha1/targetspec.go @@ -0,0 +1,89 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ +// Code generated by applyconfiguration-gen. DO NOT EDIT. + +package v1alpha1 + +import ( + invv1alpha1 "github.com/sdcio/config-server/pkg/generated/applyconfiguration/inv/v1alpha1" +) + +// TargetSpecApplyConfiguration represents a declarative configuration of the TargetSpec type for use +// with apply. +// +// TargetSpec defines the desired state of Target +type TargetSpecApplyConfiguration struct { + // Provider specifies the provider using this target. + Provider *string `json:"provider,omitempty"` + // Address defines the address to connect to the target + Address *string `json:"address,omitempty"` + // TargetProfile defines the Credentials/TLSSecret and sync/connectivity profile to connect to the target + invv1alpha1.TargetProfileApplyConfiguration `json:",inline"` +} + +// TargetSpecApplyConfiguration constructs a declarative configuration of the TargetSpec type for use with +// apply. +func TargetSpec() *TargetSpecApplyConfiguration { + return &TargetSpecApplyConfiguration{} +} + +// WithProvider sets the Provider field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Provider field is set to the value of the last call. +func (b *TargetSpecApplyConfiguration) WithProvider(value string) *TargetSpecApplyConfiguration { + b.Provider = &value + return b +} + +// WithAddress sets the Address field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Address field is set to the value of the last call. +func (b *TargetSpecApplyConfiguration) WithAddress(value string) *TargetSpecApplyConfiguration { + b.Address = &value + return b +} + +// WithCredentials sets the Credentials field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Credentials field is set to the value of the last call. +func (b *TargetSpecApplyConfiguration) WithCredentials(value string) *TargetSpecApplyConfiguration { + b.TargetProfileApplyConfiguration.Credentials = &value + return b +} + +// WithTLSSecret sets the TLSSecret field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the TLSSecret field is set to the value of the last call. +func (b *TargetSpecApplyConfiguration) WithTLSSecret(value string) *TargetSpecApplyConfiguration { + b.TargetProfileApplyConfiguration.TLSSecret = &value + return b +} + +// WithConnectionProfile sets the ConnectionProfile field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the ConnectionProfile field is set to the value of the last call. +func (b *TargetSpecApplyConfiguration) WithConnectionProfile(value string) *TargetSpecApplyConfiguration { + b.TargetProfileApplyConfiguration.ConnectionProfile = &value + return b +} + +// WithSyncProfile sets the SyncProfile field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the SyncProfile field is set to the value of the last call. +func (b *TargetSpecApplyConfiguration) WithSyncProfile(value string) *TargetSpecApplyConfiguration { + b.TargetProfileApplyConfiguration.SyncProfile = &value + return b +} diff --git a/pkg/generated/applyconfiguration/config/v1alpha1/targetstatus.go b/pkg/generated/applyconfiguration/config/v1alpha1/targetstatus.go index 8eb4a795..686f61df 100644 --- a/pkg/generated/applyconfiguration/config/v1alpha1/targetstatus.go +++ b/pkg/generated/applyconfiguration/config/v1alpha1/targetstatus.go @@ -23,12 +23,15 @@ import ( // TargetStatusApplyConfiguration represents a declarative configuration of the TargetStatus type for use // with apply. +// +// TargetStatus defines the observed state of Target type TargetStatusApplyConfiguration struct { - Name *string `json:"name,omitempty"` - // right now we assume the namespace of the config and target are aligned - // NameSpace string `json:"namespace" protobuf:"bytes,2,opt,name=name"` - // Condition of the configCR status - conditionv1alpha1.Condition `json:",inline"` + // ConditionedStatus provides the status of the Target using conditions + conditionv1alpha1.ConditionedStatus `json:",inline"` + // Discovery info defines the information retrieved during discovery + DiscoveryInfo *DiscoveryInfoApplyConfiguration `json:"discoveryInfo,omitempty"` + // UsedReferences track the resource used to reconcile the cr + UsedReferences *TargetStatusUsedReferencesApplyConfiguration `json:"usedReferences,omitempty"` } // TargetStatusApplyConfiguration constructs a declarative configuration of the TargetStatus type for use with @@ -37,10 +40,28 @@ func TargetStatus() *TargetStatusApplyConfiguration { return &TargetStatusApplyConfiguration{} } -// WithName sets the Name field in the declarative configuration to the given value +// WithConditions adds the given value to the Conditions field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, values provided by each call will be appended to the Conditions field. +func (b *TargetStatusApplyConfiguration) WithConditions(values ...conditionv1alpha1.Condition) *TargetStatusApplyConfiguration { + for i := range values { + b.ConditionedStatus.Conditions = append(b.ConditionedStatus.Conditions, values[i]) + } + return b +} + +// WithDiscoveryInfo sets the DiscoveryInfo field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the DiscoveryInfo field is set to the value of the last call. +func (b *TargetStatusApplyConfiguration) WithDiscoveryInfo(value *DiscoveryInfoApplyConfiguration) *TargetStatusApplyConfiguration { + b.DiscoveryInfo = value + return b +} + +// WithUsedReferences sets the UsedReferences field in the declarative configuration to the given value // and returns the receiver, so that objects can be built by chaining "With" function invocations. -// If called multiple times, the Name field is set to the value of the last call. -func (b *TargetStatusApplyConfiguration) WithName(value string) *TargetStatusApplyConfiguration { - b.Name = &value +// If called multiple times, the UsedReferences field is set to the value of the last call. +func (b *TargetStatusApplyConfiguration) WithUsedReferences(value *TargetStatusUsedReferencesApplyConfiguration) *TargetStatusApplyConfiguration { + b.UsedReferences = value return b } diff --git a/pkg/generated/applyconfiguration/config/v1alpha1/targetstatususedreferences.go b/pkg/generated/applyconfiguration/config/v1alpha1/targetstatususedreferences.go new file mode 100644 index 00000000..958a4625 --- /dev/null +++ b/pkg/generated/applyconfiguration/config/v1alpha1/targetstatususedreferences.go @@ -0,0 +1,65 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ +// Code generated by applyconfiguration-gen. DO NOT EDIT. + +package v1alpha1 + +// TargetStatusUsedReferencesApplyConfiguration represents a declarative configuration of the TargetStatusUsedReferences type for use +// with apply. +type TargetStatusUsedReferencesApplyConfiguration struct { + SecretResourceVersion *string `json:"secretResourceVersion,omitempty"` + TLSSecretResourceVersion *string `json:"tlsSecretResourceVersion,omitempty"` + ConnectionProfileResourceVersion *string `json:"connectionProfileResourceVersion,omitempty"` + SyncProfileResourceVersion *string `json:"syncProfileResourceVersion,omitempty"` +} + +// TargetStatusUsedReferencesApplyConfiguration constructs a declarative configuration of the TargetStatusUsedReferences type for use with +// apply. +func TargetStatusUsedReferences() *TargetStatusUsedReferencesApplyConfiguration { + return &TargetStatusUsedReferencesApplyConfiguration{} +} + +// WithSecretResourceVersion sets the SecretResourceVersion field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the SecretResourceVersion field is set to the value of the last call. +func (b *TargetStatusUsedReferencesApplyConfiguration) WithSecretResourceVersion(value string) *TargetStatusUsedReferencesApplyConfiguration { + b.SecretResourceVersion = &value + return b +} + +// WithTLSSecretResourceVersion sets the TLSSecretResourceVersion field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the TLSSecretResourceVersion field is set to the value of the last call. +func (b *TargetStatusUsedReferencesApplyConfiguration) WithTLSSecretResourceVersion(value string) *TargetStatusUsedReferencesApplyConfiguration { + b.TLSSecretResourceVersion = &value + return b +} + +// WithConnectionProfileResourceVersion sets the ConnectionProfileResourceVersion field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the ConnectionProfileResourceVersion field is set to the value of the last call. +func (b *TargetStatusUsedReferencesApplyConfiguration) WithConnectionProfileResourceVersion(value string) *TargetStatusUsedReferencesApplyConfiguration { + b.ConnectionProfileResourceVersion = &value + return b +} + +// WithSyncProfileResourceVersion sets the SyncProfileResourceVersion field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the SyncProfileResourceVersion field is set to the value of the last call. +func (b *TargetStatusUsedReferencesApplyConfiguration) WithSyncProfileResourceVersion(value string) *TargetStatusUsedReferencesApplyConfiguration { + b.SyncProfileResourceVersion = &value + return b +} diff --git a/pkg/generated/applyconfiguration/utils.go b/pkg/generated/applyconfiguration/utils.go index de3aad3f..354baa37 100644 --- a/pkg/generated/applyconfiguration/utils.go +++ b/pkg/generated/applyconfiguration/utils.go @@ -49,6 +49,10 @@ func ForKind(kind schema.GroupVersionKind) interface{} { return &configv1alpha1.ConfigSetSpecApplyConfiguration{} case v1alpha1.SchemeGroupVersion.WithKind("ConfigSetStatus"): return &configv1alpha1.ConfigSetStatusApplyConfiguration{} + case v1alpha1.SchemeGroupVersion.WithKind("ConfigSetTarget"): + return &configv1alpha1.ConfigSetTargetApplyConfiguration{} + case v1alpha1.SchemeGroupVersion.WithKind("ConfigSetTargetStatus"): + return &configv1alpha1.ConfigSetTargetStatusApplyConfiguration{} case v1alpha1.SchemeGroupVersion.WithKind("ConfigSpec"): return &configv1alpha1.ConfigSpecApplyConfiguration{} case v1alpha1.SchemeGroupVersion.WithKind("ConfigStatus"): @@ -61,6 +65,8 @@ func ForKind(kind schema.GroupVersionKind) interface{} { return &configv1alpha1.DeviationSpecApplyConfiguration{} case v1alpha1.SchemeGroupVersion.WithKind("DeviationStatus"): return &configv1alpha1.DeviationStatusApplyConfiguration{} + case v1alpha1.SchemeGroupVersion.WithKind("DiscoveryInfo"): + return &configv1alpha1.DiscoveryInfoApplyConfiguration{} case v1alpha1.SchemeGroupVersion.WithKind("Lifecycle"): return &configv1alpha1.LifecycleApplyConfiguration{} case v1alpha1.SchemeGroupVersion.WithKind("RunningConfig"): @@ -77,12 +83,14 @@ func ForKind(kind schema.GroupVersionKind) interface{} { return &configv1alpha1.SensitiveConfigStatusApplyConfiguration{} case v1alpha1.SchemeGroupVersion.WithKind("Target"): return &configv1alpha1.TargetApplyConfiguration{} + case v1alpha1.SchemeGroupVersion.WithKind("TargetSpec"): + return &configv1alpha1.TargetSpecApplyConfiguration{} case v1alpha1.SchemeGroupVersion.WithKind("TargetStatus"): return &configv1alpha1.TargetStatusApplyConfiguration{} + case v1alpha1.SchemeGroupVersion.WithKind("TargetStatusUsedReferences"): + return &configv1alpha1.TargetStatusUsedReferencesApplyConfiguration{} // Group=inv.sdcio.dev, Version=v1alpha1 - case invv1alpha1.SchemeGroupVersion.WithKind("DiscoveryInfo"): - return &applyconfigurationinvv1alpha1.DiscoveryInfoApplyConfiguration{} case invv1alpha1.SchemeGroupVersion.WithKind("DiscoveryParameters"): return &applyconfigurationinvv1alpha1.DiscoveryParametersApplyConfiguration{} case invv1alpha1.SchemeGroupVersion.WithKind("DiscoveryPathDefinition"): @@ -143,20 +151,12 @@ func ForKind(kind schema.GroupVersionKind) interface{} { return &applyconfigurationinvv1alpha1.SubscriptionStatusApplyConfiguration{} case invv1alpha1.SchemeGroupVersion.WithKind("SubscriptionTarget"): return &applyconfigurationinvv1alpha1.SubscriptionTargetApplyConfiguration{} - case invv1alpha1.SchemeGroupVersion.WithKind("Target"): - return &applyconfigurationinvv1alpha1.TargetApplyConfiguration{} case invv1alpha1.SchemeGroupVersion.WithKind("TargetConnectionProfile"): return &applyconfigurationinvv1alpha1.TargetConnectionProfileApplyConfiguration{} case invv1alpha1.SchemeGroupVersion.WithKind("TargetConnectionProfileSpec"): return &applyconfigurationinvv1alpha1.TargetConnectionProfileSpecApplyConfiguration{} case invv1alpha1.SchemeGroupVersion.WithKind("TargetProfile"): return &applyconfigurationinvv1alpha1.TargetProfileApplyConfiguration{} - case invv1alpha1.SchemeGroupVersion.WithKind("TargetSpec"): - return &applyconfigurationinvv1alpha1.TargetSpecApplyConfiguration{} - case invv1alpha1.SchemeGroupVersion.WithKind("TargetStatus"): - return &applyconfigurationinvv1alpha1.TargetStatusApplyConfiguration{} - case invv1alpha1.SchemeGroupVersion.WithKind("TargetStatusUsedReferences"): - return &applyconfigurationinvv1alpha1.TargetStatusUsedReferencesApplyConfiguration{} case invv1alpha1.SchemeGroupVersion.WithKind("TargetSyncProfile"): return &applyconfigurationinvv1alpha1.TargetSyncProfileApplyConfiguration{} case invv1alpha1.SchemeGroupVersion.WithKind("TargetSyncProfileSpec"): diff --git a/pkg/generated/clientset/versioned/typed/config/v1alpha1/config_client.go b/pkg/generated/clientset/versioned/typed/config/v1alpha1/config_client.go index 74021aa7..f9164671 100644 --- a/pkg/generated/clientset/versioned/typed/config/v1alpha1/config_client.go +++ b/pkg/generated/clientset/versioned/typed/config/v1alpha1/config_client.go @@ -33,6 +33,7 @@ type ConfigV1alpha1Interface interface { DeviationsGetter RunningConfigsGetter SensitiveConfigsGetter + TargetsGetter } // ConfigV1alpha1Client is used to interact with features provided by the config.sdcio.dev group. @@ -64,6 +65,10 @@ func (c *ConfigV1alpha1Client) SensitiveConfigs(namespace string) SensitiveConfi return newSensitiveConfigs(c, namespace) } +func (c *ConfigV1alpha1Client) Targets(namespace string) TargetInterface { + return newTargets(c, namespace) +} + // NewForConfig creates a new ConfigV1alpha1Client for the given config. // NewForConfig is equivalent to NewForConfigAndClient(c, httpClient), // where httpClient was generated with rest.HTTPClientFor(c). diff --git a/pkg/generated/clientset/versioned/typed/config/v1alpha1/fake/fake_config_client.go b/pkg/generated/clientset/versioned/typed/config/v1alpha1/fake/fake_config_client.go index e9234883..df4bc527 100644 --- a/pkg/generated/clientset/versioned/typed/config/v1alpha1/fake/fake_config_client.go +++ b/pkg/generated/clientset/versioned/typed/config/v1alpha1/fake/fake_config_client.go @@ -51,6 +51,10 @@ func (c *FakeConfigV1alpha1) SensitiveConfigs(namespace string) v1alpha1.Sensiti return newFakeSensitiveConfigs(c, namespace) } +func (c *FakeConfigV1alpha1) Targets(namespace string) v1alpha1.TargetInterface { + return newFakeTargets(c, namespace) +} + // RESTClient returns a RESTClient that is used to communicate // with API server by this client implementation. func (c *FakeConfigV1alpha1) RESTClient() rest.Interface { diff --git a/pkg/generated/clientset/versioned/typed/inv/v1alpha1/fake/fake_target.go b/pkg/generated/clientset/versioned/typed/config/v1alpha1/fake/fake_target.go similarity index 83% rename from pkg/generated/clientset/versioned/typed/inv/v1alpha1/fake/fake_target.go rename to pkg/generated/clientset/versioned/typed/config/v1alpha1/fake/fake_target.go index 6da1064d..764fc05f 100644 --- a/pkg/generated/clientset/versioned/typed/inv/v1alpha1/fake/fake_target.go +++ b/pkg/generated/clientset/versioned/typed/config/v1alpha1/fake/fake_target.go @@ -18,18 +18,18 @@ limitations under the License. package fake import ( - v1alpha1 "github.com/sdcio/config-server/apis/inv/v1alpha1" - invv1alpha1 "github.com/sdcio/config-server/pkg/generated/clientset/versioned/typed/inv/v1alpha1" + v1alpha1 "github.com/sdcio/config-server/apis/config/v1alpha1" + configv1alpha1 "github.com/sdcio/config-server/pkg/generated/clientset/versioned/typed/config/v1alpha1" gentype "k8s.io/client-go/gentype" ) // fakeTargets implements TargetInterface type fakeTargets struct { *gentype.FakeClientWithList[*v1alpha1.Target, *v1alpha1.TargetList] - Fake *FakeInvV1alpha1 + Fake *FakeConfigV1alpha1 } -func newFakeTargets(fake *FakeInvV1alpha1, namespace string) invv1alpha1.TargetInterface { +func newFakeTargets(fake *FakeConfigV1alpha1, namespace string) configv1alpha1.TargetInterface { return &fakeTargets{ gentype.NewFakeClientWithList[*v1alpha1.Target, *v1alpha1.TargetList]( fake.Fake, diff --git a/pkg/generated/clientset/versioned/typed/config/v1alpha1/generated_expansion.go b/pkg/generated/clientset/versioned/typed/config/v1alpha1/generated_expansion.go index 709d2456..2881f978 100644 --- a/pkg/generated/clientset/versioned/typed/config/v1alpha1/generated_expansion.go +++ b/pkg/generated/clientset/versioned/typed/config/v1alpha1/generated_expansion.go @@ -28,3 +28,5 @@ type DeviationExpansion interface{} type RunningConfigExpansion interface{} type SensitiveConfigExpansion interface{} + +type TargetExpansion interface{} diff --git a/pkg/generated/clientset/versioned/typed/inv/v1alpha1/target.go b/pkg/generated/clientset/versioned/typed/config/v1alpha1/target.go similarity index 64% rename from pkg/generated/clientset/versioned/typed/inv/v1alpha1/target.go rename to pkg/generated/clientset/versioned/typed/config/v1alpha1/target.go index a65305f7..3e22b6a7 100644 --- a/pkg/generated/clientset/versioned/typed/inv/v1alpha1/target.go +++ b/pkg/generated/clientset/versioned/typed/config/v1alpha1/target.go @@ -20,7 +20,7 @@ package v1alpha1 import ( context "context" - invv1alpha1 "github.com/sdcio/config-server/apis/inv/v1alpha1" + configv1alpha1 "github.com/sdcio/config-server/apis/config/v1alpha1" scheme "github.com/sdcio/config-server/pkg/generated/clientset/versioned/scheme" v1 "k8s.io/apimachinery/pkg/apis/meta/v1" types "k8s.io/apimachinery/pkg/types" @@ -36,34 +36,34 @@ type TargetsGetter interface { // TargetInterface has methods to work with Target resources. type TargetInterface interface { - Create(ctx context.Context, target *invv1alpha1.Target, opts v1.CreateOptions) (*invv1alpha1.Target, error) - Update(ctx context.Context, target *invv1alpha1.Target, opts v1.UpdateOptions) (*invv1alpha1.Target, error) + Create(ctx context.Context, target *configv1alpha1.Target, opts v1.CreateOptions) (*configv1alpha1.Target, error) + Update(ctx context.Context, target *configv1alpha1.Target, opts v1.UpdateOptions) (*configv1alpha1.Target, error) // Add a +genclient:noStatus comment above the type to avoid generating UpdateStatus(). - UpdateStatus(ctx context.Context, target *invv1alpha1.Target, opts v1.UpdateOptions) (*invv1alpha1.Target, error) + UpdateStatus(ctx context.Context, target *configv1alpha1.Target, opts v1.UpdateOptions) (*configv1alpha1.Target, error) Delete(ctx context.Context, name string, opts v1.DeleteOptions) error DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error - Get(ctx context.Context, name string, opts v1.GetOptions) (*invv1alpha1.Target, error) - List(ctx context.Context, opts v1.ListOptions) (*invv1alpha1.TargetList, error) + Get(ctx context.Context, name string, opts v1.GetOptions) (*configv1alpha1.Target, error) + List(ctx context.Context, opts v1.ListOptions) (*configv1alpha1.TargetList, error) Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error) - Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *invv1alpha1.Target, err error) + Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *configv1alpha1.Target, err error) TargetExpansion } // targets implements TargetInterface type targets struct { - *gentype.ClientWithList[*invv1alpha1.Target, *invv1alpha1.TargetList] + *gentype.ClientWithList[*configv1alpha1.Target, *configv1alpha1.TargetList] } // newTargets returns a Targets -func newTargets(c *InvV1alpha1Client, namespace string) *targets { +func newTargets(c *ConfigV1alpha1Client, namespace string) *targets { return &targets{ - gentype.NewClientWithList[*invv1alpha1.Target, *invv1alpha1.TargetList]( + gentype.NewClientWithList[*configv1alpha1.Target, *configv1alpha1.TargetList]( "targets", c.RESTClient(), scheme.ParameterCodec, namespace, - func() *invv1alpha1.Target { return &invv1alpha1.Target{} }, - func() *invv1alpha1.TargetList { return &invv1alpha1.TargetList{} }, + func() *configv1alpha1.Target { return &configv1alpha1.Target{} }, + func() *configv1alpha1.TargetList { return &configv1alpha1.TargetList{} }, ), } } diff --git a/pkg/generated/clientset/versioned/typed/inv/v1alpha1/fake/fake_inv_client.go b/pkg/generated/clientset/versioned/typed/inv/v1alpha1/fake/fake_inv_client.go index 7275f8b8..5fa300f7 100644 --- a/pkg/generated/clientset/versioned/typed/inv/v1alpha1/fake/fake_inv_client.go +++ b/pkg/generated/clientset/versioned/typed/inv/v1alpha1/fake/fake_inv_client.go @@ -47,10 +47,6 @@ func (c *FakeInvV1alpha1) Subscriptions(namespace string) v1alpha1.SubscriptionI return newFakeSubscriptions(c, namespace) } -func (c *FakeInvV1alpha1) Targets(namespace string) v1alpha1.TargetInterface { - return newFakeTargets(c, namespace) -} - func (c *FakeInvV1alpha1) TargetConnectionProfiles(namespace string) v1alpha1.TargetConnectionProfileInterface { return newFakeTargetConnectionProfiles(c, namespace) } diff --git a/pkg/generated/clientset/versioned/typed/inv/v1alpha1/generated_expansion.go b/pkg/generated/clientset/versioned/typed/inv/v1alpha1/generated_expansion.go index d7e8daab..6f2d0d40 100644 --- a/pkg/generated/clientset/versioned/typed/inv/v1alpha1/generated_expansion.go +++ b/pkg/generated/clientset/versioned/typed/inv/v1alpha1/generated_expansion.go @@ -27,8 +27,6 @@ type SchemaExpansion interface{} type SubscriptionExpansion interface{} -type TargetExpansion interface{} - type TargetConnectionProfileExpansion interface{} type TargetSyncProfileExpansion interface{} diff --git a/pkg/generated/clientset/versioned/typed/inv/v1alpha1/inv_client.go b/pkg/generated/clientset/versioned/typed/inv/v1alpha1/inv_client.go index c203138f..6d408ad7 100644 --- a/pkg/generated/clientset/versioned/typed/inv/v1alpha1/inv_client.go +++ b/pkg/generated/clientset/versioned/typed/inv/v1alpha1/inv_client.go @@ -32,7 +32,6 @@ type InvV1alpha1Interface interface { RolloutsGetter SchemasGetter SubscriptionsGetter - TargetsGetter TargetConnectionProfilesGetter TargetSyncProfilesGetter WorkspacesGetter @@ -63,10 +62,6 @@ func (c *InvV1alpha1Client) Subscriptions(namespace string) SubscriptionInterfac return newSubscriptions(c, namespace) } -func (c *InvV1alpha1Client) Targets(namespace string) TargetInterface { - return newTargets(c, namespace) -} - func (c *InvV1alpha1Client) TargetConnectionProfiles(namespace string) TargetConnectionProfileInterface { return newTargetConnectionProfiles(c, namespace) } diff --git a/pkg/generated/informers/externalversions/config/v1alpha1/interface.go b/pkg/generated/informers/externalversions/config/v1alpha1/interface.go index 5c24fb9c..abab3842 100644 --- a/pkg/generated/informers/externalversions/config/v1alpha1/interface.go +++ b/pkg/generated/informers/externalversions/config/v1alpha1/interface.go @@ -35,6 +35,8 @@ type Interface interface { RunningConfigs() RunningConfigInformer // SensitiveConfigs returns a SensitiveConfigInformer. SensitiveConfigs() SensitiveConfigInformer + // Targets returns a TargetInformer. + Targets() TargetInformer } type version struct { @@ -77,3 +79,8 @@ func (v *version) RunningConfigs() RunningConfigInformer { func (v *version) SensitiveConfigs() SensitiveConfigInformer { return &sensitiveConfigInformer{factory: v.factory, namespace: v.namespace, tweakListOptions: v.tweakListOptions} } + +// Targets returns a TargetInformer. +func (v *version) Targets() TargetInformer { + return &targetInformer{factory: v.factory, namespace: v.namespace, tweakListOptions: v.tweakListOptions} +} diff --git a/pkg/generated/informers/externalversions/inv/v1alpha1/target.go b/pkg/generated/informers/externalversions/config/v1alpha1/target.go similarity index 81% rename from pkg/generated/informers/externalversions/inv/v1alpha1/target.go rename to pkg/generated/informers/externalversions/config/v1alpha1/target.go index ffe7c925..fbda33e9 100644 --- a/pkg/generated/informers/externalversions/inv/v1alpha1/target.go +++ b/pkg/generated/informers/externalversions/config/v1alpha1/target.go @@ -21,10 +21,10 @@ import ( context "context" time "time" - apisinvv1alpha1 "github.com/sdcio/config-server/apis/inv/v1alpha1" + apisconfigv1alpha1 "github.com/sdcio/config-server/apis/config/v1alpha1" versioned "github.com/sdcio/config-server/pkg/generated/clientset/versioned" internalinterfaces "github.com/sdcio/config-server/pkg/generated/informers/externalversions/internalinterfaces" - invv1alpha1 "github.com/sdcio/config-server/pkg/generated/listers/inv/v1alpha1" + configv1alpha1 "github.com/sdcio/config-server/pkg/generated/listers/config/v1alpha1" v1 "k8s.io/apimachinery/pkg/apis/meta/v1" runtime "k8s.io/apimachinery/pkg/runtime" watch "k8s.io/apimachinery/pkg/watch" @@ -35,7 +35,7 @@ import ( // Targets. type TargetInformer interface { Informer() cache.SharedIndexInformer - Lister() invv1alpha1.TargetLister + Lister() configv1alpha1.TargetLister } type targetInformer struct { @@ -61,28 +61,28 @@ func NewFilteredTargetInformer(client versioned.Interface, namespace string, res if tweakListOptions != nil { tweakListOptions(&options) } - return client.InvV1alpha1().Targets(namespace).List(context.Background(), options) + return client.ConfigV1alpha1().Targets(namespace).List(context.Background(), options) }, WatchFunc: func(options v1.ListOptions) (watch.Interface, error) { if tweakListOptions != nil { tweakListOptions(&options) } - return client.InvV1alpha1().Targets(namespace).Watch(context.Background(), options) + return client.ConfigV1alpha1().Targets(namespace).Watch(context.Background(), options) }, ListWithContextFunc: func(ctx context.Context, options v1.ListOptions) (runtime.Object, error) { if tweakListOptions != nil { tweakListOptions(&options) } - return client.InvV1alpha1().Targets(namespace).List(ctx, options) + return client.ConfigV1alpha1().Targets(namespace).List(ctx, options) }, WatchFuncWithContext: func(ctx context.Context, options v1.ListOptions) (watch.Interface, error) { if tweakListOptions != nil { tweakListOptions(&options) } - return client.InvV1alpha1().Targets(namespace).Watch(ctx, options) + return client.ConfigV1alpha1().Targets(namespace).Watch(ctx, options) }, }, client), - &apisinvv1alpha1.Target{}, + &apisconfigv1alpha1.Target{}, resyncPeriod, indexers, ) @@ -93,9 +93,9 @@ func (f *targetInformer) defaultInformer(client versioned.Interface, resyncPerio } func (f *targetInformer) Informer() cache.SharedIndexInformer { - return f.factory.InformerFor(&apisinvv1alpha1.Target{}, f.defaultInformer) + return f.factory.InformerFor(&apisconfigv1alpha1.Target{}, f.defaultInformer) } -func (f *targetInformer) Lister() invv1alpha1.TargetLister { - return invv1alpha1.NewTargetLister(f.Informer().GetIndexer()) +func (f *targetInformer) Lister() configv1alpha1.TargetLister { + return configv1alpha1.NewTargetLister(f.Informer().GetIndexer()) } diff --git a/pkg/generated/informers/externalversions/generic.go b/pkg/generated/informers/externalversions/generic.go index b3414835..f9e678aa 100644 --- a/pkg/generated/informers/externalversions/generic.go +++ b/pkg/generated/informers/externalversions/generic.go @@ -65,6 +65,8 @@ func (f *sharedInformerFactory) ForResource(resource schema.GroupVersionResource return &genericInformer{resource: resource.GroupResource(), informer: f.Config().V1alpha1().RunningConfigs().Informer()}, nil case v1alpha1.SchemeGroupVersion.WithResource("sensitiveconfigs"): return &genericInformer{resource: resource.GroupResource(), informer: f.Config().V1alpha1().SensitiveConfigs().Informer()}, nil + case v1alpha1.SchemeGroupVersion.WithResource("targets"): + return &genericInformer{resource: resource.GroupResource(), informer: f.Config().V1alpha1().Targets().Informer()}, nil // Group=inv.sdcio.dev, Version=v1alpha1 case invv1alpha1.SchemeGroupVersion.WithResource("discoveryrules"): @@ -77,8 +79,6 @@ func (f *sharedInformerFactory) ForResource(resource schema.GroupVersionResource return &genericInformer{resource: resource.GroupResource(), informer: f.Inv().V1alpha1().Schemas().Informer()}, nil case invv1alpha1.SchemeGroupVersion.WithResource("subscriptions"): return &genericInformer{resource: resource.GroupResource(), informer: f.Inv().V1alpha1().Subscriptions().Informer()}, nil - case invv1alpha1.SchemeGroupVersion.WithResource("targets"): - return &genericInformer{resource: resource.GroupResource(), informer: f.Inv().V1alpha1().Targets().Informer()}, nil case invv1alpha1.SchemeGroupVersion.WithResource("targetconnectionprofiles"): return &genericInformer{resource: resource.GroupResource(), informer: f.Inv().V1alpha1().TargetConnectionProfiles().Informer()}, nil case invv1alpha1.SchemeGroupVersion.WithResource("targetsyncprofiles"): diff --git a/pkg/generated/informers/externalversions/inv/v1alpha1/interface.go b/pkg/generated/informers/externalversions/inv/v1alpha1/interface.go index b0d43822..6038cc3e 100644 --- a/pkg/generated/informers/externalversions/inv/v1alpha1/interface.go +++ b/pkg/generated/informers/externalversions/inv/v1alpha1/interface.go @@ -33,8 +33,6 @@ type Interface interface { Schemas() SchemaInformer // Subscriptions returns a SubscriptionInformer. Subscriptions() SubscriptionInformer - // Targets returns a TargetInformer. - Targets() TargetInformer // TargetConnectionProfiles returns a TargetConnectionProfileInformer. TargetConnectionProfiles() TargetConnectionProfileInformer // TargetSyncProfiles returns a TargetSyncProfileInformer. @@ -79,11 +77,6 @@ func (v *version) Subscriptions() SubscriptionInformer { return &subscriptionInformer{factory: v.factory, namespace: v.namespace, tweakListOptions: v.tweakListOptions} } -// Targets returns a TargetInformer. -func (v *version) Targets() TargetInformer { - return &targetInformer{factory: v.factory, namespace: v.namespace, tweakListOptions: v.tweakListOptions} -} - // TargetConnectionProfiles returns a TargetConnectionProfileInformer. func (v *version) TargetConnectionProfiles() TargetConnectionProfileInformer { return &targetConnectionProfileInformer{factory: v.factory, namespace: v.namespace, tweakListOptions: v.tweakListOptions} diff --git a/pkg/generated/listers/config/v1alpha1/expansion_generated.go b/pkg/generated/listers/config/v1alpha1/expansion_generated.go index e6b61cf8..bd3358d3 100644 --- a/pkg/generated/listers/config/v1alpha1/expansion_generated.go +++ b/pkg/generated/listers/config/v1alpha1/expansion_generated.go @@ -64,3 +64,11 @@ type SensitiveConfigListerExpansion interface{} // SensitiveConfigNamespaceListerExpansion allows custom methods to be added to // SensitiveConfigNamespaceLister. type SensitiveConfigNamespaceListerExpansion interface{} + +// TargetListerExpansion allows custom methods to be added to +// TargetLister. +type TargetListerExpansion interface{} + +// TargetNamespaceListerExpansion allows custom methods to be added to +// TargetNamespaceLister. +type TargetNamespaceListerExpansion interface{} diff --git a/pkg/generated/listers/inv/v1alpha1/target.go b/pkg/generated/listers/config/v1alpha1/target.go similarity index 77% rename from pkg/generated/listers/inv/v1alpha1/target.go rename to pkg/generated/listers/config/v1alpha1/target.go index 39275995..44226b36 100644 --- a/pkg/generated/listers/inv/v1alpha1/target.go +++ b/pkg/generated/listers/config/v1alpha1/target.go @@ -18,7 +18,7 @@ limitations under the License. package v1alpha1 import ( - invv1alpha1 "github.com/sdcio/config-server/apis/inv/v1alpha1" + configv1alpha1 "github.com/sdcio/config-server/apis/config/v1alpha1" labels "k8s.io/apimachinery/pkg/labels" listers "k8s.io/client-go/listers" cache "k8s.io/client-go/tools/cache" @@ -29,7 +29,7 @@ import ( type TargetLister interface { // List lists all Targets in the indexer. // Objects returned here must be treated as read-only. - List(selector labels.Selector) (ret []*invv1alpha1.Target, err error) + List(selector labels.Selector) (ret []*configv1alpha1.Target, err error) // Targets returns an object that can list and get Targets. Targets(namespace string) TargetNamespaceLister TargetListerExpansion @@ -37,17 +37,17 @@ type TargetLister interface { // targetLister implements the TargetLister interface. type targetLister struct { - listers.ResourceIndexer[*invv1alpha1.Target] + listers.ResourceIndexer[*configv1alpha1.Target] } // NewTargetLister returns a new TargetLister. func NewTargetLister(indexer cache.Indexer) TargetLister { - return &targetLister{listers.New[*invv1alpha1.Target](indexer, invv1alpha1.Resource("target"))} + return &targetLister{listers.New[*configv1alpha1.Target](indexer, configv1alpha1.Resource("target"))} } // Targets returns an object that can list and get Targets. func (s *targetLister) Targets(namespace string) TargetNamespaceLister { - return targetNamespaceLister{listers.NewNamespaced[*invv1alpha1.Target](s.ResourceIndexer, namespace)} + return targetNamespaceLister{listers.NewNamespaced[*configv1alpha1.Target](s.ResourceIndexer, namespace)} } // TargetNamespaceLister helps list and get Targets. @@ -55,15 +55,15 @@ func (s *targetLister) Targets(namespace string) TargetNamespaceLister { type TargetNamespaceLister interface { // List lists all Targets in the indexer for a given namespace. // Objects returned here must be treated as read-only. - List(selector labels.Selector) (ret []*invv1alpha1.Target, err error) + List(selector labels.Selector) (ret []*configv1alpha1.Target, err error) // Get retrieves the Target from the indexer for a given namespace and name. // Objects returned here must be treated as read-only. - Get(name string) (*invv1alpha1.Target, error) + Get(name string) (*configv1alpha1.Target, error) TargetNamespaceListerExpansion } // targetNamespaceLister implements the TargetNamespaceLister // interface. type targetNamespaceLister struct { - listers.ResourceIndexer[*invv1alpha1.Target] + listers.ResourceIndexer[*configv1alpha1.Target] } diff --git a/pkg/generated/listers/inv/v1alpha1/expansion_generated.go b/pkg/generated/listers/inv/v1alpha1/expansion_generated.go index 09d3b5fc..b86141dd 100644 --- a/pkg/generated/listers/inv/v1alpha1/expansion_generated.go +++ b/pkg/generated/listers/inv/v1alpha1/expansion_generated.go @@ -57,14 +57,6 @@ type SubscriptionListerExpansion interface{} // SubscriptionNamespaceLister. type SubscriptionNamespaceListerExpansion interface{} -// TargetListerExpansion allows custom methods to be added to -// TargetLister. -type TargetListerExpansion interface{} - -// TargetNamespaceListerExpansion allows custom methods to be added to -// TargetNamespaceLister. -type TargetNamespaceListerExpansion interface{} - // TargetConnectionProfileListerExpansion allows custom methods to be added to // TargetConnectionProfileLister. type TargetConnectionProfileListerExpansion interface{} diff --git a/pkg/generated/openapi/zz_generated.openapi.go b/pkg/generated/openapi/zz_generated.openapi.go index 46591b55..007ec274 100644 --- a/pkg/generated/openapi/zz_generated.openapi.go +++ b/pkg/generated/openapi/zz_generated.openapi.go @@ -47,6 +47,8 @@ func GetOpenAPIDefinitions(ref common.ReferenceCallback) map[string]common.OpenA "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigSetList": schema_config_server_apis_config_v1alpha1_ConfigSetList(ref), "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigSetSpec": schema_config_server_apis_config_v1alpha1_ConfigSetSpec(ref), "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigSetStatus": schema_config_server_apis_config_v1alpha1_ConfigSetStatus(ref), + "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigSetTarget": schema_config_server_apis_config_v1alpha1_ConfigSetTarget(ref), + "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigSetTargetStatus": schema_config_server_apis_config_v1alpha1_ConfigSetTargetStatus(ref), "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigSpec": schema_config_server_apis_config_v1alpha1_ConfigSpec(ref), "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigStatus": schema_config_server_apis_config_v1alpha1_ConfigStatus(ref), "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigStatusLastKnownGoodSchema": schema_config_server_apis_config_v1alpha1_ConfigStatusLastKnownGoodSchema(ref), @@ -54,6 +56,7 @@ func GetOpenAPIDefinitions(ref common.ReferenceCallback) map[string]common.OpenA "github.com/sdcio/config-server/apis/config/v1alpha1.DeviationList": schema_config_server_apis_config_v1alpha1_DeviationList(ref), "github.com/sdcio/config-server/apis/config/v1alpha1.DeviationSpec": schema_config_server_apis_config_v1alpha1_DeviationSpec(ref), "github.com/sdcio/config-server/apis/config/v1alpha1.DeviationStatus": schema_config_server_apis_config_v1alpha1_DeviationStatus(ref), + "github.com/sdcio/config-server/apis/config/v1alpha1.DiscoveryInfo": schema_config_server_apis_config_v1alpha1_DiscoveryInfo(ref), "github.com/sdcio/config-server/apis/config/v1alpha1.Lifecycle": schema_config_server_apis_config_v1alpha1_Lifecycle(ref), "github.com/sdcio/config-server/apis/config/v1alpha1.RunningConfig": schema_config_server_apis_config_v1alpha1_RunningConfig(ref), "github.com/sdcio/config-server/apis/config/v1alpha1.RunningConfigList": schema_config_server_apis_config_v1alpha1_RunningConfigList(ref), @@ -65,8 +68,10 @@ func GetOpenAPIDefinitions(ref common.ReferenceCallback) map[string]common.OpenA "github.com/sdcio/config-server/apis/config/v1alpha1.SensitiveConfigSpec": schema_config_server_apis_config_v1alpha1_SensitiveConfigSpec(ref), "github.com/sdcio/config-server/apis/config/v1alpha1.SensitiveConfigStatus": schema_config_server_apis_config_v1alpha1_SensitiveConfigStatus(ref), "github.com/sdcio/config-server/apis/config/v1alpha1.Target": schema_config_server_apis_config_v1alpha1_Target(ref), + "github.com/sdcio/config-server/apis/config/v1alpha1.TargetList": schema_config_server_apis_config_v1alpha1_TargetList(ref), + "github.com/sdcio/config-server/apis/config/v1alpha1.TargetSpec": schema_config_server_apis_config_v1alpha1_TargetSpec(ref), "github.com/sdcio/config-server/apis/config/v1alpha1.TargetStatus": schema_config_server_apis_config_v1alpha1_TargetStatus(ref), - "github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryInfo": schema_config_server_apis_inv_v1alpha1_DiscoveryInfo(ref), + "github.com/sdcio/config-server/apis/config/v1alpha1.TargetStatusUsedReferences": schema_config_server_apis_config_v1alpha1_TargetStatusUsedReferences(ref), "github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryParameters": schema_config_server_apis_inv_v1alpha1_DiscoveryParameters(ref), "github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryPathDefinition": schema_config_server_apis_inv_v1alpha1_DiscoveryPathDefinition(ref), "github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryProfile": schema_config_server_apis_inv_v1alpha1_DiscoveryProfile(ref), @@ -102,15 +107,10 @@ func GetOpenAPIDefinitions(ref common.ReferenceCallback) map[string]common.OpenA "github.com/sdcio/config-server/apis/inv/v1alpha1.SubscriptionSpec": schema_config_server_apis_inv_v1alpha1_SubscriptionSpec(ref), "github.com/sdcio/config-server/apis/inv/v1alpha1.SubscriptionStatus": schema_config_server_apis_inv_v1alpha1_SubscriptionStatus(ref), "github.com/sdcio/config-server/apis/inv/v1alpha1.SubscriptionTarget": schema_config_server_apis_inv_v1alpha1_SubscriptionTarget(ref), - "github.com/sdcio/config-server/apis/inv/v1alpha1.Target": schema_config_server_apis_inv_v1alpha1_Target(ref), "github.com/sdcio/config-server/apis/inv/v1alpha1.TargetConnectionProfile": schema_config_server_apis_inv_v1alpha1_TargetConnectionProfile(ref), "github.com/sdcio/config-server/apis/inv/v1alpha1.TargetConnectionProfileList": schema_config_server_apis_inv_v1alpha1_TargetConnectionProfileList(ref), "github.com/sdcio/config-server/apis/inv/v1alpha1.TargetConnectionProfileSpec": schema_config_server_apis_inv_v1alpha1_TargetConnectionProfileSpec(ref), - "github.com/sdcio/config-server/apis/inv/v1alpha1.TargetList": schema_config_server_apis_inv_v1alpha1_TargetList(ref), "github.com/sdcio/config-server/apis/inv/v1alpha1.TargetProfile": schema_config_server_apis_inv_v1alpha1_TargetProfile(ref), - "github.com/sdcio/config-server/apis/inv/v1alpha1.TargetSpec": schema_config_server_apis_inv_v1alpha1_TargetSpec(ref), - "github.com/sdcio/config-server/apis/inv/v1alpha1.TargetStatus": schema_config_server_apis_inv_v1alpha1_TargetStatus(ref), - "github.com/sdcio/config-server/apis/inv/v1alpha1.TargetStatusUsedReferences": schema_config_server_apis_inv_v1alpha1_TargetStatusUsedReferences(ref), "github.com/sdcio/config-server/apis/inv/v1alpha1.TargetSyncProfile": schema_config_server_apis_inv_v1alpha1_TargetSyncProfile(ref), "github.com/sdcio/config-server/apis/inv/v1alpha1.TargetSyncProfileList": schema_config_server_apis_inv_v1alpha1_TargetSyncProfileList(ref), "github.com/sdcio/config-server/apis/inv/v1alpha1.TargetSyncProfileSpec": schema_config_server_apis_inv_v1alpha1_TargetSyncProfileSpec(ref), @@ -579,13 +579,6 @@ func schema_config_server_apis_config_v1alpha1_Config(ref common.ReferenceCallba }, }, }, - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-group-version-kind": []interface{}{ - map[string]interface{}{"group": "config.sdcio.dev", "kind": "Config", "version": "v1alpha1"}, - }, - }, - }, }, Dependencies: []string{ "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigSpec", "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigStatus", metav1.ObjectMeta{}.OpenAPIModelName()}, @@ -633,13 +626,6 @@ func schema_config_server_apis_config_v1alpha1_ConfigBlame(ref common.ReferenceC }, }, }, - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-group-version-kind": []interface{}{ - map[string]interface{}{"group": "config.sdcio.dev", "kind": "ConfigBlame", "version": "v1alpha1"}, - }, - }, - }, }, Dependencies: []string{ "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigBlameSpec", "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigBlameStatus", metav1.ObjectMeta{}.OpenAPIModelName()}, @@ -884,13 +870,6 @@ func schema_config_server_apis_config_v1alpha1_ConfigSet(ref common.ReferenceCal }, }, }, - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-group-version-kind": []interface{}{ - map[string]interface{}{"group": "config.sdcio.dev", "kind": "ConfigSet", "version": "v1alpha1"}, - }, - }, - }, }, Dependencies: []string{ "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigSetSpec", "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigSetStatus", metav1.ObjectMeta{}.OpenAPIModelName()}, @@ -957,7 +936,7 @@ func schema_config_server_apis_config_v1alpha1_ConfigSetSpec(ref common.Referenc SchemaProps: spec.SchemaProps{ Description: "Targets defines the targets on which this configSet applies", Default: map[string]interface{}{}, - Ref: ref("github.com/sdcio/config-server/apis/config/v1alpha1.Target"), + Ref: ref("github.com/sdcio/config-server/apis/config/v1alpha1.ConfigSetTarget"), }, }, "lifecycle": { @@ -1004,7 +983,7 @@ func schema_config_server_apis_config_v1alpha1_ConfigSetSpec(ref common.Referenc }, }, Dependencies: []string{ - "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigBlob", "github.com/sdcio/config-server/apis/config/v1alpha1.Lifecycle", "github.com/sdcio/config-server/apis/config/v1alpha1.Target"}, + "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigBlob", "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigSetTarget", "github.com/sdcio/config-server/apis/config/v1alpha1.Lifecycle"}, } } @@ -1050,7 +1029,7 @@ func schema_config_server_apis_config_v1alpha1_ConfigSetStatus(ref common.Refere Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/sdcio/config-server/apis/config/v1alpha1.TargetStatus"), + Ref: ref("github.com/sdcio/config-server/apis/config/v1alpha1.ConfigSetTargetStatus"), }, }, }, @@ -1060,7 +1039,94 @@ func schema_config_server_apis_config_v1alpha1_ConfigSetStatus(ref common.Refere }, }, Dependencies: []string{ - "github.com/sdcio/config-server/apis/condition/v1alpha1.Condition", "github.com/sdcio/config-server/apis/config/v1alpha1.TargetStatus"}, + "github.com/sdcio/config-server/apis/condition/v1alpha1.Condition", "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigSetTargetStatus"}, + } +} + +func schema_config_server_apis_config_v1alpha1_ConfigSetTarget(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "targetSelector": { + SchemaProps: spec.SchemaProps{ + Description: "TargetSelector defines the selector used to select the targets to which the config applies", + Ref: ref(metav1.LabelSelector{}.OpenAPIModelName()), + }, + }, + }, + }, + }, + Dependencies: []string{ + metav1.LabelSelector{}.OpenAPIModelName()}, + } +} + +func schema_config_server_apis_config_v1alpha1_ConfigSetTargetStatus(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "name": { + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "type": { + SchemaProps: spec.SchemaProps{ + Description: "type of condition in CamelCase or in foo.example.com/CamelCase.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "status": { + SchemaProps: spec.SchemaProps{ + Description: "status of the condition, one of True, False, Unknown.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "observedGeneration": { + SchemaProps: spec.SchemaProps{ + Description: "observedGeneration represents the .metadata.generation that the condition was set based upon. For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date with respect to the current state of the instance.", + Type: []string{"integer"}, + Format: "int64", + }, + }, + "lastTransitionTime": { + SchemaProps: spec.SchemaProps{ + Description: "lastTransitionTime is the last time the condition transitioned from one status to another. This should be when the underlying condition changed. If that is not known, then using the time when the API field changed is acceptable.", + Ref: ref(metav1.Time{}.OpenAPIModelName()), + }, + }, + "reason": { + SchemaProps: spec.SchemaProps{ + Description: "reason contains a programmatic identifier indicating the reason for the condition's last transition. Producers of specific condition types may define expected values and meanings for this field, and whether the values are considered a guaranteed API. The value should be a CamelCase string. This field may not be empty.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "message": { + SchemaProps: spec.SchemaProps{ + Description: "message is a human readable message indicating details about the transition. This may be an empty string.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"name", "type", "status", "lastTransitionTime", "reason", "message"}, + }, + }, + Dependencies: []string{ + metav1.Time{}.OpenAPIModelName()}, } } @@ -1249,13 +1315,6 @@ func schema_config_server_apis_config_v1alpha1_Deviation(ref common.ReferenceCal }, }, }, - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-group-version-kind": []interface{}{ - map[string]interface{}{"group": "config.sdcio.dev", "kind": "Deviation", "version": "v1alpha1"}, - }, - }, - }, }, Dependencies: []string{ "github.com/sdcio/config-server/apis/config/v1alpha1.DeviationSpec", "github.com/sdcio/config-server/apis/config/v1alpha1.DeviationStatus", metav1.ObjectMeta{}.OpenAPIModelName()}, @@ -1388,6 +1447,87 @@ func schema_config_server_apis_config_v1alpha1_DeviationStatus(ref common.Refere } } +func schema_config_server_apis_config_v1alpha1_DiscoveryInfo(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "protocol": { + SchemaProps: spec.SchemaProps{ + Description: "Protocol used for discovery", + Type: []string{"string"}, + Format: "", + }, + }, + "provider": { + SchemaProps: spec.SchemaProps{ + Description: "Type associated with the target", + Type: []string{"string"}, + Format: "", + }, + }, + "version": { + SchemaProps: spec.SchemaProps{ + Description: "Version associated with the target", + Type: []string{"string"}, + Format: "", + }, + }, + "hostname": { + SchemaProps: spec.SchemaProps{ + Description: "Hostname associated with the target", + Type: []string{"string"}, + Format: "", + }, + }, + "platform": { + SchemaProps: spec.SchemaProps{ + Description: "Platform associated with the target", + Type: []string{"string"}, + Format: "", + }, + }, + "macAddress": { + SchemaProps: spec.SchemaProps{ + Description: "MacAddress associated with the target", + Type: []string{"string"}, + Format: "", + }, + }, + "serialNumber": { + SchemaProps: spec.SchemaProps{ + Description: "SerialNumber associated with the target", + Type: []string{"string"}, + Format: "", + }, + }, + "supportedEncodings": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-type": "atomic", + }, + }, + SchemaProps: spec.SchemaProps{ + Description: "Supported Encodings of the target", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + }, + }, + }, + } +} + func schema_config_server_apis_config_v1alpha1_Lifecycle(ref common.ReferenceCallback) common.OpenAPIDefinition { return common.OpenAPIDefinition{ Schema: spec.Schema{ @@ -1448,13 +1588,6 @@ func schema_config_server_apis_config_v1alpha1_RunningConfig(ref common.Referenc }, }, }, - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-group-version-kind": []interface{}{ - map[string]interface{}{"group": "config.sdcio.dev", "kind": "RunningConfig", "version": "v1alpha1"}, - }, - }, - }, }, Dependencies: []string{ "github.com/sdcio/config-server/apis/config/v1alpha1.RunningConfigSpec", "github.com/sdcio/config-server/apis/config/v1alpha1.RunningConfigStatus", metav1.ObjectMeta{}.OpenAPIModelName()}, @@ -1583,13 +1716,6 @@ func schema_config_server_apis_config_v1alpha1_SensitiveConfig(ref common.Refere }, }, }, - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-group-version-kind": []interface{}{ - map[string]interface{}{"group": "config.sdcio.dev", "kind": "SensitiveConfig", "version": "v1alpha1"}, - }, - }, - }, }, Dependencies: []string{ "github.com/sdcio/config-server/apis/config/v1alpha1.SensitiveConfigSpec", "github.com/sdcio/config-server/apis/config/v1alpha1.SensitiveConfigStatus", metav1.ObjectMeta{}.OpenAPIModelName()}, @@ -1790,165 +1916,241 @@ func schema_config_server_apis_config_v1alpha1_Target(ref common.ReferenceCallba return common.OpenAPIDefinition{ Schema: spec.Schema{ SchemaProps: spec.SchemaProps{ - Type: []string{"object"}, + Description: "Target is the Schema for the Target API", + Type: []string{"object"}, Properties: map[string]spec.Schema{ - "targetSelector": { + "kind": { SchemaProps: spec.SchemaProps{ - Description: "TargetSelector defines the selector used to select the targets to which the config applies", - Ref: ref(metav1.LabelSelector{}.OpenAPIModelName()), + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "metadata": { + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), + }, + }, + "spec": { + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("github.com/sdcio/config-server/apis/config/v1alpha1.TargetSpec"), + }, + }, + "status": { + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("github.com/sdcio/config-server/apis/config/v1alpha1.TargetStatus"), }, }, }, }, }, Dependencies: []string{ - metav1.LabelSelector{}.OpenAPIModelName()}, + "github.com/sdcio/config-server/apis/config/v1alpha1.TargetSpec", "github.com/sdcio/config-server/apis/config/v1alpha1.TargetStatus", metav1.ObjectMeta{}.OpenAPIModelName()}, } } -func schema_config_server_apis_config_v1alpha1_TargetStatus(ref common.ReferenceCallback) common.OpenAPIDefinition { +func schema_config_server_apis_config_v1alpha1_TargetList(ref common.ReferenceCallback) common.OpenAPIDefinition { return common.OpenAPIDefinition{ Schema: spec.Schema{ SchemaProps: spec.SchemaProps{ - Type: []string{"object"}, + Description: "TargetList contains a list of Targets", + Type: []string{"object"}, Properties: map[string]spec.Schema{ - "name": { + "kind": { SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", }, }, - "type": { + "apiVersion": { SchemaProps: spec.SchemaProps{ - Description: "type of condition in CamelCase or in foo.example.com/CamelCase.", + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "metadata": { + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), + }, + }, + "items": { + SchemaProps: spec.SchemaProps{ + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("github.com/sdcio/config-server/apis/config/v1alpha1.Target"), + }, + }, + }, + }, + }, + }, + Required: []string{"items"}, + }, + }, + Dependencies: []string{ + "github.com/sdcio/config-server/apis/config/v1alpha1.Target", metav1.ListMeta{}.OpenAPIModelName()}, + } +} + +func schema_config_server_apis_config_v1alpha1_TargetSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "TargetSpec defines the desired state of Target", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "provider": { + SchemaProps: spec.SchemaProps{ + Description: "Provider specifies the provider using this target.", Default: "", Type: []string{"string"}, Format: "", }, }, - "status": { + "address": { SchemaProps: spec.SchemaProps{ - Description: "status of the condition, one of True, False, Unknown.", + Description: "Address defines the address to connect to the target", Default: "", Type: []string{"string"}, Format: "", }, }, - "observedGeneration": { + "credentials": { SchemaProps: spec.SchemaProps{ - Description: "observedGeneration represents the .metadata.generation that the condition was set based upon. For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date with respect to the current state of the instance.", - Type: []string{"integer"}, - Format: "int64", + Description: "Credentials defines the name of the secret that holds the credentials to connect to the target", + Default: "", + Type: []string{"string"}, + Format: "", }, }, - "lastTransitionTime": { + "tlsSecret": { SchemaProps: spec.SchemaProps{ - Description: "lastTransitionTime is the last time the condition transitioned from one status to another. This should be when the underlying condition changed. If that is not known, then using the time when the API field changed is acceptable.", - Ref: ref(metav1.Time{}.OpenAPIModelName()), + Description: "TLSSecret defines the name of the TLS secret to connect to the target if mtls is used", + Type: []string{"string"}, + Format: "", }, }, - "reason": { + "connectionProfile": { SchemaProps: spec.SchemaProps{ - Description: "reason contains a programmatic identifier indicating the reason for the condition's last transition. Producers of specific condition types may define expected values and meanings for this field, and whether the values are considered a guaranteed API. The value should be a CamelCase string. This field may not be empty.", + Description: "ConnectionProfile define the profile used to connect to the target once discovered", Default: "", Type: []string{"string"}, Format: "", }, }, - "message": { + "syncProfile": { SchemaProps: spec.SchemaProps{ - Description: "message is a human readable message indicating details about the transition. This may be an empty string.", - Default: "", + Description: "SyncProfile define the profile used to sync to the target config once discovered", Type: []string{"string"}, Format: "", }, }, }, - Required: []string{"name", "type", "status", "lastTransitionTime", "reason", "message"}, + Required: []string{"provider", "address", "credentials", "connectionProfile"}, }, }, - Dependencies: []string{ - metav1.Time{}.OpenAPIModelName()}, } } -func schema_config_server_apis_inv_v1alpha1_DiscoveryInfo(ref common.ReferenceCallback) common.OpenAPIDefinition { +func schema_config_server_apis_config_v1alpha1_TargetStatus(ref common.ReferenceCallback) common.OpenAPIDefinition { return common.OpenAPIDefinition{ Schema: spec.Schema{ SchemaProps: spec.SchemaProps{ - Type: []string{"object"}, + Description: "TargetStatus defines the observed state of Target", + Type: []string{"object"}, Properties: map[string]spec.Schema{ - "protocol": { - SchemaProps: spec.SchemaProps{ - Description: "Protocol used for discovery", - Type: []string{"string"}, - Format: "", + "conditions": { + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-list-map-keys": []interface{}{ + "type", + }, + "x-kubernetes-list-type": "map", + }, }, - }, - "provider": { SchemaProps: spec.SchemaProps{ - Description: "Type associated with the target", - Type: []string{"string"}, - Format: "", + Description: "Conditions of the resource.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("github.com/sdcio/config-server/apis/condition/v1alpha1.Condition"), + }, + }, + }, }, }, - "version": { + "discoveryInfo": { SchemaProps: spec.SchemaProps{ - Description: "Version associated with the target", - Type: []string{"string"}, - Format: "", + Description: "Discovery info defines the information retrieved during discovery", + Ref: ref("github.com/sdcio/config-server/apis/config/v1alpha1.DiscoveryInfo"), }, }, - "hostname": { + "usedReferences": { SchemaProps: spec.SchemaProps{ - Description: "Hostname associated with the target", - Type: []string{"string"}, - Format: "", + Description: "UsedReferences track the resource used to reconcile the cr", + Ref: ref("github.com/sdcio/config-server/apis/config/v1alpha1.TargetStatusUsedReferences"), }, }, - "platform": { + }, + }, + }, + Dependencies: []string{ + "github.com/sdcio/config-server/apis/condition/v1alpha1.Condition", "github.com/sdcio/config-server/apis/config/v1alpha1.DiscoveryInfo", "github.com/sdcio/config-server/apis/config/v1alpha1.TargetStatusUsedReferences"}, + } +} + +func schema_config_server_apis_config_v1alpha1_TargetStatusUsedReferences(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "secretResourceVersion": { SchemaProps: spec.SchemaProps{ - Description: "Platform associated with the target", - Type: []string{"string"}, - Format: "", + Type: []string{"string"}, + Format: "", }, }, - "macAddress": { + "tlsSecretResourceVersion": { SchemaProps: spec.SchemaProps{ - Description: "MacAddress associated with the target", - Type: []string{"string"}, - Format: "", + Type: []string{"string"}, + Format: "", }, }, - "serialNumber": { + "connectionProfileResourceVersion": { SchemaProps: spec.SchemaProps{ - Description: "SerialNumber associated with the target", - Type: []string{"string"}, - Format: "", + Default: "", + Type: []string{"string"}, + Format: "", }, }, - "supportedEncodings": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-type": "atomic", - }, - }, + "syncProfileResourceVersion": { SchemaProps: spec.SchemaProps{ - Description: "Supported Encodings of the target", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, + Default: "", + Type: []string{"string"}, + Format: "", }, }, }, + Required: []string{"connectionProfileResourceVersion", "syncProfileResourceVersion"}, }, }, } @@ -3712,53 +3914,6 @@ func schema_config_server_apis_inv_v1alpha1_SubscriptionTarget(ref common.Refere } } -func schema_config_server_apis_inv_v1alpha1_Target(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "Target is the Schema for the Target API", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Type: []string{"string"}, - Format: "", - }, - }, - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", - Type: []string{"string"}, - Format: "", - }, - }, - "metadata": { - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), - }, - }, - "spec": { - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.TargetSpec"), - }, - }, - "status": { - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.TargetStatus"), - }, - }, - }, - }, - }, - Dependencies: []string{ - "github.com/sdcio/config-server/apis/inv/v1alpha1.TargetSpec", "github.com/sdcio/config-server/apis/inv/v1alpha1.TargetStatus", metav1.ObjectMeta{}.OpenAPIModelName()}, - } -} - func schema_config_server_apis_inv_v1alpha1_TargetConnectionProfile(ref common.ReferenceCallback) common.OpenAPIDefinition { return common.OpenAPIDefinition{ Schema: spec.Schema{ @@ -3945,55 +4100,6 @@ func schema_config_server_apis_inv_v1alpha1_TargetConnectionProfileSpec(ref comm } } -func schema_config_server_apis_inv_v1alpha1_TargetList(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "TargetList contains a list of Targets", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Type: []string{"string"}, - Format: "", - }, - }, - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", - Type: []string{"string"}, - Format: "", - }, - }, - "metadata": { - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(metav1.ListMeta{}.OpenAPIModelName()), - }, - }, - "items": { - SchemaProps: spec.SchemaProps{ - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.Target"), - }, - }, - }, - }, - }, - }, - Required: []string{"items"}, - }, - }, - Dependencies: []string{ - "github.com/sdcio/config-server/apis/inv/v1alpha1.Target", metav1.ListMeta{}.OpenAPIModelName()}, - } -} - func schema_config_server_apis_inv_v1alpha1_TargetProfile(ref common.ReferenceCallback) common.OpenAPIDefinition { return common.OpenAPIDefinition{ Schema: spec.Schema{ @@ -4037,154 +4143,6 @@ func schema_config_server_apis_inv_v1alpha1_TargetProfile(ref common.ReferenceCa } } -func schema_config_server_apis_inv_v1alpha1_TargetSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "TargetSpec defines the desired state of Target", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "provider": { - SchemaProps: spec.SchemaProps{ - Description: "Provider specifies the provider using this target.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "address": { - SchemaProps: spec.SchemaProps{ - Description: "Address defines the address to connect to the target", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "credentials": { - SchemaProps: spec.SchemaProps{ - Description: "Credentials defines the name of the secret that holds the credentials to connect to the target", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "tlsSecret": { - SchemaProps: spec.SchemaProps{ - Description: "TLSSecret defines the name of the TLS secret to connect to the target if mtls is used", - Type: []string{"string"}, - Format: "", - }, - }, - "connectionProfile": { - SchemaProps: spec.SchemaProps{ - Description: "ConnectionProfile define the profile used to connect to the target once discovered", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "syncProfile": { - SchemaProps: spec.SchemaProps{ - Description: "SyncProfile define the profile used to sync to the target config once discovered", - Type: []string{"string"}, - Format: "", - }, - }, - }, - Required: []string{"provider", "address", "credentials", "connectionProfile"}, - }, - }, - } -} - -func schema_config_server_apis_inv_v1alpha1_TargetStatus(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "TargetStatus defines the observed state of Target", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "conditions": { - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-list-map-keys": []interface{}{ - "type", - }, - "x-kubernetes-list-type": "map", - }, - }, - SchemaProps: spec.SchemaProps{ - Description: "Conditions of the resource.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref("github.com/sdcio/config-server/apis/condition/v1alpha1.Condition"), - }, - }, - }, - }, - }, - "discoveryInfo": { - SchemaProps: spec.SchemaProps{ - Description: "Discovery info defines the information retrieved during discovery", - Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryInfo"), - }, - }, - "usedReferences": { - SchemaProps: spec.SchemaProps{ - Description: "UsedReferences track the resource used to reconcile the cr", - Ref: ref("github.com/sdcio/config-server/apis/inv/v1alpha1.TargetStatusUsedReferences"), - }, - }, - }, - }, - }, - Dependencies: []string{ - "github.com/sdcio/config-server/apis/condition/v1alpha1.Condition", "github.com/sdcio/config-server/apis/inv/v1alpha1.DiscoveryInfo", "github.com/sdcio/config-server/apis/inv/v1alpha1.TargetStatusUsedReferences"}, - } -} - -func schema_config_server_apis_inv_v1alpha1_TargetStatusUsedReferences(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "secretResourceVersion": { - SchemaProps: spec.SchemaProps{ - Type: []string{"string"}, - Format: "", - }, - }, - "tlsSecretResourceVersion": { - SchemaProps: spec.SchemaProps{ - Type: []string{"string"}, - Format: "", - }, - }, - "connectionProfileResourceVersion": { - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "syncProfileResourceVersion": { - SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - }, - Required: []string{"connectionProfileResourceVersion", "syncProfileResourceVersion"}, - }, - }, - } -} - func schema_config_server_apis_inv_v1alpha1_TargetSyncProfile(ref common.ReferenceCallback) common.OpenAPIDefinition { return common.OpenAPIDefinition{ Schema: spec.Schema{ diff --git a/pkg/reconcilers/configset/reconciler.go b/pkg/reconcilers/configset/reconciler.go index ca0965e0..8f88821a 100644 --- a/pkg/reconcilers/configset/reconciler.go +++ b/pkg/reconcilers/configset/reconciler.go @@ -29,7 +29,6 @@ import ( condv1alpha1 "github.com/sdcio/config-server/apis/condition/v1alpha1" "github.com/sdcio/config-server/apis/config" configv1alpha1 "github.com/sdcio/config-server/apis/config/v1alpha1" - invv1alpha1 "github.com/sdcio/config-server/apis/inv/v1alpha1" configv1alpha1apply "github.com/sdcio/config-server/pkg/generated/applyconfiguration/config/v1alpha1" "github.com/sdcio/config-server/pkg/reconcilers" "github.com/sdcio/config-server/pkg/reconcilers/ctrlconfig" @@ -71,7 +70,7 @@ func (r *reconciler) SetupWithManager(ctx context.Context, mgr ctrl.Manager, c i Named(reconcilerName). Owns(&configv1alpha1.Config{}). For(&configv1alpha1.ConfigSet{}). - Watches(&invv1alpha1.Target{}, &eventhandler.TargetForConfigSet{Client: mgr.GetClient(), ControllerName: reconcilerName}). + Watches(&configv1alpha1.Target{}, &eventhandler.TargetForConfigSet{Client: mgr.GetClient(), ControllerName: reconcilerName}). Complete(r) } @@ -161,7 +160,7 @@ func (r *reconciler) unrollDownstreamTargets(ctx context.Context, configSet *con client.MatchingLabelsSelector{Selector: selector}, } - targetList := &invv1alpha1.TargetList{} + targetList := &configv1alpha1.TargetList{} if err := r.client.List(ctx, targetList, opts...); err != nil { return nil, err } @@ -186,9 +185,9 @@ func (r *reconciler) ensureConfigs(ctx context.Context, configSet *configv1alpha existingConfigs := r.getOrphanConfigsFromConfigSet(ctx, configSet) // TODO run in parallel and/or try 1 first to see if the validation works or not - TargetsStatus := make([]configv1alpha1.TargetStatus, len(targets)) + TargetsStatus := make([]configv1alpha1.ConfigSetTargetStatus, len(targets)) for i, target := range targets { - TargetsStatus[i] = configv1alpha1.TargetStatus{Name: target.Name} + TargetsStatus[i] = configv1alpha1.ConfigSetTargetStatus{Name: target.Name} var oldConfig *configv1alpha1.Config newConfig := buildConfig(ctx, configSet, target) @@ -249,7 +248,7 @@ func (r *reconciler) ensureConfigs(ctx context.Context, configSet *configv1alpha } if oldHash == newHash { - TargetsStatus[i] = configv1alpha1.TargetStatus{ + TargetsStatus[i] = configv1alpha1.ConfigSetTargetStatus{ Name: target.Name, Condition: oldConfig.GetCondition(condv1alpha1.ConditionTypeReady), } @@ -402,10 +401,10 @@ func (r *reconciler) determineOverallStatus(_ context.Context, configSet *config return sb.String() } -func targetStatusToApply(targets []configv1alpha1.TargetStatus) []*configv1alpha1apply.TargetStatusApplyConfiguration { - result := make([]*configv1alpha1apply.TargetStatusApplyConfiguration, 0, len(targets)) +func targetStatusToApply(targets []configv1alpha1.ConfigSetTargetStatus) []*configv1alpha1apply.ConfigSetTargetStatusApplyConfiguration { + result := make([]*configv1alpha1apply.ConfigSetTargetStatusApplyConfiguration, 0, len(targets)) for _, t := range targets { - result = append(result, configv1alpha1apply.TargetStatus(). + result = append(result, configv1alpha1apply.ConfigSetTargetStatus(). WithName(t.Name), ) } diff --git a/pkg/reconcilers/eventhandler/watch_schema_for_target.go b/pkg/reconcilers/eventhandler/watch_schema_for_target.go index 0b798c15..ba307ff0 100644 --- a/pkg/reconcilers/eventhandler/watch_schema_for_target.go +++ b/pkg/reconcilers/eventhandler/watch_schema_for_target.go @@ -21,6 +21,7 @@ import ( "fmt" "github.com/henderiw/logger/log" + configv1alpha1 "github.com/sdcio/config-server/apis/config/v1alpha1" invv1alpha1 "github.com/sdcio/config-server/apis/inv/v1alpha1" "k8s.io/apimachinery/pkg/runtime" "k8s.io/apimachinery/pkg/types" @@ -69,7 +70,7 @@ func (r *SchemaForTargetEventHandler) add(ctx context.Context, obj runtime.Objec opts := []client.ListOption{ client.InNamespace(cr.Namespace), } - targets := &invv1alpha1.TargetList{} + targets := &configv1alpha1.TargetList{} if err := r.Client.List(ctx, targets, opts...); err != nil { log.Error("cannot list targets", "error", err) return diff --git a/pkg/reconcilers/eventhandler/watch_secret_for_target.go b/pkg/reconcilers/eventhandler/watch_secret_for_target.go index c923dc9a..7ecf7f39 100644 --- a/pkg/reconcilers/eventhandler/watch_secret_for_target.go +++ b/pkg/reconcilers/eventhandler/watch_secret_for_target.go @@ -21,7 +21,7 @@ import ( "fmt" "github.com/henderiw/logger/log" - invv1alpha1 "github.com/sdcio/config-server/apis/inv/v1alpha1" + configv1alpha1 "github.com/sdcio/config-server/apis/config/v1alpha1" corev1 "k8s.io/api/core/v1" "k8s.io/apimachinery/pkg/runtime" "k8s.io/apimachinery/pkg/types" @@ -70,7 +70,7 @@ func (r *SecretForTargetEventHandler) add(ctx context.Context, obj runtime.Objec opts := []client.ListOption{ client.InNamespace(cr.Namespace), } - targets := &invv1alpha1.TargetList{} + targets := &configv1alpha1.TargetList{} if err := r.Client.List(ctx, targets, opts...); err != nil { log.Error("cannot list targets", "error", err) return diff --git a/pkg/reconcilers/eventhandler/watch_target_for_config.go b/pkg/reconcilers/eventhandler/watch_target_for_config.go index c9dcb1d3..b4c12d0c 100644 --- a/pkg/reconcilers/eventhandler/watch_target_for_config.go +++ b/pkg/reconcilers/eventhandler/watch_target_for_config.go @@ -22,7 +22,6 @@ import ( "github.com/henderiw/logger/log" "github.com/sdcio/config-server/apis/config" configv1alpha1 "github.com/sdcio/config-server/apis/config/v1alpha1" - invv1alpha1 "github.com/sdcio/config-server/apis/inv/v1alpha1" "github.com/sdcio/config-server/pkg/reconcilers/ctrlconfig" "k8s.io/apimachinery/pkg/runtime" "k8s.io/apimachinery/pkg/types" @@ -59,14 +58,14 @@ func (r *TargetForConfigEventHandler) Generic(ctx context.Context, evt event.Gen } func (r *TargetForConfigEventHandler) add(ctx context.Context, obj runtime.Object, queue adder) { - target, ok := obj.(*invv1alpha1.Target) + target, ok := obj.(*configv1alpha1.Target) if !ok { return } ctx = ctrlconfig.InitContext(ctx, r.ControllerName, types.NamespacedName{Namespace: "target-event", Name: target.GetName()}) log := log.FromContext(ctx) - log.Debug("event", "gvk", invv1alpha1.TargetGroupVersionKind.String(), "name", target.GetName()) + log.Debug("event", "gvk", configv1alpha1.TargetGroupVersionKind.String(), "name", target.GetName()) // list all the configs of the particular target that got changed opts := []client.ListOption{ diff --git a/pkg/reconcilers/eventhandler/watch_target_for_configset.go b/pkg/reconcilers/eventhandler/watch_target_for_configset.go index aff505b9..a01f42bc 100644 --- a/pkg/reconcilers/eventhandler/watch_target_for_configset.go +++ b/pkg/reconcilers/eventhandler/watch_target_for_configset.go @@ -21,7 +21,6 @@ import ( "github.com/henderiw/logger/log" configv1alpha1 "github.com/sdcio/config-server/apis/config/v1alpha1" - invv1alpha1 "github.com/sdcio/config-server/apis/inv/v1alpha1" "github.com/sdcio/config-server/pkg/reconcilers/ctrlconfig" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/apimachinery/pkg/labels" @@ -60,14 +59,14 @@ func (r *TargetForConfigSet) Generic(ctx context.Context, evt event.GenericEvent } func (r *TargetForConfigSet) add(ctx context.Context, obj runtime.Object, queue adder) { - target, ok := obj.(*invv1alpha1.Target) + target, ok := obj.(*configv1alpha1.Target) if !ok { return } ctx = ctrlconfig.InitContext(ctx, r.ControllerName, types.NamespacedName{Namespace: "target-event", Name: target.GetName()}) log := log.FromContext(ctx) - log.Debug("event", "gvk", invv1alpha1.TargetGroupVersionKind.String(), "name", target.GetName()) + log.Debug("event", "gvk", configv1alpha1.TargetGroupVersionKind.String(), "name", target.GetName()) // list the configsets and see opts := []client.ListOption{ diff --git a/pkg/reconcilers/eventhandler/watch_target_for_subscription.go b/pkg/reconcilers/eventhandler/watch_target_for_subscription.go index c1a2718e..725d0bd3 100644 --- a/pkg/reconcilers/eventhandler/watch_target_for_subscription.go +++ b/pkg/reconcilers/eventhandler/watch_target_for_subscription.go @@ -20,6 +20,7 @@ import ( "context" "github.com/henderiw/logger/log" + configv1alpha1 "github.com/sdcio/config-server/apis/config/v1alpha1" invv1alpha1 "github.com/sdcio/config-server/apis/inv/v1alpha1" "github.com/sdcio/config-server/pkg/reconcilers/ctrlconfig" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" @@ -59,14 +60,14 @@ func (r *TargetForSubscriptionEventHandler) Generic(ctx context.Context, evt eve } func (r *TargetForSubscriptionEventHandler) add(ctx context.Context, obj runtime.Object, queue adder) { - target, ok := obj.(*invv1alpha1.Target) + target, ok := obj.(*configv1alpha1.Target) if !ok { return } ctx = ctrlconfig.InitContext(ctx, r.ControllerName, types.NamespacedName{Namespace: "target-event", Name: target.GetName()}) log := log.FromContext(ctx) - log.Debug("event", "gvk", invv1alpha1.TargetGroupVersionKind.String(), "name", target.GetName()) + log.Debug("event", "gvk", configv1alpha1.TargetGroupVersionKind.String(), "name", target.GetName()) // list the configsets and see opts := []client.ListOption{ diff --git a/pkg/reconcilers/eventhandler/watch_targetconnprofile_for_target.go b/pkg/reconcilers/eventhandler/watch_targetconnprofile_for_target.go index 7fb8553f..496c178b 100644 --- a/pkg/reconcilers/eventhandler/watch_targetconnprofile_for_target.go +++ b/pkg/reconcilers/eventhandler/watch_targetconnprofile_for_target.go @@ -21,6 +21,7 @@ import ( "fmt" "github.com/henderiw/logger/log" + configv1alpha1 "github.com/sdcio/config-server/apis/config/v1alpha1" invv1alpha1 "github.com/sdcio/config-server/apis/inv/v1alpha1" "k8s.io/apimachinery/pkg/runtime" "k8s.io/apimachinery/pkg/types" @@ -69,7 +70,7 @@ func (r *TargetConnProfileForTargetEventHandler) add(ctx context.Context, obj ru opts := []client.ListOption{ client.InNamespace(cr.Namespace), } - targets := &invv1alpha1.TargetList{} + targets := &configv1alpha1.TargetList{} if err := r.Client.List(ctx, targets, opts...); err != nil { log.Error("cannot list targets", "error", err) return diff --git a/pkg/reconcilers/eventhandler/watch_targetsyncprofile_for_target.go b/pkg/reconcilers/eventhandler/watch_targetsyncprofile_for_target.go index a1aa2f0a..c1e2e00f 100644 --- a/pkg/reconcilers/eventhandler/watch_targetsyncprofile_for_target.go +++ b/pkg/reconcilers/eventhandler/watch_targetsyncprofile_for_target.go @@ -21,6 +21,7 @@ import ( "fmt" "github.com/henderiw/logger/log" + configv1alpha1 "github.com/sdcio/config-server/apis/config/v1alpha1" invv1alpha1 "github.com/sdcio/config-server/apis/inv/v1alpha1" "k8s.io/apimachinery/pkg/runtime" "k8s.io/apimachinery/pkg/types" @@ -69,7 +70,7 @@ func (r *TargetSyncProfileForTargetEventHandler) add(ctx context.Context, obj ru opts := []client.ListOption{ client.InNamespace(cr.Namespace), } - targets := &invv1alpha1.TargetList{} + targets := &configv1alpha1.TargetList{} if err := r.Client.List(ctx, targets, opts...); err != nil { log.Error("cannot list targets", "error", err) return diff --git a/pkg/reconcilers/rollout/transaction.go b/pkg/reconcilers/rollout/transaction.go index c13e8930..73c01cd6 100644 --- a/pkg/reconcilers/rollout/transaction.go +++ b/pkg/reconcilers/rollout/transaction.go @@ -27,6 +27,7 @@ import ( memstore "github.com/henderiw/apiserver-store/pkg/storebackend/memory" "github.com/henderiw/logger/log" "github.com/sdcio/config-server/apis/config" + configv1alpha1 "github.com/sdcio/config-server/apis/config/v1alpha1" invv1alpha1 "github.com/sdcio/config-server/apis/inv/v1alpha1" dsclient "github.com/sdcio/config-server/pkg/sdc/dataserver/client" sdcpb "github.com/sdcio/sdc-protos/sdcpb" @@ -97,7 +98,7 @@ func (r *transactionManager) TransactToAllTargets(ctx context.Context, transacti done := make(chan struct{}) for _, targetKey := range r.targets.UnsortedList() { - t := &invv1alpha1.Target{} + t := &configv1alpha1.Target{} if err := r.client.Get(ctx, targetKey, t); err != nil { // target unavailable -> we continue for now targetStatus := invv1alpha1.RolloutTargetStatus{Name: targetKey.String()} diff --git a/pkg/reconcilers/subscription/reconciler.go b/pkg/reconcilers/subscription/reconciler.go index 908502f7..9fc69b32 100644 --- a/pkg/reconcilers/subscription/reconciler.go +++ b/pkg/reconcilers/subscription/reconciler.go @@ -24,6 +24,7 @@ import ( "github.com/henderiw/logger/log" pkgerrors "github.com/pkg/errors" condv1alpha1 "github.com/sdcio/config-server/apis/condition/v1alpha1" + configv1alpha1 "github.com/sdcio/config-server/apis/config/v1alpha1" invv1alpha1 "github.com/sdcio/config-server/apis/inv/v1alpha1" invv1alpha1apply "github.com/sdcio/config-server/pkg/generated/applyconfiguration/inv/v1alpha1" "github.com/sdcio/config-server/pkg/reconcilers" @@ -68,7 +69,7 @@ func (r *reconciler) SetupWithManager(ctx context.Context, mgr ctrl.Manager, c i return nil, ctrl.NewControllerManagedBy(mgr). Named(reconcilerName). For(&invv1alpha1.Subscription{}). - Watches(&invv1alpha1.Target{}, &eventhandler.TargetForSubscriptionEventHandler{Client: mgr.GetClient(), ControllerName: reconcilerName}). + Watches(&configv1alpha1.Target{}, &eventhandler.TargetForSubscriptionEventHandler{Client: mgr.GetClient(), ControllerName: reconcilerName}). Complete(r) } diff --git a/pkg/reconcilers/target/reconciler.go b/pkg/reconcilers/target/reconciler.go index deac07ce..7c8162e9 100644 --- a/pkg/reconcilers/target/reconciler.go +++ b/pkg/reconcilers/target/reconciler.go @@ -23,7 +23,7 @@ import ( "github.com/henderiw/logger/log" pkgerrors "github.com/pkg/errors" condv1alpha1 "github.com/sdcio/config-server/apis/condition/v1alpha1" - invv1alpha1 "github.com/sdcio/config-server/apis/inv/v1alpha1" + configv1alpha1 "github.com/sdcio/config-server/apis/config/v1alpha1" invv1alpha1apply "github.com/sdcio/config-server/pkg/generated/applyconfiguration/inv/v1alpha1" "github.com/sdcio/config-server/pkg/reconcilers" "github.com/sdcio/config-server/pkg/reconcilers/ctrlconfig" @@ -58,7 +58,7 @@ func (r *reconciler) SetupWithManager(ctx context.Context, mgr ctrl.Manager, c i return nil, ctrl.NewControllerManagedBy(mgr). Named(reconcilerName). - For(&invv1alpha1.Target{}). + For(&configv1alpha1.Target{}). Complete(r) } @@ -73,7 +73,7 @@ func (r *reconciler) Reconcile(ctx context.Context, req ctrl.Request) (ctrl.Resu log := log.FromContext(ctx) log.Info("reconcile") - target := &invv1alpha1.Target{} + target := &configv1alpha1.Target{} if err := r.client.Get(ctx, req.NamespacedName, target); err != nil { // if the resource no longer exists the reconcile loop is done if resource.IgnoreNotFound(err) != nil { @@ -103,12 +103,12 @@ func (r *reconciler) Reconcile(ctx context.Context, req ctrl.Request) (ctrl.Resu return ctrl.Result{}, nil } -func (r *reconciler) updateCondition(ctx context.Context, target *invv1alpha1.Target) (changed bool, newReady bool, err error) { +func (r *reconciler) updateCondition(ctx context.Context, target *configv1alpha1.Target) (changed bool, newReady bool, err error) { log := log.FromContext(ctx) log.Debug("handleSuccess", "key", target.GetNamespacedName(), "status old", target.DeepCopy().Status) oldCond := target.GetCondition(condv1alpha1.ConditionTypeReady) - newCond := invv1alpha1.GetOverallStatus(target) + newCond := configv1alpha1.GetOverallStatus(target) changed = !newCond.Equal(oldCond) newReady = newCond.IsTrue() @@ -122,9 +122,9 @@ func (r *reconciler) updateCondition(ctx context.Context, target *invv1alpha1.Ta // Optional: emit different event types if newReady { - r.recorder.Eventf(target, nil, corev1.EventTypeNormal, invv1alpha1.TargetKind, "ready", "") + r.recorder.Eventf(target, nil, corev1.EventTypeNormal, configv1alpha1.TargetKind, "ready", "") } else { - r.recorder.Eventf(target, nil, corev1.EventTypeWarning, invv1alpha1.TargetKind, "not ready", "") + r.recorder.Eventf(target, nil, corev1.EventTypeWarning, configv1alpha1.TargetKind, "not ready", "") } applyConfig := invv1alpha1apply.Target(target.Name, target.Namespace). diff --git a/pkg/reconcilers/targetconfig/reconciler.go b/pkg/reconcilers/targetconfig/reconciler.go index 487b8bff..9f554353 100644 --- a/pkg/reconcilers/targetconfig/reconciler.go +++ b/pkg/reconcilers/targetconfig/reconciler.go @@ -26,7 +26,6 @@ import ( "github.com/henderiw/logger/log" "github.com/pkg/errors" configv1alpha1 "github.com/sdcio/config-server/apis/config/v1alpha1" - invv1alpha1 "github.com/sdcio/config-server/apis/inv/v1alpha1" "github.com/sdcio/config-server/pkg/reconcilers" "github.com/sdcio/config-server/pkg/reconcilers/ctrlconfig" "github.com/sdcio/config-server/pkg/reconcilers/eventhandler" @@ -79,7 +78,7 @@ func (r *reconciler) SetupWithManager(ctx context.Context, mgr ctrl.Manager, c i return nil, ctrl.NewControllerManagedBy(mgr). Named(reconcilerName). - For(&invv1alpha1.Target{}). + For(&configv1alpha1.Target{}). Watches(&configv1alpha1.Config{}, &eventhandler.ConfigForTargetEventHandler{Client: mgr.GetClient(), ControllerName: reconcilerName}). Complete(r) } @@ -105,7 +104,7 @@ func (r *reconciler) Reconcile(ctx context.Context, req ctrl.Request) (ctrl.Resu targetKey := storebackend.KeyFromNSN(req.NamespacedName) - target := &invv1alpha1.Target{} + target := &configv1alpha1.Target{} if err := r.client.Get(ctx, req.NamespacedName, target); err != nil { // if the resource no longer exists the reconcile loop is done if resource.IgnoreNotFound(err) != nil { @@ -120,7 +119,7 @@ func (r *reconciler) Reconcile(ctx context.Context, req ctrl.Request) (ctrl.Resu if err := r.transactor.SetConfigsTargetConditionForTarget( ctx, targetOrig, - configv1alpha1.TargetFailed("target not available"), + configv1alpha1.TargetForConfigFailed("target not available"), ); err != nil { return ctrl.Result{Requeue: true}, errors.Wrap(r.handleError(ctx, targetOrig, "cannot update config status", err), errUpdateStatus) @@ -145,7 +144,7 @@ func (r *reconciler) Reconcile(ctx context.Context, req ctrl.Request) (ctrl.Resu err := r.transactor.SetConfigsTargetConditionForTarget( ctx, targetOrig, - configv1alpha1.TargetFailed("target not ready"), + configv1alpha1.TargetForConfigFailed("target not ready"), ) return ctrl.Result{RequeueAfter: 5 * time.Second}, errors.Wrap(r.handleError(ctx, targetOrig, @@ -159,7 +158,7 @@ func (r *reconciler) Reconcile(ctx context.Context, req ctrl.Request) (ctrl.Resu err := r.transactor.SetConfigsTargetConditionForTarget( ctx, targetOrig, - configv1alpha1.TargetFailed("target not ready (no dsctx yet)"), + configv1alpha1.TargetForConfigFailed("target not ready (no dsctx yet)"), ) return ctrl.Result{RequeueAfter: 5 * time.Second}, errors.Wrap(r.handleError(ctx, targetOrig, @@ -172,7 +171,7 @@ func (r *reconciler) Reconcile(ctx context.Context, req ctrl.Request) (ctrl.Resu err := r.transactor.SetConfigsTargetConditionForTarget( ctx, targetOrig, - configv1alpha1.TargetFailed("target not ready (no dsctx client)"), + configv1alpha1.TargetForConfigFailed("target not ready (no dsctx client)"), ) return ctrl.Result{RequeueAfter: 5 * time.Second}, errors.Wrap(r.handleError(ctx, targetOrig, @@ -187,20 +186,20 @@ func (r *reconciler) Reconcile(ctx context.Context, req ctrl.Request) (ctrl.Resu err := r.transactor.SetConfigsTargetConditionForTarget( ctx, targetOrig, - configv1alpha1.TargetFailed("target not recovered"), + configv1alpha1.TargetForConfigFailed("target not recovered"), ) log.Info("config transaction -> target not recovered yet") return ctrl.Result{RequeueAfter: 5 * time.Second}, err } - retry, err := r.transactor.Transact(ctx, target, dsctx, configv1alpha1.TargetReady("target ready")) + retry, err := r.transactor.Transact(ctx, target, dsctx, configv1alpha1.TargetForConfigReady("target ready")) if err != nil { log.Warn("config transaction failed", "retry", retry, "err", err) if retry { if err := r.transactor.SetConfigsTargetConditionForTarget( ctx, targetOrig, - configv1alpha1.TargetReady("target ready"), + configv1alpha1.TargetForConfigReady("target ready"), ); err != nil { return ctrl.Result{}, errors.Wrap(r.handleError(ctx, targetOrig, "", err), errUpdateStatus) } @@ -217,7 +216,7 @@ func (r *reconciler) Reconcile(ctx context.Context, req ctrl.Request) (ctrl.Resu if err := r.transactor.SetConfigsTargetConditionForTarget( ctx, targetOrig, - configv1alpha1.TargetReady("target ready"), + configv1alpha1.TargetForConfigReady("target ready"), ); err != nil { return ctrl.Result{}, errors.Wrap(r.handleError(ctx, targetOrig, "", err), errUpdateStatus) } @@ -231,21 +230,21 @@ func (r *reconciler) Reconcile(ctx context.Context, req ctrl.Request) (ctrl.Resu if err := r.transactor.SetConfigsTargetConditionForTarget( ctx, targetOrig, - configv1alpha1.TargetReady("target ready"), + configv1alpha1.TargetForConfigReady("target ready"), ); err != nil { return ctrl.Result{}, errors.Wrap(r.handleError(ctx, targetOrig, "", err), errUpdateStatus) } return ctrl.Result{}, errors.Wrap(r.handleSuccess(ctx, targetOrig), errUpdateStatus) } -func (r *reconciler) handleSuccess(ctx context.Context, target *invv1alpha1.Target) error { +func (r *reconciler) handleSuccess(ctx context.Context, target *configv1alpha1.Target) error { log := log.FromContext(ctx) log.Debug("handleSuccess", "key", target.GetNamespacedName(), "status old", target.DeepCopy().Status) return nil } -func (r *reconciler) handleError(ctx context.Context, target *invv1alpha1.Target, msg string, err error) error { +func (r *reconciler) handleError(ctx context.Context, target *configv1alpha1.Target, msg string, err error) error { log := log.FromContext(ctx) if err != nil { diff --git a/pkg/reconcilers/targetdatastore/reconciler.go b/pkg/reconcilers/targetdatastore/reconciler.go index 1d3ba55a..b4bdf930 100644 --- a/pkg/reconcilers/targetdatastore/reconciler.go +++ b/pkg/reconcilers/targetdatastore/reconciler.go @@ -26,6 +26,7 @@ import ( "github.com/henderiw/logger/log" "github.com/pkg/errors" condv1alpha1 "github.com/sdcio/config-server/apis/condition/v1alpha1" + configv1alpha1 "github.com/sdcio/config-server/apis/config/v1alpha1" invv1alpha1 "github.com/sdcio/config-server/apis/inv/v1alpha1" invv1alpha1apply "github.com/sdcio/config-server/pkg/generated/applyconfiguration/inv/v1alpha1" "github.com/sdcio/config-server/pkg/reconcilers" @@ -80,7 +81,7 @@ func (r *reconciler) SetupWithManager(ctx context.Context, mgr ctrl.Manager, c i return nil, ctrl.NewControllerManagedBy(mgr). Named(reconcilerName). - For(&invv1alpha1.Target{}). + For(&configv1alpha1.Target{}). Watches(&invv1alpha1.TargetConnectionProfile{}, &eventhandler.TargetConnProfileForTargetEventHandler{Client: mgr.GetClient()}). Watches(&invv1alpha1.TargetSyncProfile{}, &eventhandler.TargetSyncProfileForTargetEventHandler{Client: mgr.GetClient()}). Watches(&corev1.Secret{}, &eventhandler.SecretForTargetEventHandler{Client: mgr.GetClient()}). @@ -102,7 +103,7 @@ func (r *reconciler) Reconcile(ctx context.Context, req ctrl.Request) (ctrl.Resu targetKey := storebackend.KeyFromNSN(req.NamespacedName) - target := &invv1alpha1.Target{} + target := &configv1alpha1.Target{} if err := r.client.Get(ctx, req.NamespacedName, target); err != nil { // if the resource no longer exists the reconcile loop is done if resource.IgnoreNotFound(err) != nil { @@ -146,8 +147,8 @@ func (r *reconciler) Reconcile(ctx context.Context, req ctrl.Request) (ctrl.Resu // We dont act as long the target is not discoveredReady (ready state is handled by the discovery controller) // Ready -> NotReady: happens only when the discovery fails => we keep the target as is do not delete the datatore/etc - log.Info("target discovery ready condition", "status", target.Status.GetCondition(invv1alpha1.ConditionTypeDiscoveryReady).Status) - if target.Status.GetCondition(invv1alpha1.ConditionTypeDiscoveryReady).Status != metav1.ConditionTrue { + log.Info("target discovery ready condition", "status", target.Status.GetCondition(configv1alpha1.ConditionTypeTargetDiscoveryReady).Status) + if target.Status.GetCondition(configv1alpha1.ConditionTypeTargetDiscoveryReady).Status != metav1.ConditionTrue { if r.targetMgr != nil { r.targetMgr.ClearDesired(ctx, targetKey) } @@ -208,12 +209,12 @@ func (r *reconciler) Reconcile(ctx context.Context, req ctrl.Request) (ctrl.Resu } } -func (r *reconciler) handleSuccess(ctx context.Context, target *invv1alpha1.Target, usedRefs *invv1alpha1.TargetStatusUsedReferences) error { +func (r *reconciler) handleSuccess(ctx context.Context, target *configv1alpha1.Target, usedRefs *configv1alpha1.TargetStatusUsedReferences) error { log := log.FromContext(ctx) //log.Info("handleSuccess", "key", target.GetNamespacedName(), "status old", target.DeepCopy().Status) // take a snapshot of the current object - newCond := invv1alpha1.DatastoreReady() - oldCond := target.GetCondition(invv1alpha1.ConditionTypeDatastoreReady) + newCond := configv1alpha1.TargetDatastoreReady() + oldCond := target.GetCondition(configv1alpha1.ConditionTypeTargetDatastoreReady) // we don't update the resource if no condition changed if newCond.Equal(oldCond) && @@ -226,7 +227,7 @@ func (r *reconciler) handleSuccess(ctx context.Context, target *invv1alpha1.Targ "usedRefs change", !equality.Semantic.DeepEqual(usedRefs, target.Status.UsedReferences), ) - r.recorder.Eventf(target, nil, corev1.EventTypeNormal, invv1alpha1.TargetKind, "datastore ready", "") + r.recorder.Eventf(target, nil, corev1.EventTypeNormal, configv1alpha1.TargetKind, "datastore ready", "") applyConfig := invv1alpha1apply.Target(target.Name, target.Namespace). WithStatus(invv1alpha1apply.TargetStatus(). @@ -241,17 +242,17 @@ func (r *reconciler) handleSuccess(ctx context.Context, target *invv1alpha1.Targ }) } -func (r *reconciler) handleError(ctx context.Context, target *invv1alpha1.Target, msg string, err error, resetUsedRefs bool) error { +func (r *reconciler) handleError(ctx context.Context, target *configv1alpha1.Target, msg string, err error, resetUsedRefs bool) error { log := log.FromContext(ctx) if err != nil { msg = fmt.Sprintf("%s err %s", msg, err.Error()) } - newCond := invv1alpha1.DatastoreFailed(msg) - oldCond := target.GetCondition(invv1alpha1.ConditionTypeDatastoreReady) + newCond := configv1alpha1.TargetDatastoreFailed(msg) + oldCond := target.GetCondition(configv1alpha1.ConditionTypeTargetDatastoreReady) - var newUsedRefs *invv1alpha1.TargetStatusUsedReferences + var newUsedRefs *configv1alpha1.TargetStatusUsedReferences if !resetUsedRefs { newUsedRefs = target.Status.UsedReferences } @@ -267,7 +268,7 @@ func (r *reconciler) handleError(ctx context.Context, target *invv1alpha1.Target "usedRefs change", !equality.Semantic.DeepEqual(newUsedRefs, target.Status.UsedReferences), ) log.Error(msg, "error", err) - r.recorder.Eventf(target, nil, corev1.EventTypeWarning, invv1alpha1.TargetKind, msg, "") + r.recorder.Eventf(target, nil, corev1.EventTypeWarning, configv1alpha1.TargetKind, msg, "") applyConfig := invv1alpha1apply.Target(target.Name, target.Namespace). WithStatus(invv1alpha1apply.TargetStatus(). @@ -312,7 +313,7 @@ func (r *reconciler) getSecret(ctx context.Context, key types.NamespacedName) (* return secret, nil } -func (r *reconciler) isSchemaReady(ctx context.Context, target *invv1alpha1.Target) (bool, string, error) { +func (r *reconciler) isSchemaReady(ctx context.Context, target *configv1alpha1.Target) (bool, string, error) { //log := log.FromContext(ctx) schemaList := &invv1alpha1.SchemaList{} opts := []client.ListOption{ @@ -337,8 +338,8 @@ func (r *reconciler) isSchemaReady(ctx context.Context, target *invv1alpha1.Targ } -func (r *reconciler) getCreateDataStoreRequest(ctx context.Context, target *invv1alpha1.Target) (*sdcpb.CreateDataStoreRequest, *invv1alpha1.TargetStatusUsedReferences, error) { - usedReferences := &invv1alpha1.TargetStatusUsedReferences{} +func (r *reconciler) getCreateDataStoreRequest(ctx context.Context, target *configv1alpha1.Target) (*sdcpb.CreateDataStoreRequest, *configv1alpha1.TargetStatusUsedReferences, error) { + usedReferences := &configv1alpha1.TargetStatusUsedReferences{} syncProfile, err := r.getSyncProfile(ctx, types.NamespacedName{Namespace: target.GetNamespace(), Name: *target.Spec.SyncProfile}) if err != nil { @@ -435,7 +436,7 @@ func (r *reconciler) getCreateDataStoreRequest(ctx context.Context, target *invv return req, usedReferences, nil } -func usedRefsToApply(refs *invv1alpha1.TargetStatusUsedReferences) *invv1alpha1apply.TargetStatusUsedReferencesApplyConfiguration { +func usedRefsToApply(refs *configv1alpha1.TargetStatusUsedReferences) *invv1alpha1apply.TargetStatusUsedReferencesApplyConfiguration { if refs == nil { return nil } diff --git a/pkg/reconcilers/targetrecovery/reconciler.go b/pkg/reconcilers/targetrecovery/reconciler.go index 6a720d19..16d1dbee 100644 --- a/pkg/reconcilers/targetrecovery/reconciler.go +++ b/pkg/reconcilers/targetrecovery/reconciler.go @@ -26,7 +26,6 @@ import ( "github.com/henderiw/logger/log" "github.com/pkg/errors" configv1alpha1 "github.com/sdcio/config-server/apis/config/v1alpha1" - invv1alpha1 "github.com/sdcio/config-server/apis/inv/v1alpha1" invv1alpha1apply "github.com/sdcio/config-server/pkg/generated/applyconfiguration/inv/v1alpha1" "github.com/sdcio/config-server/pkg/reconcilers" "github.com/sdcio/config-server/pkg/reconcilers/ctrlconfig" @@ -82,7 +81,7 @@ func (r *reconciler) SetupWithManager(ctx context.Context, mgr ctrl.Manager, c i return nil, ctrl.NewControllerManagedBy(mgr). Named(reconcilerName). - For(&invv1alpha1.Target{}). + For(&configv1alpha1.Target{}). Complete(r) } @@ -107,7 +106,7 @@ func (r *reconciler) Reconcile(ctx context.Context, req ctrl.Request) (ctrl.Resu targetKey := storebackend.KeyFromNSN(req.NamespacedName) - target := &invv1alpha1.Target{} + target := &configv1alpha1.Target{} if err := r.client.Get(ctx, req.NamespacedName, target); err != nil { // if the resource no longer exists the reconcile loop is done if resource.IgnoreNotFound(err) != nil { @@ -157,14 +156,14 @@ func (r *reconciler) Reconcile(ctx context.Context, req ctrl.Request) (ctrl.Resu return ctrl.Result{}, errors.Wrap(r.handleSuccess(ctx, targetOrig, msg), errUpdateStatus) } -func (r *reconciler) handleSuccess(ctx context.Context, target *invv1alpha1.Target, msg *string) error { +func (r *reconciler) handleSuccess(ctx context.Context, target *configv1alpha1.Target, msg *string) error { log := log.FromContext(ctx) newMsg := "" if msg != nil { newMsg = *msg } - newCond := invv1alpha1.ConfigRecoveryReady(newMsg) - oldCond := target.GetCondition(invv1alpha1.ConditionTypeConfigRecoveryReady) + newCond := configv1alpha1.TargetConfigRecoveryReady(newMsg) + oldCond := target.GetCondition(configv1alpha1.ConditionTypeTargetConfigRecoveryReady) if newCond.Equal(oldCond) { log.Info("handleSuccess -> no change") @@ -172,7 +171,7 @@ func (r *reconciler) handleSuccess(ctx context.Context, target *invv1alpha1.Targ } log.Info("handleSuccess -> change", "condition change", true) - r.recorder.Eventf(target, nil, corev1.EventTypeNormal, invv1alpha1.TargetKind, "config recovery ready", "") + r.recorder.Eventf(target, nil, corev1.EventTypeNormal, configv1alpha1.TargetKind, "config recovery ready", "") applyConfig := invv1alpha1apply.Target(target.Name, target.Namespace). WithStatus(invv1alpha1apply.TargetStatus(). @@ -182,19 +181,19 @@ func (r *reconciler) handleSuccess(ctx context.Context, target *invv1alpha1.Targ return r.client.Status().Apply(ctx, applyConfig, &client.SubResourceApplyOptions{ ApplyOptions: client.ApplyOptions{ FieldManager: reconcilerName, - Force: ptr.To(true), + Force: ptr.To(true), }, }) } -func (r *reconciler) handleError(ctx context.Context, target *invv1alpha1.Target, msg string, err error) error { +func (r *reconciler) handleError(ctx context.Context, target *configv1alpha1.Target, msg string, err error) error { log := log.FromContext(ctx) if err != nil { msg = fmt.Sprintf("%s err %s", msg, err.Error()) } - newCond := invv1alpha1.ConfigRecoveryFailed(msg) - oldCond := target.GetCondition(invv1alpha1.ConditionTypeConfigRecoveryReady) + newCond := configv1alpha1.TargetConfigRecoveryFailed(msg) + oldCond := target.GetCondition(configv1alpha1.ConditionTypeTargetConfigRecoveryReady) if newCond.Equal(oldCond) { log.Info("handleError -> no change") @@ -203,7 +202,7 @@ func (r *reconciler) handleError(ctx context.Context, target *invv1alpha1.Target log.Warn(msg, "error", err) log.Info("handleError -> change", "condition change", true) - r.recorder.Eventf(target, nil, corev1.EventTypeWarning, invv1alpha1.TargetKind, msg, "") + r.recorder.Eventf(target, nil, corev1.EventTypeWarning, configv1alpha1.TargetKind, msg, "") applyConfig := invv1alpha1apply.Target(target.Name, target.Namespace). WithStatus(invv1alpha1apply.TargetStatus(). @@ -213,7 +212,7 @@ func (r *reconciler) handleError(ctx context.Context, target *invv1alpha1.Target return r.client.Status().Apply(ctx, applyConfig, &client.SubResourceApplyOptions{ ApplyOptions: client.ApplyOptions{ FieldManager: reconcilerName, - Force: ptr.To(true), + Force: ptr.To(true), }, }) } diff --git a/pkg/registry/configblame/strategy_resource.go b/pkg/registry/configblame/strategy_resource.go index 0f01bb42..9366fcf6 100644 --- a/pkg/registry/configblame/strategy_resource.go +++ b/pkg/registry/configblame/strategy_resource.go @@ -27,7 +27,7 @@ import ( watchermanager "github.com/henderiw/apiserver-store/pkg/watcher-manager" "github.com/henderiw/logger/log" "github.com/sdcio/config-server/apis/config" - invv1alpha1 "github.com/sdcio/config-server/apis/inv/v1alpha1" + configv1alpha1 "github.com/sdcio/config-server/apis/config/v1alpha1" "github.com/sdcio/config-server/pkg/registry/options" dsclient "github.com/sdcio/config-server/pkg/sdc/dataserver/client" sdcpb "github.com/sdcio/sdc-protos/sdcpb" @@ -149,7 +149,7 @@ func (r *strategy) Delete(ctx context.Context, key types.NamespacedName, obj run return obj, nil } -func (r *strategy) getConfigBlame(ctx context.Context, target *invv1alpha1.Target, key types.NamespacedName) (*config.ConfigBlame, error) { +func (r *strategy) getConfigBlame(ctx context.Context, target *configv1alpha1.Target, key types.NamespacedName) (*config.ConfigBlame, error) { if !target.IsReady() { return nil, apierrors.NewNotFound(r.gr, key.Name) } @@ -226,7 +226,7 @@ func (r *strategy) getConfigBlame(ctx context.Context, target *invv1alpha1.Targe } func (r *strategy) Get(ctx context.Context, key types.NamespacedName) (runtime.Object, error) { - target := &invv1alpha1.Target{} + target := &configv1alpha1.Target{} if err := r.client.Get(ctx, key, target); err != nil { return nil, apierrors.NewNotFound(r.gr, key.Name) } @@ -247,7 +247,7 @@ func (r *strategy) List(ctx context.Context, opts *metainternalversion.ListOptio return nil, err } - targets := &invv1alpha1.TargetList{} + targets := &configv1alpha1.TargetList{} if err := r.client.List(ctx, targets, options.ListOptsFromInternal(filter, opts)...); err != nil { return nil, err } diff --git a/pkg/registry/generic/store.go b/pkg/registry/generic/store.go index 8aa83c94..90686b5e 100644 --- a/pkg/registry/generic/store.go +++ b/pkg/registry/generic/store.go @@ -136,8 +136,8 @@ func NewStatusREST( statusStore := *registryStore statusStore.CreateStrategy = nil statusStore.DeleteStrategy = nil - statusStore.CategoryList = nil - statusStore.ShortNameList = nil + statusStore.CategoryList = nil + statusStore.ShortNameList = nil statusStrategy := NewStatusStrategy(obj, scheme, registryStore.Storage, watcherManager, opts) statusStore.UpdateStrategy = statusStrategy statusStore.ResetFieldsStrategy = statusStrategy diff --git a/pkg/registry/generic/strategy_resource.go b/pkg/registry/generic/strategy_resource.go index a10b5185..e726f78f 100644 --- a/pkg/registry/generic/strategy_resource.go +++ b/pkg/registry/generic/strategy_resource.go @@ -35,9 +35,9 @@ import ( "k8s.io/apimachinery/pkg/types" "k8s.io/apimachinery/pkg/util/validation/field" "k8s.io/apimachinery/pkg/watch" + genericapirequest "k8s.io/apiserver/pkg/endpoints/request" "k8s.io/apiserver/pkg/storage/names" "sigs.k8s.io/structured-merge-diff/v6/fieldpath" - genericapirequest "k8s.io/apiserver/pkg/endpoints/request" ) // NewStrategy creates and returns a strategy instance diff --git a/pkg/registry/options/fieldselector.go b/pkg/registry/options/fieldselector.go index 1f7cb2e2..d27810ec 100644 --- a/pkg/registry/options/fieldselector.go +++ b/pkg/registry/options/fieldselector.go @@ -21,10 +21,10 @@ import ( "fmt" apierrors "k8s.io/apimachinery/pkg/api/errors" + metainternalversion "k8s.io/apimachinery/pkg/apis/meta/internalversion" "k8s.io/apimachinery/pkg/fields" "k8s.io/apimachinery/pkg/selection" genericapirequest "k8s.io/apiserver/pkg/endpoints/request" - metainternalversion "k8s.io/apimachinery/pkg/apis/meta/internalversion" "sigs.k8s.io/controller-runtime/pkg/client" ) @@ -83,27 +83,26 @@ func ParseFieldSelector(ctx context.Context, fieldSelector fields.Selector) (*Fi return filter, nil } - func ListOptsFromInternal(filter *Filter, opts *metainternalversion.ListOptions) []client.ListOption { - listOpts := []client.ListOption{} - - if filter != nil && filter.Namespace != "" { - listOpts = append(listOpts, client.InNamespace(filter.Namespace)) - } - - if opts != nil { - if opts.LabelSelector != nil { - listOpts = append(listOpts, client.MatchingLabelsSelector{ - Selector: opts.LabelSelector, - }) - } - if opts.Limit > 0 { - listOpts = append(listOpts, client.Limit(opts.Limit)) - } - if opts.Continue != "" { - listOpts = append(listOpts, client.Continue(opts.Continue)) - } - } - - return listOpts -} \ No newline at end of file + listOpts := []client.ListOption{} + + if filter != nil && filter.Namespace != "" { + listOpts = append(listOpts, client.InNamespace(filter.Namespace)) + } + + if opts != nil { + if opts.LabelSelector != nil { + listOpts = append(listOpts, client.MatchingLabelsSelector{ + Selector: opts.LabelSelector, + }) + } + if opts.Limit > 0 { + listOpts = append(listOpts, client.Limit(opts.Limit)) + } + if opts.Continue != "" { + listOpts = append(listOpts, client.Continue(opts.Continue)) + } + } + + return listOpts +} diff --git a/pkg/registry/runningconfig/strategy_resource.go b/pkg/registry/runningconfig/strategy_resource.go index 83218d46..f9282590 100644 --- a/pkg/registry/runningconfig/strategy_resource.go +++ b/pkg/registry/runningconfig/strategy_resource.go @@ -27,7 +27,7 @@ import ( watchermanager "github.com/henderiw/apiserver-store/pkg/watcher-manager" "github.com/henderiw/logger/log" "github.com/sdcio/config-server/apis/config" - invv1alpha1 "github.com/sdcio/config-server/apis/inv/v1alpha1" + configv1alpha1 "github.com/sdcio/config-server/apis/config/v1alpha1" "github.com/sdcio/config-server/pkg/registry/options" dsclient "github.com/sdcio/config-server/pkg/sdc/dataserver/client" sdcpb "github.com/sdcio/sdc-protos/sdcpb" @@ -148,7 +148,7 @@ func (r *strategy) Delete(ctx context.Context, key types.NamespacedName, obj run return obj, nil } -func (r *strategy) getRunningConfig(ctx context.Context, target *invv1alpha1.Target, key types.NamespacedName) (*config.RunningConfig, error) { +func (r *strategy) getRunningConfig(ctx context.Context, target *configv1alpha1.Target, key types.NamespacedName) (*config.RunningConfig, error) { if !target.IsReady() { return nil, apierrors.NewNotFound(r.gr, key.Name) } @@ -200,7 +200,7 @@ func (r *strategy) getRunningConfig(ctx context.Context, target *invv1alpha1.Tar } func (r *strategy) Get(ctx context.Context, key types.NamespacedName) (runtime.Object, error) { - target := &invv1alpha1.Target{} + target := &configv1alpha1.Target{} if err := r.client.Get(ctx, key, target); err != nil { return nil, apierrors.NewNotFound(r.gr, key.Name) } @@ -221,7 +221,7 @@ func (r *strategy) List(ctx context.Context, opts *metainternalversion.ListOptio return nil, err } - targets := &invv1alpha1.TargetList{} + targets := &configv1alpha1.TargetList{} if err := r.client.List(ctx, targets, options.ListOptsFromInternal(filter, opts)...); err != nil { return nil, err } diff --git a/pkg/sdc/target/manager/dryrun.go b/pkg/sdc/target/manager/dryrun.go index b14da70c..07097185 100644 --- a/pkg/sdc/target/manager/dryrun.go +++ b/pkg/sdc/target/manager/dryrun.go @@ -22,7 +22,7 @@ import ( "github.com/sdcio/config-server/apis/condition" "github.com/sdcio/config-server/apis/config" - invv1alpha1 "github.com/sdcio/config-server/apis/inv/v1alpha1" + configv1alpha1 "github.com/sdcio/config-server/apis/config/v1alpha1" dsclient "github.com/sdcio/config-server/pkg/sdc/dataserver/client" sdcpb "github.com/sdcio/sdc-protos/sdcpb" "k8s.io/apimachinery/pkg/runtime" @@ -37,7 +37,7 @@ func RunDryRunTransaction( ctx context.Context, key types.NamespacedName, c *config.Config, - target *invv1alpha1.Target, + target *configv1alpha1.Target, intents []*sdcpb.TransactionIntent, dryrun bool, ) (runtime.Object, error) { diff --git a/pkg/sdc/target/manager/manager.go b/pkg/sdc/target/manager/manager.go index f51377f0..8633ac2c 100644 --- a/pkg/sdc/target/manager/manager.go +++ b/pkg/sdc/target/manager/manager.go @@ -71,7 +71,7 @@ func (m *TargetManager) ApplyDesired( ctx context.Context, key storebackend.Key, req *sdcpb.CreateDataStoreRequest, - refs *invv1alpha1.TargetStatusUsedReferences, + refs *configv1alpha1.TargetStatusUsedReferences, hash string, ) { rt := m.GetOrCreate(key) @@ -167,7 +167,7 @@ func (m *TargetManager) GetRuntimeForTarget(_ context.Context, key storebackend. return m.targets[key] } -func ComputeCreateDSHash(req *sdcpb.CreateDataStoreRequest, refs *invv1alpha1.TargetStatusUsedReferences) string { +func ComputeCreateDSHash(req *sdcpb.CreateDataStoreRequest, refs *configv1alpha1.TargetStatusUsedReferences) string { h := sha256.New() // hash the request deterministically @@ -264,7 +264,7 @@ func (r *TargetManager) getDownstreamTargets(ctx context.Context, sub *invv1alph client.MatchingLabelsSelector{Selector: selector}, } - targetList := &invv1alpha1.TargetList{} + targetList := &configv1alpha1.TargetList{} if err := r.k8s.List(ctx, targetList, opts...); err != nil { return nil, err } diff --git a/pkg/sdc/target/manager/runtime.go b/pkg/sdc/target/manager/runtime.go index 89c4edc9..f6c99d12 100644 --- a/pkg/sdc/target/manager/runtime.go +++ b/pkg/sdc/target/manager/runtime.go @@ -59,7 +59,7 @@ type TargetRuntime struct { // desired (from reconciler) desiredMu sync.RWMutex desired *sdcpb.CreateDataStoreRequest - desiredRefs *invv1alpha1.TargetStatusUsedReferences + desiredRefs *configv1alpha1.TargetStatusUsedReferences desiredHash string // running state @@ -104,7 +104,7 @@ func NewTargetRuntime(key storebackend.Key, ds *dsmanager.DSConnManager, k8s cli } } -func (r *TargetRuntime) SetDesired(req *sdcpb.CreateDataStoreRequest, refs *invv1alpha1.TargetStatusUsedReferences, hash string) { +func (r *TargetRuntime) SetDesired(req *sdcpb.CreateDataStoreRequest, refs *configv1alpha1.TargetStatusUsedReferences, hash string) { r.desiredMu.Lock() r.desired = req r.desiredRefs = refs @@ -592,7 +592,7 @@ func (r *TargetRuntime) pushConnIfChanged(ctx context.Context, connected bool, m r.lastConn = connected r.statusMu.Unlock() - target := &invv1alpha1.Target{} + target := &configv1alpha1.Target{} if err := r.client.Get(ctx, r.key.NamespacedName, target); err != nil { log.Error("target fetch failed", "error", err) return @@ -600,12 +600,12 @@ func (r *TargetRuntime) pushConnIfChanged(ctx context.Context, connected bool, m var newCond condv1alpha1.Condition if connected { - newCond = invv1alpha1.TargetConnectionReady() + newCond = configv1alpha1.TargetConnectionReady() } else { - newCond = invv1alpha1.TargetConnectionFailed(msg) + newCond = configv1alpha1.TargetConnectionFailed(msg) } - oldCond := target.GetCondition(invv1alpha1.ConditionTypeTargetConnectionReady) + oldCond := target.GetCondition(configv1alpha1.ConditionTypeTargetConnectionReady) if newCond.Equal(oldCond) { log.Info("pushConnIfChanged -> no change", "connected", connected, diff --git a/pkg/sdc/target/manager/transactor.go b/pkg/sdc/target/manager/transactor.go index c72513a9..240b1cd3 100644 --- a/pkg/sdc/target/manager/transactor.go +++ b/pkg/sdc/target/manager/transactor.go @@ -30,7 +30,6 @@ import ( condv1alpha1 "github.com/sdcio/config-server/apis/condition/v1alpha1" "github.com/sdcio/config-server/apis/config" configv1alpha1 "github.com/sdcio/config-server/apis/config/v1alpha1" - invv1alpha1 "github.com/sdcio/config-server/apis/inv/v1alpha1" configv1alpha1apply "github.com/sdcio/config-server/pkg/generated/applyconfiguration/config/v1alpha1" "github.com/sdcio/config-server/pkg/reconcilers/resource" sdcpb "github.com/sdcio/sdc-protos/sdcpb" @@ -62,7 +61,7 @@ func NewTransactor(client client.Client, fieldManager string) *Transactor { } } -func (r *Transactor) RecoverConfigs(ctx context.Context, target *invv1alpha1.Target, dsctx *DatastoreHandle) (*string, error) { +func (r *Transactor) RecoverConfigs(ctx context.Context, target *configv1alpha1.Target, dsctx *DatastoreHandle) (*string, error) { log := log.FromContext(ctx) log.Debug("RecoverConfigs") configList, err := r.ListConfigsPerTarget(ctx, target) @@ -177,8 +176,8 @@ func (r *Transactor) TransactionSet( } func (r *Transactor) Transact( - ctx context.Context, - target *invv1alpha1.Target, + ctx context.Context, + target *configv1alpha1.Target, dsctx *DatastoreHandle, targetCond condv1alpha1.Condition, ) (bool, error) { @@ -415,7 +414,6 @@ func (r *Transactor) updateConfigWithSuccess( cfg.SetOverallStatus() overallCond := cfg.GetCondition(condv1alpha1.ConditionTypeReady) - // check against OLD state if configCond.Equal(oldConfigCond) && targetCond.Equal(oldTargetCond) && @@ -439,7 +437,7 @@ func (r *Transactor) updateConfigWithSuccess( }) } -func (r *Transactor) ListConfigsPerTarget(ctx context.Context, target *invv1alpha1.Target) (*config.ConfigList, error) { +func (r *Transactor) ListConfigsPerTarget(ctx context.Context, target *configv1alpha1.Target) (*config.ConfigList, error) { ctx = genericapirequest.WithNamespace(ctx, target.GetNamespace()) opts := []client.ListOption{ @@ -731,7 +729,7 @@ func analyzeIntentResponse(err error, rsp *sdcpb.TransactionSetResponse) Transac func (r *Transactor) SetConfigsTargetConditionForTarget( ctx context.Context, - target *invv1alpha1.Target, + target *configv1alpha1.Target, targetCond condv1alpha1.Condition, ) error { //log := log.FromContext(ctx) From 16981b4fafc23ff82e82857cc94191b11149ca50 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Sun, 1 Mar 2026 10:11:21 +0100 Subject: [PATCH 064/135] added target storage --- cmd/api-server/main.go | 3 +++ 1 file changed, 3 insertions(+) diff --git a/cmd/api-server/main.go b/cmd/api-server/main.go index 6b003e12..30255b30 100644 --- a/cmd/api-server/main.go +++ b/cmd/api-server/main.go @@ -139,6 +139,7 @@ func main() { configregistryOptions.DryRunUpdateFn = configHandler.DryRunUpdateFn configregistryOptions.DryRunDeleteFn = configHandler.DryRunDeleteFn + targetStorageProvider := genericregistry.NewStorageProvider(ctx, sdcconfig.BuildEmptyTarget(), registryOptions) configStorageProvider := genericregistry.NewStorageProvider(ctx, sdcconfig.BuildEmptyConfig(), &configregistryOptions) sensitiveconfigStorageProvider := genericregistry.NewStorageProvider(ctx, sdcconfig.BuildEmptySensitiveConfig(), &configregistryOptions) @@ -160,6 +161,8 @@ func main() { if err := builder.APIServer. WithServerName("config-server"). WithOpenAPIDefinitions("Config", "v1alpha1", openapi.GetOpenAPIDefinitions). + WithResourceAndHandler(&sdcconfig.Target{}, targetStorageProvider). + WithResourceAndHandler(&configv1alpha1.Target{}, targetStorageProvider). WithResourceAndHandler(&sdcconfig.Config{}, configStorageProvider). WithResourceAndHandler(&configv1alpha1.Config{}, configStorageProvider). WithResourceAndHandler(&sdcconfig.SensitiveConfig{}, sensitiveconfigStorageProvider). From 50ad628ff9b1a3d9995fd6db007b6193a110abe7 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Sun, 1 Mar 2026 10:49:12 +0100 Subject: [PATCH 065/135] removed inventory from apiserver --- cmd/api-server/main.go | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/cmd/api-server/main.go b/cmd/api-server/main.go index 30255b30..afb226f3 100644 --- a/cmd/api-server/main.go +++ b/cmd/api-server/main.go @@ -31,7 +31,7 @@ import ( sdcconfig "github.com/sdcio/config-server/apis/config" "github.com/sdcio/config-server/apis/config/handlers" configv1alpha1 "github.com/sdcio/config-server/apis/config/v1alpha1" - invv1alpha1 "github.com/sdcio/config-server/apis/inv/v1alpha1" + //invv1alpha1 "github.com/sdcio/config-server/apis/inv/v1alpha1" "github.com/sdcio/config-server/pkg/generated/openapi" _ "github.com/sdcio/config-server/pkg/reconcilers/all" configblameregistry "github.com/sdcio/config-server/pkg/registry/configblame" @@ -76,7 +76,7 @@ func main() { for _, api := range (runtime.SchemeBuilder{ clientgoscheme.AddToScheme, configv1alpha1.AddToScheme, - invv1alpha1.AddToScheme, + //invv1alpha1.AddToScheme, }) { if err := api(runScheme); err != nil { log.Error("cannot add scheme", "err", err) @@ -141,7 +141,6 @@ func main() { targetStorageProvider := genericregistry.NewStorageProvider(ctx, sdcconfig.BuildEmptyTarget(), registryOptions) configStorageProvider := genericregistry.NewStorageProvider(ctx, sdcconfig.BuildEmptyConfig(), &configregistryOptions) - sensitiveconfigStorageProvider := genericregistry.NewStorageProvider(ctx, sdcconfig.BuildEmptySensitiveConfig(), &configregistryOptions) configSetStorageProvider := genericregistry.NewStorageProvider(ctx, sdcconfig.BuildEmptyConfigSet(), registryOptions) From d720a07308db6ac119619f7b8c88ceb8e93fa66e Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Sun, 1 Mar 2026 11:41:05 +0100 Subject: [PATCH 066/135] add bookmark to watch event --- cmd/api-server/main.go | 3 +++ pkg/registry/configblame/watcher.go | 12 ++++++++++++ pkg/registry/generic/watcher.go | 12 ++++++++++++ pkg/registry/runningconfig/watcher.go | 12 ++++++++++++ 4 files changed, 39 insertions(+) diff --git a/cmd/api-server/main.go b/cmd/api-server/main.go index afb226f3..d3b40349 100644 --- a/cmd/api-server/main.go +++ b/cmd/api-server/main.go @@ -49,6 +49,7 @@ import ( "sigs.k8s.io/controller-runtime/pkg/log/zap" "sigs.k8s.io/controller-runtime/pkg/metrics/filters" metricsserver "sigs.k8s.io/controller-runtime/pkg/metrics/server" + "k8s.io/client-go/features" ) var ( @@ -59,6 +60,8 @@ func main() { logs.InitLogs() defer logs.FlushLogs() + features.SetFeatureGateUsage(features.WatchListClient, false) + l := log.NewLogger(&log.HandlerOptions{Name: "sdc-api-server-logger", AddSource: false}) slog.SetDefault(l) ctx := log.IntoContext(context.Background(), l) diff --git a/pkg/registry/configblame/watcher.go b/pkg/registry/configblame/watcher.go index a85f451e..94e91e71 100644 --- a/pkg/registry/configblame/watcher.go +++ b/pkg/registry/configblame/watcher.go @@ -173,6 +173,18 @@ func (r *watcher) innerListAndWatch(ctx context.Context, l rest.RESTListStrategy r.sendWatchEvent(ctx, ev) } + // Send bookmark event to signal initial list is complete + bookmarkObj := r.obj.DeepCopyObject() + accessor, _ := meta.Accessor(bookmarkObj) + // Set resourceVersion so the client knows where it is + if accessor.GetResourceVersion() == "" { + accessor.SetResourceVersion("0") + } + r.sendWatchEvent(ctx, watch.Event{ + Type: watch.Bookmark, + Object: bookmarkObj, + }) + log.Debug("moving into streaming mode") r.eventCallback = func(eventType watch.EventType, obj runtime.Object) bool { accessor, _ := meta.Accessor(obj) diff --git a/pkg/registry/generic/watcher.go b/pkg/registry/generic/watcher.go index 4c616174..04fd6ff0 100644 --- a/pkg/registry/generic/watcher.go +++ b/pkg/registry/generic/watcher.go @@ -173,6 +173,18 @@ func (r *watcher) innerListAndWatch(ctx context.Context, l rest.RESTListStrategy r.sendWatchEvent(ctx, ev) } + // Send bookmark event to signal initial list is complete + bookmarkObj := r.obj.DeepCopyObject() + accessor, _ := meta.Accessor(bookmarkObj) + // Set resourceVersion so the client knows where it is + if accessor.GetResourceVersion() == "" { + accessor.SetResourceVersion("0") + } + r.sendWatchEvent(ctx, watch.Event{ + Type: watch.Bookmark, + Object: bookmarkObj, + }) + log.Debug("moving into streaming mode") r.eventCallback = func(eventType watch.EventType, obj runtime.Object) bool { accessor, _ := meta.Accessor(obj) diff --git a/pkg/registry/runningconfig/watcher.go b/pkg/registry/runningconfig/watcher.go index 74118985..09b4b99a 100644 --- a/pkg/registry/runningconfig/watcher.go +++ b/pkg/registry/runningconfig/watcher.go @@ -173,6 +173,18 @@ func (r *watcher) innerListAndWatch(ctx context.Context, l rest.RESTListStrategy r.sendWatchEvent(ctx, ev) } + // Send bookmark event to signal initial list is complete + bookmarkObj := r.obj.DeepCopyObject() + accessor, _ := meta.Accessor(bookmarkObj) + // Set resourceVersion so the client knows where it is + if accessor.GetResourceVersion() == "" { + accessor.SetResourceVersion("0") + } + r.sendWatchEvent(ctx, watch.Event{ + Type: watch.Bookmark, + Object: bookmarkObj, + }) + log.Debug("moving into streaming mode") r.eventCallback = func(eventType watch.EventType, obj runtime.Object) bool { accessor, _ := meta.Accessor(obj) From 5ca3013c041294f68dfcc1d815c79780445e70bf Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Sun, 1 Mar 2026 11:42:58 +0100 Subject: [PATCH 067/135] add bookmark to watch event --- cmd/api-server/main.go | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/cmd/api-server/main.go b/cmd/api-server/main.go index d3b40349..3f95cff9 100644 --- a/cmd/api-server/main.go +++ b/cmd/api-server/main.go @@ -49,7 +49,6 @@ import ( "sigs.k8s.io/controller-runtime/pkg/log/zap" "sigs.k8s.io/controller-runtime/pkg/metrics/filters" metricsserver "sigs.k8s.io/controller-runtime/pkg/metrics/server" - "k8s.io/client-go/features" ) var ( @@ -59,8 +58,7 @@ var ( func main() { logs.InitLogs() defer logs.FlushLogs() - - features.SetFeatureGateUsage(features.WatchListClient, false) + l := log.NewLogger(&log.HandlerOptions{Name: "sdc-api-server-logger", AddSource: false}) slog.SetDefault(l) From 50853896f098ace7b44b85d348cc0ea23de4d3d4 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Sun, 1 Mar 2026 11:49:37 +0100 Subject: [PATCH 068/135] add bookmark to watch event --- pkg/registry/configblame/watcher.go | 2 +- pkg/registry/generic/watcher.go | 2 +- pkg/registry/runningconfig/watcher.go | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/pkg/registry/configblame/watcher.go b/pkg/registry/configblame/watcher.go index 94e91e71..f37119f4 100644 --- a/pkg/registry/configblame/watcher.go +++ b/pkg/registry/configblame/watcher.go @@ -174,7 +174,7 @@ func (r *watcher) innerListAndWatch(ctx context.Context, l rest.RESTListStrategy } // Send bookmark event to signal initial list is complete - bookmarkObj := r.obj.DeepCopyObject() + bookmarkObj := r.obj.New() accessor, _ := meta.Accessor(bookmarkObj) // Set resourceVersion so the client knows where it is if accessor.GetResourceVersion() == "" { diff --git a/pkg/registry/generic/watcher.go b/pkg/registry/generic/watcher.go index 04fd6ff0..c8d55b1e 100644 --- a/pkg/registry/generic/watcher.go +++ b/pkg/registry/generic/watcher.go @@ -174,7 +174,7 @@ func (r *watcher) innerListAndWatch(ctx context.Context, l rest.RESTListStrategy } // Send bookmark event to signal initial list is complete - bookmarkObj := r.obj.DeepCopyObject() + bookmarkObj := r.obj.New() accessor, _ := meta.Accessor(bookmarkObj) // Set resourceVersion so the client knows where it is if accessor.GetResourceVersion() == "" { diff --git a/pkg/registry/runningconfig/watcher.go b/pkg/registry/runningconfig/watcher.go index 09b4b99a..961fc0db 100644 --- a/pkg/registry/runningconfig/watcher.go +++ b/pkg/registry/runningconfig/watcher.go @@ -174,7 +174,7 @@ func (r *watcher) innerListAndWatch(ctx context.Context, l rest.RESTListStrategy } // Send bookmark event to signal initial list is complete - bookmarkObj := r.obj.DeepCopyObject() + bookmarkObj := r.obj.New() accessor, _ := meta.Accessor(bookmarkObj) // Set resourceVersion so the client knows where it is if accessor.GetResourceVersion() == "" { From a3dcdd1030c48d20284a0de1bb4f7257f4158b8c Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Sun, 1 Mar 2026 11:55:50 +0100 Subject: [PATCH 069/135] add bookmark to watch event --- pkg/registry/configblame/strategy_resource.go | 1 + pkg/registry/runningconfig/strategy_resource.go | 1 + 2 files changed, 2 insertions(+) diff --git a/pkg/registry/configblame/strategy_resource.go b/pkg/registry/configblame/strategy_resource.go index 9366fcf6..f99b3fd0 100644 --- a/pkg/registry/configblame/strategy_resource.go +++ b/pkg/registry/configblame/strategy_resource.go @@ -274,6 +274,7 @@ func (r *strategy) Watch(ctx context.Context, options *metainternalversion.ListO cancel: cancel, resultChan: make(chan watch.Event), watcherManager: r.watcherManager, + obj: r.obj, } go w.listAndWatch(ctx, r, options) diff --git a/pkg/registry/runningconfig/strategy_resource.go b/pkg/registry/runningconfig/strategy_resource.go index f9282590..70154da9 100644 --- a/pkg/registry/runningconfig/strategy_resource.go +++ b/pkg/registry/runningconfig/strategy_resource.go @@ -248,6 +248,7 @@ func (r *strategy) Watch(ctx context.Context, options *metainternalversion.ListO cancel: cancel, resultChan: make(chan watch.Event), watcherManager: r.watcherManager, + obj: r.obj, } go w.listAndWatch(ctx, r, options) From d1a6ebc1caf661d2f81e4ac9576475d3768a5b30 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Sun, 1 Mar 2026 12:22:30 +0100 Subject: [PATCH 070/135] updated ssa for target --- artifacts/deployment-apiserver.yaml | 2 + artifacts/deployment-controller.yaml | 2 + artifacts/statefulset-data-server.yaml | 2 + pkg/discovery/discoveryrule/target.go | 10 +- .../applyconfiguration/inv/v1alpha1/target.go | 244 ------------------ .../inv/v1alpha1/targetspec.go | 85 ------ .../inv/v1alpha1/targetstatus.go | 67 ----- .../v1alpha1/targetstatususedreferences.go | 65 ----- pkg/reconcilers/target/reconciler.go | 6 +- pkg/reconcilers/targetdatastore/reconciler.go | 14 +- pkg/reconcilers/targetrecovery/reconciler.go | 10 +- pkg/sdc/target/manager/runtime.go | 6 +- 12 files changed, 29 insertions(+), 484 deletions(-) delete mode 100644 pkg/generated/applyconfiguration/inv/v1alpha1/target.go delete mode 100644 pkg/generated/applyconfiguration/inv/v1alpha1/targetspec.go delete mode 100644 pkg/generated/applyconfiguration/inv/v1alpha1/targetstatus.go delete mode 100644 pkg/generated/applyconfiguration/inv/v1alpha1/targetstatususedreferences.go diff --git a/artifacts/deployment-apiserver.yaml b/artifacts/deployment-apiserver.yaml index 678ef130..52e664e3 100644 --- a/artifacts/deployment-apiserver.yaml +++ b/artifacts/deployment-apiserver.yaml @@ -61,6 +61,8 @@ spec: fieldPath: status.hostIP - name: METRIC_PORT value: "8443" + - name: KUBE_FEATURE_WatchListClient + value: "false" volumeMounts: - name: api-server-certs mountPath: /apiserver.local.config/certificates diff --git a/artifacts/deployment-controller.yaml b/artifacts/deployment-controller.yaml index 07ca39fa..24120601 100644 --- a/artifacts/deployment-controller.yaml +++ b/artifacts/deployment-controller.yaml @@ -76,6 +76,8 @@ spec: value: "true" - name: ENABLE_ROLLOUT value: "true" + - name: KUBE_FEATURE_WatchListClient + value: "false" volumeMounts: #- name: schema-store # mountPath: /schemas diff --git a/artifacts/statefulset-data-server.yaml b/artifacts/statefulset-data-server.yaml index 103d72de..7859106d 100644 --- a/artifacts/statefulset-data-server.yaml +++ b/artifacts/statefulset-data-server.yaml @@ -78,6 +78,8 @@ spec: # value: "true" #- name: ENABLE_ROLLOUT # value: "true" + - name: KUBE_FEATURE_WatchListClient + value: "false" volumeMounts: - name: schema-store mountPath: /schemas diff --git a/pkg/discovery/discoveryrule/target.go b/pkg/discovery/discoveryrule/target.go index 7d38e0f5..874de007 100644 --- a/pkg/discovery/discoveryrule/target.go +++ b/pkg/discovery/discoveryrule/target.go @@ -27,7 +27,7 @@ import ( //condv1alpha1 "github.com/sdcio/config-server/apis/condition/v1alpha1" configv1alpha1 "github.com/sdcio/config-server/apis/config/v1alpha1" invv1alpha1 "github.com/sdcio/config-server/apis/inv/v1alpha1" - invv1alpha1apply "github.com/sdcio/config-server/pkg/generated/applyconfiguration/inv/v1alpha1" + configv1alpha1apply "github.com/sdcio/config-server/pkg/generated/applyconfiguration/config/v1alpha1" "github.com/sdcio/config-server/pkg/reconcilers/resource" "k8s.io/apimachinery/pkg/api/equality" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" @@ -162,14 +162,14 @@ func (r *dr) applyTarget(ctx context.Context, newTarget *configv1alpha1.Target) "discovery info change", !equality.Semantic.DeepEqual(newTarget.Status.DiscoveryInfo, target.Status.DiscoveryInfo), ) - statusApply := invv1alpha1apply.TargetStatus(). + statusApply := configv1alpha1apply.TargetStatus(). WithConditions(newCond) if newTarget.Status.DiscoveryInfo != nil { statusApply = statusApply.WithDiscoveryInfo(discoveryInfoToApply(newTarget.Status.DiscoveryInfo)) } - applyConfig := invv1alpha1apply.Target(newTarget.Name, newTarget.Namespace). + applyConfig := configv1alpha1apply.Target(newTarget.Name, newTarget.Namespace). WithStatus(statusApply) if err := r.client.Status().Apply(ctx, applyConfig, &client.SubResourceApplyOptions{ @@ -183,11 +183,11 @@ func (r *dr) applyTarget(ctx context.Context, newTarget *configv1alpha1.Target) return nil } -func discoveryInfoToApply(di *configv1alpha1.DiscoveryInfo) *invv1alpha1apply.DiscoveryInfoApplyConfiguration { +func discoveryInfoToApply(di *configv1alpha1.DiscoveryInfo) *configv1alpha1apply.DiscoveryInfoApplyConfiguration { if di == nil { return nil } - a := invv1alpha1apply.DiscoveryInfo() + a := configv1alpha1apply.DiscoveryInfo() if di.Protocol != "" { a.WithProtocol(di.Protocol) } diff --git a/pkg/generated/applyconfiguration/inv/v1alpha1/target.go b/pkg/generated/applyconfiguration/inv/v1alpha1/target.go deleted file mode 100644 index fe4c9b0a..00000000 --- a/pkg/generated/applyconfiguration/inv/v1alpha1/target.go +++ /dev/null @@ -1,244 +0,0 @@ -/* -Copyright 2024 Nokia. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ -// Code generated by applyconfiguration-gen. DO NOT EDIT. - -package v1alpha1 - -import ( - metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" - types "k8s.io/apimachinery/pkg/types" - v1 "k8s.io/client-go/applyconfigurations/meta/v1" -) - -// TargetApplyConfiguration represents a declarative configuration of the Target type for use -// with apply. -// -// Target is the Schema for the Target API -type TargetApplyConfiguration struct { - v1.TypeMetaApplyConfiguration `json:",inline"` - *v1.ObjectMetaApplyConfiguration `json:"metadata,omitempty"` - Spec *TargetSpecApplyConfiguration `json:"spec,omitempty"` - Status *TargetStatusApplyConfiguration `json:"status,omitempty"` -} - -// Target constructs a declarative configuration of the Target type for use with -// apply. -func Target(name, namespace string) *TargetApplyConfiguration { - b := &TargetApplyConfiguration{} - b.WithName(name) - b.WithNamespace(namespace) - b.WithKind("Target") - b.WithAPIVersion("inv.sdcio.dev/v1alpha1") - return b -} - -func (b TargetApplyConfiguration) IsApplyConfiguration() {} - -// WithKind sets the Kind field in the declarative configuration to the given value -// and returns the receiver, so that objects can be built by chaining "With" function invocations. -// If called multiple times, the Kind field is set to the value of the last call. -func (b *TargetApplyConfiguration) WithKind(value string) *TargetApplyConfiguration { - b.TypeMetaApplyConfiguration.Kind = &value - return b -} - -// WithAPIVersion sets the APIVersion field in the declarative configuration to the given value -// and returns the receiver, so that objects can be built by chaining "With" function invocations. -// If called multiple times, the APIVersion field is set to the value of the last call. -func (b *TargetApplyConfiguration) WithAPIVersion(value string) *TargetApplyConfiguration { - b.TypeMetaApplyConfiguration.APIVersion = &value - return b -} - -// WithName sets the Name field in the declarative configuration to the given value -// and returns the receiver, so that objects can be built by chaining "With" function invocations. -// If called multiple times, the Name field is set to the value of the last call. -func (b *TargetApplyConfiguration) WithName(value string) *TargetApplyConfiguration { - b.ensureObjectMetaApplyConfigurationExists() - b.ObjectMetaApplyConfiguration.Name = &value - return b -} - -// WithGenerateName sets the GenerateName field in the declarative configuration to the given value -// and returns the receiver, so that objects can be built by chaining "With" function invocations. -// If called multiple times, the GenerateName field is set to the value of the last call. -func (b *TargetApplyConfiguration) WithGenerateName(value string) *TargetApplyConfiguration { - b.ensureObjectMetaApplyConfigurationExists() - b.ObjectMetaApplyConfiguration.GenerateName = &value - return b -} - -// WithNamespace sets the Namespace field in the declarative configuration to the given value -// and returns the receiver, so that objects can be built by chaining "With" function invocations. -// If called multiple times, the Namespace field is set to the value of the last call. -func (b *TargetApplyConfiguration) WithNamespace(value string) *TargetApplyConfiguration { - b.ensureObjectMetaApplyConfigurationExists() - b.ObjectMetaApplyConfiguration.Namespace = &value - return b -} - -// WithUID sets the UID field in the declarative configuration to the given value -// and returns the receiver, so that objects can be built by chaining "With" function invocations. -// If called multiple times, the UID field is set to the value of the last call. -func (b *TargetApplyConfiguration) WithUID(value types.UID) *TargetApplyConfiguration { - b.ensureObjectMetaApplyConfigurationExists() - b.ObjectMetaApplyConfiguration.UID = &value - return b -} - -// WithResourceVersion sets the ResourceVersion field in the declarative configuration to the given value -// and returns the receiver, so that objects can be built by chaining "With" function invocations. -// If called multiple times, the ResourceVersion field is set to the value of the last call. -func (b *TargetApplyConfiguration) WithResourceVersion(value string) *TargetApplyConfiguration { - b.ensureObjectMetaApplyConfigurationExists() - b.ObjectMetaApplyConfiguration.ResourceVersion = &value - return b -} - -// WithGeneration sets the Generation field in the declarative configuration to the given value -// and returns the receiver, so that objects can be built by chaining "With" function invocations. -// If called multiple times, the Generation field is set to the value of the last call. -func (b *TargetApplyConfiguration) WithGeneration(value int64) *TargetApplyConfiguration { - b.ensureObjectMetaApplyConfigurationExists() - b.ObjectMetaApplyConfiguration.Generation = &value - return b -} - -// WithCreationTimestamp sets the CreationTimestamp field in the declarative configuration to the given value -// and returns the receiver, so that objects can be built by chaining "With" function invocations. -// If called multiple times, the CreationTimestamp field is set to the value of the last call. -func (b *TargetApplyConfiguration) WithCreationTimestamp(value metav1.Time) *TargetApplyConfiguration { - b.ensureObjectMetaApplyConfigurationExists() - b.ObjectMetaApplyConfiguration.CreationTimestamp = &value - return b -} - -// WithDeletionTimestamp sets the DeletionTimestamp field in the declarative configuration to the given value -// and returns the receiver, so that objects can be built by chaining "With" function invocations. -// If called multiple times, the DeletionTimestamp field is set to the value of the last call. -func (b *TargetApplyConfiguration) WithDeletionTimestamp(value metav1.Time) *TargetApplyConfiguration { - b.ensureObjectMetaApplyConfigurationExists() - b.ObjectMetaApplyConfiguration.DeletionTimestamp = &value - return b -} - -// WithDeletionGracePeriodSeconds sets the DeletionGracePeriodSeconds field in the declarative configuration to the given value -// and returns the receiver, so that objects can be built by chaining "With" function invocations. -// If called multiple times, the DeletionGracePeriodSeconds field is set to the value of the last call. -func (b *TargetApplyConfiguration) WithDeletionGracePeriodSeconds(value int64) *TargetApplyConfiguration { - b.ensureObjectMetaApplyConfigurationExists() - b.ObjectMetaApplyConfiguration.DeletionGracePeriodSeconds = &value - return b -} - -// WithLabels puts the entries into the Labels field in the declarative configuration -// and returns the receiver, so that objects can be build by chaining "With" function invocations. -// If called multiple times, the entries provided by each call will be put on the Labels field, -// overwriting an existing map entries in Labels field with the same key. -func (b *TargetApplyConfiguration) WithLabels(entries map[string]string) *TargetApplyConfiguration { - b.ensureObjectMetaApplyConfigurationExists() - if b.ObjectMetaApplyConfiguration.Labels == nil && len(entries) > 0 { - b.ObjectMetaApplyConfiguration.Labels = make(map[string]string, len(entries)) - } - for k, v := range entries { - b.ObjectMetaApplyConfiguration.Labels[k] = v - } - return b -} - -// WithAnnotations puts the entries into the Annotations field in the declarative configuration -// and returns the receiver, so that objects can be build by chaining "With" function invocations. -// If called multiple times, the entries provided by each call will be put on the Annotations field, -// overwriting an existing map entries in Annotations field with the same key. -func (b *TargetApplyConfiguration) WithAnnotations(entries map[string]string) *TargetApplyConfiguration { - b.ensureObjectMetaApplyConfigurationExists() - if b.ObjectMetaApplyConfiguration.Annotations == nil && len(entries) > 0 { - b.ObjectMetaApplyConfiguration.Annotations = make(map[string]string, len(entries)) - } - for k, v := range entries { - b.ObjectMetaApplyConfiguration.Annotations[k] = v - } - return b -} - -// WithOwnerReferences adds the given value to the OwnerReferences field in the declarative configuration -// and returns the receiver, so that objects can be build by chaining "With" function invocations. -// If called multiple times, values provided by each call will be appended to the OwnerReferences field. -func (b *TargetApplyConfiguration) WithOwnerReferences(values ...*v1.OwnerReferenceApplyConfiguration) *TargetApplyConfiguration { - b.ensureObjectMetaApplyConfigurationExists() - for i := range values { - if values[i] == nil { - panic("nil value passed to WithOwnerReferences") - } - b.ObjectMetaApplyConfiguration.OwnerReferences = append(b.ObjectMetaApplyConfiguration.OwnerReferences, *values[i]) - } - return b -} - -// WithFinalizers adds the given value to the Finalizers field in the declarative configuration -// and returns the receiver, so that objects can be build by chaining "With" function invocations. -// If called multiple times, values provided by each call will be appended to the Finalizers field. -func (b *TargetApplyConfiguration) WithFinalizers(values ...string) *TargetApplyConfiguration { - b.ensureObjectMetaApplyConfigurationExists() - for i := range values { - b.ObjectMetaApplyConfiguration.Finalizers = append(b.ObjectMetaApplyConfiguration.Finalizers, values[i]) - } - return b -} - -func (b *TargetApplyConfiguration) ensureObjectMetaApplyConfigurationExists() { - if b.ObjectMetaApplyConfiguration == nil { - b.ObjectMetaApplyConfiguration = &v1.ObjectMetaApplyConfiguration{} - } -} - -// WithSpec sets the Spec field in the declarative configuration to the given value -// and returns the receiver, so that objects can be built by chaining "With" function invocations. -// If called multiple times, the Spec field is set to the value of the last call. -func (b *TargetApplyConfiguration) WithSpec(value *TargetSpecApplyConfiguration) *TargetApplyConfiguration { - b.Spec = value - return b -} - -// WithStatus sets the Status field in the declarative configuration to the given value -// and returns the receiver, so that objects can be built by chaining "With" function invocations. -// If called multiple times, the Status field is set to the value of the last call. -func (b *TargetApplyConfiguration) WithStatus(value *TargetStatusApplyConfiguration) *TargetApplyConfiguration { - b.Status = value - return b -} - -// GetKind retrieves the value of the Kind field in the declarative configuration. -func (b *TargetApplyConfiguration) GetKind() *string { - return b.TypeMetaApplyConfiguration.Kind -} - -// GetAPIVersion retrieves the value of the APIVersion field in the declarative configuration. -func (b *TargetApplyConfiguration) GetAPIVersion() *string { - return b.TypeMetaApplyConfiguration.APIVersion -} - -// GetName retrieves the value of the Name field in the declarative configuration. -func (b *TargetApplyConfiguration) GetName() *string { - b.ensureObjectMetaApplyConfigurationExists() - return b.ObjectMetaApplyConfiguration.Name -} - -// GetNamespace retrieves the value of the Namespace field in the declarative configuration. -func (b *TargetApplyConfiguration) GetNamespace() *string { - b.ensureObjectMetaApplyConfigurationExists() - return b.ObjectMetaApplyConfiguration.Namespace -} diff --git a/pkg/generated/applyconfiguration/inv/v1alpha1/targetspec.go b/pkg/generated/applyconfiguration/inv/v1alpha1/targetspec.go deleted file mode 100644 index f5d68aa7..00000000 --- a/pkg/generated/applyconfiguration/inv/v1alpha1/targetspec.go +++ /dev/null @@ -1,85 +0,0 @@ -/* -Copyright 2024 Nokia. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ -// Code generated by applyconfiguration-gen. DO NOT EDIT. - -package v1alpha1 - -// TargetSpecApplyConfiguration represents a declarative configuration of the TargetSpec type for use -// with apply. -// -// TargetSpec defines the desired state of Target -type TargetSpecApplyConfiguration struct { - // Provider specifies the provider using this target. - Provider *string `json:"provider,omitempty"` - // Address defines the address to connect to the target - Address *string `json:"address,omitempty"` - // TargetProfile defines the Credentials/TLSSecret and sync/connectivity profile to connect to the target - TargetProfileApplyConfiguration `json:",inline"` -} - -// TargetSpecApplyConfiguration constructs a declarative configuration of the TargetSpec type for use with -// apply. -func TargetSpec() *TargetSpecApplyConfiguration { - return &TargetSpecApplyConfiguration{} -} - -// WithProvider sets the Provider field in the declarative configuration to the given value -// and returns the receiver, so that objects can be built by chaining "With" function invocations. -// If called multiple times, the Provider field is set to the value of the last call. -func (b *TargetSpecApplyConfiguration) WithProvider(value string) *TargetSpecApplyConfiguration { - b.Provider = &value - return b -} - -// WithAddress sets the Address field in the declarative configuration to the given value -// and returns the receiver, so that objects can be built by chaining "With" function invocations. -// If called multiple times, the Address field is set to the value of the last call. -func (b *TargetSpecApplyConfiguration) WithAddress(value string) *TargetSpecApplyConfiguration { - b.Address = &value - return b -} - -// WithCredentials sets the Credentials field in the declarative configuration to the given value -// and returns the receiver, so that objects can be built by chaining "With" function invocations. -// If called multiple times, the Credentials field is set to the value of the last call. -func (b *TargetSpecApplyConfiguration) WithCredentials(value string) *TargetSpecApplyConfiguration { - b.TargetProfileApplyConfiguration.Credentials = &value - return b -} - -// WithTLSSecret sets the TLSSecret field in the declarative configuration to the given value -// and returns the receiver, so that objects can be built by chaining "With" function invocations. -// If called multiple times, the TLSSecret field is set to the value of the last call. -func (b *TargetSpecApplyConfiguration) WithTLSSecret(value string) *TargetSpecApplyConfiguration { - b.TargetProfileApplyConfiguration.TLSSecret = &value - return b -} - -// WithConnectionProfile sets the ConnectionProfile field in the declarative configuration to the given value -// and returns the receiver, so that objects can be built by chaining "With" function invocations. -// If called multiple times, the ConnectionProfile field is set to the value of the last call. -func (b *TargetSpecApplyConfiguration) WithConnectionProfile(value string) *TargetSpecApplyConfiguration { - b.TargetProfileApplyConfiguration.ConnectionProfile = &value - return b -} - -// WithSyncProfile sets the SyncProfile field in the declarative configuration to the given value -// and returns the receiver, so that objects can be built by chaining "With" function invocations. -// If called multiple times, the SyncProfile field is set to the value of the last call. -func (b *TargetSpecApplyConfiguration) WithSyncProfile(value string) *TargetSpecApplyConfiguration { - b.TargetProfileApplyConfiguration.SyncProfile = &value - return b -} diff --git a/pkg/generated/applyconfiguration/inv/v1alpha1/targetstatus.go b/pkg/generated/applyconfiguration/inv/v1alpha1/targetstatus.go deleted file mode 100644 index 686f61df..00000000 --- a/pkg/generated/applyconfiguration/inv/v1alpha1/targetstatus.go +++ /dev/null @@ -1,67 +0,0 @@ -/* -Copyright 2024 Nokia. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ -// Code generated by applyconfiguration-gen. DO NOT EDIT. - -package v1alpha1 - -import ( - conditionv1alpha1 "github.com/sdcio/config-server/apis/condition/v1alpha1" -) - -// TargetStatusApplyConfiguration represents a declarative configuration of the TargetStatus type for use -// with apply. -// -// TargetStatus defines the observed state of Target -type TargetStatusApplyConfiguration struct { - // ConditionedStatus provides the status of the Target using conditions - conditionv1alpha1.ConditionedStatus `json:",inline"` - // Discovery info defines the information retrieved during discovery - DiscoveryInfo *DiscoveryInfoApplyConfiguration `json:"discoveryInfo,omitempty"` - // UsedReferences track the resource used to reconcile the cr - UsedReferences *TargetStatusUsedReferencesApplyConfiguration `json:"usedReferences,omitempty"` -} - -// TargetStatusApplyConfiguration constructs a declarative configuration of the TargetStatus type for use with -// apply. -func TargetStatus() *TargetStatusApplyConfiguration { - return &TargetStatusApplyConfiguration{} -} - -// WithConditions adds the given value to the Conditions field in the declarative configuration -// and returns the receiver, so that objects can be build by chaining "With" function invocations. -// If called multiple times, values provided by each call will be appended to the Conditions field. -func (b *TargetStatusApplyConfiguration) WithConditions(values ...conditionv1alpha1.Condition) *TargetStatusApplyConfiguration { - for i := range values { - b.ConditionedStatus.Conditions = append(b.ConditionedStatus.Conditions, values[i]) - } - return b -} - -// WithDiscoveryInfo sets the DiscoveryInfo field in the declarative configuration to the given value -// and returns the receiver, so that objects can be built by chaining "With" function invocations. -// If called multiple times, the DiscoveryInfo field is set to the value of the last call. -func (b *TargetStatusApplyConfiguration) WithDiscoveryInfo(value *DiscoveryInfoApplyConfiguration) *TargetStatusApplyConfiguration { - b.DiscoveryInfo = value - return b -} - -// WithUsedReferences sets the UsedReferences field in the declarative configuration to the given value -// and returns the receiver, so that objects can be built by chaining "With" function invocations. -// If called multiple times, the UsedReferences field is set to the value of the last call. -func (b *TargetStatusApplyConfiguration) WithUsedReferences(value *TargetStatusUsedReferencesApplyConfiguration) *TargetStatusApplyConfiguration { - b.UsedReferences = value - return b -} diff --git a/pkg/generated/applyconfiguration/inv/v1alpha1/targetstatususedreferences.go b/pkg/generated/applyconfiguration/inv/v1alpha1/targetstatususedreferences.go deleted file mode 100644 index 958a4625..00000000 --- a/pkg/generated/applyconfiguration/inv/v1alpha1/targetstatususedreferences.go +++ /dev/null @@ -1,65 +0,0 @@ -/* -Copyright 2024 Nokia. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ -// Code generated by applyconfiguration-gen. DO NOT EDIT. - -package v1alpha1 - -// TargetStatusUsedReferencesApplyConfiguration represents a declarative configuration of the TargetStatusUsedReferences type for use -// with apply. -type TargetStatusUsedReferencesApplyConfiguration struct { - SecretResourceVersion *string `json:"secretResourceVersion,omitempty"` - TLSSecretResourceVersion *string `json:"tlsSecretResourceVersion,omitempty"` - ConnectionProfileResourceVersion *string `json:"connectionProfileResourceVersion,omitempty"` - SyncProfileResourceVersion *string `json:"syncProfileResourceVersion,omitempty"` -} - -// TargetStatusUsedReferencesApplyConfiguration constructs a declarative configuration of the TargetStatusUsedReferences type for use with -// apply. -func TargetStatusUsedReferences() *TargetStatusUsedReferencesApplyConfiguration { - return &TargetStatusUsedReferencesApplyConfiguration{} -} - -// WithSecretResourceVersion sets the SecretResourceVersion field in the declarative configuration to the given value -// and returns the receiver, so that objects can be built by chaining "With" function invocations. -// If called multiple times, the SecretResourceVersion field is set to the value of the last call. -func (b *TargetStatusUsedReferencesApplyConfiguration) WithSecretResourceVersion(value string) *TargetStatusUsedReferencesApplyConfiguration { - b.SecretResourceVersion = &value - return b -} - -// WithTLSSecretResourceVersion sets the TLSSecretResourceVersion field in the declarative configuration to the given value -// and returns the receiver, so that objects can be built by chaining "With" function invocations. -// If called multiple times, the TLSSecretResourceVersion field is set to the value of the last call. -func (b *TargetStatusUsedReferencesApplyConfiguration) WithTLSSecretResourceVersion(value string) *TargetStatusUsedReferencesApplyConfiguration { - b.TLSSecretResourceVersion = &value - return b -} - -// WithConnectionProfileResourceVersion sets the ConnectionProfileResourceVersion field in the declarative configuration to the given value -// and returns the receiver, so that objects can be built by chaining "With" function invocations. -// If called multiple times, the ConnectionProfileResourceVersion field is set to the value of the last call. -func (b *TargetStatusUsedReferencesApplyConfiguration) WithConnectionProfileResourceVersion(value string) *TargetStatusUsedReferencesApplyConfiguration { - b.ConnectionProfileResourceVersion = &value - return b -} - -// WithSyncProfileResourceVersion sets the SyncProfileResourceVersion field in the declarative configuration to the given value -// and returns the receiver, so that objects can be built by chaining "With" function invocations. -// If called multiple times, the SyncProfileResourceVersion field is set to the value of the last call. -func (b *TargetStatusUsedReferencesApplyConfiguration) WithSyncProfileResourceVersion(value string) *TargetStatusUsedReferencesApplyConfiguration { - b.SyncProfileResourceVersion = &value - return b -} diff --git a/pkg/reconcilers/target/reconciler.go b/pkg/reconcilers/target/reconciler.go index 7c8162e9..07759a2d 100644 --- a/pkg/reconcilers/target/reconciler.go +++ b/pkg/reconcilers/target/reconciler.go @@ -24,7 +24,7 @@ import ( pkgerrors "github.com/pkg/errors" condv1alpha1 "github.com/sdcio/config-server/apis/condition/v1alpha1" configv1alpha1 "github.com/sdcio/config-server/apis/config/v1alpha1" - invv1alpha1apply "github.com/sdcio/config-server/pkg/generated/applyconfiguration/inv/v1alpha1" + configv1alpha1apply "github.com/sdcio/config-server/pkg/generated/applyconfiguration/config/v1alpha1" "github.com/sdcio/config-server/pkg/reconcilers" "github.com/sdcio/config-server/pkg/reconcilers/ctrlconfig" "github.com/sdcio/config-server/pkg/reconcilers/resource" @@ -127,8 +127,8 @@ func (r *reconciler) updateCondition(ctx context.Context, target *configv1alpha1 r.recorder.Eventf(target, nil, corev1.EventTypeWarning, configv1alpha1.TargetKind, "not ready", "") } - applyConfig := invv1alpha1apply.Target(target.Name, target.Namespace). - WithStatus(invv1alpha1apply.TargetStatus(). + applyConfig := configv1alpha1apply.Target(target.Name, target.Namespace). + WithStatus(configv1alpha1apply.TargetStatus(). WithConditions(newCond), ) diff --git a/pkg/reconcilers/targetdatastore/reconciler.go b/pkg/reconcilers/targetdatastore/reconciler.go index b4bdf930..4c362ed6 100644 --- a/pkg/reconcilers/targetdatastore/reconciler.go +++ b/pkg/reconcilers/targetdatastore/reconciler.go @@ -28,7 +28,7 @@ import ( condv1alpha1 "github.com/sdcio/config-server/apis/condition/v1alpha1" configv1alpha1 "github.com/sdcio/config-server/apis/config/v1alpha1" invv1alpha1 "github.com/sdcio/config-server/apis/inv/v1alpha1" - invv1alpha1apply "github.com/sdcio/config-server/pkg/generated/applyconfiguration/inv/v1alpha1" + configv1alpha1apply "github.com/sdcio/config-server/pkg/generated/applyconfiguration/config/v1alpha1" "github.com/sdcio/config-server/pkg/reconcilers" "github.com/sdcio/config-server/pkg/reconcilers/ctrlconfig" "github.com/sdcio/config-server/pkg/reconcilers/eventhandler" @@ -229,8 +229,8 @@ func (r *reconciler) handleSuccess(ctx context.Context, target *configv1alpha1.T r.recorder.Eventf(target, nil, corev1.EventTypeNormal, configv1alpha1.TargetKind, "datastore ready", "") - applyConfig := invv1alpha1apply.Target(target.Name, target.Namespace). - WithStatus(invv1alpha1apply.TargetStatus(). + applyConfig := configv1alpha1apply.Target(target.Name, target.Namespace). + WithStatus(configv1alpha1apply.TargetStatus(). WithConditions(newCond). WithUsedReferences(usedRefsToApply(usedRefs)), ) @@ -270,8 +270,8 @@ func (r *reconciler) handleError(ctx context.Context, target *configv1alpha1.Tar log.Error(msg, "error", err) r.recorder.Eventf(target, nil, corev1.EventTypeWarning, configv1alpha1.TargetKind, msg, "") - applyConfig := invv1alpha1apply.Target(target.Name, target.Namespace). - WithStatus(invv1alpha1apply.TargetStatus(). + applyConfig := configv1alpha1apply.Target(target.Name, target.Namespace). + WithStatus(configv1alpha1apply.TargetStatus(). WithConditions(newCond). WithUsedReferences(usedRefsToApply(newUsedRefs)), ) @@ -436,11 +436,11 @@ func (r *reconciler) getCreateDataStoreRequest(ctx context.Context, target *conf return req, usedReferences, nil } -func usedRefsToApply(refs *configv1alpha1.TargetStatusUsedReferences) *invv1alpha1apply.TargetStatusUsedReferencesApplyConfiguration { +func usedRefsToApply(refs *configv1alpha1.TargetStatusUsedReferences) *configv1alpha1apply.TargetStatusUsedReferencesApplyConfiguration { if refs == nil { return nil } - a := invv1alpha1apply.TargetStatusUsedReferences() + a := configv1alpha1apply.TargetStatusUsedReferences() if refs.SecretResourceVersion != "" { a.WithSecretResourceVersion(refs.SecretResourceVersion) } diff --git a/pkg/reconcilers/targetrecovery/reconciler.go b/pkg/reconcilers/targetrecovery/reconciler.go index 16d1dbee..171bff23 100644 --- a/pkg/reconcilers/targetrecovery/reconciler.go +++ b/pkg/reconcilers/targetrecovery/reconciler.go @@ -26,7 +26,7 @@ import ( "github.com/henderiw/logger/log" "github.com/pkg/errors" configv1alpha1 "github.com/sdcio/config-server/apis/config/v1alpha1" - invv1alpha1apply "github.com/sdcio/config-server/pkg/generated/applyconfiguration/inv/v1alpha1" + configv1alpha1apply "github.com/sdcio/config-server/pkg/generated/applyconfiguration/config/v1alpha1" "github.com/sdcio/config-server/pkg/reconcilers" "github.com/sdcio/config-server/pkg/reconcilers/ctrlconfig" "github.com/sdcio/config-server/pkg/reconcilers/resource" @@ -173,8 +173,8 @@ func (r *reconciler) handleSuccess(ctx context.Context, target *configv1alpha1.T log.Info("handleSuccess -> change", "condition change", true) r.recorder.Eventf(target, nil, corev1.EventTypeNormal, configv1alpha1.TargetKind, "config recovery ready", "") - applyConfig := invv1alpha1apply.Target(target.Name, target.Namespace). - WithStatus(invv1alpha1apply.TargetStatus(). + applyConfig := configv1alpha1apply.Target(target.Name, target.Namespace). + WithStatus(configv1alpha1apply.TargetStatus(). WithConditions(newCond), ) @@ -204,8 +204,8 @@ func (r *reconciler) handleError(ctx context.Context, target *configv1alpha1.Tar log.Info("handleError -> change", "condition change", true) r.recorder.Eventf(target, nil, corev1.EventTypeWarning, configv1alpha1.TargetKind, msg, "") - applyConfig := invv1alpha1apply.Target(target.Name, target.Namespace). - WithStatus(invv1alpha1apply.TargetStatus(). + applyConfig := configv1alpha1apply.Target(target.Name, target.Namespace). + WithStatus(configv1alpha1apply.TargetStatus(). WithConditions(newCond), ) diff --git a/pkg/sdc/target/manager/runtime.go b/pkg/sdc/target/manager/runtime.go index f6c99d12..d59dfbff 100644 --- a/pkg/sdc/target/manager/runtime.go +++ b/pkg/sdc/target/manager/runtime.go @@ -28,7 +28,7 @@ import ( condv1alpha1 "github.com/sdcio/config-server/apis/condition/v1alpha1" configv1alpha1 "github.com/sdcio/config-server/apis/config/v1alpha1" invv1alpha1 "github.com/sdcio/config-server/apis/inv/v1alpha1" - invv1alpha1apply "github.com/sdcio/config-server/pkg/generated/applyconfiguration/inv/v1alpha1" + configv1alpha1apply "github.com/sdcio/config-server/pkg/generated/applyconfiguration/config/v1alpha1" dsclient "github.com/sdcio/config-server/pkg/sdc/dataserver/client" dsmanager "github.com/sdcio/config-server/pkg/sdc/dataserver/manager" sdcpb "github.com/sdcio/sdc-protos/sdcpb" @@ -615,8 +615,8 @@ func (r *TargetRuntime) pushConnIfChanged(ctx context.Context, connected bool, m return } - applyConfig := invv1alpha1apply.Target(target.Name, target.Namespace). - WithStatus(invv1alpha1apply.TargetStatus(). + applyConfig := configv1alpha1apply.Target(target.Name, target.Namespace). + WithStatus(configv1alpha1apply.TargetStatus(). WithConditions(newCond), ) From 74b513fcdda8e37794ee888911cb9c3831a9e735 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Sun, 1 Mar 2026 12:35:51 +0100 Subject: [PATCH 071/135] update openapi spec --- artifacts/inv.sdcio.dev_targets.yaml | 211 ++++++++++++++++++ .../inv/v1alpha1/discoveryinfo.go | 111 --------- pkg/generated/openapi/zz_generated.openapi.go | 49 ++++ pkg/registry/configblame/fieldselector.go | 82 +++++++ pkg/registry/runningconfig/fieldselector.go | 82 +++++++ 5 files changed, 424 insertions(+), 111 deletions(-) create mode 100644 artifacts/inv.sdcio.dev_targets.yaml delete mode 100644 pkg/generated/applyconfiguration/inv/v1alpha1/discoveryinfo.go create mode 100644 pkg/registry/configblame/fieldselector.go create mode 100644 pkg/registry/runningconfig/fieldselector.go diff --git a/artifacts/inv.sdcio.dev_targets.yaml b/artifacts/inv.sdcio.dev_targets.yaml new file mode 100644 index 00000000..ca896dc5 --- /dev/null +++ b/artifacts/inv.sdcio.dev_targets.yaml @@ -0,0 +1,211 @@ +--- +apiVersion: apiextensions.k8s.io/v1 +kind: CustomResourceDefinition +metadata: + annotations: + controller-gen.kubebuilder.io/version: v0.20.0 + name: targets.inv.sdcio.dev +spec: + group: inv.sdcio.dev + names: + categories: + - sdc + - inv + kind: Target + listKind: TargetList + plural: targets + singular: target + scope: Namespaced + versions: + - additionalPrinterColumns: + - jsonPath: .status.conditions[?(@.type=='Ready')].status + name: READY + type: string + - jsonPath: .status.conditions[?(@.type=='Ready')].message + name: REASON + type: string + - jsonPath: .spec.provider + name: PROVIDER + type: string + - jsonPath: .status.discoveryInfo.version + name: VERSION + type: string + - jsonPath: .spec.address + name: ADDRESS + type: string + - jsonPath: .status.discoveryInfo.platform + name: PLATFORM + type: string + - jsonPath: .status.discoveryInfo.serialNumber + name: SERIALNUMBER + type: string + - jsonPath: .status.discoveryInfo.macAddress + name: MACADDRESS + type: string + name: v1alpha1 + schema: + openAPIV3Schema: + description: Target is the Schema for the Target API + properties: + apiVersion: + description: |- + APIVersion defines the versioned schema of this representation of an object. + Servers should convert recognized schemas to the latest internal value, and + may reject unrecognized values. + More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + type: string + kind: + description: |- + Kind is a string value representing the REST resource this object represents. + Servers may infer this from the endpoint the client submits requests to. + Cannot be updated. + In CamelCase. + More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + type: string + metadata: + type: object + spec: + description: TargetSpec defines the desired state of Target + properties: + address: + description: Address defines the address to connect to the target + type: string + connectionProfile: + description: ConnectionProfile define the profile used to connect + to the target once discovered + type: string + credentials: + description: Credentials defines the name of the secret that holds + the credentials to connect to the target + type: string + provider: + description: Provider specifies the provider using this target. + type: string + syncProfile: + description: SyncProfile define the profile used to sync to the target + config once discovered + type: string + tlsSecret: + description: TLSSecret defines the name of the TLS secret to connect + to the target if mtls is used + type: string + required: + - address + - connectionProfile + - credentials + - provider + type: object + status: + description: TargetStatus defines the observed state of Target + properties: + conditions: + description: Conditions of the resource. + items: + properties: + lastTransitionTime: + description: |- + lastTransitionTime is the last time the condition transitioned from one status to another. + This should be when the underlying condition changed. If that is not known, then using the time when the API field changed is acceptable. + format: date-time + type: string + message: + description: |- + message is a human readable message indicating details about the transition. + This may be an empty string. + maxLength: 32768 + type: string + observedGeneration: + description: |- + observedGeneration represents the .metadata.generation that the condition was set based upon. + For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date + with respect to the current state of the instance. + format: int64 + minimum: 0 + type: integer + reason: + description: |- + reason contains a programmatic identifier indicating the reason for the condition's last transition. + Producers of specific condition types may define expected values and meanings for this field, + and whether the values are considered a guaranteed API. + The value should be a CamelCase string. + This field may not be empty. + maxLength: 1024 + minLength: 1 + pattern: ^[A-Za-z]([A-Za-z0-9_,:]*[A-Za-z0-9_])?$ + type: string + status: + description: status of the condition, one of True, False, Unknown. + enum: + - "True" + - "False" + - Unknown + type: string + type: + description: type of condition in CamelCase or in foo.example.com/CamelCase. + maxLength: 316 + pattern: ^([a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*/)?(([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9])$ + type: string + required: + - lastTransitionTime + - message + - reason + - status + - type + type: object + type: array + x-kubernetes-list-map-keys: + - type + x-kubernetes-list-type: map + discoveryInfo: + description: Discovery info defines the information retrieved during + discovery + properties: + hostname: + description: HostName associated with the target + type: string + macAddress: + description: MacAddress associated with the target + type: string + platform: + description: Platform associated with the target + type: string + protocol: + description: Protocol used for discovery + type: string + provider: + description: Type associated with the target + type: string + serialNumber: + description: SerialNumber associated with the target + type: string + supportedEncodings: + description: Supported Encodings of the target + items: + type: string + type: array + version: + description: Version associated with the target + type: string + type: object + usedReferences: + description: UsedReferences track the resource used to reconcile the + cr + properties: + connectionProfileResourceVersion: + type: string + secretResourceVersion: + type: string + syncProfileResourceVersion: + type: string + tlsSecretResourceVersion: + type: string + required: + - connectionProfileResourceVersion + - syncProfileResourceVersion + type: object + type: object + type: object + served: true + storage: true + subresources: + status: {} diff --git a/pkg/generated/applyconfiguration/inv/v1alpha1/discoveryinfo.go b/pkg/generated/applyconfiguration/inv/v1alpha1/discoveryinfo.go deleted file mode 100644 index 7096908d..00000000 --- a/pkg/generated/applyconfiguration/inv/v1alpha1/discoveryinfo.go +++ /dev/null @@ -1,111 +0,0 @@ -/* -Copyright 2024 Nokia. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ -// Code generated by applyconfiguration-gen. DO NOT EDIT. - -package v1alpha1 - -// DiscoveryInfoApplyConfiguration represents a declarative configuration of the DiscoveryInfo type for use -// with apply. -type DiscoveryInfoApplyConfiguration struct { - // Protocol used for discovery - Protocol *string `json:"protocol,omitempty"` - // Type associated with the target - Provider *string `json:"provider,omitempty"` - // Version associated with the target - Version *string `json:"version,omitempty"` - // Hostname associated with the target - Hostname *string `json:"hostname,omitempty"` - // Platform associated with the target - Platform *string `json:"platform,omitempty"` - // MacAddress associated with the target - MacAddress *string `json:"macAddress,omitempty"` - // SerialNumber associated with the target - SerialNumber *string `json:"serialNumber,omitempty"` - // Supported Encodings of the target - SupportedEncodings []string `json:"supportedEncodings,omitempty"` -} - -// DiscoveryInfoApplyConfiguration constructs a declarative configuration of the DiscoveryInfo type for use with -// apply. -func DiscoveryInfo() *DiscoveryInfoApplyConfiguration { - return &DiscoveryInfoApplyConfiguration{} -} - -// WithProtocol sets the Protocol field in the declarative configuration to the given value -// and returns the receiver, so that objects can be built by chaining "With" function invocations. -// If called multiple times, the Protocol field is set to the value of the last call. -func (b *DiscoveryInfoApplyConfiguration) WithProtocol(value string) *DiscoveryInfoApplyConfiguration { - b.Protocol = &value - return b -} - -// WithProvider sets the Provider field in the declarative configuration to the given value -// and returns the receiver, so that objects can be built by chaining "With" function invocations. -// If called multiple times, the Provider field is set to the value of the last call. -func (b *DiscoveryInfoApplyConfiguration) WithProvider(value string) *DiscoveryInfoApplyConfiguration { - b.Provider = &value - return b -} - -// WithVersion sets the Version field in the declarative configuration to the given value -// and returns the receiver, so that objects can be built by chaining "With" function invocations. -// If called multiple times, the Version field is set to the value of the last call. -func (b *DiscoveryInfoApplyConfiguration) WithVersion(value string) *DiscoveryInfoApplyConfiguration { - b.Version = &value - return b -} - -// WithHostname sets the Hostname field in the declarative configuration to the given value -// and returns the receiver, so that objects can be built by chaining "With" function invocations. -// If called multiple times, the Hostname field is set to the value of the last call. -func (b *DiscoveryInfoApplyConfiguration) WithHostname(value string) *DiscoveryInfoApplyConfiguration { - b.Hostname = &value - return b -} - -// WithPlatform sets the Platform field in the declarative configuration to the given value -// and returns the receiver, so that objects can be built by chaining "With" function invocations. -// If called multiple times, the Platform field is set to the value of the last call. -func (b *DiscoveryInfoApplyConfiguration) WithPlatform(value string) *DiscoveryInfoApplyConfiguration { - b.Platform = &value - return b -} - -// WithMacAddress sets the MacAddress field in the declarative configuration to the given value -// and returns the receiver, so that objects can be built by chaining "With" function invocations. -// If called multiple times, the MacAddress field is set to the value of the last call. -func (b *DiscoveryInfoApplyConfiguration) WithMacAddress(value string) *DiscoveryInfoApplyConfiguration { - b.MacAddress = &value - return b -} - -// WithSerialNumber sets the SerialNumber field in the declarative configuration to the given value -// and returns the receiver, so that objects can be built by chaining "With" function invocations. -// If called multiple times, the SerialNumber field is set to the value of the last call. -func (b *DiscoveryInfoApplyConfiguration) WithSerialNumber(value string) *DiscoveryInfoApplyConfiguration { - b.SerialNumber = &value - return b -} - -// WithSupportedEncodings adds the given value to the SupportedEncodings field in the declarative configuration -// and returns the receiver, so that objects can be build by chaining "With" function invocations. -// If called multiple times, values provided by each call will be appended to the SupportedEncodings field. -func (b *DiscoveryInfoApplyConfiguration) WithSupportedEncodings(values ...string) *DiscoveryInfoApplyConfiguration { - for i := range values { - b.SupportedEncodings = append(b.SupportedEncodings, values[i]) - } - return b -} diff --git a/pkg/generated/openapi/zz_generated.openapi.go b/pkg/generated/openapi/zz_generated.openapi.go index 007ec274..c84a233f 100644 --- a/pkg/generated/openapi/zz_generated.openapi.go +++ b/pkg/generated/openapi/zz_generated.openapi.go @@ -579,6 +579,13 @@ func schema_config_server_apis_config_v1alpha1_Config(ref common.ReferenceCallba }, }, }, + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-group-version-kind": []interface{}{ + map[string]interface{}{"group": "config.sdcio.dev", "kind": "Config", "version": "v1alpha1"}, + }, + }, + }, }, Dependencies: []string{ "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigSpec", "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigStatus", metav1.ObjectMeta{}.OpenAPIModelName()}, @@ -626,6 +633,13 @@ func schema_config_server_apis_config_v1alpha1_ConfigBlame(ref common.ReferenceC }, }, }, + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-group-version-kind": []interface{}{ + map[string]interface{}{"group": "config.sdcio.dev", "kind": "ConfigBlame", "version": "v1alpha1"}, + }, + }, + }, }, Dependencies: []string{ "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigBlameSpec", "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigBlameStatus", metav1.ObjectMeta{}.OpenAPIModelName()}, @@ -870,6 +884,13 @@ func schema_config_server_apis_config_v1alpha1_ConfigSet(ref common.ReferenceCal }, }, }, + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-group-version-kind": []interface{}{ + map[string]interface{}{"group": "config.sdcio.dev", "kind": "ConfigSet", "version": "v1alpha1"}, + }, + }, + }, }, Dependencies: []string{ "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigSetSpec", "github.com/sdcio/config-server/apis/config/v1alpha1.ConfigSetStatus", metav1.ObjectMeta{}.OpenAPIModelName()}, @@ -1315,6 +1336,13 @@ func schema_config_server_apis_config_v1alpha1_Deviation(ref common.ReferenceCal }, }, }, + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-group-version-kind": []interface{}{ + map[string]interface{}{"group": "config.sdcio.dev", "kind": "Deviation", "version": "v1alpha1"}, + }, + }, + }, }, Dependencies: []string{ "github.com/sdcio/config-server/apis/config/v1alpha1.DeviationSpec", "github.com/sdcio/config-server/apis/config/v1alpha1.DeviationStatus", metav1.ObjectMeta{}.OpenAPIModelName()}, @@ -1588,6 +1616,13 @@ func schema_config_server_apis_config_v1alpha1_RunningConfig(ref common.Referenc }, }, }, + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-group-version-kind": []interface{}{ + map[string]interface{}{"group": "config.sdcio.dev", "kind": "RunningConfig", "version": "v1alpha1"}, + }, + }, + }, }, Dependencies: []string{ "github.com/sdcio/config-server/apis/config/v1alpha1.RunningConfigSpec", "github.com/sdcio/config-server/apis/config/v1alpha1.RunningConfigStatus", metav1.ObjectMeta{}.OpenAPIModelName()}, @@ -1716,6 +1751,13 @@ func schema_config_server_apis_config_v1alpha1_SensitiveConfig(ref common.Refere }, }, }, + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-group-version-kind": []interface{}{ + map[string]interface{}{"group": "config.sdcio.dev", "kind": "SensitiveConfig", "version": "v1alpha1"}, + }, + }, + }, }, Dependencies: []string{ "github.com/sdcio/config-server/apis/config/v1alpha1.SensitiveConfigSpec", "github.com/sdcio/config-server/apis/config/v1alpha1.SensitiveConfigStatus", metav1.ObjectMeta{}.OpenAPIModelName()}, @@ -1953,6 +1995,13 @@ func schema_config_server_apis_config_v1alpha1_Target(ref common.ReferenceCallba }, }, }, + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-group-version-kind": []interface{}{ + map[string]interface{}{"group": "config.sdcio.dev", "kind": "Target", "version": "v1alpha1"}, + }, + }, + }, }, Dependencies: []string{ "github.com/sdcio/config-server/apis/config/v1alpha1.TargetSpec", "github.com/sdcio/config-server/apis/config/v1alpha1.TargetStatus", metav1.ObjectMeta{}.OpenAPIModelName()}, diff --git a/pkg/registry/configblame/fieldselector.go b/pkg/registry/configblame/fieldselector.go new file mode 100644 index 00000000..ea4b82c8 --- /dev/null +++ b/pkg/registry/configblame/fieldselector.go @@ -0,0 +1,82 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package configblame + +import ( + "context" + "fmt" + + apierrors "k8s.io/apimachinery/pkg/api/errors" + "k8s.io/apimachinery/pkg/fields" + "k8s.io/apimachinery/pkg/selection" + genericapirequest "k8s.io/apiserver/pkg/endpoints/request" +) + +// Filter +type Filter struct { + // Name filters by the name of the objects + Name string + + // Namespace filters by the namespace of the objects + Namespace string +} + +// parseFieldSelector parses client-provided fields.Selector into a packageFilter +func parseFieldSelector(ctx context.Context, fieldSelector fields.Selector) (*Filter, error) { + var filter *Filter + + // add the namespace to the list + namespace, ok := genericapirequest.NamespaceFrom(ctx) + if fieldSelector == nil { + if ok { + return &Filter{Namespace: namespace}, nil + } + return filter, nil + } + + requirements := fieldSelector.Requirements() + for _, requirement := range requirements { + filter = &Filter{} + switch requirement.Operator { + case selection.Equals, selection.DoesNotExist: + if requirement.Value == "" { + return filter, apierrors.NewBadRequest(fmt.Sprintf("unsupported fieldSelector value %q for field %q with operator %q", requirement.Value, requirement.Field, requirement.Operator)) + } + default: + return filter, apierrors.NewBadRequest(fmt.Sprintf("unsupported fieldSelector operator %q for field %q", requirement.Operator, requirement.Field)) + } + + switch requirement.Field { + case "metadata.name": + filter.Name = requirement.Value + case "metadata.namespace": + filter.Namespace = requirement.Value + default: + return filter, apierrors.NewBadRequest(fmt.Sprintf("unknown fieldSelector field %q", requirement.Field)) + } + } + // add namespace to the filter selector if specified + if ok { + if filter != nil { + filter.Namespace = namespace + } else { + filter = &Filter{Namespace: namespace} + } + } + + return filter, nil +} diff --git a/pkg/registry/runningconfig/fieldselector.go b/pkg/registry/runningconfig/fieldselector.go new file mode 100644 index 00000000..db1d34ea --- /dev/null +++ b/pkg/registry/runningconfig/fieldselector.go @@ -0,0 +1,82 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package runningconfig + +import ( + "context" + "fmt" + + apierrors "k8s.io/apimachinery/pkg/api/errors" + "k8s.io/apimachinery/pkg/fields" + "k8s.io/apimachinery/pkg/selection" + genericapirequest "k8s.io/apiserver/pkg/endpoints/request" +) + +// Filter +type Filter struct { + // Name filters by the name of the objects + Name string + + // Namespace filters by the namespace of the objects + Namespace string +} + +// parseFieldSelector parses client-provided fields.Selector into a packageFilter +func parseFieldSelector(ctx context.Context, fieldSelector fields.Selector) (*Filter, error) { + var filter *Filter + + // add the namespace to the list + namespace, ok := genericapirequest.NamespaceFrom(ctx) + if fieldSelector == nil { + if ok { + return &Filter{Namespace: namespace}, nil + } + return filter, nil + } + + requirements := fieldSelector.Requirements() + for _, requirement := range requirements { + filter = &Filter{} + switch requirement.Operator { + case selection.Equals, selection.DoesNotExist: + if requirement.Value == "" { + return filter, apierrors.NewBadRequest(fmt.Sprintf("unsupported fieldSelector value %q for field %q with operator %q", requirement.Value, requirement.Field, requirement.Operator)) + } + default: + return filter, apierrors.NewBadRequest(fmt.Sprintf("unsupported fieldSelector operator %q for field %q", requirement.Operator, requirement.Field)) + } + + switch requirement.Field { + case "metadata.name": + filter.Name = requirement.Value + case "metadata.namespace": + filter.Namespace = requirement.Value + default: + return filter, apierrors.NewBadRequest(fmt.Sprintf("unknown fieldSelector field %q", requirement.Field)) + } + } + // add namespace to the filter selector if specified + if ok { + if filter != nil { + filter.Namespace = namespace + } else { + filter = &Filter{Namespace: namespace} + } + } + + return filter, nil +} From 0388f523774d54d9e09e4c877a9c1d4f4bf179ef Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Sun, 1 Mar 2026 12:59:13 +0100 Subject: [PATCH 072/135] update message truncation --- pkg/reconcilers/targetdatastore/reconciler.go | 5 ++++- pkg/registry/configblame/watcher.go | 22 ++++++++++--------- pkg/registry/generic/watcher.go | 22 ++++++++++--------- pkg/registry/runningconfig/watcher.go | 22 ++++++++++--------- 4 files changed, 40 insertions(+), 31 deletions(-) diff --git a/pkg/reconcilers/targetdatastore/reconciler.go b/pkg/reconcilers/targetdatastore/reconciler.go index 4c362ed6..4f3f5127 100644 --- a/pkg/reconcilers/targetdatastore/reconciler.go +++ b/pkg/reconcilers/targetdatastore/reconciler.go @@ -246,7 +246,10 @@ func (r *reconciler) handleError(ctx context.Context, target *configv1alpha1.Tar log := log.FromContext(ctx) if err != nil { - msg = fmt.Sprintf("%s err %s", msg, err.Error()) + msg = fmt.Sprintf("%q err %q", msg, err.Error()) + } + if len(msg) > 256 { + msg = msg[:256] } newCond := configv1alpha1.TargetDatastoreFailed(msg) diff --git a/pkg/registry/configblame/watcher.go b/pkg/registry/configblame/watcher.go index f37119f4..7638f8a8 100644 --- a/pkg/registry/configblame/watcher.go +++ b/pkg/registry/configblame/watcher.go @@ -174,16 +174,18 @@ func (r *watcher) innerListAndWatch(ctx context.Context, l rest.RESTListStrategy } // Send bookmark event to signal initial list is complete - bookmarkObj := r.obj.New() - accessor, _ := meta.Accessor(bookmarkObj) - // Set resourceVersion so the client knows where it is - if accessor.GetResourceVersion() == "" { - accessor.SetResourceVersion("0") - } - r.sendWatchEvent(ctx, watch.Event{ - Type: watch.Bookmark, - Object: bookmarkObj, - }) + /* + bookmarkObj := r.obj.New() + accessor, _ := meta.Accessor(bookmarkObj) + // Set resourceVersion so the client knows where it is + if accessor.GetResourceVersion() == "" { + accessor.SetResourceVersion("0") + } + r.sendWatchEvent(ctx, watch.Event{ + Type: watch.Bookmark, + Object: bookmarkObj, + }) + */ log.Debug("moving into streaming mode") r.eventCallback = func(eventType watch.EventType, obj runtime.Object) bool { diff --git a/pkg/registry/generic/watcher.go b/pkg/registry/generic/watcher.go index c8d55b1e..98d21e31 100644 --- a/pkg/registry/generic/watcher.go +++ b/pkg/registry/generic/watcher.go @@ -174,16 +174,18 @@ func (r *watcher) innerListAndWatch(ctx context.Context, l rest.RESTListStrategy } // Send bookmark event to signal initial list is complete - bookmarkObj := r.obj.New() - accessor, _ := meta.Accessor(bookmarkObj) - // Set resourceVersion so the client knows where it is - if accessor.GetResourceVersion() == "" { - accessor.SetResourceVersion("0") - } - r.sendWatchEvent(ctx, watch.Event{ - Type: watch.Bookmark, - Object: bookmarkObj, - }) + /* + bookmarkObj := r.obj.New() + accessor, _ := meta.Accessor(bookmarkObj) + // Set resourceVersion so the client knows where it is + if accessor.GetResourceVersion() == "" { + accessor.SetResourceVersion("0") + } + r.sendWatchEvent(ctx, watch.Event{ + Type: watch.Bookmark, + Object: bookmarkObj, + }) + */ log.Debug("moving into streaming mode") r.eventCallback = func(eventType watch.EventType, obj runtime.Object) bool { diff --git a/pkg/registry/runningconfig/watcher.go b/pkg/registry/runningconfig/watcher.go index 961fc0db..c0dbfd7b 100644 --- a/pkg/registry/runningconfig/watcher.go +++ b/pkg/registry/runningconfig/watcher.go @@ -174,16 +174,18 @@ func (r *watcher) innerListAndWatch(ctx context.Context, l rest.RESTListStrategy } // Send bookmark event to signal initial list is complete - bookmarkObj := r.obj.New() - accessor, _ := meta.Accessor(bookmarkObj) - // Set resourceVersion so the client knows where it is - if accessor.GetResourceVersion() == "" { - accessor.SetResourceVersion("0") - } - r.sendWatchEvent(ctx, watch.Event{ - Type: watch.Bookmark, - Object: bookmarkObj, - }) + /* + bookmarkObj := r.obj.New() + accessor, _ := meta.Accessor(bookmarkObj) + // Set resourceVersion so the client knows where it is + if accessor.GetResourceVersion() == "" { + accessor.SetResourceVersion("0") + } + r.sendWatchEvent(ctx, watch.Event{ + Type: watch.Bookmark, + Object: bookmarkObj, + }) + */ log.Debug("moving into streaming mode") r.eventCallback = func(eventType watch.EventType, obj runtime.Object) bool { From c12cb5a24f24332ae792e69a22993a1f81f394df Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Sun, 1 Mar 2026 14:54:10 +0100 Subject: [PATCH 073/135] update target discovery with force true --- pkg/discovery/discoveryrule/target.go | 1 + 1 file changed, 1 insertion(+) diff --git a/pkg/discovery/discoveryrule/target.go b/pkg/discovery/discoveryrule/target.go index 874de007..a34db101 100644 --- a/pkg/discovery/discoveryrule/target.go +++ b/pkg/discovery/discoveryrule/target.go @@ -175,6 +175,7 @@ func (r *dr) applyTarget(ctx context.Context, newTarget *configv1alpha1.Target) if err := r.client.Status().Apply(ctx, applyConfig, &client.SubResourceApplyOptions{ ApplyOptions: client.ApplyOptions{ FieldManager: reconcilerName, + Force: ptr.To(true), }, }); err != nil { log.Error("failed to patch target status", "err", err) From 4632ab4089aa84ecea519d8859098f1074f0532e Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Sun, 1 Mar 2026 15:42:36 +0100 Subject: [PATCH 074/135] updated target discovery ssa and finalizer updates --- pkg/discovery/discoveryrule/target.go | 186 ++++++++++++++------------ pkg/reconcilers/resource/finalizer.go | 9 +- 2 files changed, 101 insertions(+), 94 deletions(-) diff --git a/pkg/discovery/discoveryrule/target.go b/pkg/discovery/discoveryrule/target.go index a34db101..98224c01 100644 --- a/pkg/discovery/discoveryrule/target.go +++ b/pkg/discovery/discoveryrule/target.go @@ -19,26 +19,25 @@ package discoveryrule import ( "context" "strings" - "time" "github.com/henderiw/apiserver-store/pkg/storebackend" "github.com/henderiw/logger/log" - //condv1alpha1 "github.com/sdcio/config-server/apis/condition/v1alpha1" configv1alpha1 "github.com/sdcio/config-server/apis/config/v1alpha1" invv1alpha1 "github.com/sdcio/config-server/apis/inv/v1alpha1" configv1alpha1apply "github.com/sdcio/config-server/pkg/generated/applyconfiguration/config/v1alpha1" - "github.com/sdcio/config-server/pkg/reconcilers/resource" "k8s.io/apimachinery/pkg/api/equality" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/apimachinery/pkg/runtime/schema" "k8s.io/apimachinery/pkg/types" + v1 "k8s.io/client-go/applyconfigurations/meta/v1" "k8s.io/utils/ptr" "sigs.k8s.io/controller-runtime/pkg/client" ) const ( - reconcilerName = "DiscoveryController" + specFieldManager = "DiscoveryRuleController-spec" + statusFieldManager = "DiscoveryRuleController-status" ) func (r *dr) createTarget(ctx context.Context, provider, address string, di *configv1alpha1.DiscoveryInfo) error { @@ -47,25 +46,19 @@ func (r *dr) createTarget(ctx context.Context, provider, address string, di *con return err } - newTarget, err := r.newTarget( - ctx, - provider, - address, - di, - ) - if err != nil { - return err + targetKey := types.NamespacedName{ + Namespace: r.cfg.CR.GetNamespace(), + Name: getTargetName(di.Hostname), } - if err := r.applyTarget(ctx, newTarget); err != nil { + if err := r.applyTargetSpec(ctx, targetKey, provider, address); err != nil { log.Info("dynamic target creation failed", "error", err) return err } - targetKey := newTarget.GetNamespacedName() - target := &configv1alpha1.Target{} - if err := r.client.Get(ctx, targetKey, target); err != nil { - log.Info("cannot get target", "error", err) + target, err := r.applyTargetStatus(ctx, targetKey, di) + if err != nil { + log.Info("dynamic target status apply failed", "error", err) return err } @@ -76,112 +69,96 @@ func (r *dr) createTarget(ctx context.Context, provider, address string, di *con return nil } -func (r *dr) newTarget(_ context.Context, providerName, address string, di *configv1alpha1.DiscoveryInfo) (*configv1alpha1.Target, error) { - targetSpec := configv1alpha1.TargetSpec{ - Provider: providerName, - Address: address, - TargetProfile: invv1alpha1.TargetProfile{ - Credentials: r.cfg.CR.GetDiscoveryParameters().TargetConnectionProfiles[0].Credentials, - // TODO TLSSecret: - ConnectionProfile: r.cfg.CR.GetDiscoveryParameters().TargetConnectionProfiles[0].ConnectionProfile, - SyncProfile: r.cfg.CR.GetDiscoveryParameters().TargetConnectionProfiles[0].SyncProfile, - }, - } +func (r *dr) applyTargetSpec(ctx context.Context, targetKey types.NamespacedName, provider, address string) error { + //di := newTarget.Status.DiscoveryInfo.DeepCopy() + log := log.FromContext(ctx).With("target", targetKey) + labels, err := r.cfg.CR.GetDiscoveryParameters().GetTargetLabels(r.cfg.CR.GetName()) if err != nil { - return nil, err + return err } anno, err := r.cfg.CR.GetDiscoveryParameters().GetTargetAnnotations(r.cfg.CR.GetName()) if err != nil { - return nil, err + return err } - return configv1alpha1.BuildTarget( - metav1.ObjectMeta{ - Name: getTargetName(di.Hostname), - Namespace: r.cfg.CR.GetNamespace(), - Labels: labels, - Annotations: anno, - OwnerReferences: []metav1.OwnerReference{ - { - APIVersion: schema.GroupVersion{ - Group: r.cfg.CR.GetObjectKind().GroupVersionKind().Group, - Version: r.cfg.CR.GetObjectKind().GroupVersionKind().Version, - }.String(), - Kind: r.cfg.CR.GetObjectKind().GroupVersionKind().Kind, - Name: r.cfg.CR.GetName(), - UID: r.cfg.CR.GetUID(), - Controller: ptr.To[bool](true), - }}, - }, - targetSpec, - configv1alpha1.TargetStatus{ - DiscoveryInfo: di, - }, - ), nil + applyConfig := configv1alpha1apply.Target(targetKey.Name, targetKey.Namespace). + WithLabels(labels). + WithAnnotations(anno). + WithOwnerReferences(ownerRefsToApply([]metav1.OwnerReference{ + { + APIVersion: schema.GroupVersion{ + Group: r.cfg.CR.GetObjectKind().GroupVersionKind().Group, + Version: r.cfg.CR.GetObjectKind().GroupVersionKind().Version, + }.String(), + Kind: r.cfg.CR.GetObjectKind().GroupVersionKind().Kind, + Name: r.cfg.CR.GetName(), + UID: r.cfg.CR.GetUID(), + Controller: ptr.To[bool](true), + }})...). + WithSpec(specToApply(&configv1alpha1.TargetSpec{ + Provider: provider, + Address: address, + TargetProfile: invv1alpha1.TargetProfile{ + Credentials: r.cfg.CR.GetDiscoveryParameters().TargetConnectionProfiles[0].Credentials, + // TODO TLSSecret: + ConnectionProfile: r.cfg.CR.GetDiscoveryParameters().TargetConnectionProfiles[0].ConnectionProfile, + SyncProfile: r.cfg.CR.GetDiscoveryParameters().TargetConnectionProfiles[0].SyncProfile, + }, + })) + + if err := r.client.Apply(ctx, applyConfig, &client.ApplyOptions{ + FieldManager: specFieldManager, + }); err != nil { + log.Error("failed to apply target spec", "err", err) + return err + } + return nil } -// w/o seperated discovery info +// applyTargetStatus applies status (condition + discoveryInfo) via SSA on the status subresource +func (r *dr) applyTargetStatus(ctx context.Context, targetKey types.NamespacedName, di *configv1alpha1.DiscoveryInfo) (*configv1alpha1.Target, error) { + log := log.FromContext(ctx).With("targetKey", targetKey) -func (r *dr) applyTarget(ctx context.Context, newTarget *configv1alpha1.Target) error { - //di := newTarget.Status.DiscoveryInfo.DeepCopy() - log := log.FromContext(ctx).With("targetName", newTarget.Name, "address", newTarget.Spec.Address) - - // Check if the target already exists + // Check current state to avoid unnecessary updates target := &configv1alpha1.Target{} - if err := r.client.Get(ctx, types.NamespacedName{ - Namespace: newTarget.Namespace, - Name: newTarget.Name, - }, target); err != nil { - if resource.IgnoreNotFound(err) != nil { - return err - } - log.Info("discovery target apply, target does not exist -> create") - - target := newTarget.DeepCopy() - - if err := r.client.Create(ctx, target, &client.CreateOptions{FieldManager: reconcilerName}); err != nil { - return err - } - time.Sleep(500 * time.Millisecond) + if err := r.client.Get(ctx, targetKey, target); err != nil { + return nil, err } newCond := configv1alpha1.TargetDiscoveryReady() oldCond := target.GetCondition(configv1alpha1.ConditionTypeTargetDiscoveryReady) if newCond.Equal(oldCond) && - equality.Semantic.DeepEqual(newTarget.Spec, target.Spec) && - equality.Semantic.DeepEqual(newTarget.Status.DiscoveryInfo, target.Status.DiscoveryInfo) { - log.Info("handleSuccess -> no change") - return nil + equality.Semantic.DeepEqual(di, target.Status.DiscoveryInfo) { + log.Info("applyTargetStatus -> no change") + return target, nil } - log.Info("handleSuccess", + log.Info("applyTargetStatus", "condition change", !newCond.Equal(oldCond), - "spec change", !equality.Semantic.DeepEqual(newTarget.Spec, target.Spec), - "discovery info change", !equality.Semantic.DeepEqual(newTarget.Status.DiscoveryInfo, target.Status.DiscoveryInfo), + "discovery info change", !equality.Semantic.DeepEqual(di, target.Status.DiscoveryInfo), ) statusApply := configv1alpha1apply.TargetStatus(). WithConditions(newCond) - if newTarget.Status.DiscoveryInfo != nil { - statusApply = statusApply.WithDiscoveryInfo(discoveryInfoToApply(newTarget.Status.DiscoveryInfo)) + if di != nil { + statusApply = statusApply.WithDiscoveryInfo(discoveryInfoToApply(di)) } - applyConfig := configv1alpha1apply.Target(newTarget.Name, newTarget.Namespace). + applyConfig := configv1alpha1apply.Target(targetKey.Name, targetKey.Namespace). WithStatus(statusApply) if err := r.client.Status().Apply(ctx, applyConfig, &client.SubResourceApplyOptions{ ApplyOptions: client.ApplyOptions{ - FieldManager: reconcilerName, - Force: ptr.To(true), + FieldManager: statusFieldManager, }, }); err != nil { - log.Error("failed to patch target status", "err", err) - return err + log.Error("failed to apply target status", "err", err) + return nil, err } - return nil + return target, nil } func discoveryInfoToApply(di *configv1alpha1.DiscoveryInfo) *configv1alpha1apply.DiscoveryInfoApplyConfiguration { @@ -217,3 +194,34 @@ func getTargetName(s string) string { targetName := strings.ReplaceAll(s, ":", "-") return strings.ToLower(targetName) } + +func specToApply(spec *configv1alpha1.TargetSpec) *configv1alpha1apply.TargetSpecApplyConfiguration { + a := configv1alpha1apply.TargetSpec(). + WithProvider(spec.Provider). + WithAddress(spec.Address). + WithCredentials(spec.Credentials). + WithConnectionProfile(spec.ConnectionProfile) + if spec.SyncProfile != nil { + a.WithSyncProfile(*spec.SyncProfile) + } + if spec.TLSSecret != nil { + a.WithTLSSecret(*spec.TLSSecret) + } + return a +} + +func ownerRefsToApply(refs []metav1.OwnerReference) []*v1.OwnerReferenceApplyConfiguration { + result := make([]*v1.OwnerReferenceApplyConfiguration, 0, len(refs)) + for _, ref := range refs { + r := v1.OwnerReference(). + WithAPIVersion(ref.APIVersion). + WithKind(ref.Kind). + WithName(ref.Name). + WithUID(ref.UID) + if ref.Controller != nil { + r.WithController(*ref.Controller) + } + result = append(result, r) + } + return result +} diff --git a/pkg/reconcilers/resource/finalizer.go b/pkg/reconcilers/resource/finalizer.go index 4fe583d0..a0edddcb 100644 --- a/pkg/reconcilers/resource/finalizer.go +++ b/pkg/reconcilers/resource/finalizer.go @@ -64,11 +64,10 @@ func (r *APIFinalizer) AddFinalizer(ctx context.Context, obj client.Object) erro } func (r *APIFinalizer) Update(ctx context.Context, obj client.Object, patch client.Patch) error { - return r.client.Patch(ctx, obj, patch, &client.SubResourcePatchOptions{ - PatchOptions: client.PatchOptions{ - FieldManager: r.reconcilerName, - }, - }) + return r.client.Patch(ctx, obj, patch, &client.PatchOptions{ + FieldManager: r.reconcilerName, + }, + ) } func (r *APIFinalizer) RemoveFinalizer(ctx context.Context, obj client.Object) error { From 6890860dbb7b4daed83b4f1e0663653df0d9e084 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Sun, 1 Mar 2026 16:05:38 +0100 Subject: [PATCH 075/135] updated target discovery ssa and finalizer updates --- pkg/reconcilers/configset/reconciler.go | 9 +- pkg/reconcilers/resource/finalizer.go | 79 +++----- pkg/reconcilers/resource/finalizer_test.go | 190 ------------------ pkg/reconcilers/rollout/reconciler.go | 3 +- pkg/reconcilers/schema/reconciler.go | 3 +- pkg/reconcilers/subscription/reconciler.go | 9 +- pkg/reconcilers/target/reconciler.go | 9 +- pkg/reconcilers/targetconfig/reconciler.go | 4 +- pkg/reconcilers/targetdatastore/reconciler.go | 3 +- pkg/reconcilers/targetrecovery/reconciler.go | 4 +- pkg/reconcilers/workspace/reconciler.go | 9 +- 11 files changed, 60 insertions(+), 262 deletions(-) delete mode 100644 pkg/reconcilers/resource/finalizer_test.go diff --git a/pkg/reconcilers/configset/reconciler.go b/pkg/reconcilers/configset/reconciler.go index 8f88821a..20157443 100644 --- a/pkg/reconcilers/configset/reconciler.go +++ b/pkg/reconcilers/configset/reconciler.go @@ -50,9 +50,10 @@ func init() { } const ( - crName = "configset" - reconcilerName = "ConfigSetController" - finalizer = "configset.config.sdcio.dev/finalizer" + crName = "configset" + fieldmanagerfinalizer = "ConfigSetControllerFinalizer" + reconcilerName = "ConfigSetController" + finalizer = "configset.config.sdcio.dev/finalizer" // errors errGetCr = "cannot get cr" errUpdateDataStore = "cannot update datastore" @@ -63,7 +64,7 @@ const ( func (r *reconciler) SetupWithManager(ctx context.Context, mgr ctrl.Manager, c interface{}) (map[schema.GroupVersionKind]chan event.GenericEvent, error) { r.client = mgr.GetClient() - r.finalizer = resource.NewAPIFinalizer(mgr.GetClient(), finalizer, reconcilerName) + r.finalizer = resource.NewAPIFinalizer(mgr.GetClient(), finalizer, fieldmanagerfinalizer) r.recorder = mgr.GetEventRecorder(reconcilerName) return nil, ctrl.NewControllerManagedBy(mgr). diff --git a/pkg/reconcilers/resource/finalizer.go b/pkg/reconcilers/resource/finalizer.go index a0edddcb..b1d35cd0 100644 --- a/pkg/reconcilers/resource/finalizer.go +++ b/pkg/reconcilers/resource/finalizer.go @@ -18,10 +18,11 @@ package resource import ( "context" + "encoding/json" "fmt" - "github.com/pkg/errors" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/types" "sigs.k8s.io/controller-runtime/pkg/client" ) @@ -45,69 +46,49 @@ func NewAPIFinalizer(c client.Client, finalizer, reconcilerName string) *APIFina // AddFinalizer to the supplied Managed resource. func (r *APIFinalizer) AddFinalizer(ctx context.Context, obj client.Object) error { - // take a snapshot of the current object - origObj := obj.DeepCopyObject() - - // Again assert to client.Object to manipulate metadata and finalizers - copiedObj, ok := origObj.(client.Object) - if !ok { - return fmt.Errorf("deep copied object does not implement client.Object") - } - - patch := client.MergeFrom(copiedObj) - if FinalizerExists(obj, r.finalizer) { return nil } - AddFinalizer(obj, r.finalizer) - return errors.Wrap(r.Update(ctx, obj, patch), errUpdateObject) -} - -func (r *APIFinalizer) Update(ctx context.Context, obj client.Object, patch client.Patch) error { - return r.client.Patch(ctx, obj, patch, &client.PatchOptions{ + patch, err := r.finalizerPatch(obj, []string{r.finalizer}) + if err != nil { + return fmt.Errorf("cannot build finalizer patch: %w", err) + } + return r.client.Patch(ctx, obj, client.RawPatch(types.ApplyPatchType, patch), client.ForceOwnership, &client.PatchOptions{ FieldManager: r.reconcilerName, - }, - ) + }) } func (r *APIFinalizer) RemoveFinalizer(ctx context.Context, obj client.Object) error { - // take a snapshot of the current object - origObj := obj.DeepCopyObject() - - // Again assert to client.Object to manipulate metadata and finalizers - copiedObj, ok := origObj.(client.Object) - if !ok { - return fmt.Errorf("deep copied object does not implement client.Object") - } - patch := client.MergeFrom(copiedObj) - if !FinalizerExists(obj, r.finalizer) { return nil } - RemoveFinalizer(obj, r.finalizer) - return errors.Wrap(r.Update(ctx, obj, patch), errUpdateObject) + patch, err := r.finalizerPatch(obj, nil) + if err != nil { + return fmt.Errorf("cannot build finalizer patch: %w", err) + } + return r.client.Patch(ctx, obj, client.RawPatch(types.ApplyPatchType, patch), client.ForceOwnership, &client.PatchOptions{ + FieldManager: r.reconcilerName, + }) } -// AddFinalizer to the supplied k8s object's metadata. -func AddFinalizer(o metav1.Object, finalizer string) { - f := o.GetFinalizers() - for _, e := range f { - if e == finalizer { - return - } +// finalizerPatch builds a minimal SSA patch containing only apiVersion, kind, metadata.name, +// metadata.namespace, and metadata.finalizers. +func (r *APIFinalizer) finalizerPatch(obj client.Object, finalizers []string) ([]byte, error) { + gvk := obj.GetObjectKind().GroupVersionKind() + if gvk.Empty() { + return nil, fmt.Errorf("object has no GVK set") } - o.SetFinalizers(append(f, finalizer)) -} -// RemoveFinalizer from the supplied k8s object's metadata. -func RemoveFinalizer(o metav1.Object, finalizer string) { - f := o.GetFinalizers() - for i, e := range f { - if e == finalizer { - f = append(f[:i], f[i+1:]...) - } + patch := map[string]interface{}{ + "apiVersion": gvk.GroupVersion().String(), + "kind": gvk.Kind, + "metadata": map[string]interface{}{ + "name": obj.GetName(), + "namespace": obj.GetNamespace(), + "finalizers": finalizers, + }, } - o.SetFinalizers(f) + return json.Marshal(patch) } // FinalizerExists checks whether a certain finalizer is already set diff --git a/pkg/reconcilers/resource/finalizer_test.go b/pkg/reconcilers/resource/finalizer_test.go deleted file mode 100644 index 9ce78e51..00000000 --- a/pkg/reconcilers/resource/finalizer_test.go +++ /dev/null @@ -1,190 +0,0 @@ -/* -Copyright 2024 Nokia. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ - -package resource - -import ( - "testing" - - "github.com/google/go-cmp/cmp" - corev1 "k8s.io/api/core/v1" - metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" -) - -func TestAddFinalizer(t *testing.T) { - finalizer := "fin" - funalizer := "fun" - - type args struct { - o metav1.Object - finalizer string - } - - cases := map[string]struct { - args args - want []string - }{ - "NoExistingFinalizers": { - args: args{ - o: &corev1.Pod{}, - finalizer: finalizer, - }, - want: []string{finalizer}, - }, - "FinalizerAlreadyExists": { - args: args{ - o: &corev1.Pod{ - ObjectMeta: metav1.ObjectMeta{ - Finalizers: []string{finalizer}, - }, - }, - finalizer: finalizer, - }, - want: []string{finalizer}, - }, - "AnotherFinalizerExists": { - args: args{ - o: &corev1.Pod{ - ObjectMeta: metav1.ObjectMeta{ - Finalizers: []string{funalizer}, - }, - }, - finalizer: finalizer, - }, - want: []string{funalizer, finalizer}, - }, - } - - for name, tc := range cases { - t.Run(name, func(t *testing.T) { - AddFinalizer(tc.args.o, tc.args.finalizer) - - got := tc.args.o.GetFinalizers() - if diff := cmp.Diff(tc.want, got); diff != "" { - t.Errorf("tc.args.o.GetFinalizers(...): -want, +got:\n%s", diff) - } - }) - } -} - -func TestRemoveFinalizer(t *testing.T) { - finalizer := "fin" - funalizer := "fun" - - type args struct { - o metav1.Object - finalizer string - } - - cases := map[string]struct { - args args - want []string - }{ - "NoExistingFinalizers": { - args: args{ - o: &corev1.Pod{}, - finalizer: finalizer, - }, - want: nil, - }, - "FinalizerExists": { - args: args{ - o: &corev1.Pod{ - ObjectMeta: metav1.ObjectMeta{ - Finalizers: []string{finalizer}, - }, - }, - finalizer: finalizer, - }, - want: []string{}, - }, - "AnotherFinalizerExists": { - args: args{ - o: &corev1.Pod{ - ObjectMeta: metav1.ObjectMeta{ - Finalizers: []string{finalizer, funalizer}, - }, - }, - finalizer: finalizer, - }, - want: []string{funalizer}, - }, - } - - for name, tc := range cases { - t.Run(name, func(t *testing.T) { - RemoveFinalizer(tc.args.o, tc.args.finalizer) - - got := tc.args.o.GetFinalizers() - if diff := cmp.Diff(tc.want, got); diff != "" { - t.Errorf("tc.args.o.GetFinalizers(...): -want, +got:\n%s", diff) - } - }) - } -} - -func TestFinalizerExists(t *testing.T) { - finalizer := "fin" - funalizer := "fun" - - type args struct { - o metav1.Object - finalizer string - } - - cases := map[string]struct { - args args - want bool - }{ - "NoExistingFinalizers": { - args: args{ - o: &corev1.Pod{}, - finalizer: finalizer, - }, - want: false, - }, - "FinalizerExists": { - args: args{ - o: &corev1.Pod{ - ObjectMeta: metav1.ObjectMeta{ - Finalizers: []string{finalizer}, - }, - }, - finalizer: finalizer, - }, - want: true, - }, - "AnotherFinalizerExists": { - args: args{ - o: &corev1.Pod{ - ObjectMeta: metav1.ObjectMeta{ - Finalizers: []string{funalizer}, - }, - }, - finalizer: finalizer, - }, - want: false, - }, - } - - for name, tc := range cases { - t.Run(name, func(t *testing.T) { - if diff := cmp.Diff(tc.want, FinalizerExists(tc.args.o, tc.args.finalizer)); diff != "" { - t.Errorf("tc.args.o.GetFinalizers(...): -want, +got:\n%s", diff) - } - }) - } -} diff --git a/pkg/reconcilers/rollout/reconciler.go b/pkg/reconcilers/rollout/reconciler.go index 00734887..4fd8847c 100644 --- a/pkg/reconcilers/rollout/reconciler.go +++ b/pkg/reconcilers/rollout/reconciler.go @@ -56,6 +56,7 @@ func init() { const ( crName = "rollout" + fieldmanagerfinalizer = "RolloutControllerFinalizer" reconcilerName = "RolloutController" finalizer = "rollout.inv.sdcio.dev/finalizer" // errors @@ -72,7 +73,7 @@ func (r *reconciler) SetupWithManager(ctx context.Context, mgr ctrl.Manager, c i } r.client = mgr.GetClient() - r.finalizer = resource.NewAPIFinalizer(mgr.GetClient(), finalizer, reconcilerName) + r.finalizer = resource.NewAPIFinalizer(mgr.GetClient(), finalizer, fieldmanagerfinalizer) // initializes the directory r.workspaceReader, err = workspacereader.NewReader( cfg.WorkspaceDir, diff --git a/pkg/reconcilers/schema/reconciler.go b/pkg/reconcilers/schema/reconciler.go index ef109ec8..34b2e288 100644 --- a/pkg/reconcilers/schema/reconciler.go +++ b/pkg/reconcilers/schema/reconciler.go @@ -54,6 +54,7 @@ func init() { const ( crName = "schema" + fieldmanagerfinalizer = "SchemaControllerFinalizer" reconcilerName = "SchemaController" finalizer = "schema.inv.sdcio.dev/finalizer" // errors @@ -70,7 +71,7 @@ func (r *reconciler) SetupWithManager(ctx context.Context, mgr ctrl.Manager, c i } r.client = mgr.GetClient() - r.finalizer = resource.NewAPIFinalizer(mgr.GetClient(), finalizer, reconcilerName) + r.finalizer = resource.NewAPIFinalizer(mgr.GetClient(), finalizer, fieldmanagerfinalizer) // initializes the directory r.schemaBasePath = cfg.SchemaDir r.schemaLoader, err = schemaloader.NewLoader( diff --git a/pkg/reconcilers/subscription/reconciler.go b/pkg/reconcilers/subscription/reconciler.go index 9fc69b32..77a39f0e 100644 --- a/pkg/reconcilers/subscription/reconciler.go +++ b/pkg/reconcilers/subscription/reconciler.go @@ -45,9 +45,10 @@ func init() { } const ( - crName = "subscription" - reconcilerName = "SubscriptionController" - finalizer = "subscription.inv.sdcio.dev/finalizer" + crName = "subscription" + fieldmanagerfinalizer = "SubscriptionControllerFinalizer" + reconcilerName = "SubscriptionController" + finalizer = "subscription.inv.sdcio.dev/finalizer" // errors errGetCr = "cannot get cr" errUpdateDataStore = "cannot update datastore" @@ -62,7 +63,7 @@ func (r *reconciler) SetupWithManager(ctx context.Context, mgr ctrl.Manager, c i } r.client = mgr.GetClient() - r.finalizer = resource.NewAPIFinalizer(mgr.GetClient(), finalizer, reconcilerName) + r.finalizer = resource.NewAPIFinalizer(mgr.GetClient(), finalizer, fieldmanagerfinalizer) r.targetMgr = cfg.TargetManager r.recorder = mgr.GetEventRecorder(reconcilerName) diff --git a/pkg/reconcilers/target/reconciler.go b/pkg/reconcilers/target/reconciler.go index 07759a2d..4c248d50 100644 --- a/pkg/reconcilers/target/reconciler.go +++ b/pkg/reconcilers/target/reconciler.go @@ -41,9 +41,10 @@ func init() { } const ( - crName = "target" - reconcilerName = "TargetController" - finalizer = "target.inv.sdcio.dev/finalizer" + crName = "target" + fieldmanagerfinalizer = "TargetControllerFinalizer" + reconcilerName = "TargetController" + finalizer = "target.inv.sdcio.dev/finalizer" // errors errGetCr = "cannot get cr" errUpdateDataStore = "cannot update datastore" @@ -53,7 +54,7 @@ const ( // SetupWithManager sets up the controller with the Manager. func (r *reconciler) SetupWithManager(ctx context.Context, mgr ctrl.Manager, c interface{}) (map[schema.GroupVersionKind]chan event.GenericEvent, error) { r.client = mgr.GetClient() - r.finalizer = resource.NewAPIFinalizer(mgr.GetClient(), finalizer, reconcilerName) + r.finalizer = resource.NewAPIFinalizer(mgr.GetClient(), finalizer, fieldmanagerfinalizer) r.recorder = mgr.GetEventRecorder(reconcilerName) return nil, ctrl.NewControllerManagedBy(mgr). diff --git a/pkg/reconcilers/targetconfig/reconciler.go b/pkg/reconcilers/targetconfig/reconciler.go index 9f554353..5e4b6ce5 100644 --- a/pkg/reconcilers/targetconfig/reconciler.go +++ b/pkg/reconcilers/targetconfig/reconciler.go @@ -45,7 +45,7 @@ func init() { const ( crName = "targetconfig" - fieldmanagerfinalizer = "targetconfigfinalizer" + fieldmanagerfinalizer = "TargetConfigControllerFinalizer" reconcilerName = "TargetConfigController" finalizer = "targetconfig.inv.sdcio.dev/finalizer" // errors @@ -71,7 +71,7 @@ func (r *reconciler) SetupWithManager(ctx context.Context, mgr ctrl.Manager, c i } r.client = mgr.GetClient() - r.finalizer = resource.NewAPIFinalizer(mgr.GetClient(), finalizer, reconcilerName) + r.finalizer = resource.NewAPIFinalizer(mgr.GetClient(), finalizer, fieldmanagerfinalizer) r.targetMgr = cfg.TargetManager r.recorder = mgr.GetEventRecorder(reconcilerName) r.transactor = targetmanager.NewTransactor(r.client, "transactor") diff --git a/pkg/reconcilers/targetdatastore/reconciler.go b/pkg/reconcilers/targetdatastore/reconciler.go index 4f3f5127..6ec7ff38 100644 --- a/pkg/reconcilers/targetdatastore/reconciler.go +++ b/pkg/reconcilers/targetdatastore/reconciler.go @@ -52,6 +52,7 @@ func init() { const ( crName = "targetdatastore" + fieldmanagerfinalizer = "TargetDataStoreControllerFinalizer" reconcilerName = "TargetDataStoreController" finalizer = "targetdatastore.inv.sdcio.dev/finalizer" // errors @@ -75,7 +76,7 @@ func (r *reconciler) SetupWithManager(ctx context.Context, mgr ctrl.Manager, c i } r.client = mgr.GetClient() - r.finalizer = resource.NewAPIFinalizer(mgr.GetClient(), finalizer, reconcilerName) + r.finalizer = resource.NewAPIFinalizer(mgr.GetClient(), finalizer, fieldmanagerfinalizer) r.targetMgr = cfg.TargetManager r.recorder = mgr.GetEventRecorder(reconcilerName) diff --git a/pkg/reconcilers/targetrecovery/reconciler.go b/pkg/reconcilers/targetrecovery/reconciler.go index 171bff23..b023eaea 100644 --- a/pkg/reconcilers/targetrecovery/reconciler.go +++ b/pkg/reconcilers/targetrecovery/reconciler.go @@ -47,7 +47,7 @@ func init() { const ( crName = "targetrecoveryconfig" - fieldmanagerfinalizer = "targetrecoveryconfigfinalizer" + fieldmanagerfinalizer = "TargetRecoveryConfigControllerFinalizer" reconcilerName = "TargetRecoveryConfigController" finalizer = "targetrecoveryserver.inv.sdcio.dev/finalizer" // errors @@ -74,7 +74,7 @@ func (r *reconciler) SetupWithManager(ctx context.Context, mgr ctrl.Manager, c i } r.client = mgr.GetClient() - r.finalizer = resource.NewAPIFinalizer(mgr.GetClient(), finalizer, reconcilerName) + r.finalizer = resource.NewAPIFinalizer(mgr.GetClient(), finalizer, fieldmanagerfinalizer) r.targetMgr = cfg.TargetManager r.recorder = mgr.GetEventRecorder(reconcilerName) r.transactor = targetmanager.NewTransactor(r.client, "transactor") diff --git a/pkg/reconcilers/workspace/reconciler.go b/pkg/reconcilers/workspace/reconciler.go index 2669bb06..2510dabf 100644 --- a/pkg/reconcilers/workspace/reconciler.go +++ b/pkg/reconcilers/workspace/reconciler.go @@ -48,9 +48,10 @@ func init() { } const ( - crName = "workspace" - reconcilerName = "WorkspaceController" - finalizer = "workspace.inv.sdcio.dev/finalizer" + crName = "workspace" + fieldmanagerfinalizer = "WorkspaceControllerFinalizer" + reconcilerName = "WorkspaceController" + finalizer = "workspace.inv.sdcio.dev/finalizer" // errors errGetCr = "cannot get cr" errUpdateDataStore = "cannot update datastore" @@ -66,7 +67,7 @@ func (r *reconciler) SetupWithManager(ctx context.Context, mgr ctrl.Manager, c i } r.client = mgr.GetClient() - r.finalizer = resource.NewAPIFinalizer(mgr.GetClient(), finalizer, reconcilerName) + r.finalizer = resource.NewAPIFinalizer(mgr.GetClient(), finalizer, fieldmanagerfinalizer) // initializes the directory r.workspaceLoader, err = workspaceloader.NewLoader( cfg.WorkspaceDir, From 2cb73290473b6a4334ce1554ec8150f09fa9656b Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Sun, 1 Mar 2026 16:30:25 +0100 Subject: [PATCH 076/135] updated target discovery ssa and finalizer updates --- artifacts/rbac-cluster-role-api-server.yaml | 2 +- artifacts/rbac-cluster-role-controller.yaml | 2 +- ...c-cluster-role-data-server-controller.yaml | 2 +- pkg/reconcilers/resource/finalizer.go | 63 +++++++------------ 4 files changed, 25 insertions(+), 44 deletions(-) diff --git a/artifacts/rbac-cluster-role-api-server.yaml b/artifacts/rbac-cluster-role-api-server.yaml index 037ee431..96501375 100644 --- a/artifacts/rbac-cluster-role-api-server.yaml +++ b/artifacts/rbac-cluster-role-api-server.yaml @@ -6,7 +6,7 @@ rules: - apiGroups: [""] resources: ["namespaces", "secrets", "configmaps", "services", "pods"] verbs: ["get", "watch", "list"] -- apiGroups: [""] +- apiGroups: ["events.k8s.io"] resources: ["events"] verbs: ["create", "patch"] - apiGroups: ["admissionregistration.k8s.io"] diff --git a/artifacts/rbac-cluster-role-controller.yaml b/artifacts/rbac-cluster-role-controller.yaml index 6ca7e1e3..7e2620d5 100644 --- a/artifacts/rbac-cluster-role-controller.yaml +++ b/artifacts/rbac-cluster-role-controller.yaml @@ -6,7 +6,7 @@ rules: - apiGroups: [""] resources: ["namespaces", "secrets", "services", "pods"] verbs: ["get", "watch", "list"] -- apiGroups: [""] +- apiGroups: ["events.k8s.io"] resources: ["events"] verbs: ["create", "patch"] - apiGroups: ["admissionregistration.k8s.io"] diff --git a/artifacts/rbac-cluster-role-data-server-controller.yaml b/artifacts/rbac-cluster-role-data-server-controller.yaml index c4989d32..21f54023 100644 --- a/artifacts/rbac-cluster-role-data-server-controller.yaml +++ b/artifacts/rbac-cluster-role-data-server-controller.yaml @@ -6,7 +6,7 @@ rules: - apiGroups: [""] resources: ["namespaces", "secrets", "services", "pods"] verbs: ["get", "watch", "list"] -- apiGroups: [""] +- apiGroups: ["events.k8s.io"] resources: ["events"] verbs: ["create", "patch"] - apiGroups: ["admissionregistration.k8s.io"] diff --git a/pkg/reconcilers/resource/finalizer.go b/pkg/reconcilers/resource/finalizer.go index b1d35cd0..92848f3d 100644 --- a/pkg/reconcilers/resource/finalizer.go +++ b/pkg/reconcilers/resource/finalizer.go @@ -18,87 +18,68 @@ package resource import ( "context" - "encoding/json" - "fmt" + "github.com/pkg/errors" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" - "k8s.io/apimachinery/pkg/types" "sigs.k8s.io/controller-runtime/pkg/client" ) -// Finalizer manages the lifecycle of the finalizer on a k8s object type Finalizer interface { AddFinalizer(ctx context.Context, obj client.Object) error RemoveFinalizer(ctx context.Context, obj client.Object) error } -// An APIFinalizer manages the lifecycle of a finalizer on a k8s object. type APIFinalizer struct { client client.Client reconcilerName string finalizer string } -// NewAPIFinalizer returns a new APIFinalizer. func NewAPIFinalizer(c client.Client, finalizer, reconcilerName string) *APIFinalizer { return &APIFinalizer{client: c, finalizer: finalizer, reconcilerName: reconcilerName} } -// AddFinalizer to the supplied Managed resource. func (r *APIFinalizer) AddFinalizer(ctx context.Context, obj client.Object) error { if FinalizerExists(obj, r.finalizer) { return nil } - patch, err := r.finalizerPatch(obj, []string{r.finalizer}) - if err != nil { - return fmt.Errorf("cannot build finalizer patch: %w", err) - } - return r.client.Patch(ctx, obj, client.RawPatch(types.ApplyPatchType, patch), client.ForceOwnership, &client.PatchOptions{ - FieldManager: r.reconcilerName, - }) + addFinalizer(obj, r.finalizer) + return errors.Wrap(r.client.Update(ctx, obj), errUpdateObject) } func (r *APIFinalizer) RemoveFinalizer(ctx context.Context, obj client.Object) error { if !FinalizerExists(obj, r.finalizer) { return nil } - patch, err := r.finalizerPatch(obj, nil) - if err != nil { - return fmt.Errorf("cannot build finalizer patch: %w", err) - } - return r.client.Patch(ctx, obj, client.RawPatch(types.ApplyPatchType, patch), client.ForceOwnership, &client.PatchOptions{ - FieldManager: r.reconcilerName, - }) + removeFinalizer(obj, r.finalizer) + return errors.Wrap(r.client.Update(ctx, obj), errUpdateObject) } -// finalizerPatch builds a minimal SSA patch containing only apiVersion, kind, metadata.name, -// metadata.namespace, and metadata.finalizers. -func (r *APIFinalizer) finalizerPatch(obj client.Object, finalizers []string) ([]byte, error) { - gvk := obj.GetObjectKind().GroupVersionKind() - if gvk.Empty() { - return nil, fmt.Errorf("object has no GVK set") +func addFinalizer(o metav1.Object, finalizer string) { + f := o.GetFinalizers() + for _, e := range f { + if e == finalizer { + return + } } + o.SetFinalizers(append(f, finalizer)) +} - patch := map[string]interface{}{ - "apiVersion": gvk.GroupVersion().String(), - "kind": gvk.Kind, - "metadata": map[string]interface{}{ - "name": obj.GetName(), - "namespace": obj.GetNamespace(), - "finalizers": finalizers, - }, +func removeFinalizer(o metav1.Object, finalizer string) { + var result []string + for _, e := range o.GetFinalizers() { + if e != finalizer { + result = append(result, e) + } } - return json.Marshal(patch) + o.SetFinalizers(result) } -// FinalizerExists checks whether a certain finalizer is already set -// on the aupplied object func FinalizerExists(o metav1.Object, finalizer string) bool { - f := o.GetFinalizers() - for _, e := range f { + for _, e := range o.GetFinalizers() { if e == finalizer { return true } } return false -} +} \ No newline at end of file From 01750043dfd159209fccc56ba48fce36ff0543c3 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Sun, 1 Mar 2026 17:14:22 +0100 Subject: [PATCH 077/135] ssa for target finalizer --- apis/config/v1alpha1/generated.pb.go | 349 +++++++++++++++++- apis/config/v1alpha1/generated.proto | 2 +- pkg/reconcilers/configset/reconciler.go | 14 +- pkg/reconcilers/discoveryrule/reconciler.go | 21 +- pkg/reconcilers/resource/finalizer.go | 61 ++- pkg/reconcilers/rollout/reconciler.go | 22 +- pkg/reconcilers/schema/reconciler.go | 20 +- pkg/reconcilers/subscription/reconciler.go | 14 +- pkg/reconcilers/target/reconciler.go | 14 +- pkg/reconcilers/targetconfig/reconciler.go | 17 +- pkg/reconcilers/targetdatastore/reconciler.go | 20 +- pkg/reconcilers/targetrecovery/reconciler.go | 14 +- pkg/reconcilers/workspace/reconciler.go | 14 +- 13 files changed, 522 insertions(+), 60 deletions(-) diff --git a/apis/config/v1alpha1/generated.pb.go b/apis/config/v1alpha1/generated.pb.go index 4aee6b04..ff825809 100644 --- a/apis/config/v1alpha1/generated.pb.go +++ b/apis/config/v1alpha1/generated.pb.go @@ -30,6 +30,10 @@ import ( strings "strings" ) +func (m *LocalObjectReference) Reset() { *m = LocalObjectReference{} } + +func (m *SecretKeySelector) Reset() { *m = SecretKeySelector{} } + func (m *Config) Reset() { *m = Config{} } func (m *ConfigBlame) Reset() { *m = ConfigBlame{} } @@ -104,6 +108,82 @@ func (m *TargetStatus) Reset() { *m = TargetStatus{} } func (m *TargetStatusUsedReferences) Reset() { *m = TargetStatusUsedReferences{} } +func (m *LocalObjectReference) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *LocalObjectReference) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *LocalObjectReference) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + i -= len(m.Name) + copy(dAtA[i:], m.Name) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Name))) + i-- + dAtA[i] = 0xa + return len(dAtA) - i, nil +} + +func (m *SecretKeySelector) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *SecretKeySelector) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *SecretKeySelector) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + if m.Optional != nil { + i-- + if *m.Optional { + dAtA[i] = 1 + } else { + dAtA[i] = 0 + } + i-- + dAtA[i] = 0x18 + } + i -= len(m.Key) + copy(dAtA[i:], m.Key) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Key))) + i-- + dAtA[i] = 0x12 + { + size, err := m.LocalObjectReference.MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintGenerated(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0xa + return len(dAtA) - i, nil +} + func (m *Config) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) @@ -1843,6 +1923,32 @@ func encodeVarintGenerated(dAtA []byte, offset int, v uint64) int { dAtA[offset] = uint8(v) return base } +func (m *LocalObjectReference) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + l = len(m.Name) + n += 1 + l + sovGenerated(uint64(l)) + return n +} + +func (m *SecretKeySelector) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + l = m.LocalObjectReference.Size() + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.Key) + n += 1 + l + sovGenerated(uint64(l)) + if m.Optional != nil { + n += 2 + } + return n +} func (m *Config) Size() (n int) { if m == nil { @@ -2455,7 +2561,28 @@ func sovGenerated(x uint64) (n int) { func sozGenerated(x uint64) (n int) { return sovGenerated(uint64((x << 1) ^ uint64((int64(x) >> 63)))) } - +func (this *LocalObjectReference) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&LocalObjectReference{`, + `Name:` + fmt.Sprintf("%v", this.Name) + `,`, + `}`, + }, "") + return s +} +func (this *SecretKeySelector) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&SecretKeySelector{`, + `LocalObjectReference:` + strings.Replace(strings.Replace(this.LocalObjectReference.String(), "LocalObjectReference", "LocalObjectReference", 1), `&`, ``, 1) + `,`, + `Key:` + fmt.Sprintf("%v", this.Key) + `,`, + `Optional:` + valueToStringGenerated(this.Optional) + `,`, + `}`, + }, "") + return s +} func (this *Config) String() string { if this == nil { return "nil" @@ -2593,7 +2720,7 @@ func (this *ConfigSetSpec) String() string { } repeatedStringForConfig += "}" s := strings.Join([]string{`&ConfigSetSpec{`, - `Target:` + strings.Replace(strings.Replace(this.Target.String(), "Target", "Target", 1), `&`, ``, 1) + `,`, + `Target:` + strings.Replace(strings.Replace(this.Target.String(), "ConfigSetTarget", "ConfigSetTarget", 1), `&`, ``, 1) + `,`, `Lifecycle:` + strings.Replace(this.Lifecycle.String(), "Lifecycle", "Lifecycle", 1) + `,`, `Priority:` + fmt.Sprintf("%v", this.Priority) + `,`, `Revertive:` + valueToStringGenerated(this.Revertive) + `,`, @@ -2953,6 +3080,224 @@ func valueToStringGenerated(v interface{}) string { pv := reflect.Indirect(rv).Interface() return fmt.Sprintf("*%v", pv) } +func (m *LocalObjectReference) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: LocalObjectReference: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: LocalObjectReference: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return ErrInvalidLengthGenerated + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Name = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *SecretKeySelector) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: SecretKeySelector: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: SecretKeySelector: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field LocalObjectReference", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return ErrInvalidLengthGenerated + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.LocalObjectReference.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Key", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return ErrInvalidLengthGenerated + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Key = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 3: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Optional", wireType) + } + var v int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + b := bool(v != 0) + m.Optional = &b + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} func (m *Config) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 diff --git a/apis/config/v1alpha1/generated.proto b/apis/config/v1alpha1/generated.proto index 524e4669..4f043868 100644 --- a/apis/config/v1alpha1/generated.proto +++ b/apis/config/v1alpha1/generated.proto @@ -137,7 +137,7 @@ message ConfigSetList { // ConfigSetSpec defines the desired state of Config message ConfigSetSpec { // Targets defines the targets on which this configSet applies - optional Target target = 1; + optional ConfigSetTarget target = 1; // Lifecycle determines the lifecycle policies the resource e.g. delete is orphan or delete // will follow diff --git a/pkg/reconcilers/configset/reconciler.go b/pkg/reconcilers/configset/reconciler.go index 20157443..f67ce255 100644 --- a/pkg/reconcilers/configset/reconciler.go +++ b/pkg/reconcilers/configset/reconciler.go @@ -36,6 +36,7 @@ import ( "github.com/sdcio/config-server/pkg/reconcilers/resource" corev1 "k8s.io/api/core/v1" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/runtime" "k8s.io/apimachinery/pkg/runtime/schema" "k8s.io/apimachinery/pkg/types" "k8s.io/client-go/tools/events" @@ -64,7 +65,18 @@ const ( func (r *reconciler) SetupWithManager(ctx context.Context, mgr ctrl.Manager, c interface{}) (map[schema.GroupVersionKind]chan event.GenericEvent, error) { r.client = mgr.GetClient() - r.finalizer = resource.NewAPIFinalizer(mgr.GetClient(), finalizer, fieldmanagerfinalizer) + r.finalizer = resource.NewAPIFinalizer( + mgr.GetClient(), + finalizer, + fieldmanagerfinalizer, + func(name, namespace string, finalizers ...string) runtime.ApplyConfiguration { + ac := configv1alpha1apply.ConfigSet(name, namespace) + if len(finalizers) > 0 { + ac.WithFinalizers(finalizers...) + } + return ac + }, + ) r.recorder = mgr.GetEventRecorder(reconcilerName) return nil, ctrl.NewControllerManagedBy(mgr). diff --git a/pkg/reconcilers/discoveryrule/reconciler.go b/pkg/reconcilers/discoveryrule/reconciler.go index 7dd5ed54..70a39ee5 100644 --- a/pkg/reconcilers/discoveryrule/reconciler.go +++ b/pkg/reconcilers/discoveryrule/reconciler.go @@ -35,6 +35,7 @@ import ( "github.com/sdcio/config-server/pkg/reconcilers/resource" corev1 "k8s.io/api/core/v1" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/runtime" "k8s.io/apimachinery/pkg/runtime/schema" "k8s.io/client-go/tools/events" ctrl "sigs.k8s.io/controller-runtime" @@ -47,9 +48,10 @@ func init() { } const ( - crName = "discoveryrule" - reconcilerName = "DiscoveryRuleController" - finalizer = "discoveryrule.inv.sdcio.dev/finalizer" + crName = "discoveryrule" + fieldmanagerfinalizer = "DiscoveryRuleController-finalizer" + reconcilerName = "DiscoveryRuleController" + finalizer = "discoveryrule.inv.sdcio.dev/finalizer" // errors errGetCr = "cannot get cr" errUpdateStatus = "cannot update status" @@ -63,7 +65,18 @@ func (r *reconciler) SetupWithManager(ctx context.Context, mgr ctrl.Manager, c i } r.client = mgr.GetClient() - r.finalizer = resource.NewAPIFinalizer(mgr.GetClient(), finalizer, reconcilerName) + r.finalizer = resource.NewAPIFinalizer( + mgr.GetClient(), + finalizer, + fieldmanagerfinalizer, + func(name, namespace string, finalizers ...string) runtime.ApplyConfiguration { + ac := invv1alpha1apply.DiscoveryRule(name, namespace) + if len(finalizers) > 0 { + ac.WithFinalizers(finalizers...) + } + return ac + }, + ) r.discoveryStore = memstore.NewStore[discoveryrule.DiscoveryRule]() r.recorder = mgr.GetEventRecorder(reconcilerName) diff --git a/pkg/reconcilers/resource/finalizer.go b/pkg/reconcilers/resource/finalizer.go index 92848f3d..b99dc225 100644 --- a/pkg/reconcilers/resource/finalizer.go +++ b/pkg/reconcilers/resource/finalizer.go @@ -19,60 +19,55 @@ package resource import ( "context" - "github.com/pkg/errors" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/runtime" "sigs.k8s.io/controller-runtime/pkg/client" ) +// ApplyConfigFn builds a typed apply configuration for the given object. +// When finalizers is non-empty, they should be set on the apply config. +type ApplyConfigFn func(name, namespace string, finalizers ...string) runtime.ApplyConfiguration + type Finalizer interface { - AddFinalizer(ctx context.Context, obj client.Object) error - RemoveFinalizer(ctx context.Context, obj client.Object) error + AddFinalizer(ctx context.Context, obj runtime.ApplyConfiguration) error + RemoveFinalizer(ctx context.Context, obj runtime.ApplyConfiguration) error } type APIFinalizer struct { - client client.Client - reconcilerName string - finalizer string + client client.Client + fieldManager string + finalizer string + buildApply ApplyConfigFn } -func NewAPIFinalizer(c client.Client, finalizer, reconcilerName string) *APIFinalizer { - return &APIFinalizer{client: c, finalizer: finalizer, reconcilerName: reconcilerName} +func NewAPIFinalizer(c client.Client, finalizer, fieldManager string, buildApply ApplyConfigFn) *APIFinalizer { + return &APIFinalizer{ + client: c, + finalizer: finalizer, + fieldManager: fieldManager, + buildApply: buildApply, + } } func (r *APIFinalizer) AddFinalizer(ctx context.Context, obj client.Object) error { if FinalizerExists(obj, r.finalizer) { return nil } - addFinalizer(obj, r.finalizer) - return errors.Wrap(r.client.Update(ctx, obj), errUpdateObject) + applyConfig := r.buildApply(obj.GetName(), obj.GetNamespace(), r.finalizer) + return r.client.Apply(ctx, applyConfig, &client.ApplyOptions{ + FieldManager: r.fieldManager, + }) } func (r *APIFinalizer) RemoveFinalizer(ctx context.Context, obj client.Object) error { if !FinalizerExists(obj, r.finalizer) { return nil } - removeFinalizer(obj, r.finalizer) - return errors.Wrap(r.client.Update(ctx, obj), errUpdateObject) -} - -func addFinalizer(o metav1.Object, finalizer string) { - f := o.GetFinalizers() - for _, e := range f { - if e == finalizer { - return - } - } - o.SetFinalizers(append(f, finalizer)) -} - -func removeFinalizer(o metav1.Object, finalizer string) { - var result []string - for _, e := range o.GetFinalizers() { - if e != finalizer { - result = append(result, e) - } - } - o.SetFinalizers(result) + // Apply with no finalizers — SSA removes only what this field manager owns + applyConfig := r.buildApply(obj.GetName(), obj.GetNamespace()) + return r.client.Apply(ctx, applyConfig, &client.ApplyOptions{ + FieldManager: r.fieldManager, + }) } func FinalizerExists(o metav1.Object, finalizer string) bool { @@ -82,4 +77,4 @@ func FinalizerExists(o metav1.Object, finalizer string) bool { } } return false -} \ No newline at end of file +} diff --git a/pkg/reconcilers/rollout/reconciler.go b/pkg/reconcilers/rollout/reconciler.go index 4fd8847c..d67120ae 100644 --- a/pkg/reconcilers/rollout/reconciler.go +++ b/pkg/reconcilers/rollout/reconciler.go @@ -40,6 +40,7 @@ import ( workspacereader "github.com/sdcio/config-server/pkg/workspace" corev1 "k8s.io/api/core/v1" k8serrors "k8s.io/apimachinery/pkg/api/errors" + "k8s.io/apimachinery/pkg/runtime" "k8s.io/apimachinery/pkg/runtime/schema" "k8s.io/apimachinery/pkg/types" "k8s.io/client-go/tools/events" @@ -55,10 +56,10 @@ func init() { } const ( - crName = "rollout" - fieldmanagerfinalizer = "RolloutControllerFinalizer" - reconcilerName = "RolloutController" - finalizer = "rollout.inv.sdcio.dev/finalizer" + crName = "rollout" + fieldmanagerfinalizer = "RolloutController-finalizer" + reconcilerName = "RolloutController" + finalizer = "rollout.inv.sdcio.dev/finalizer" // errors errGetCr = "cannot get cr" errUpdateStatus = "cannot update status" @@ -73,7 +74,18 @@ func (r *reconciler) SetupWithManager(ctx context.Context, mgr ctrl.Manager, c i } r.client = mgr.GetClient() - r.finalizer = resource.NewAPIFinalizer(mgr.GetClient(), finalizer, fieldmanagerfinalizer) + r.finalizer = resource.NewAPIFinalizer( + mgr.GetClient(), + finalizer, + fieldmanagerfinalizer, + func(name, namespace string, finalizers ...string) runtime.ApplyConfiguration { + ac := invv1alpha1apply.Rollout(name, namespace) + if len(finalizers) > 0 { + ac.WithFinalizers(finalizers...) + } + return ac + }, + ) // initializes the directory r.workspaceReader, err = workspacereader.NewReader( cfg.WorkspaceDir, diff --git a/pkg/reconcilers/schema/reconciler.go b/pkg/reconcilers/schema/reconciler.go index 34b2e288..5bba3a02 100644 --- a/pkg/reconcilers/schema/reconciler.go +++ b/pkg/reconcilers/schema/reconciler.go @@ -39,6 +39,7 @@ import ( sdcpb "github.com/sdcio/sdc-protos/sdcpb" corev1 "k8s.io/api/core/v1" k8serrors "k8s.io/apimachinery/pkg/api/errors" + "k8s.io/apimachinery/pkg/runtime" "k8s.io/apimachinery/pkg/runtime/schema" "k8s.io/client-go/tools/events" ctrl "sigs.k8s.io/controller-runtime" @@ -53,10 +54,10 @@ func init() { } const ( - crName = "schema" + crName = "schema" fieldmanagerfinalizer = "SchemaControllerFinalizer" - reconcilerName = "SchemaController" - finalizer = "schema.inv.sdcio.dev/finalizer" + reconcilerName = "SchemaController" + finalizer = "schema.inv.sdcio.dev/finalizer" // errors errGetCr = "cannot get cr" errUpdateStatus = "cannot update status" @@ -71,7 +72,18 @@ func (r *reconciler) SetupWithManager(ctx context.Context, mgr ctrl.Manager, c i } r.client = mgr.GetClient() - r.finalizer = resource.NewAPIFinalizer(mgr.GetClient(), finalizer, fieldmanagerfinalizer) + r.finalizer = resource.NewAPIFinalizer( + mgr.GetClient(), + finalizer, + fieldmanagerfinalizer, + func(name, namespace string, finalizers ...string) runtime.ApplyConfiguration { + ac := invv1alpha1apply.Schema(name, namespace) + if len(finalizers) > 0 { + ac.WithFinalizers(finalizers...) + } + return ac + }, + ) // initializes the directory r.schemaBasePath = cfg.SchemaDir r.schemaLoader, err = schemaloader.NewLoader( diff --git a/pkg/reconcilers/subscription/reconciler.go b/pkg/reconcilers/subscription/reconciler.go index 77a39f0e..8df7ca72 100644 --- a/pkg/reconcilers/subscription/reconciler.go +++ b/pkg/reconcilers/subscription/reconciler.go @@ -33,6 +33,7 @@ import ( "github.com/sdcio/config-server/pkg/reconcilers/resource" targetmanager "github.com/sdcio/config-server/pkg/sdc/target/manager" corev1 "k8s.io/api/core/v1" + "k8s.io/apimachinery/pkg/runtime" "k8s.io/apimachinery/pkg/runtime/schema" "k8s.io/client-go/tools/events" ctrl "sigs.k8s.io/controller-runtime" @@ -63,7 +64,18 @@ func (r *reconciler) SetupWithManager(ctx context.Context, mgr ctrl.Manager, c i } r.client = mgr.GetClient() - r.finalizer = resource.NewAPIFinalizer(mgr.GetClient(), finalizer, fieldmanagerfinalizer) + r.finalizer = resource.NewAPIFinalizer( + mgr.GetClient(), + finalizer, + fieldmanagerfinalizer, + func(name, namespace string, finalizers ...string) runtime.ApplyConfiguration { + ac := invv1alpha1apply.Subscription(name, namespace) + if len(finalizers) > 0 { + ac.WithFinalizers(finalizers...) + } + return ac + }, + ) r.targetMgr = cfg.TargetManager r.recorder = mgr.GetEventRecorder(reconcilerName) diff --git a/pkg/reconcilers/target/reconciler.go b/pkg/reconcilers/target/reconciler.go index 4c248d50..b023dc94 100644 --- a/pkg/reconcilers/target/reconciler.go +++ b/pkg/reconcilers/target/reconciler.go @@ -29,6 +29,7 @@ import ( "github.com/sdcio/config-server/pkg/reconcilers/ctrlconfig" "github.com/sdcio/config-server/pkg/reconcilers/resource" corev1 "k8s.io/api/core/v1" + "k8s.io/apimachinery/pkg/runtime" "k8s.io/apimachinery/pkg/runtime/schema" "k8s.io/client-go/tools/events" ctrl "sigs.k8s.io/controller-runtime" @@ -54,7 +55,18 @@ const ( // SetupWithManager sets up the controller with the Manager. func (r *reconciler) SetupWithManager(ctx context.Context, mgr ctrl.Manager, c interface{}) (map[schema.GroupVersionKind]chan event.GenericEvent, error) { r.client = mgr.GetClient() - r.finalizer = resource.NewAPIFinalizer(mgr.GetClient(), finalizer, fieldmanagerfinalizer) + r.finalizer = resource.NewAPIFinalizer( + mgr.GetClient(), + finalizer, + fieldmanagerfinalizer, + func(name, namespace string, finalizers ...string) runtime.ApplyConfiguration { + ac := configv1alpha1apply.Target(name, namespace) + if len(finalizers) > 0 { + ac.WithFinalizers(finalizers...) + } + return ac + }, + ) r.recorder = mgr.GetEventRecorder(reconcilerName) return nil, ctrl.NewControllerManagedBy(mgr). diff --git a/pkg/reconcilers/targetconfig/reconciler.go b/pkg/reconcilers/targetconfig/reconciler.go index 5e4b6ce5..c48af5d5 100644 --- a/pkg/reconcilers/targetconfig/reconciler.go +++ b/pkg/reconcilers/targetconfig/reconciler.go @@ -26,11 +26,13 @@ import ( "github.com/henderiw/logger/log" "github.com/pkg/errors" configv1alpha1 "github.com/sdcio/config-server/apis/config/v1alpha1" + configv1alpha1apply "github.com/sdcio/config-server/pkg/generated/applyconfiguration/config/v1alpha1" "github.com/sdcio/config-server/pkg/reconcilers" "github.com/sdcio/config-server/pkg/reconcilers/ctrlconfig" "github.com/sdcio/config-server/pkg/reconcilers/eventhandler" "github.com/sdcio/config-server/pkg/reconcilers/resource" targetmanager "github.com/sdcio/config-server/pkg/sdc/target/manager" + "k8s.io/apimachinery/pkg/runtime" "k8s.io/apimachinery/pkg/runtime/schema" "k8s.io/client-go/discovery" "k8s.io/client-go/tools/events" @@ -45,7 +47,7 @@ func init() { const ( crName = "targetconfig" - fieldmanagerfinalizer = "TargetConfigControllerFinalizer" + fieldmanagerfinalizer = "TargetDataStoreController-finalizer" reconcilerName = "TargetConfigController" finalizer = "targetconfig.inv.sdcio.dev/finalizer" // errors @@ -71,7 +73,18 @@ func (r *reconciler) SetupWithManager(ctx context.Context, mgr ctrl.Manager, c i } r.client = mgr.GetClient() - r.finalizer = resource.NewAPIFinalizer(mgr.GetClient(), finalizer, fieldmanagerfinalizer) + r.finalizer = resource.NewAPIFinalizer( + mgr.GetClient(), + finalizer, + fieldmanagerfinalizer, + func(name, namespace string, finalizers ...string) runtime.ApplyConfiguration { + ac := configv1alpha1apply.Target(name, namespace) + if len(finalizers) > 0 { + ac.WithFinalizers(finalizers...) + } + return ac + }, + ) r.targetMgr = cfg.TargetManager r.recorder = mgr.GetEventRecorder(reconcilerName) r.transactor = targetmanager.NewTransactor(r.client, "transactor") diff --git a/pkg/reconcilers/targetdatastore/reconciler.go b/pkg/reconcilers/targetdatastore/reconciler.go index 6ec7ff38..3f500515 100644 --- a/pkg/reconcilers/targetdatastore/reconciler.go +++ b/pkg/reconcilers/targetdatastore/reconciler.go @@ -38,6 +38,7 @@ import ( corev1 "k8s.io/api/core/v1" "k8s.io/apimachinery/pkg/api/equality" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/runtime" "k8s.io/apimachinery/pkg/runtime/schema" "k8s.io/apimachinery/pkg/types" "k8s.io/client-go/tools/events" @@ -51,10 +52,10 @@ func init() { } const ( - crName = "targetdatastore" + crName = "targetdatastore" fieldmanagerfinalizer = "TargetDataStoreControllerFinalizer" - reconcilerName = "TargetDataStoreController" - finalizer = "targetdatastore.inv.sdcio.dev/finalizer" + reconcilerName = "TargetDataStoreController" + finalizer = "targetdatastore.inv.sdcio.dev/finalizer" // errors errGetCr = "cannot get cr" errUpdateDataStore = "cannot update datastore" @@ -76,7 +77,18 @@ func (r *reconciler) SetupWithManager(ctx context.Context, mgr ctrl.Manager, c i } r.client = mgr.GetClient() - r.finalizer = resource.NewAPIFinalizer(mgr.GetClient(), finalizer, fieldmanagerfinalizer) + r.finalizer = resource.NewAPIFinalizer( + mgr.GetClient(), + finalizer, + fieldmanagerfinalizer, + func(name, namespace string, finalizers ...string) runtime.ApplyConfiguration { + ac := configv1alpha1apply.Target(name, namespace) + if len(finalizers) > 0 { + ac.WithFinalizers(finalizers...) + } + return ac + }, + ) r.targetMgr = cfg.TargetManager r.recorder = mgr.GetEventRecorder(reconcilerName) diff --git a/pkg/reconcilers/targetrecovery/reconciler.go b/pkg/reconcilers/targetrecovery/reconciler.go index b023eaea..da95f57d 100644 --- a/pkg/reconcilers/targetrecovery/reconciler.go +++ b/pkg/reconcilers/targetrecovery/reconciler.go @@ -32,6 +32,7 @@ import ( "github.com/sdcio/config-server/pkg/reconcilers/resource" targetmanager "github.com/sdcio/config-server/pkg/sdc/target/manager" corev1 "k8s.io/api/core/v1" + "k8s.io/apimachinery/pkg/runtime" "k8s.io/apimachinery/pkg/runtime/schema" "k8s.io/client-go/discovery" "k8s.io/client-go/tools/events" @@ -74,7 +75,18 @@ func (r *reconciler) SetupWithManager(ctx context.Context, mgr ctrl.Manager, c i } r.client = mgr.GetClient() - r.finalizer = resource.NewAPIFinalizer(mgr.GetClient(), finalizer, fieldmanagerfinalizer) + r.finalizer = resource.NewAPIFinalizer( + mgr.GetClient(), + finalizer, + fieldmanagerfinalizer, + func(name, namespace string, finalizers ...string) runtime.ApplyConfiguration { + ac := configv1alpha1apply.Target(name, namespace) + if len(finalizers) > 0 { + ac.WithFinalizers(finalizers...) + } + return ac + }, + ) r.targetMgr = cfg.TargetManager r.recorder = mgr.GetEventRecorder(reconcilerName) r.transactor = targetmanager.NewTransactor(r.client, "transactor") diff --git a/pkg/reconcilers/workspace/reconciler.go b/pkg/reconcilers/workspace/reconciler.go index 2510dabf..2825b80c 100644 --- a/pkg/reconcilers/workspace/reconciler.go +++ b/pkg/reconcilers/workspace/reconciler.go @@ -34,6 +34,7 @@ import ( workspaceloader "github.com/sdcio/config-server/pkg/workspace" corev1 "k8s.io/api/core/v1" k8serrors "k8s.io/apimachinery/pkg/api/errors" + "k8s.io/apimachinery/pkg/runtime" "k8s.io/apimachinery/pkg/runtime/schema" "k8s.io/client-go/tools/events" ctrl "sigs.k8s.io/controller-runtime" @@ -67,7 +68,18 @@ func (r *reconciler) SetupWithManager(ctx context.Context, mgr ctrl.Manager, c i } r.client = mgr.GetClient() - r.finalizer = resource.NewAPIFinalizer(mgr.GetClient(), finalizer, fieldmanagerfinalizer) + r.finalizer = resource.NewAPIFinalizer( + mgr.GetClient(), + finalizer, + fieldmanagerfinalizer, + func(name, namespace string, finalizers ...string) runtime.ApplyConfiguration { + ac := invv1alpha1apply.Workspace(name, namespace) + if len(finalizers) > 0 { + ac.WithFinalizers(finalizers...) + } + return ac + }, + ) // initializes the directory r.workspaceLoader, err = workspaceloader.NewLoader( cfg.WorkspaceDir, From f9bdb85b3e4e2e51c0f4f436af841524fc23ebee Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Sun, 1 Mar 2026 17:17:14 +0100 Subject: [PATCH 078/135] ssa for target finalizer --- apis/config/v1alpha1/generated.pb.go | 345 --------------------------- 1 file changed, 345 deletions(-) diff --git a/apis/config/v1alpha1/generated.pb.go b/apis/config/v1alpha1/generated.pb.go index ff825809..6f553179 100644 --- a/apis/config/v1alpha1/generated.pb.go +++ b/apis/config/v1alpha1/generated.pb.go @@ -30,10 +30,6 @@ import ( strings "strings" ) -func (m *LocalObjectReference) Reset() { *m = LocalObjectReference{} } - -func (m *SecretKeySelector) Reset() { *m = SecretKeySelector{} } - func (m *Config) Reset() { *m = Config{} } func (m *ConfigBlame) Reset() { *m = ConfigBlame{} } @@ -108,81 +104,6 @@ func (m *TargetStatus) Reset() { *m = TargetStatus{} } func (m *TargetStatusUsedReferences) Reset() { *m = TargetStatusUsedReferences{} } -func (m *LocalObjectReference) Marshal() (dAtA []byte, err error) { - size := m.Size() - dAtA = make([]byte, size) - n, err := m.MarshalToSizedBuffer(dAtA[:size]) - if err != nil { - return nil, err - } - return dAtA[:n], nil -} - -func (m *LocalObjectReference) MarshalTo(dAtA []byte) (int, error) { - size := m.Size() - return m.MarshalToSizedBuffer(dAtA[:size]) -} - -func (m *LocalObjectReference) MarshalToSizedBuffer(dAtA []byte) (int, error) { - i := len(dAtA) - _ = i - var l int - _ = l - i -= len(m.Name) - copy(dAtA[i:], m.Name) - i = encodeVarintGenerated(dAtA, i, uint64(len(m.Name))) - i-- - dAtA[i] = 0xa - return len(dAtA) - i, nil -} - -func (m *SecretKeySelector) Marshal() (dAtA []byte, err error) { - size := m.Size() - dAtA = make([]byte, size) - n, err := m.MarshalToSizedBuffer(dAtA[:size]) - if err != nil { - return nil, err - } - return dAtA[:n], nil -} - -func (m *SecretKeySelector) MarshalTo(dAtA []byte) (int, error) { - size := m.Size() - return m.MarshalToSizedBuffer(dAtA[:size]) -} - -func (m *SecretKeySelector) MarshalToSizedBuffer(dAtA []byte) (int, error) { - i := len(dAtA) - _ = i - var l int - _ = l - if m.Optional != nil { - i-- - if *m.Optional { - dAtA[i] = 1 - } else { - dAtA[i] = 0 - } - i-- - dAtA[i] = 0x18 - } - i -= len(m.Key) - copy(dAtA[i:], m.Key) - i = encodeVarintGenerated(dAtA, i, uint64(len(m.Key))) - i-- - dAtA[i] = 0x12 - { - size, err := m.LocalObjectReference.MarshalToSizedBuffer(dAtA[:i]) - if err != nil { - return 0, err - } - i -= size - i = encodeVarintGenerated(dAtA, i, uint64(size)) - } - i-- - dAtA[i] = 0xa - return len(dAtA) - i, nil -} func (m *Config) Marshal() (dAtA []byte, err error) { size := m.Size() @@ -1923,32 +1844,6 @@ func encodeVarintGenerated(dAtA []byte, offset int, v uint64) int { dAtA[offset] = uint8(v) return base } -func (m *LocalObjectReference) Size() (n int) { - if m == nil { - return 0 - } - var l int - _ = l - l = len(m.Name) - n += 1 + l + sovGenerated(uint64(l)) - return n -} - -func (m *SecretKeySelector) Size() (n int) { - if m == nil { - return 0 - } - var l int - _ = l - l = m.LocalObjectReference.Size() - n += 1 + l + sovGenerated(uint64(l)) - l = len(m.Key) - n += 1 + l + sovGenerated(uint64(l)) - if m.Optional != nil { - n += 2 - } - return n -} func (m *Config) Size() (n int) { if m == nil { @@ -2561,28 +2456,6 @@ func sovGenerated(x uint64) (n int) { func sozGenerated(x uint64) (n int) { return sovGenerated(uint64((x << 1) ^ uint64((int64(x) >> 63)))) } -func (this *LocalObjectReference) String() string { - if this == nil { - return "nil" - } - s := strings.Join([]string{`&LocalObjectReference{`, - `Name:` + fmt.Sprintf("%v", this.Name) + `,`, - `}`, - }, "") - return s -} -func (this *SecretKeySelector) String() string { - if this == nil { - return "nil" - } - s := strings.Join([]string{`&SecretKeySelector{`, - `LocalObjectReference:` + strings.Replace(strings.Replace(this.LocalObjectReference.String(), "LocalObjectReference", "LocalObjectReference", 1), `&`, ``, 1) + `,`, - `Key:` + fmt.Sprintf("%v", this.Key) + `,`, - `Optional:` + valueToStringGenerated(this.Optional) + `,`, - `}`, - }, "") - return s -} func (this *Config) String() string { if this == nil { return "nil" @@ -3080,224 +2953,6 @@ func valueToStringGenerated(v interface{}) string { pv := reflect.Indirect(rv).Interface() return fmt.Sprintf("*%v", pv) } -func (m *LocalObjectReference) Unmarshal(dAtA []byte) error { - l := len(dAtA) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - wire |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: LocalObjectReference: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: LocalObjectReference: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - stringLen |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex < 0 { - return ErrInvalidLengthGenerated - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Name = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipGenerated(dAtA[iNdEx:]) - if err != nil { - return err - } - if (skippy < 0) || (iNdEx+skippy) < 0 { - return ErrInvalidLengthGenerated - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *SecretKeySelector) Unmarshal(dAtA []byte) error { - l := len(dAtA) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - wire |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: SecretKeySelector: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: SecretKeySelector: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field LocalObjectReference", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - msglen |= int(b&0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + msglen - if postIndex < 0 { - return ErrInvalidLengthGenerated - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - if err := m.LocalObjectReference.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - case 2: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Key", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - stringLen |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex < 0 { - return ErrInvalidLengthGenerated - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Key = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex - case 3: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field Optional", wireType) - } - var v int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - v |= int(b&0x7F) << shift - if b < 0x80 { - break - } - } - b := bool(v != 0) - m.Optional = &b - default: - iNdEx = preIndex - skippy, err := skipGenerated(dAtA[iNdEx:]) - if err != nil { - return err - } - if (skippy < 0) || (iNdEx+skippy) < 0 { - return ErrInvalidLengthGenerated - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} func (m *Config) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 From fcfe99af691d3e514111712a4a90c45aae08ecc2 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Sun, 1 Mar 2026 17:34:44 +0100 Subject: [PATCH 079/135] ssa for target finalizer --- pkg/reconcilers/configset/reconciler.go | 2 +- pkg/reconcilers/resource/finalizer.go | 2 ++ pkg/reconcilers/schema/reconciler.go | 2 +- pkg/reconcilers/subscription/reconciler.go | 2 +- pkg/reconcilers/target/reconciler.go | 2 +- pkg/reconcilers/targetconfig/reconciler.go | 7 +++++-- pkg/reconcilers/targetdatastore/reconciler.go | 6 +++--- pkg/reconcilers/targetrecovery/reconciler.go | 7 +++++-- 8 files changed, 19 insertions(+), 11 deletions(-) diff --git a/pkg/reconcilers/configset/reconciler.go b/pkg/reconcilers/configset/reconciler.go index f67ce255..b38c22de 100644 --- a/pkg/reconcilers/configset/reconciler.go +++ b/pkg/reconcilers/configset/reconciler.go @@ -52,7 +52,7 @@ func init() { const ( crName = "configset" - fieldmanagerfinalizer = "ConfigSetControllerFinalizer" + fieldmanagerfinalizer = "ConfigSetController-finalizer" reconcilerName = "ConfigSetController" finalizer = "configset.config.sdcio.dev/finalizer" // errors diff --git a/pkg/reconcilers/resource/finalizer.go b/pkg/reconcilers/resource/finalizer.go index b99dc225..5456b9f8 100644 --- a/pkg/reconcilers/resource/finalizer.go +++ b/pkg/reconcilers/resource/finalizer.go @@ -19,6 +19,7 @@ package resource import ( "context" + "github.com/henderiw/logger/log" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/apimachinery/pkg/runtime" "sigs.k8s.io/controller-runtime/pkg/client" @@ -53,6 +54,7 @@ func (r *APIFinalizer) AddFinalizer(ctx context.Context, obj client.Object) erro if FinalizerExists(obj, r.finalizer) { return nil } + log.FromContext(ctx).Info("SSA applying finalizer", "fieldManager", r.fieldManager, "finalizer", r.finalizer) applyConfig := r.buildApply(obj.GetName(), obj.GetNamespace(), r.finalizer) return r.client.Apply(ctx, applyConfig, &client.ApplyOptions{ FieldManager: r.fieldManager, diff --git a/pkg/reconcilers/schema/reconciler.go b/pkg/reconcilers/schema/reconciler.go index 5bba3a02..b62c9959 100644 --- a/pkg/reconcilers/schema/reconciler.go +++ b/pkg/reconcilers/schema/reconciler.go @@ -55,7 +55,7 @@ func init() { const ( crName = "schema" - fieldmanagerfinalizer = "SchemaControllerFinalizer" + fieldmanagerfinalizer = "SchemaController-finalizer" reconcilerName = "SchemaController" finalizer = "schema.inv.sdcio.dev/finalizer" // errors diff --git a/pkg/reconcilers/subscription/reconciler.go b/pkg/reconcilers/subscription/reconciler.go index 8df7ca72..ef6ef11a 100644 --- a/pkg/reconcilers/subscription/reconciler.go +++ b/pkg/reconcilers/subscription/reconciler.go @@ -47,7 +47,7 @@ func init() { const ( crName = "subscription" - fieldmanagerfinalizer = "SubscriptionControllerFinalizer" + fieldmanagerfinalizer = "SubscriptionController-finalizer" reconcilerName = "SubscriptionController" finalizer = "subscription.inv.sdcio.dev/finalizer" // errors diff --git a/pkg/reconcilers/target/reconciler.go b/pkg/reconcilers/target/reconciler.go index b023dc94..8c16f960 100644 --- a/pkg/reconcilers/target/reconciler.go +++ b/pkg/reconcilers/target/reconciler.go @@ -43,7 +43,7 @@ func init() { const ( crName = "target" - fieldmanagerfinalizer = "TargetControllerFinalizer" + fieldmanagerfinalizer = "TargetController-finalizer" reconcilerName = "TargetController" finalizer = "target.inv.sdcio.dev/finalizer" // errors diff --git a/pkg/reconcilers/targetconfig/reconciler.go b/pkg/reconcilers/targetconfig/reconciler.go index c48af5d5..422c6f0f 100644 --- a/pkg/reconcilers/targetconfig/reconciler.go +++ b/pkg/reconcilers/targetconfig/reconciler.go @@ -47,7 +47,7 @@ func init() { const ( crName = "targetconfig" - fieldmanagerfinalizer = "TargetDataStoreController-finalizer" + fieldmanagerfinalizer = "TargetConfigController-finalizer" reconcilerName = "TargetConfigController" finalizer = "targetconfig.inv.sdcio.dev/finalizer" // errors @@ -261,7 +261,10 @@ func (r *reconciler) handleError(ctx context.Context, target *configv1alpha1.Tar log := log.FromContext(ctx) if err != nil { - msg = fmt.Sprintf("%s err %s", msg, err.Error()) + msg = fmt.Sprintf("%q err %q", msg, err.Error()) + } + if len(msg) > 128 { + msg = msg[:128] } log.Warn("config transaction failed", "msg", msg, "err", err) diff --git a/pkg/reconcilers/targetdatastore/reconciler.go b/pkg/reconcilers/targetdatastore/reconciler.go index 3f500515..70d505b8 100644 --- a/pkg/reconcilers/targetdatastore/reconciler.go +++ b/pkg/reconcilers/targetdatastore/reconciler.go @@ -53,7 +53,7 @@ func init() { const ( crName = "targetdatastore" - fieldmanagerfinalizer = "TargetDataStoreControllerFinalizer" + fieldmanagerfinalizer = "TargetDataStoreController-finalizer" reconcilerName = "TargetDataStoreController" finalizer = "targetdatastore.inv.sdcio.dev/finalizer" // errors @@ -261,8 +261,8 @@ func (r *reconciler) handleError(ctx context.Context, target *configv1alpha1.Tar if err != nil { msg = fmt.Sprintf("%q err %q", msg, err.Error()) } - if len(msg) > 256 { - msg = msg[:256] + if len(msg) > 128 { + msg = msg[:128] } newCond := configv1alpha1.TargetDatastoreFailed(msg) diff --git a/pkg/reconcilers/targetrecovery/reconciler.go b/pkg/reconcilers/targetrecovery/reconciler.go index da95f57d..a39d73c9 100644 --- a/pkg/reconcilers/targetrecovery/reconciler.go +++ b/pkg/reconcilers/targetrecovery/reconciler.go @@ -48,7 +48,7 @@ func init() { const ( crName = "targetrecoveryconfig" - fieldmanagerfinalizer = "TargetRecoveryConfigControllerFinalizer" + fieldmanagerfinalizer = "TargetRecoveryConfigController-finalizer" reconcilerName = "TargetRecoveryConfigController" finalizer = "targetrecoveryserver.inv.sdcio.dev/finalizer" // errors @@ -202,7 +202,10 @@ func (r *reconciler) handleError(ctx context.Context, target *configv1alpha1.Tar log := log.FromContext(ctx) if err != nil { - msg = fmt.Sprintf("%s err %s", msg, err.Error()) + msg = fmt.Sprintf("%q err %q", msg, err.Error()) + } + if len(msg) > 128 { + msg = msg[:128] } newCond := configv1alpha1.TargetConfigRecoveryFailed(msg) oldCond := target.GetCondition(configv1alpha1.ConditionTypeTargetConfigRecoveryReady) From 7a72e6b13a87ff96bdd801c072bc54079cf23137 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Sun, 1 Mar 2026 17:57:04 +0100 Subject: [PATCH 080/135] debug ssa --- pkg/reconcilers/targetconfig/reconciler.go | 10 +++++----- pkg/reconcilers/targetdatastore/reconciler.go | 6 +++--- pkg/registry/generic/strategy_resource.go | 7 +++++++ 3 files changed, 15 insertions(+), 8 deletions(-) diff --git a/pkg/reconcilers/targetconfig/reconciler.go b/pkg/reconcilers/targetconfig/reconciler.go index 422c6f0f..07658f88 100644 --- a/pkg/reconcilers/targetconfig/reconciler.go +++ b/pkg/reconcilers/targetconfig/reconciler.go @@ -128,7 +128,7 @@ func (r *reconciler) Reconcile(ctx context.Context, req ctrl.Request) (ctrl.Resu } targetOrig := target.DeepCopy() - if !target.GetDeletionTimestamp().IsZero() { + if !targetOrig.GetDeletionTimestamp().IsZero() { if err := r.transactor.SetConfigsTargetConditionForTarget( ctx, targetOrig, @@ -139,7 +139,7 @@ func (r *reconciler) Reconcile(ctx context.Context, req ctrl.Request) (ctrl.Resu } // remove the finalizer - if err := r.finalizer.RemoveFinalizer(ctx, target); err != nil { + if err := r.finalizer.RemoveFinalizer(ctx, targetOrig); err != nil { return ctrl.Result{Requeue: true}, errors.Wrap(r.handleError(ctx, targetOrig, "cannot delete finalizer", err), errUpdateStatus) } @@ -148,12 +148,12 @@ func (r *reconciler) Reconcile(ctx context.Context, req ctrl.Request) (ctrl.Resu return ctrl.Result{}, nil } - if err := r.finalizer.AddFinalizer(ctx, target); err != nil { + if err := r.finalizer.AddFinalizer(ctx, targetOrig); err != nil { return ctrl.Result{Requeue: true}, errors.Wrap(r.handleError(ctx, targetOrig, "cannot add finalizer", err), errUpdateStatus) } - if !target.IsReady() { + if !targetOrig.IsReady() { err := r.transactor.SetConfigsTargetConditionForTarget( ctx, targetOrig, @@ -205,7 +205,7 @@ func (r *reconciler) Reconcile(ctx context.Context, req ctrl.Request) (ctrl.Resu return ctrl.Result{RequeueAfter: 5 * time.Second}, err } - retry, err := r.transactor.Transact(ctx, target, dsctx, configv1alpha1.TargetForConfigReady("target ready")) + retry, err := r.transactor.Transact(ctx, targetOrig, dsctx, configv1alpha1.TargetForConfigReady("target ready")) if err != nil { log.Warn("config transaction failed", "retry", retry, "err", err) if retry { diff --git a/pkg/reconcilers/targetdatastore/reconciler.go b/pkg/reconcilers/targetdatastore/reconciler.go index 70d505b8..6c2cd818 100644 --- a/pkg/reconcilers/targetdatastore/reconciler.go +++ b/pkg/reconcilers/targetdatastore/reconciler.go @@ -128,10 +128,10 @@ func (r *reconciler) Reconcile(ctx context.Context, req ctrl.Request) (ctrl.Resu targetOrig := target.DeepCopy() - if !target.GetDeletionTimestamp().IsZero() { + if !targetOrig.GetDeletionTimestamp().IsZero() { if len(target.GetFinalizers()) > 1 { // this should be the last finalizer to be removed as this deletes the target from the targetStore - log.Debug("requeue delete, not all finalizers removed", "finalizers", target.GetFinalizers()) + log.Debug("requeue delete, not all finalizers removed", "finalizers", targetOrig.GetFinalizers()) return ctrl.Result{Requeue: true}, errors.Wrap(r.handleError(ctx, targetOrig, "deleting target, not all finalizers removed", nil, true), errUpdateStatus) } @@ -160,7 +160,7 @@ func (r *reconciler) Reconcile(ctx context.Context, req ctrl.Request) (ctrl.Resu // We dont act as long the target is not discoveredReady (ready state is handled by the discovery controller) // Ready -> NotReady: happens only when the discovery fails => we keep the target as is do not delete the datatore/etc - log.Info("target discovery ready condition", "status", target.Status.GetCondition(configv1alpha1.ConditionTypeTargetDiscoveryReady).Status) + log.Info("target discovery ready condition", "status", targetOrig.GetCondition(configv1alpha1.ConditionTypeTargetDiscoveryReady).Status) if target.Status.GetCondition(configv1alpha1.ConditionTypeTargetDiscoveryReady).Status != metav1.ConditionTrue { if r.targetMgr != nil { r.targetMgr.ClearDesired(ctx, targetKey) diff --git a/pkg/registry/generic/strategy_resource.go b/pkg/registry/generic/strategy_resource.go index e726f78f..fa078fe6 100644 --- a/pkg/registry/generic/strategy_resource.go +++ b/pkg/registry/generic/strategy_resource.go @@ -87,6 +87,13 @@ func (r *strategy) Get(ctx context.Context, key types.NamespacedName) (runtime.O if err != nil { return nil, apierrors.NewNotFound(r.gr, key.Name) } + accessor, _ := meta.Accessor(obj) + log.FromContext(ctx).Info("strategy.Get", + "key", key, + "managedFieldsCount", len(accessor.GetManagedFields()), + "labelsCount", len(accessor.GetLabels()), + "finalizersCount", len(accessor.GetFinalizers()), + ) return obj, nil } From 28ae402aee4c6bf06d1904c7397645815fd08cae Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Sun, 1 Mar 2026 18:19:52 +0100 Subject: [PATCH 081/135] update ssa for target --- apis/config/target_resource.go | 46 ----------------------- pkg/reconcilers/resource/finalizer.go | 8 ++++ pkg/registry/generic/strategy_resource.go | 2 +- 3 files changed, 9 insertions(+), 47 deletions(-) diff --git a/apis/config/target_resource.go b/apis/config/target_resource.go index 50ad3fee..d014e434 100644 --- a/apis/config/target_resource.go +++ b/apis/config/target_resource.go @@ -26,7 +26,6 @@ import ( "github.com/sdcio/config-server/apis/condition" apiequality "k8s.io/apimachinery/pkg/api/equality" apierrors "k8s.io/apimachinery/pkg/api/errors" - "k8s.io/apimachinery/pkg/api/meta" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/apimachinery/pkg/fields" "k8s.io/apimachinery/pkg/runtime" @@ -305,50 +304,5 @@ func (r *Target) PrepareForUpdate(ctx context.Context, obj, old runtime.Object) func (r *Target) ValidateUpdate(ctx context.Context, obj, old runtime.Object) field.ErrorList { var allErrs field.ErrorList - newaccessor, err := meta.Accessor(obj) - if err != nil { - allErrs = append(allErrs, field.Invalid( - field.NewPath(""), - obj, - err.Error(), - )) - return allErrs - } - newKey, err := GetTargetKey(newaccessor.GetLabels()) - if err != nil { - allErrs = append(allErrs, field.Invalid( - field.NewPath("metadata.labels"), - obj, - err.Error(), - )) - } - oldaccessor, err := meta.Accessor(old) - if err != nil { - allErrs = append(allErrs, field.Invalid( - field.NewPath(""), - obj, - err.Error(), - )) - return allErrs - } - oldKey, err := GetTargetKey(oldaccessor.GetLabels()) - if err != nil { - allErrs = append(allErrs, field.Invalid( - field.NewPath("metadata.labels"), - obj, - err.Error(), - )) - } - - if len(allErrs) != 0 { - return allErrs - } - if oldKey.String() != newKey.String() { - allErrs = append(allErrs, field.Invalid( - field.NewPath("metadata.labels"), - obj, - fmt.Errorf("target keys are immutable: oldKey: %s, newKey %s", oldKey.String(), newKey.String()).Error(), - )) - } return allErrs } diff --git a/pkg/reconcilers/resource/finalizer.go b/pkg/reconcilers/resource/finalizer.go index 5456b9f8..3d8f0c82 100644 --- a/pkg/reconcilers/resource/finalizer.go +++ b/pkg/reconcilers/resource/finalizer.go @@ -56,6 +56,10 @@ func (r *APIFinalizer) AddFinalizer(ctx context.Context, obj client.Object) erro } log.FromContext(ctx).Info("SSA applying finalizer", "fieldManager", r.fieldManager, "finalizer", r.finalizer) applyConfig := r.buildApply(obj.GetName(), obj.GetNamespace(), r.finalizer) + + + log.FromContext(ctx).Info("SSA applying finalizer", "fieldManager", r.fieldManager, "applyConfig", applyConfig) + return r.client.Apply(ctx, applyConfig, &client.ApplyOptions{ FieldManager: r.fieldManager, }) @@ -67,6 +71,10 @@ func (r *APIFinalizer) RemoveFinalizer(ctx context.Context, obj client.Object) e } // Apply with no finalizers — SSA removes only what this field manager owns applyConfig := r.buildApply(obj.GetName(), obj.GetNamespace()) + + + log.FromContext(ctx).Info("SSA removing finalizer", "fieldManager", r.fieldManager, "applyConfig", applyConfig) + return r.client.Apply(ctx, applyConfig, &client.ApplyOptions{ FieldManager: r.fieldManager, }) diff --git a/pkg/registry/generic/strategy_resource.go b/pkg/registry/generic/strategy_resource.go index fa078fe6..26a7083e 100644 --- a/pkg/registry/generic/strategy_resource.go +++ b/pkg/registry/generic/strategy_resource.go @@ -138,7 +138,7 @@ func (r *strategy) PrepareForUpdate(ctx context.Context, obj, old runtime.Object r.obj.PrepareForUpdate(ctx, obj, old) } -func (r *strategy) AllowCreateOnUpdate() bool { return false } +func (r *strategy) AllowCreateOnUpdate() bool { return true } func (r *strategy) AllowUnconditionalUpdate() bool { return false } From 6fddf3865712be4e874ce5812bba32caffa7f768 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Sun, 1 Mar 2026 20:00:22 +0100 Subject: [PATCH 082/135] added robustness for discovery --- pkg/discovery/discoveryrule/target.go | 39 ++++++++++++++++----------- pkg/reconcilers/target/reconciler.go | 2 +- 2 files changed, 25 insertions(+), 16 deletions(-) diff --git a/pkg/discovery/discoveryrule/target.go b/pkg/discovery/discoveryrule/target.go index 98224c01..2f46408f 100644 --- a/pkg/discovery/discoveryrule/target.go +++ b/pkg/discovery/discoveryrule/target.go @@ -122,27 +122,31 @@ func (r *dr) applyTargetStatus(ctx context.Context, targetKey types.NamespacedNa // Check current state to avoid unnecessary updates target := &configv1alpha1.Target{} + targetExists := true if err := r.client.Get(ctx, targetKey, target); err != nil { - return nil, err + if client.IgnoreNotFound(err) != nil { + return nil, err + } + // Object just created — cache hasn't synced yet, skip optimization + targetExists = false } - newCond := configv1alpha1.TargetDiscoveryReady() - oldCond := target.GetCondition(configv1alpha1.ConditionTypeTargetDiscoveryReady) - - if newCond.Equal(oldCond) && - equality.Semantic.DeepEqual(di, target.Status.DiscoveryInfo) { - log.Info("applyTargetStatus -> no change") - return target, nil + if targetExists { + newCond := configv1alpha1.TargetDiscoveryReady() + oldCond := target.GetCondition(configv1alpha1.ConditionTypeTargetDiscoveryReady) + if newCond.Equal(oldCond) && + equality.Semantic.DeepEqual(di, target.Status.DiscoveryInfo) { + log.Info("applyTargetStatus -> no change") + return target, nil + } + log.Info("applyTargetStatus", + "condition change", !newCond.Equal(oldCond), + "discovery info change", !equality.Semantic.DeepEqual(di, target.Status.DiscoveryInfo), + ) } - log.Info("applyTargetStatus", - "condition change", !newCond.Equal(oldCond), - "discovery info change", !equality.Semantic.DeepEqual(di, target.Status.DiscoveryInfo), - ) - statusApply := configv1alpha1apply.TargetStatus(). - WithConditions(newCond) - + WithConditions(configv1alpha1.TargetDiscoveryReady()) if di != nil { statusApply = statusApply.WithDiscoveryInfo(discoveryInfoToApply(di)) } @@ -158,6 +162,11 @@ func (r *dr) applyTargetStatus(ctx context.Context, targetKey types.NamespacedNa log.Error("failed to apply target status", "err", err) return nil, err } + + // Re-fetch to return fresh object + if err := r.client.Get(ctx, targetKey, target); err != nil { + return nil, err + } return target, nil } diff --git a/pkg/reconcilers/target/reconciler.go b/pkg/reconcilers/target/reconciler.go index 8c16f960..75008f40 100644 --- a/pkg/reconcilers/target/reconciler.go +++ b/pkg/reconcilers/target/reconciler.go @@ -102,7 +102,7 @@ func (r *reconciler) Reconcile(ctx context.Context, req ctrl.Request) (ctrl.Resu changed, newReady, err := r.updateCondition(ctx, target) if err != nil { - return ctrl.Result{}, pkgerrors.Wrap(err, errUpdateStatus) + return ctrl.Result{RequeueAfter: 5 * time.Second}, pkgerrors.Wrap(err, errUpdateStatus) } // "One more kick": if after computing/updating Ready it is still not ready, From 9cef2fac95bcc7906f3c4ad2b109cfa52f2436d2 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Sun, 1 Mar 2026 20:38:40 +0100 Subject: [PATCH 083/135] update target connection condition robustiness --- pkg/sdc/target/manager/runtime.go | 25 ++++++++++++++++++++++--- 1 file changed, 22 insertions(+), 3 deletions(-) diff --git a/pkg/sdc/target/manager/runtime.go b/pkg/sdc/target/manager/runtime.go index d59dfbff..7da847b5 100644 --- a/pkg/sdc/target/manager/runtime.go +++ b/pkg/sdc/target/manager/runtime.go @@ -587,9 +587,9 @@ func (r *TargetRuntime) pushConnIfChanged(ctx context.Context, connected bool, m r.statusMu.Unlock() return } - r.lastPushed = time.Now() - r.lastConnValid = true - r.lastConn = connected + //we're about to push, but don't mark as "done" yet unless apply succeeds + pushing := connected + pushingMsg := msg r.statusMu.Unlock() target := &configv1alpha1.Target{} @@ -612,9 +612,21 @@ func (r *TargetRuntime) pushConnIfChanged(ctx context.Context, connected bool, m "phase", r.Status().Phase, "msg", msg, ) + // Already correct in storage — mark as pushed so we don't retry needlessly + r.statusMu.Lock() + r.lastConnValid = true + r.lastConn = pushing + r.lastPushed = time.Now() + r.statusMu.Unlock() return } + log.Info("pushConnIfChanged -> applying", + "connected", pushing, + "phase", r.Status().Phase, + "msg", pushingMsg, + ) + applyConfig := configv1alpha1apply.Target(target.Name, target.Namespace). WithStatus(configv1alpha1apply.TargetStatus(). WithConditions(newCond), @@ -629,6 +641,13 @@ func (r *TargetRuntime) pushConnIfChanged(ctx context.Context, connected bool, m return } + // Only mark as successfully pushed AFTER Apply succeeds + r.statusMu.Lock() + r.lastConnValid = true + r.lastConn = pushing + r.lastPushed = time.Now() + r.statusMu.Unlock() + log.Info("pushConnIfChanged -> updated", "connected", connected, "phase", r.Status().Phase, From 0f84ebfafa61a3f356836f761357d66d7afadda2 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Sun, 1 Mar 2026 20:50:59 +0100 Subject: [PATCH 084/135] update target discovery robustness --- pkg/discovery/discoveryrule/target.go | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/pkg/discovery/discoveryrule/target.go b/pkg/discovery/discoveryrule/target.go index 2f46408f..5ab318b8 100644 --- a/pkg/discovery/discoveryrule/target.go +++ b/pkg/discovery/discoveryrule/target.go @@ -42,7 +42,8 @@ const ( func (r *dr) createTarget(ctx context.Context, provider, address string, di *configv1alpha1.DiscoveryInfo) error { log := log.FromContext(ctx) - if err := r.children.Create(ctx, storebackend.ToKey(getTargetName(di.Hostname)), ""); err != nil { + if err := r.children.Apply(ctx, storebackend.ToKey(getTargetName(di.Hostname)), ""); err != nil { + log.Warn("children.apply", "error", err) return err } @@ -52,17 +53,18 @@ func (r *dr) createTarget(ctx context.Context, provider, address string, di *con } if err := r.applyTargetSpec(ctx, targetKey, provider, address); err != nil { - log.Info("dynamic target creation failed", "error", err) + log.Error("dynamic target creation failed", "error", err) return err } target, err := r.applyTargetStatus(ctx, targetKey, di) if err != nil { - log.Info("dynamic target status apply failed", "error", err) + log.Error("dynamic target status apply failed", "error", err) return err } if err := r.applyTargetDeviationCR(ctx, target); err != nil { + log.Error("apply deviation failed", "error", err) return err } From d74e013fe6544efaa05f1868df1e8b95cc7e8ef2 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Sun, 1 Mar 2026 21:06:35 +0100 Subject: [PATCH 085/135] update dr ctx --- pkg/reconcilers/discoveryrule/reconciler.go | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/pkg/reconcilers/discoveryrule/reconciler.go b/pkg/reconcilers/discoveryrule/reconciler.go index 70a39ee5..d79d895c 100644 --- a/pkg/reconcilers/discoveryrule/reconciler.go +++ b/pkg/reconcilers/discoveryrule/reconciler.go @@ -79,6 +79,7 @@ func (r *reconciler) SetupWithManager(ctx context.Context, mgr ctrl.Manager, c i ) r.discoveryStore = memstore.NewStore[discoveryrule.DiscoveryRule]() r.recorder = mgr.GetEventRecorder(reconcilerName) + r.baseCtx = ctx return nil, ctrl.NewControllerManagedBy(mgr). Named(reconcilerName). @@ -95,6 +96,7 @@ type reconciler struct { discoveryStore storebackend.Storer[discoveryrule.DiscoveryRule] recorder events.EventRecorder + baseCtx context.Context // manager-scoped, lives until shutdown } func (r *reconciler) Reconcile(ctx context.Context, req ctrl.Request) (ctrl.Result, error) { @@ -128,7 +130,7 @@ func (r *reconciler) Reconcile(ctx context.Context, req ctrl.Request) (ctrl.Resu return ctrl.Result{}, nil } // stop and delete the discovery rule - dr.Stop(ctx) + dr.Stop(r.baseCtx) if err := r.discoveryStore.Delete(ctx, key); err != nil { return ctrl.Result{Requeue: true}, errors.Wrap(r.handleError(ctx, discoveryRuleOrig, "cannot delete discoveryRule from store", err), errUpdateStatus) @@ -193,7 +195,7 @@ func (r *reconciler) Reconcile(ctx context.Context, req ctrl.Request) (ctrl.Resu } go func() { - if err := dr.Run(ctx); err != nil { + if err := dr.Run(r.baseCtx); err != nil { log.Error("run error", "err", err) } }() From 70383c534088bb0307eb3cc4f697664ec2645e20 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Sun, 1 Mar 2026 21:10:46 +0100 Subject: [PATCH 086/135] fix go lint - unused --- pkg/reconcilers/resource/errors.go | 4 - pkg/registry/configblame/fieldselector.go | 82 --------------------- pkg/registry/runningconfig/fieldselector.go | 82 --------------------- 3 files changed, 168 deletions(-) delete mode 100644 pkg/registry/configblame/fieldselector.go delete mode 100644 pkg/registry/runningconfig/fieldselector.go diff --git a/pkg/reconcilers/resource/errors.go b/pkg/reconcilers/resource/errors.go index 1c6425f8..5706a7cf 100644 --- a/pkg/reconcilers/resource/errors.go +++ b/pkg/reconcilers/resource/errors.go @@ -20,10 +20,6 @@ import ( "k8s.io/apimachinery/pkg/api/errors" ) -const ( - errUpdateObject = "cannot update k8s resource" -) - type ErrorIs func(err error) bool func Ignore(is ErrorIs, err error) error { diff --git a/pkg/registry/configblame/fieldselector.go b/pkg/registry/configblame/fieldselector.go deleted file mode 100644 index ea4b82c8..00000000 --- a/pkg/registry/configblame/fieldselector.go +++ /dev/null @@ -1,82 +0,0 @@ -/* -Copyright 2024 Nokia. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ - -package configblame - -import ( - "context" - "fmt" - - apierrors "k8s.io/apimachinery/pkg/api/errors" - "k8s.io/apimachinery/pkg/fields" - "k8s.io/apimachinery/pkg/selection" - genericapirequest "k8s.io/apiserver/pkg/endpoints/request" -) - -// Filter -type Filter struct { - // Name filters by the name of the objects - Name string - - // Namespace filters by the namespace of the objects - Namespace string -} - -// parseFieldSelector parses client-provided fields.Selector into a packageFilter -func parseFieldSelector(ctx context.Context, fieldSelector fields.Selector) (*Filter, error) { - var filter *Filter - - // add the namespace to the list - namespace, ok := genericapirequest.NamespaceFrom(ctx) - if fieldSelector == nil { - if ok { - return &Filter{Namespace: namespace}, nil - } - return filter, nil - } - - requirements := fieldSelector.Requirements() - for _, requirement := range requirements { - filter = &Filter{} - switch requirement.Operator { - case selection.Equals, selection.DoesNotExist: - if requirement.Value == "" { - return filter, apierrors.NewBadRequest(fmt.Sprintf("unsupported fieldSelector value %q for field %q with operator %q", requirement.Value, requirement.Field, requirement.Operator)) - } - default: - return filter, apierrors.NewBadRequest(fmt.Sprintf("unsupported fieldSelector operator %q for field %q", requirement.Operator, requirement.Field)) - } - - switch requirement.Field { - case "metadata.name": - filter.Name = requirement.Value - case "metadata.namespace": - filter.Namespace = requirement.Value - default: - return filter, apierrors.NewBadRequest(fmt.Sprintf("unknown fieldSelector field %q", requirement.Field)) - } - } - // add namespace to the filter selector if specified - if ok { - if filter != nil { - filter.Namespace = namespace - } else { - filter = &Filter{Namespace: namespace} - } - } - - return filter, nil -} diff --git a/pkg/registry/runningconfig/fieldselector.go b/pkg/registry/runningconfig/fieldselector.go deleted file mode 100644 index db1d34ea..00000000 --- a/pkg/registry/runningconfig/fieldselector.go +++ /dev/null @@ -1,82 +0,0 @@ -/* -Copyright 2024 Nokia. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ - -package runningconfig - -import ( - "context" - "fmt" - - apierrors "k8s.io/apimachinery/pkg/api/errors" - "k8s.io/apimachinery/pkg/fields" - "k8s.io/apimachinery/pkg/selection" - genericapirequest "k8s.io/apiserver/pkg/endpoints/request" -) - -// Filter -type Filter struct { - // Name filters by the name of the objects - Name string - - // Namespace filters by the namespace of the objects - Namespace string -} - -// parseFieldSelector parses client-provided fields.Selector into a packageFilter -func parseFieldSelector(ctx context.Context, fieldSelector fields.Selector) (*Filter, error) { - var filter *Filter - - // add the namespace to the list - namespace, ok := genericapirequest.NamespaceFrom(ctx) - if fieldSelector == nil { - if ok { - return &Filter{Namespace: namespace}, nil - } - return filter, nil - } - - requirements := fieldSelector.Requirements() - for _, requirement := range requirements { - filter = &Filter{} - switch requirement.Operator { - case selection.Equals, selection.DoesNotExist: - if requirement.Value == "" { - return filter, apierrors.NewBadRequest(fmt.Sprintf("unsupported fieldSelector value %q for field %q with operator %q", requirement.Value, requirement.Field, requirement.Operator)) - } - default: - return filter, apierrors.NewBadRequest(fmt.Sprintf("unsupported fieldSelector operator %q for field %q", requirement.Operator, requirement.Field)) - } - - switch requirement.Field { - case "metadata.name": - filter.Name = requirement.Value - case "metadata.namespace": - filter.Namespace = requirement.Value - default: - return filter, apierrors.NewBadRequest(fmt.Sprintf("unknown fieldSelector field %q", requirement.Field)) - } - } - // add namespace to the filter selector if specified - if ok { - if filter != nil { - filter.Namespace = namespace - } else { - filter = &Filter{Namespace: namespace} - } - } - - return filter, nil -} From 1799b63afe9403d56bf7539827bc8de93c2d631e Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Mon, 2 Mar 2026 06:09:43 +0100 Subject: [PATCH 087/135] update change handling of a DR CR --- pkg/discovery/discoveryrule/config.go | 22 ++++++++++----------- pkg/reconcilers/discoveryrule/reconciler.go | 20 ++++++++++--------- 2 files changed, 22 insertions(+), 20 deletions(-) diff --git a/pkg/discovery/discoveryrule/config.go b/pkg/discovery/discoveryrule/config.go index d567946f..b4353f66 100644 --- a/pkg/discovery/discoveryrule/config.go +++ b/pkg/discovery/discoveryrule/config.go @@ -40,18 +40,18 @@ type DiscoveryRuleConfig struct { } type DiscoveryProfile struct { - Secret string - SecretResourceVersion string // used to validate a profile change - TLSSecret string - TLSSecretResourceVersion string // used to validate a profile change - Connectionprofiles []*invv1alpha1.TargetConnectionProfile + Secret string + SecretResourceVersion string // used to validate a profile change (secrets only increment resourceVersion iso generation) + TLSSecret string + TLSSecretGeneration string // used to validate a profile change + Connectionprofiles []*invv1alpha1.TargetConnectionProfile } type TargetConnectionProfile struct { - Secret string - SecretResourceVersion string // used to validate a profile change + provide the version to the target if provisioned - TLSSecret string - TLSSecretResourceVersion string // used to validate a profile change + provide the version to the target if provisioned - Connectionprofile *invv1alpha1.TargetConnectionProfile - Syncprofile *invv1alpha1.TargetSyncProfile + Secret string + SecretResourceVersion string // used to validate a profile change + provide the version to the target if provisioned + TLSSecret string + TLSSecretGeneration string // used to validate a profile change + provide the version to the target if provisioned + Connectionprofile *invv1alpha1.TargetConnectionProfile + Syncprofile *invv1alpha1.TargetSyncProfile } diff --git a/pkg/reconcilers/discoveryrule/reconciler.go b/pkg/reconcilers/discoveryrule/reconciler.go index d79d895c..b57789c8 100644 --- a/pkg/reconcilers/discoveryrule/reconciler.go +++ b/pkg/reconcilers/discoveryrule/reconciler.go @@ -152,6 +152,7 @@ func (r *reconciler) Reconcile(ctx context.Context, req ctrl.Request) (ctrl.Resu return ctrl.Result{Requeue: true}, errors.Wrap(r.handleError(ctx, discoveryRuleOrig, "cannot add finalizer", err), errUpdateStatus) } + // check if the discovery rule is running isDRRunning := false dr, err := r.discoveryStore.Get(ctx, key) @@ -210,9 +211,9 @@ func (r *reconciler) HasChanged(ctx context.Context, newDRConfig, currentDRConfi if newDRConfig.DiscoveryProfile != nil { log.Info("HasChanged", - "CR RV", fmt.Sprintf("%s/%s", - newDRConfig.CR.GetResourceVersion(), - currentDRConfig.CR.GetResourceVersion(), + "CR Generation", fmt.Sprintf("%d/%d", + newDRConfig.CR.GetGeneration(), + currentDRConfig.CR.GetGeneration(), ), "DiscoveryProfile Secret RV", fmt.Sprintf("%s/%s", newDRConfig.DiscoveryProfile.SecretResourceVersion, @@ -225,13 +226,14 @@ func (r *reconciler) HasChanged(ctx context.Context, newDRConfig, currentDRConfi ) } else { log.Info("HasChanged", - "CR RV", fmt.Sprintf("%s/%s", - newDRConfig.CR.GetResourceVersion(), - currentDRConfig.CR.GetResourceVersion(), + "CR Generation", fmt.Sprintf("%d/%d", + newDRConfig.CR.GetGeneration(), + currentDRConfig.CR.GetGeneration(), ), ) } - if newDRConfig.CR.GetResourceVersion() != currentDRConfig.CR.GetResourceVersion() { + + if newDRConfig.CR.GetGeneration() != currentDRConfig.CR.GetGeneration() { return true } @@ -259,10 +261,10 @@ func (r *reconciler) HasChanged(ctx context.Context, newDRConfig, currentDRConfi if newDRConfig.TargetConnectionProfiles[i].SecretResourceVersion != currentDRConfig.TargetConnectionProfiles[i].SecretResourceVersion { return true } - if newDRConfig.TargetConnectionProfiles[i].Connectionprofile.ResourceVersion != currentDRConfig.TargetConnectionProfiles[i].Connectionprofile.ResourceVersion { + if newDRConfig.TargetConnectionProfiles[i].Connectionprofile.Generation != currentDRConfig.TargetConnectionProfiles[i].Connectionprofile.Generation { return true } - if newDRConfig.TargetConnectionProfiles[i].Syncprofile.ResourceVersion != currentDRConfig.TargetConnectionProfiles[i].Syncprofile.ResourceVersion { + if newDRConfig.TargetConnectionProfiles[i].Syncprofile.Generation != currentDRConfig.TargetConnectionProfiles[i].Syncprofile.Generation { return true } } From bfc3ccf8b24b44bc706b6abec02ef96cc794cc8f Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Mon, 2 Mar 2026 06:27:08 +0100 Subject: [PATCH 088/135] update discovery debug --- pkg/discovery/discoveryrule/discover.go | 4 ++-- pkg/discovery/discoveryrule/discover_gnmi.go | 10 +++++----- pkg/discovery/discoveryrule/target.go | 6 +++++- 3 files changed, 12 insertions(+), 8 deletions(-) diff --git a/pkg/discovery/discoveryrule/discover.go b/pkg/discovery/discoveryrule/discover.go index 85da347a..a4c95ab3 100644 --- a/pkg/discovery/discoveryrule/discover.go +++ b/pkg/discovery/discoveryrule/discover.go @@ -57,12 +57,12 @@ func (r *dr) discover(ctx context.Context, h *hostInfo) error { for _, connProfile := range r.getDiscoveryProfiles(ctx, h) { discover, ok := r.protocols.get(connProfile.Spec.Protocol) if !ok { - log.Info("connection profile points to unsupported protocol", "protocol", connProfile.Spec.Protocol) + log.Warn("connection profile points to unsupported protocol", "protocol", connProfile.Spec.Protocol) err = errors.Join(err, fmt.Errorf("unsupported protocol :%s", string(connProfile.Spec.Protocol))) continue } if derr := discover(ctx, h, connProfile); derr != nil { - log.Info("discovery failed", "protocol", connProfile.Spec.Protocol) + log.Debug("discovery failed", "protocol", connProfile.Spec.Protocol) err = errors.Join(err, derr) continue } diff --git a/pkg/discovery/discoveryrule/discover_gnmi.go b/pkg/discovery/discoveryrule/discover_gnmi.go index 46117014..db3188dd 100644 --- a/pkg/discovery/discoveryrule/discover_gnmi.go +++ b/pkg/discovery/discoveryrule/discover_gnmi.go @@ -56,7 +56,7 @@ func (r *dr) discoverWithGNMI(ctx context.Context, h *hostInfo, connProfile *inv if err != nil { return err } - log.Info("Creating gNMI client") + log.Debug("Creating gNMI client") err = t.CreateGNMIClient(ctx) if err != nil { return err @@ -235,7 +235,7 @@ func (r *Discoverer) parseDiscoveryInformation( gnmiPath = strings.Join(strings.Split(gnmiPath, ":")[1:], ":") } - log.Info("discovery", "path", preserveNamespace) + log.Debug("discovery", "path", preserveNamespace) // SRLINUX a path that was requested without keys is returned as a JSON blob up to the first element // for which the first key was found @@ -244,7 +244,7 @@ func (r *Discoverer) parseDiscoveryInformation( if param, exists := pathMap[gnmiPath]; exists { if targetField, found := fieldMapping[param.Key]; found { - log.Info("discovery before transform", "path", gnmiPath, "key", param.Key, "value", upd.GetVal()) + log.Debug("discovery before transform", "path", gnmiPath, "key", param.Key, "value", upd.GetVal()) string_value, err := getStringValue(upd.GetVal()) if err != nil { @@ -253,7 +253,7 @@ func (r *Discoverer) parseDiscoveryInformation( *targetField = string_value - log.Info("discovery before transform", "path", gnmiPath, "key", param.Key, "value", *targetField) + log.Debug("discovery before transform", "path", gnmiPath, "key", param.Key, "value", *targetField) // Apply transformations (Regex + Starlark) transformedValue, err := applyTransformations(ctx, param, *targetField) @@ -261,7 +261,7 @@ func (r *Discoverer) parseDiscoveryInformation( return nil, fmt.Errorf("failed to process transformation for %q: %w", param.Key, err) } - log.Info("discovery after transform", "path", gnmiPath, "key", param.Key, "value", transformedValue) + log.Debug("discovery after transform", "path", gnmiPath, "key", param.Key, "value", transformedValue) *targetField = transformedValue } } diff --git a/pkg/discovery/discoveryrule/target.go b/pkg/discovery/discoveryrule/target.go index 5ab318b8..ce8b4a33 100644 --- a/pkg/discovery/discoveryrule/target.go +++ b/pkg/discovery/discoveryrule/target.go @@ -42,6 +42,7 @@ const ( func (r *dr) createTarget(ctx context.Context, provider, address string, di *configv1alpha1.DiscoveryInfo) error { log := log.FromContext(ctx) + log.Info("createTarget start", "hostname", di.Hostname, "address", address) if err := r.children.Apply(ctx, storebackend.ToKey(getTargetName(di.Hostname)), ""); err != nil { log.Warn("children.apply", "error", err) return err @@ -52,22 +53,25 @@ func (r *dr) createTarget(ctx context.Context, provider, address string, di *con Name: getTargetName(di.Hostname), } + log.Info("applyTargetSpec start", "target", targetKey) if err := r.applyTargetSpec(ctx, targetKey, provider, address); err != nil { log.Error("dynamic target creation failed", "error", err) return err } + log.Info("applyTargetSpec done", "target", targetKey) target, err := r.applyTargetStatus(ctx, targetKey, di) if err != nil { log.Error("dynamic target status apply failed", "error", err) return err } + log.Info("applyTargetStatus done", "target", targetKey) if err := r.applyTargetDeviationCR(ctx, target); err != nil { log.Error("apply deviation failed", "error", err) return err } - + log.Info("createTarget done", "target", targetKey) return nil } From 5d842f5f130ad1f94e25e94bf4f8c3f1c0d63f5a Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Mon, 2 Mar 2026 06:49:28 +0100 Subject: [PATCH 089/135] update discovery debug --- pkg/discovery/discoveryrule/rule.go | 4 +-- pkg/registry/generic/strategy_resource.go | 30 ++++++++++++++++++----- 2 files changed, 26 insertions(+), 8 deletions(-) diff --git a/pkg/discovery/discoveryrule/rule.go b/pkg/discovery/discoveryrule/rule.go index b86b77b1..f41a8b3b 100644 --- a/pkg/discovery/discoveryrule/rule.go +++ b/pkg/discovery/discoveryrule/rule.go @@ -130,9 +130,9 @@ func (r *dr) run(ctx context.Context) error { if err := r.discover(ctx, h); err != nil { //if status.Code(err) == codes.Canceled { if strings.Contains(err.Error(), "context cancelled") { - log.Info("discovery cancelled") + log.Debug("discovery cancelled") } else { - log.Info("discovery failed", "error", err) + log.Debug("discovery failed", "error", err) } } }(h) diff --git a/pkg/registry/generic/strategy_resource.go b/pkg/registry/generic/strategy_resource.go index 26a7083e..b1befaa9 100644 --- a/pkg/registry/generic/strategy_resource.go +++ b/pkg/registry/generic/strategy_resource.go @@ -26,6 +26,7 @@ import ( watchermanager "github.com/henderiw/apiserver-store/pkg/watcher-manager" "github.com/henderiw/logger/log" "github.com/sdcio/config-server/pkg/registry/options" + "go.yaml.in/yaml/v2" apierrors "k8s.io/apimachinery/pkg/api/errors" "k8s.io/apimachinery/pkg/api/meta" metainternalversion "k8s.io/apimachinery/pkg/apis/meta/internalversion" @@ -88,12 +89,12 @@ func (r *strategy) Get(ctx context.Context, key types.NamespacedName) (runtime.O return nil, apierrors.NewNotFound(r.gr, key.Name) } accessor, _ := meta.Accessor(obj) - log.FromContext(ctx).Info("strategy.Get", - "key", key, - "managedFieldsCount", len(accessor.GetManagedFields()), - "labelsCount", len(accessor.GetLabels()), - "finalizersCount", len(accessor.GetFinalizers()), - ) + log.FromContext(ctx).Info("strategy.Get", + "key", key, + "managedFieldsCount", len(accessor.GetManagedFields()), + "labelsCount", len(accessor.GetLabels()), + "finalizersCount", len(accessor.GetFinalizers()), + ) return obj, nil } @@ -112,6 +113,11 @@ func (r *strategy) InvokeCreate(ctx context.Context, obj runtime.Object, recursi } func (r *strategy) Create(ctx context.Context, key types.NamespacedName, obj runtime.Object, dryrun bool) (runtime.Object, error) { + b, err := yaml.Marshal(&obj) + if err == nil { + log.FromContext(ctx).Info("update strategy", "key", key, "data", string(b)) + } + if dryrun { if r.opts != nil && r.opts.DryRunCreateFn != nil { return r.opts.DryRunCreateFn(ctx, key, obj, dryrun) @@ -151,6 +157,18 @@ func (r *strategy) InvokeUpdate(ctx context.Context, obj, old runtime.Object, re } func (r *strategy) Update(ctx context.Context, key types.NamespacedName, obj, old runtime.Object, dryrun bool) (runtime.Object, error) { + + objNew, err := yaml.Marshal(&obj) + if err == nil { + log.FromContext(ctx).Info("update strategy", "key", key, "data", string(objNew)) + } + + objOld, err := yaml.Marshal(&old) + if err == nil { + log.FromContext(ctx).Info("update strategy", "key", key, "data", string(objOld)) + } + + if r.obj.IsEqual(ctx, obj, old) { return obj, nil } From d83808f19fb61308127b592e5b9e558642b6c333 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Mon, 2 Mar 2026 07:12:49 +0100 Subject: [PATCH 090/135] update discovery debug --- apis/condition/condition.go | 5 ++ apis/config/target_helpers.go | 5 ++ pkg/registry/generic/strategy_resource.go | 69 +++++++++++++++++++---- 3 files changed, 67 insertions(+), 12 deletions(-) diff --git a/apis/condition/condition.go b/apis/condition/condition.go index d2d527a2..10ac7034 100644 --- a/apis/condition/condition.go +++ b/apis/condition/condition.go @@ -84,6 +84,11 @@ func NewConditionedStatus(c ...Condition) *ConditionedStatus { return r } +// HasCondition returns if the condition is set +func (r *ConditionedStatus) GetConditions() []Condition { + return r.Conditions +} + // HasCondition returns if the condition is set func (r *ConditionedStatus) HasCondition(t ConditionType) bool { for _, c := range r.Conditions { diff --git a/apis/config/target_helpers.go b/apis/config/target_helpers.go index de1eb924..a399bd55 100644 --- a/apis/config/target_helpers.go +++ b/apis/config/target_helpers.go @@ -21,6 +21,11 @@ import ( metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" ) +// GetCondition returns the condition based on the condition kind +func (r *Target) GetConditions() []condition.Condition { + return r.Status.GetConditions() +} + // GetCondition returns the condition based on the condition kind func (r *Target) GetCondition(t condition.ConditionType) condition.Condition { return r.Status.GetCondition(t) diff --git a/pkg/registry/generic/strategy_resource.go b/pkg/registry/generic/strategy_resource.go index b1befaa9..1c4ea1d8 100644 --- a/pkg/registry/generic/strategy_resource.go +++ b/pkg/registry/generic/strategy_resource.go @@ -18,6 +18,7 @@ package generic import ( "context" + "fmt" "github.com/henderiw/apiserver-builder/pkg/builder/resource" "github.com/henderiw/apiserver-builder/pkg/builder/utils" @@ -25,8 +26,8 @@ import ( "github.com/henderiw/apiserver-store/pkg/storebackend" watchermanager "github.com/henderiw/apiserver-store/pkg/watcher-manager" "github.com/henderiw/logger/log" + "github.com/sdcio/config-server/apis/condition" "github.com/sdcio/config-server/pkg/registry/options" - "go.yaml.in/yaml/v2" apierrors "k8s.io/apimachinery/pkg/api/errors" "k8s.io/apimachinery/pkg/api/meta" metainternalversion "k8s.io/apimachinery/pkg/apis/meta/internalversion" @@ -41,6 +42,10 @@ import ( "sigs.k8s.io/structured-merge-diff/v6/fieldpath" ) +type conditionsGetter interface { + GetConditions() []condition.Condition +} + // NewStrategy creates and returns a strategy instance func NewStrategy( obj resource.InternalObject, @@ -113,11 +118,25 @@ func (r *strategy) InvokeCreate(ctx context.Context, obj runtime.Object, recursi } func (r *strategy) Create(ctx context.Context, key types.NamespacedName, obj runtime.Object, dryrun bool) (runtime.Object, error) { - b, err := yaml.Marshal(&obj) - if err == nil { - log.FromContext(ctx).Info("update strategy", "key", key, "data", string(b)) + accessor, _ := meta.Accessor(obj) + l := log.FromContext(ctx).With( + "key", key, + "resourceVersion", accessor.GetResourceVersion(), + "generation", accessor.GetGeneration(), + "managedFields", len(accessor.GetManagedFields()), + "finalizers", accessor.GetFinalizers(), + ) + + if cg, ok := obj.(conditionsGetter); ok { + conditions := cg.GetConditions() + condSummary := make([]string, 0, len(conditions)) + for _, c := range conditions { + condSummary = append(condSummary, fmt.Sprintf("%s=%s(%s)", c.Type, c.Status, c.Message)) + } + l = l.With("conditions", condSummary) } - + l.Info("Create") + if dryrun { if r.opts != nil && r.opts.DryRunCreateFn != nil { return r.opts.DryRunCreateFn(ctx, key, obj, dryrun) @@ -157,17 +176,43 @@ func (r *strategy) InvokeUpdate(ctx context.Context, obj, old runtime.Object, re } func (r *strategy) Update(ctx context.Context, key types.NamespacedName, obj, old runtime.Object, dryrun bool) (runtime.Object, error) { + accessor, _ := meta.Accessor(obj) + l := log.FromContext(ctx).With( + "key", key, + "resourceVersion", accessor.GetResourceVersion(), + "generation", accessor.GetGeneration(), + "managedFields", len(accessor.GetManagedFields()), + "finalizers", accessor.GetFinalizers(), + ) - objNew, err := yaml.Marshal(&obj) - if err == nil { - log.FromContext(ctx).Info("update strategy", "key", key, "data", string(objNew)) + if cg, ok := obj.(conditionsGetter); ok { + conditions := cg.GetConditions() + condSummary := make([]string, 0, len(conditions)) + for _, c := range conditions { + condSummary = append(condSummary, fmt.Sprintf("%s=%s(%s)", c.Type, c.Status, c.Message)) + } + l = l.With("conditions", condSummary) } + l.Info("Updata New") - objOld, err := yaml.Marshal(&old) - if err == nil { - log.FromContext(ctx).Info("update strategy", "key", key, "data", string(objOld)) - } + accessoro, _ := meta.Accessor(old) + lo := log.FromContext(ctx).With( + "key", key, + "resourceVersion", accessoro.GetResourceVersion(), + "generation", accessoro.GetGeneration(), + "managedFields", len(accessoro.GetManagedFields()), + "finalizers", accessoro.GetFinalizers(), + ) + if cg, ok := old.(conditionsGetter); ok { + conditions := cg.GetConditions() + condSummary := make([]string, 0, len(conditions)) + for _, c := range conditions { + condSummary = append(condSummary, fmt.Sprintf("%s=%s(%s)", c.Type, c.Status, c.Message)) + } + lo = lo.With("conditions", condSummary) + } + lo.Info("Updata Old") if r.obj.IsEqual(ctx, obj, old) { return obj, nil From 5615e2e711fd2d34b4e69e5903741d9b6e1fb70f Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Mon, 2 Mar 2026 07:28:45 +0100 Subject: [PATCH 091/135] update discovery debug --- pkg/registry/generic/strategy_resource.go | 66 +++++++++++------------ 1 file changed, 32 insertions(+), 34 deletions(-) diff --git a/pkg/registry/generic/strategy_resource.go b/pkg/registry/generic/strategy_resource.go index 1c4ea1d8..cb91c270 100644 --- a/pkg/registry/generic/strategy_resource.go +++ b/pkg/registry/generic/strategy_resource.go @@ -118,24 +118,9 @@ func (r *strategy) InvokeCreate(ctx context.Context, obj runtime.Object, recursi } func (r *strategy) Create(ctx context.Context, key types.NamespacedName, obj runtime.Object, dryrun bool) (runtime.Object, error) { - accessor, _ := meta.Accessor(obj) - l := log.FromContext(ctx).With( - "key", key, - "resourceVersion", accessor.GetResourceVersion(), - "generation", accessor.GetGeneration(), - "managedFields", len(accessor.GetManagedFields()), - "finalizers", accessor.GetFinalizers(), - ) - - if cg, ok := obj.(conditionsGetter); ok { - conditions := cg.GetConditions() - condSummary := make([]string, 0, len(conditions)) - for _, c := range conditions { - condSummary = append(condSummary, fmt.Sprintf("%s=%s(%s)", c.Type, c.Status, c.Message)) - } - l = l.With("conditions", condSummary) + if shouldLog(obj) { + logObject(ctx, "Create", key, obj) } - l.Info("Create") if dryrun { if r.opts != nil && r.opts.DryRunCreateFn != nil { @@ -176,24 +161,11 @@ func (r *strategy) InvokeUpdate(ctx context.Context, obj, old runtime.Object, re } func (r *strategy) Update(ctx context.Context, key types.NamespacedName, obj, old runtime.Object, dryrun bool) (runtime.Object, error) { - accessor, _ := meta.Accessor(obj) - l := log.FromContext(ctx).With( - "key", key, - "resourceVersion", accessor.GetResourceVersion(), - "generation", accessor.GetGeneration(), - "managedFields", len(accessor.GetManagedFields()), - "finalizers", accessor.GetFinalizers(), - ) - - if cg, ok := obj.(conditionsGetter); ok { - conditions := cg.GetConditions() - condSummary := make([]string, 0, len(conditions)) - for _, c := range conditions { - condSummary = append(condSummary, fmt.Sprintf("%s=%s(%s)", c.Type, c.Status, c.Message)) - } - l = l.With("conditions", condSummary) + + if shouldLog(obj) { + logObject(ctx, "Update New", key, obj) + logObject(ctx, "Update Old", key, old) } - l.Info("Updata New") accessoro, _ := meta.Accessor(old) lo := log.FromContext(ctx).With( @@ -375,3 +347,29 @@ func (r *strategy) notifyWatcher(ctx context.Context, event watch.Event) { r.watcherManager.WatchChan() <- event } + + +func shouldLog(obj runtime.Object) bool { + return obj.GetObjectKind().GroupVersionKind().Kind == "Target" +} + +func logObject(ctx context.Context, op string, key types.NamespacedName, obj runtime.Object) { + accessor, _ := meta.Accessor(obj) + l := log.FromContext(ctx).With( + "op", op, + "key", key, + "resourceVersion", accessor.GetResourceVersion(), + "generation", accessor.GetGeneration(), + "managedFields", len(accessor.GetManagedFields()), + "finalizers", accessor.GetFinalizers(), + ) + if cg, ok := obj.(conditionsGetter); ok { + conditions := cg.GetConditions() + condSummary := make([]string, 0, len(conditions)) + for _, c := range conditions { + condSummary = append(condSummary, fmt.Sprintf("%s=%s(%s)", c.Type, c.Status, c.Message)) + } + l = l.With("conditions", condSummary) + } + l.Info("strategy") +} \ No newline at end of file From e0c5ccc71a5a8025693f41774c21e10ce83fb6e5 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Mon, 2 Mar 2026 07:51:30 +0100 Subject: [PATCH 092/135] update discovery debug --- pkg/registry/generic/strategy_status.go | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/pkg/registry/generic/strategy_status.go b/pkg/registry/generic/strategy_status.go index d809b296..eed1647a 100644 --- a/pkg/registry/generic/strategy_status.go +++ b/pkg/registry/generic/strategy_status.go @@ -91,6 +91,12 @@ func (r *statusStrategy) InvokeUpdate(ctx context.Context, obj, old runtime.Obje } func (r *statusStrategy) Update(ctx context.Context, key types.NamespacedName, obj, old runtime.Object, dryrun bool) (runtime.Object, error) { + + if shouldLog(obj) { + logObject(ctx, "Update Status New", key, obj) + logObject(ctx, "Update Status Old", key, old) + } + // check if there is a change if r.obj.IsStatusEqual(ctx, obj, old) { return obj, nil From 7a071fcb501db6f3ad928c6ad51d04e161f72b00 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Mon, 2 Mar 2026 08:26:02 +0100 Subject: [PATCH 093/135] update logging --- apis/config/target_resource.go | 2 +- pkg/registry/generic/strategy_resource.go | 24 +++-------------------- 2 files changed, 4 insertions(+), 22 deletions(-) diff --git a/apis/config/target_resource.go b/apis/config/target_resource.go index d014e434..37bd8d7a 100644 --- a/apis/config/target_resource.go +++ b/apis/config/target_resource.go @@ -295,7 +295,7 @@ func (r *Target) ValidateCreate(ctx context.Context, obj runtime.Object) field.E } func (r *Target) PrepareForUpdate(ctx context.Context, obj, old runtime.Object) { - // ensure the sttaus dont get updated + // ensure the status dont get updated newobj := obj.(*Target) oldObj := old.(*Target) newobj.Status = oldObj.Status diff --git a/pkg/registry/generic/strategy_resource.go b/pkg/registry/generic/strategy_resource.go index cb91c270..4fb474be 100644 --- a/pkg/registry/generic/strategy_resource.go +++ b/pkg/registry/generic/strategy_resource.go @@ -161,31 +161,11 @@ func (r *strategy) InvokeUpdate(ctx context.Context, obj, old runtime.Object, re } func (r *strategy) Update(ctx context.Context, key types.NamespacedName, obj, old runtime.Object, dryrun bool) (runtime.Object, error) { - if shouldLog(obj) { logObject(ctx, "Update New", key, obj) logObject(ctx, "Update Old", key, old) } - accessoro, _ := meta.Accessor(old) - lo := log.FromContext(ctx).With( - "key", key, - "resourceVersion", accessoro.GetResourceVersion(), - "generation", accessoro.GetGeneration(), - "managedFields", len(accessoro.GetManagedFields()), - "finalizers", accessoro.GetFinalizers(), - ) - - if cg, ok := old.(conditionsGetter); ok { - conditions := cg.GetConditions() - condSummary := make([]string, 0, len(conditions)) - for _, c := range conditions { - condSummary = append(condSummary, fmt.Sprintf("%s=%s(%s)", c.Type, c.Status, c.Message)) - } - lo = lo.With("conditions", condSummary) - } - lo.Info("Updata Old") - if r.obj.IsEqual(ctx, obj, old) { return obj, nil } @@ -350,7 +330,8 @@ func (r *strategy) notifyWatcher(ctx context.Context, event watch.Event) { func shouldLog(obj runtime.Object) bool { - return obj.GetObjectKind().GroupVersionKind().Kind == "Target" + return true + //return obj.GetObjectKind().GroupVersionKind().Kind == "Target" } func logObject(ctx context.Context, op string, key types.NamespacedName, obj runtime.Object) { @@ -358,6 +339,7 @@ func logObject(ctx context.Context, op string, key types.NamespacedName, obj run l := log.FromContext(ctx).With( "op", op, "key", key, + "kind", obj.GetObjectKind().GroupVersionKind().Kind, "resourceVersion", accessor.GetResourceVersion(), "generation", accessor.GetGeneration(), "managedFields", len(accessor.GetManagedFields()), From 99a4b6f8a172c21a113c4b6cc77ea9ec99e8068a Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Mon, 2 Mar 2026 08:49:54 +0100 Subject: [PATCH 094/135] serialize storage updates --- go.mod | 2 +- go.sum | 4 ++-- pkg/registry/configblame/store.go | 2 ++ pkg/registry/generic/store.go | 2 ++ pkg/registry/runningconfig/store.go | 2 ++ 5 files changed, 9 insertions(+), 3 deletions(-) diff --git a/go.mod b/go.mod index ba391e67..465ef621 100644 --- a/go.mod +++ b/go.mod @@ -8,7 +8,7 @@ require ( github.com/google/go-cmp v0.7.0 github.com/google/uuid v1.6.0 github.com/henderiw/apiserver-builder v0.0.6 - github.com/henderiw/apiserver-store v0.0.3 + github.com/henderiw/apiserver-store v0.0.4-0.20260302074715-6f0b5dce6f79 github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c github.com/henderiw/logger v0.0.0-20230911123436-8655829b1abe github.com/henderiw/store v0.0.2-0.20241030044529-f6baff74eab3 diff --git a/go.sum b/go.sum index 7e6ca08b..005ed724 100644 --- a/go.sum +++ b/go.sum @@ -171,8 +171,8 @@ github.com/grpc-ecosystem/grpc-gateway/v2 v2.27.3 h1:NmZ1PKzSTQbuGHw9DGPFomqkkLW github.com/grpc-ecosystem/grpc-gateway/v2 v2.27.3/go.mod h1:zQrxl1YP88HQlA6i9c63DSVPFklWpGX4OWAc9bFuaH4= github.com/henderiw/apiserver-builder v0.0.6 h1:8vlnpGmQsIgSCVNNSQKaBeHtbAtgCvKoKQii7Vx3YLk= github.com/henderiw/apiserver-builder v0.0.6/go.mod h1:Py2AD4oB1McoYpz4chBNAFo9bYeZ9N9cKPijzkMxk2U= -github.com/henderiw/apiserver-store v0.0.3 h1:cUNzimOvxVKsw+/kj+7IkI/GnRuFlziwCc3AsfYo9zM= -github.com/henderiw/apiserver-store v0.0.3/go.mod h1:RuXLMHJwszn6LXgL6fO9fxMC7AW5wAc4zOddnnZpkKI= +github.com/henderiw/apiserver-store v0.0.4-0.20260302074715-6f0b5dce6f79 h1:xiCzr7yAr4rCVZSWHzcARwhr9GKP15gpbDkuLh3tmDw= +github.com/henderiw/apiserver-store v0.0.4-0.20260302074715-6f0b5dce6f79/go.mod h1:RuXLMHJwszn6LXgL6fO9fxMC7AW5wAc4zOddnnZpkKI= github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c h1:nFnCNyRV1Ej/zqV/gn8UnFESkoPUXhwpUCZyhSYGSYA= github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c/go.mod h1:PrPJdVAwtl5tL323wykHZ5L/b7tfJJsjhegza/wq4fQ= github.com/henderiw/logger v0.0.0-20230911123436-8655829b1abe h1:+R53KH7fW+pmqlfSYVTCGPn8pj6gqBGcQ0nq7L1h8+g= diff --git a/pkg/registry/configblame/store.go b/pkg/registry/configblame/store.go index d08e8923..b9b4b6c9 100644 --- a/pkg/registry/configblame/store.go +++ b/pkg/registry/configblame/store.go @@ -18,6 +18,7 @@ package configblame import ( "context" + "sync" "github.com/henderiw/apiserver-builder/pkg/builder/resource" builderrest "github.com/henderiw/apiserver-builder/pkg/builder/rest" @@ -82,6 +83,7 @@ func NewREST( CategoryList: obj.GetCategories(), ShortNameList: obj.GetShortNames(), Storage: nil, + KeyLocks: &sync.Map{}, } options := &generic.StoreOptions{ RESTOptions: optsGetter, diff --git a/pkg/registry/generic/store.go b/pkg/registry/generic/store.go index 90686b5e..8773a9b2 100644 --- a/pkg/registry/generic/store.go +++ b/pkg/registry/generic/store.go @@ -19,6 +19,7 @@ package generic import ( "context" "fmt" + "sync" "github.com/henderiw/apiserver-builder/pkg/builder/resource" builderrest "github.com/henderiw/apiserver-builder/pkg/builder/rest" @@ -108,6 +109,7 @@ func NewREST( CategoryList: obj.GetCategories(), ShortNameList: obj.GetShortNames(), Storage: storage, + KeyLocks: &sync.Map{}, } storeOptions := &generic.StoreOptions{ RESTOptions: optsGetter, diff --git a/pkg/registry/runningconfig/store.go b/pkg/registry/runningconfig/store.go index bf0456e2..ac4d96ca 100644 --- a/pkg/registry/runningconfig/store.go +++ b/pkg/registry/runningconfig/store.go @@ -18,6 +18,7 @@ package runningconfig import ( "context" + "sync" "github.com/henderiw/apiserver-builder/pkg/builder/resource" builderrest "github.com/henderiw/apiserver-builder/pkg/builder/rest" @@ -82,6 +83,7 @@ func NewREST( CategoryList: obj.GetCategories(), ShortNameList: obj.GetShortNames(), Storage: nil, + KeyLocks: &sync.Map{}, } options := &generic.StoreOptions{ RESTOptions: optsGetter, From ddc6163acdfcab37f0cc495c51d19a3c9a5d44d8 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Mon, 2 Mar 2026 09:04:25 +0100 Subject: [PATCH 095/135] serialize storage updates --- go.mod | 2 +- go.sum | 4 ++-- pkg/registry/generic/strategy_resource.go | 19 ++++++++++--------- 3 files changed, 13 insertions(+), 12 deletions(-) diff --git a/go.mod b/go.mod index 465ef621..e4677964 100644 --- a/go.mod +++ b/go.mod @@ -8,7 +8,7 @@ require ( github.com/google/go-cmp v0.7.0 github.com/google/uuid v1.6.0 github.com/henderiw/apiserver-builder v0.0.6 - github.com/henderiw/apiserver-store v0.0.4-0.20260302074715-6f0b5dce6f79 + github.com/henderiw/apiserver-store v0.0.4-0.20260302080324-b86cbaad3048 github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c github.com/henderiw/logger v0.0.0-20230911123436-8655829b1abe github.com/henderiw/store v0.0.2-0.20241030044529-f6baff74eab3 diff --git a/go.sum b/go.sum index 005ed724..bd514f14 100644 --- a/go.sum +++ b/go.sum @@ -171,8 +171,8 @@ github.com/grpc-ecosystem/grpc-gateway/v2 v2.27.3 h1:NmZ1PKzSTQbuGHw9DGPFomqkkLW github.com/grpc-ecosystem/grpc-gateway/v2 v2.27.3/go.mod h1:zQrxl1YP88HQlA6i9c63DSVPFklWpGX4OWAc9bFuaH4= github.com/henderiw/apiserver-builder v0.0.6 h1:8vlnpGmQsIgSCVNNSQKaBeHtbAtgCvKoKQii7Vx3YLk= github.com/henderiw/apiserver-builder v0.0.6/go.mod h1:Py2AD4oB1McoYpz4chBNAFo9bYeZ9N9cKPijzkMxk2U= -github.com/henderiw/apiserver-store v0.0.4-0.20260302074715-6f0b5dce6f79 h1:xiCzr7yAr4rCVZSWHzcARwhr9GKP15gpbDkuLh3tmDw= -github.com/henderiw/apiserver-store v0.0.4-0.20260302074715-6f0b5dce6f79/go.mod h1:RuXLMHJwszn6LXgL6fO9fxMC7AW5wAc4zOddnnZpkKI= +github.com/henderiw/apiserver-store v0.0.4-0.20260302080324-b86cbaad3048 h1:4VzivD3OU/cSwbVfiOELZnvijFbOQEC1dUx87J+n/ro= +github.com/henderiw/apiserver-store v0.0.4-0.20260302080324-b86cbaad3048/go.mod h1:RuXLMHJwszn6LXgL6fO9fxMC7AW5wAc4zOddnnZpkKI= github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c h1:nFnCNyRV1Ej/zqV/gn8UnFESkoPUXhwpUCZyhSYGSYA= github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c/go.mod h1:PrPJdVAwtl5tL323wykHZ5L/b7tfJJsjhegza/wq4fQ= github.com/henderiw/logger v0.0.0-20230911123436-8655829b1abe h1:+R53KH7fW+pmqlfSYVTCGPn8pj6gqBGcQ0nq7L1h8+g= diff --git a/pkg/registry/generic/strategy_resource.go b/pkg/registry/generic/strategy_resource.go index 4fb474be..be2d5af6 100644 --- a/pkg/registry/generic/strategy_resource.go +++ b/pkg/registry/generic/strategy_resource.go @@ -93,13 +93,15 @@ func (r *strategy) Get(ctx context.Context, key types.NamespacedName) (runtime.O if err != nil { return nil, apierrors.NewNotFound(r.gr, key.Name) } - accessor, _ := meta.Accessor(obj) - log.FromContext(ctx).Info("strategy.Get", - "key", key, - "managedFieldsCount", len(accessor.GetManagedFields()), - "labelsCount", len(accessor.GetLabels()), - "finalizersCount", len(accessor.GetFinalizers()), - ) + /* + accessor, _ := meta.Accessor(obj) + log.FromContext(ctx).Info("strategy.Get", + "key", key, + "managedFieldsCount", len(accessor.GetManagedFields()), + "labelsCount", len(accessor.GetLabels()), + "finalizersCount", len(accessor.GetFinalizers()), + ) + */ return obj, nil } @@ -328,7 +330,6 @@ func (r *strategy) notifyWatcher(ctx context.Context, event watch.Event) { r.watcherManager.WatchChan() <- event } - func shouldLog(obj runtime.Object) bool { return true //return obj.GetObjectKind().GroupVersionKind().Kind == "Target" @@ -354,4 +355,4 @@ func logObject(ctx context.Context, op string, key types.NamespacedName, obj run l = l.With("conditions", condSummary) } l.Info("strategy") -} \ No newline at end of file +} From 5150a06b99c9a79feebfa83f065fc416b3a77ae9 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Mon, 2 Mar 2026 09:12:16 +0100 Subject: [PATCH 096/135] serialize storage updates --- go.mod | 2 +- go.sum | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/go.mod b/go.mod index e4677964..eac1db1c 100644 --- a/go.mod +++ b/go.mod @@ -8,7 +8,7 @@ require ( github.com/google/go-cmp v0.7.0 github.com/google/uuid v1.6.0 github.com/henderiw/apiserver-builder v0.0.6 - github.com/henderiw/apiserver-store v0.0.4-0.20260302080324-b86cbaad3048 + github.com/henderiw/apiserver-store v0.0.4-0.20260302081117-f4f810bec88b github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c github.com/henderiw/logger v0.0.0-20230911123436-8655829b1abe github.com/henderiw/store v0.0.2-0.20241030044529-f6baff74eab3 diff --git a/go.sum b/go.sum index bd514f14..6592b20f 100644 --- a/go.sum +++ b/go.sum @@ -171,8 +171,8 @@ github.com/grpc-ecosystem/grpc-gateway/v2 v2.27.3 h1:NmZ1PKzSTQbuGHw9DGPFomqkkLW github.com/grpc-ecosystem/grpc-gateway/v2 v2.27.3/go.mod h1:zQrxl1YP88HQlA6i9c63DSVPFklWpGX4OWAc9bFuaH4= github.com/henderiw/apiserver-builder v0.0.6 h1:8vlnpGmQsIgSCVNNSQKaBeHtbAtgCvKoKQii7Vx3YLk= github.com/henderiw/apiserver-builder v0.0.6/go.mod h1:Py2AD4oB1McoYpz4chBNAFo9bYeZ9N9cKPijzkMxk2U= -github.com/henderiw/apiserver-store v0.0.4-0.20260302080324-b86cbaad3048 h1:4VzivD3OU/cSwbVfiOELZnvijFbOQEC1dUx87J+n/ro= -github.com/henderiw/apiserver-store v0.0.4-0.20260302080324-b86cbaad3048/go.mod h1:RuXLMHJwszn6LXgL6fO9fxMC7AW5wAc4zOddnnZpkKI= +github.com/henderiw/apiserver-store v0.0.4-0.20260302081117-f4f810bec88b h1:iFG9vtD2eDR481k8/Y8rVBzNGXHsHdQLYS5aRk34lbA= +github.com/henderiw/apiserver-store v0.0.4-0.20260302081117-f4f810bec88b/go.mod h1:RuXLMHJwszn6LXgL6fO9fxMC7AW5wAc4zOddnnZpkKI= github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c h1:nFnCNyRV1Ej/zqV/gn8UnFESkoPUXhwpUCZyhSYGSYA= github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c/go.mod h1:PrPJdVAwtl5tL323wykHZ5L/b7tfJJsjhegza/wq4fQ= github.com/henderiw/logger v0.0.0-20230911123436-8655829b1abe h1:+R53KH7fW+pmqlfSYVTCGPn8pj6gqBGcQ0nq7L1h8+g= From c4040c215cda4b313555fe970331ab1058cea5c9 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Mon, 2 Mar 2026 10:38:44 +0100 Subject: [PATCH 097/135] update subresources --- apis/config/target_helpers.go | 5 +++ apis/config/target_resource.go | 81 ++++++++++++++++++++++++++++++++++ apis/config/target_types.go | 17 ++++--- go.mod | 2 +- go.sum | 4 +- pkg/registry/generic/store.go | 12 +++++ 6 files changed, 113 insertions(+), 8 deletions(-) diff --git a/apis/config/target_helpers.go b/apis/config/target_helpers.go index a399bd55..d2cab47e 100644 --- a/apis/config/target_helpers.go +++ b/apis/config/target_helpers.go @@ -19,6 +19,7 @@ package config import ( "github.com/sdcio/config-server/apis/condition" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/types" ) // GetCondition returns the condition based on the condition kind @@ -75,3 +76,7 @@ func (r *Target) IsReady() bool { r.GetCondition(ConditionTypeDatastoreReady).Status == metav1.ConditionTrue && r.GetCondition(ConditionTypeTargetConnectionReady).Status == metav1.ConditionTrue } + +func (r *Target) GetNamespacedName() types.NamespacedName { + return types.NamespacedName{Namespace: r.Namespace, Name: r.Name} +} diff --git a/apis/config/target_resource.go b/apis/config/target_resource.go index 37bd8d7a..7dc75df1 100644 --- a/apis/config/target_resource.go +++ b/apis/config/target_resource.go @@ -23,7 +23,9 @@ import ( "github.com/henderiw/apiserver-builder/pkg/builder/resource" "github.com/henderiw/apiserver-store/pkg/generic/registry" + "github.com/henderiw/apiserver-store/pkg/storebackend" "github.com/sdcio/config-server/apis/condition" + "github.com/sdcio/sdc-protos/sdcpb" apiequality "k8s.io/apimachinery/pkg/api/equality" apierrors "k8s.io/apimachinery/pkg/api/errors" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" @@ -34,6 +36,7 @@ import ( "k8s.io/apimachinery/pkg/util/validation/field" genericapirequest "k8s.io/apiserver/pkg/endpoints/request" "k8s.io/apiserver/pkg/registry/rest" + dsclient "github.com/sdcio/config-server/pkg/sdc/dataserver/client" ) const ( @@ -306,3 +309,81 @@ func (r *Target) ValidateUpdate(ctx context.Context, obj, old runtime.Object) fi return allErrs } + +var _ resource.ObjectWithArbitrarySubResource = &Target{} + +func (r *Target) GetArbitrarySubResources() []resource.ArbitrarySubResource { + return []resource.ArbitrarySubResource{ + &TargetRunning{}, + } +} + +func (TargetRunning) SubResourceName() string { + return "running" +} + +func (TargetRunning) New() runtime.Object { + return &Target{} // returns parent type — GET returns the full Target +} + +func (TargetRunning) NewStorage(scheme *runtime.Scheme, parentStorage rest.Storage) (rest.Storage, error) { + return &targetRunningREST{ + parentStore: parentStorage, + }, nil +} + +// targetRunningREST implements rest.Storage + rest.Getter +type targetRunningREST struct { + parentStore rest.Storage +} + +func (r *targetRunningREST) New() runtime.Object { + return &Target{} +} + +func (r *targetRunningREST) Destroy() {} + +func (r *targetRunningREST) Get(ctx context.Context, name string, options *metav1.GetOptions) (runtime.Object, error) { + // Get the parent Target from the parent store + getter := r.parentStore.(rest.Getter) + obj, err := getter.Get(ctx, name, options) + if err != nil { + return nil, err + } + target := obj.(*Target) + + if !target.IsReady() { + return nil, apierrors.NewNotFound(target.GetGroupVersionResource().GroupResource(), name) + } + + cfg := &dsclient.Config{ + Address: dsclient.GetDataServerAddress(), + Insecure: true, + } + + dsclient, closeFn, err := dsclient.NewEphemeral(ctx, cfg) + if err != nil { + return nil, err + } + defer func() { + if err := closeFn(); err != nil { + // You can use your preferred logging framework here + fmt.Printf("failed to close connection: %v\n", err) + } + }() + + // check if the schema exists; this is == nil check; in case of err it does not exist + key := target.GetNamespacedName() + rsp, err := dsclient.GetIntent(ctx, &sdcpb.GetIntentRequest{ + DatastoreName: storebackend.KeyFromNSN(key).String(), + Intent: "running", + Format: sdcpb.Format_Intent_Format_JSON, + }) + if err != nil { + return nil, err + } + + target.Running.Value.Raw = rsp.GetBlob() + + return target, nil +} diff --git a/apis/config/target_types.go b/apis/config/target_types.go index b5bda59d..818418a7 100644 --- a/apis/config/target_types.go +++ b/apis/config/target_types.go @@ -22,6 +22,7 @@ import ( "github.com/sdcio/config-server/apis/condition" invv1alpha1 "github.com/sdcio/config-server/apis/inv/v1alpha1" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/runtime" "k8s.io/apimachinery/pkg/runtime/schema" ) @@ -67,6 +68,11 @@ type DiscoveryInfo struct { //LastSeen metav1.Time `json:"lastSeen,omitempty"` } +type TargetRunning struct { + //+kubebuilder:pruning:PreserveUnknownFields + Value runtime.RawExtension `json:"value" protobuf:"bytes,2,opt,name=value"` +} + type TargetStatusUsedReferences struct { SecretResourceVersion string `json:"secretResourceVersion,omitempty" yaml:"secretResourceVersion,omitempty" protobuf:"bytes,1,opt,name=secretResourceVersion"` TLSSecretResourceVersion string `json:"tlsSecretResourceVersion,omitempty" yaml:"tlsSecretResourceVersion,omitempty" protobuf:"bytes,2,opt,name=tlsSecretResourceVersion"` @@ -84,10 +90,11 @@ type TargetStatusUsedReferences struct { // +k8s:openapi-gen=true type Target struct { metav1.TypeMeta `json:",inline" yaml:",inline"` - metav1.ObjectMeta `json:"metadata,omitempty" yaml:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` - Spec TargetSpec `json:"spec,omitempty" yaml:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"` - Status TargetStatus `json:"status,omitempty" yaml:"status,omitempty" protobuf:"bytes,3,opt,name=status"` + Spec TargetSpec `json:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"` + Status TargetStatus `json:"status,omitempty" protobuf:"bytes,3,opt,name=status"` + Running TargetRunning `json:"running,omitempty" protobuf:"bytes,4,opt,name=running"` } // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object @@ -96,8 +103,8 @@ type Target struct { // TargetList contains a list of Targets type TargetList struct { metav1.TypeMeta `json:",inline" yaml:",inline"` - metav1.ListMeta `json:"metadata,omitempty" yaml:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` - Items []Target `json:"items" yaml:"items" protobuf:"bytes,2,rep,name=items"` + metav1.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + Items []Target `json:"items" protobuf:"bytes,2,rep,name=items"` } var ( diff --git a/go.mod b/go.mod index eac1db1c..0a389ceb 100644 --- a/go.mod +++ b/go.mod @@ -7,7 +7,7 @@ require ( github.com/go-git/go-git/v5 v5.16.5 github.com/google/go-cmp v0.7.0 github.com/google/uuid v1.6.0 - github.com/henderiw/apiserver-builder v0.0.6 + github.com/henderiw/apiserver-builder v0.0.7-0.20260302093549-7ef05fb00905 github.com/henderiw/apiserver-store v0.0.4-0.20260302081117-f4f810bec88b github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c github.com/henderiw/logger v0.0.0-20230911123436-8655829b1abe diff --git a/go.sum b/go.sum index 6592b20f..ab944178 100644 --- a/go.sum +++ b/go.sum @@ -169,8 +169,8 @@ github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0 h1:Ovs26xHkKqVztRpIrF/92Bcuy github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0/go.mod h1:8NvIoxWQoOIhqOTXgfV/d3M/q6VIi02HzZEHgUlZvzk= github.com/grpc-ecosystem/grpc-gateway/v2 v2.27.3 h1:NmZ1PKzSTQbuGHw9DGPFomqkkLWMC+vZCkfs+FHv1Vg= github.com/grpc-ecosystem/grpc-gateway/v2 v2.27.3/go.mod h1:zQrxl1YP88HQlA6i9c63DSVPFklWpGX4OWAc9bFuaH4= -github.com/henderiw/apiserver-builder v0.0.6 h1:8vlnpGmQsIgSCVNNSQKaBeHtbAtgCvKoKQii7Vx3YLk= -github.com/henderiw/apiserver-builder v0.0.6/go.mod h1:Py2AD4oB1McoYpz4chBNAFo9bYeZ9N9cKPijzkMxk2U= +github.com/henderiw/apiserver-builder v0.0.7-0.20260302093549-7ef05fb00905 h1:PrVO840pQejbWI0/u4z3B/qAF6IB55gXVDSbr1sHaA4= +github.com/henderiw/apiserver-builder v0.0.7-0.20260302093549-7ef05fb00905/go.mod h1:Py2AD4oB1McoYpz4chBNAFo9bYeZ9N9cKPijzkMxk2U= github.com/henderiw/apiserver-store v0.0.4-0.20260302081117-f4f810bec88b h1:iFG9vtD2eDR481k8/Y8rVBzNGXHsHdQLYS5aRk34lbA= github.com/henderiw/apiserver-store v0.0.4-0.20260302081117-f4f810bec88b/go.mod h1:RuXLMHJwszn6LXgL6fO9fxMC7AW5wAc4zOddnnZpkKI= github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c h1:nFnCNyRV1Ej/zqV/gn8UnFESkoPUXhwpUCZyhSYGSYA= diff --git a/pkg/registry/generic/store.go b/pkg/registry/generic/store.go index 8773a9b2..72c6b2dd 100644 --- a/pkg/registry/generic/store.go +++ b/pkg/registry/generic/store.go @@ -45,11 +45,23 @@ func NewStorageProvider(ctx context.Context, obj resource.InternalObject, opts * return NewREST(obj, scheme, watcherManager, optsGetter, opts) }, } + // status subresources if statusobj, ok := obj.(resource.ObjectWithStatusSubResource); ok { sp.StatusSubResourceStorageProviderFn = func(scheme *runtime.Scheme, store rest.Storage) (rest.Storage, error) { return NewStatusREST(statusobj, scheme, watcherManager, opts, store) } } + + // arbitrary subresources + if arb, ok := obj.(resource.ObjectWithArbitrarySubResource); ok { + sp.ArbitrarySubresourceHandlerProviders = make(map[string]builderrest.SubResourceStorageProviderFn) + for _, sub := range arb.GetArbitrarySubResources() { + sub := sub + sp.ArbitrarySubresourceHandlerProviders[sub.SubResourceName()] = func(scheme *runtime.Scheme, store rest.Storage) (rest.Storage, error) { + return sub.NewStorage(scheme, store) + } + } + } // Add addtional subresources return sp } From bdd55691fcfafba70a27b9416a3cdca5ec674c2e Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Mon, 2 Mar 2026 10:39:55 +0100 Subject: [PATCH 098/135] update g fmt --- apis/config/target_resource.go | 2 +- apis/config/target_types.go | 6 +++--- apis/config/v1alpha1/generated.pb.go | 1 - cmd/api-server/main.go | 1 - pkg/reconcilers/resource/finalizer.go | 2 -- pkg/registry/configblame/strategy_resource.go | 2 +- pkg/registry/generic/store.go | 18 +++++++++--------- pkg/registry/generic/strategy_status.go | 4 ++-- 8 files changed, 16 insertions(+), 20 deletions(-) diff --git a/apis/config/target_resource.go b/apis/config/target_resource.go index 7dc75df1..1fe3c6aa 100644 --- a/apis/config/target_resource.go +++ b/apis/config/target_resource.go @@ -25,6 +25,7 @@ import ( "github.com/henderiw/apiserver-store/pkg/generic/registry" "github.com/henderiw/apiserver-store/pkg/storebackend" "github.com/sdcio/config-server/apis/condition" + dsclient "github.com/sdcio/config-server/pkg/sdc/dataserver/client" "github.com/sdcio/sdc-protos/sdcpb" apiequality "k8s.io/apimachinery/pkg/api/equality" apierrors "k8s.io/apimachinery/pkg/api/errors" @@ -36,7 +37,6 @@ import ( "k8s.io/apimachinery/pkg/util/validation/field" genericapirequest "k8s.io/apiserver/pkg/endpoints/request" "k8s.io/apiserver/pkg/registry/rest" - dsclient "github.com/sdcio/config-server/pkg/sdc/dataserver/client" ) const ( diff --git a/apis/config/target_types.go b/apis/config/target_types.go index 818418a7..8991be22 100644 --- a/apis/config/target_types.go +++ b/apis/config/target_types.go @@ -92,9 +92,9 @@ type Target struct { metav1.TypeMeta `json:",inline" yaml:",inline"` metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` - Spec TargetSpec `json:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"` - Status TargetStatus `json:"status,omitempty" protobuf:"bytes,3,opt,name=status"` - Running TargetRunning `json:"running,omitempty" protobuf:"bytes,4,opt,name=running"` + Spec TargetSpec `json:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"` + Status TargetStatus `json:"status,omitempty" protobuf:"bytes,3,opt,name=status"` + Running TargetRunning `json:"running,omitempty" protobuf:"bytes,4,opt,name=running"` } // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object diff --git a/apis/config/v1alpha1/generated.pb.go b/apis/config/v1alpha1/generated.pb.go index 6f553179..585f452f 100644 --- a/apis/config/v1alpha1/generated.pb.go +++ b/apis/config/v1alpha1/generated.pb.go @@ -104,7 +104,6 @@ func (m *TargetStatus) Reset() { *m = TargetStatus{} } func (m *TargetStatusUsedReferences) Reset() { *m = TargetStatusUsedReferences{} } - func (m *Config) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) diff --git a/cmd/api-server/main.go b/cmd/api-server/main.go index 3f95cff9..afb226f3 100644 --- a/cmd/api-server/main.go +++ b/cmd/api-server/main.go @@ -58,7 +58,6 @@ var ( func main() { logs.InitLogs() defer logs.FlushLogs() - l := log.NewLogger(&log.HandlerOptions{Name: "sdc-api-server-logger", AddSource: false}) slog.SetDefault(l) diff --git a/pkg/reconcilers/resource/finalizer.go b/pkg/reconcilers/resource/finalizer.go index 3d8f0c82..b8fe9b5b 100644 --- a/pkg/reconcilers/resource/finalizer.go +++ b/pkg/reconcilers/resource/finalizer.go @@ -57,7 +57,6 @@ func (r *APIFinalizer) AddFinalizer(ctx context.Context, obj client.Object) erro log.FromContext(ctx).Info("SSA applying finalizer", "fieldManager", r.fieldManager, "finalizer", r.finalizer) applyConfig := r.buildApply(obj.GetName(), obj.GetNamespace(), r.finalizer) - log.FromContext(ctx).Info("SSA applying finalizer", "fieldManager", r.fieldManager, "applyConfig", applyConfig) return r.client.Apply(ctx, applyConfig, &client.ApplyOptions{ @@ -72,7 +71,6 @@ func (r *APIFinalizer) RemoveFinalizer(ctx context.Context, obj client.Object) e // Apply with no finalizers — SSA removes only what this field manager owns applyConfig := r.buildApply(obj.GetName(), obj.GetNamespace()) - log.FromContext(ctx).Info("SSA removing finalizer", "fieldManager", r.fieldManager, "applyConfig", applyConfig) return r.client.Apply(ctx, applyConfig, &client.ApplyOptions{ diff --git a/pkg/registry/configblame/strategy_resource.go b/pkg/registry/configblame/strategy_resource.go index f99b3fd0..6ed5ca32 100644 --- a/pkg/registry/configblame/strategy_resource.go +++ b/pkg/registry/configblame/strategy_resource.go @@ -274,7 +274,7 @@ func (r *strategy) Watch(ctx context.Context, options *metainternalversion.ListO cancel: cancel, resultChan: make(chan watch.Event), watcherManager: r.watcherManager, - obj: r.obj, + obj: r.obj, } go w.listAndWatch(ctx, r, options) diff --git a/pkg/registry/generic/store.go b/pkg/registry/generic/store.go index 72c6b2dd..b2e30892 100644 --- a/pkg/registry/generic/store.go +++ b/pkg/registry/generic/store.go @@ -53,15 +53,15 @@ func NewStorageProvider(ctx context.Context, obj resource.InternalObject, opts * } // arbitrary subresources - if arb, ok := obj.(resource.ObjectWithArbitrarySubResource); ok { - sp.ArbitrarySubresourceHandlerProviders = make(map[string]builderrest.SubResourceStorageProviderFn) - for _, sub := range arb.GetArbitrarySubResources() { - sub := sub - sp.ArbitrarySubresourceHandlerProviders[sub.SubResourceName()] = func(scheme *runtime.Scheme, store rest.Storage) (rest.Storage, error) { - return sub.NewStorage(scheme, store) - } - } - } + if arb, ok := obj.(resource.ObjectWithArbitrarySubResource); ok { + sp.ArbitrarySubresourceHandlerProviders = make(map[string]builderrest.SubResourceStorageProviderFn) + for _, sub := range arb.GetArbitrarySubResources() { + sub := sub + sp.ArbitrarySubresourceHandlerProviders[sub.SubResourceName()] = func(scheme *runtime.Scheme, store rest.Storage) (rest.Storage, error) { + return sub.NewStorage(scheme, store) + } + } + } // Add addtional subresources return sp } diff --git a/pkg/registry/generic/strategy_status.go b/pkg/registry/generic/strategy_status.go index eed1647a..657d1306 100644 --- a/pkg/registry/generic/strategy_status.go +++ b/pkg/registry/generic/strategy_status.go @@ -91,12 +91,12 @@ func (r *statusStrategy) InvokeUpdate(ctx context.Context, obj, old runtime.Obje } func (r *statusStrategy) Update(ctx context.Context, key types.NamespacedName, obj, old runtime.Object, dryrun bool) (runtime.Object, error) { - + if shouldLog(obj) { logObject(ctx, "Update Status New", key, obj) logObject(ctx, "Update Status Old", key, old) } - + // check if there is a change if r.obj.IsStatusEqual(ctx, obj, old) { return obj, nil From d08d753e10c91b41754cc3f1296ada57ccf61ed3 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Mon, 2 Mar 2026 10:51:15 +0100 Subject: [PATCH 099/135] update g fmt --- apis/config/condition.go | 7 ++++--- apis/config/target_helpers.go | 4 ++-- apis/config/target_resource.go | 3 ++- 3 files changed, 8 insertions(+), 6 deletions(-) diff --git a/apis/config/condition.go b/apis/config/condition.go index a5faa21f..5c25b5b9 100644 --- a/apis/config/condition.go +++ b/apis/config/condition.go @@ -27,12 +27,13 @@ const ( ) const ( + // Target relation conditions // ConditionTypeDiscoveryReady represents the resource discovery ready condition - ConditionTypeDiscoveryReady cond.ConditionType = "DiscoveryReady" + ConditionTypeTargetDiscoveryReady cond.ConditionType = "TargetDiscoveryReady" // ConditionTypeDatastoreReady represents the resource datastore ready condition - ConditionTypeDatastoreReady cond.ConditionType = "DatastoreReady" + ConditionTypeTargetDatastoreReady cond.ConditionType = "TargetDatastoreReady" // ConditionTypeConfigRecoveryReady represents the resource config recovery ready condition - ConditionTypeConfigRecoveryReady cond.ConditionType = "ConfigRecoveryReady" + ConditionTypeTargetConfigRecoveryReady cond.ConditionType = "TargetConfigRecoveryReady" // ConditionTypeTargetConnectionReady represents the resource target ready condition ConditionTypeTargetConnectionReady cond.ConditionType = "TargetConnectionReady" diff --git a/apis/config/target_helpers.go b/apis/config/target_helpers.go index d2cab47e..37f2b935 100644 --- a/apis/config/target_helpers.go +++ b/apis/config/target_helpers.go @@ -72,8 +72,8 @@ func BuildEmptyTarget() *Target { func (r *Target) IsReady() bool { return r.GetCondition(condition.ConditionTypeReady).Status == metav1.ConditionTrue && - r.GetCondition(ConditionTypeDiscoveryReady).Status == metav1.ConditionTrue && - r.GetCondition(ConditionTypeDatastoreReady).Status == metav1.ConditionTrue && + r.GetCondition(ConditionTypeTargetDiscoveryReady).Status == metav1.ConditionTrue && + r.GetCondition(ConditionTypeTargetDatastoreReady).Status == metav1.ConditionTrue && r.GetCondition(ConditionTypeTargetConnectionReady).Status == metav1.ConditionTrue } diff --git a/apis/config/target_resource.go b/apis/config/target_resource.go index 1fe3c6aa..a4cc2d24 100644 --- a/apis/config/target_resource.go +++ b/apis/config/target_resource.go @@ -353,7 +353,8 @@ func (r *targetRunningREST) Get(ctx context.Context, name string, options *metav target := obj.(*Target) if !target.IsReady() { - return nil, apierrors.NewNotFound(target.GetGroupVersionResource().GroupResource(), name) + return nil, apierrors.NewServiceUnavailable( + fmt.Sprintf("target %s is not ready: %s", name, target.GetCondition(condition.ConditionTypeReady).Message)) } cfg := &dsclient.Config{ From 4db798f105f10fb9f913bbba24b42d2a457a328f Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Mon, 2 Mar 2026 10:58:33 +0100 Subject: [PATCH 100/135] update rsp log --- apis/config/target_resource.go | 2 ++ 1 file changed, 2 insertions(+) diff --git a/apis/config/target_resource.go b/apis/config/target_resource.go index a4cc2d24..8c7e6a28 100644 --- a/apis/config/target_resource.go +++ b/apis/config/target_resource.go @@ -384,6 +384,8 @@ func (r *targetRunningREST) Get(ctx context.Context, name string, options *metav return nil, err } + fmt.Println("runnning config: %s", rsp.GetBlob()) + target.Running.Value.Raw = rsp.GetBlob() return target, nil From 9fb8557e3e18d8390ba8e41cab45474b0b395d58 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Mon, 2 Mar 2026 10:58:51 +0100 Subject: [PATCH 101/135] update rsp log --- apis/config/target_resource.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/apis/config/target_resource.go b/apis/config/target_resource.go index 8c7e6a28..684d9c1b 100644 --- a/apis/config/target_resource.go +++ b/apis/config/target_resource.go @@ -384,7 +384,7 @@ func (r *targetRunningREST) Get(ctx context.Context, name string, options *metav return nil, err } - fmt.Println("runnning config: %s", rsp.GetBlob()) + fmt.Printf("runnning config: %s", rsp.GetBlob()) target.Running.Value.Raw = rsp.GetBlob() From e64d706873c6d6de7dc125e0bd1f9eb0ac0ee2d4 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Mon, 2 Mar 2026 11:05:21 +0100 Subject: [PATCH 102/135] update genclient/deepcopy --- apis/config/target_types.go | 12 ++++++------ .../config/v1alpha1/zz_generated.conversion.go | 6 +----- apis/config/zz_generated.deepcopy.go | 18 ++++++++++++++++++ 3 files changed, 25 insertions(+), 11 deletions(-) diff --git a/apis/config/target_types.go b/apis/config/target_types.go index 8991be22..8149c47b 100644 --- a/apis/config/target_types.go +++ b/apis/config/target_types.go @@ -74,10 +74,10 @@ type TargetRunning struct { } type TargetStatusUsedReferences struct { - SecretResourceVersion string `json:"secretResourceVersion,omitempty" yaml:"secretResourceVersion,omitempty" protobuf:"bytes,1,opt,name=secretResourceVersion"` - TLSSecretResourceVersion string `json:"tlsSecretResourceVersion,omitempty" yaml:"tlsSecretResourceVersion,omitempty" protobuf:"bytes,2,opt,name=tlsSecretResourceVersion"` - ConnectionProfileResourceVersion string `json:"connectionProfileResourceVersion" yaml:"connectionProfileResourceVersion" protobuf:"bytes,3,opt,name=connectionProfileResourceVersion"` - SyncProfileResourceVersion string `json:"syncProfileResourceVersion" yaml:"syncProfileResourceVersion" protobuf:"bytes,4,opt,name=syncProfileResourceVersion"` + SecretResourceVersion string `json:"secretResourceVersion,omitempty" protobuf:"bytes,1,opt,name=secretResourceVersion"` + TLSSecretResourceVersion string `json:"tlsSecretResourceVersion,omitempty" protobuf:"bytes,2,opt,name=tlsSecretResourceVersion"` + ConnectionProfileResourceVersion string `json:"connectionProfileResourceVersion" protobuf:"bytes,3,opt,name=connectionProfileResourceVersion"` + SyncProfileResourceVersion string `json:"syncProfileResourceVersion" protobuf:"bytes,4,opt,name=syncProfileResourceVersion"` } // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object @@ -89,7 +89,7 @@ type TargetStatusUsedReferences struct { // Target is the Schema for the Target API // +k8s:openapi-gen=true type Target struct { - metav1.TypeMeta `json:",inline" yaml:",inline"` + metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` Spec TargetSpec `json:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"` @@ -102,7 +102,7 @@ type Target struct { // TargetList contains a list of Targets type TargetList struct { - metav1.TypeMeta `json:",inline" yaml:",inline"` + metav1.TypeMeta `json:",inline"` metav1.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` Items []Target `json:"items" protobuf:"bytes,2,rep,name=items"` } diff --git a/apis/config/v1alpha1/zz_generated.conversion.go b/apis/config/v1alpha1/zz_generated.conversion.go index 19c26e75..967dcd26 100644 --- a/apis/config/v1alpha1/zz_generated.conversion.go +++ b/apis/config/v1alpha1/zz_generated.conversion.go @@ -1365,14 +1365,10 @@ func autoConvert_config_Target_To_v1alpha1_Target(in *config.Target, out *Target if err := Convert_config_TargetStatus_To_v1alpha1_TargetStatus(&in.Status, &out.Status, s); err != nil { return err } + // WARNING: in.Running requires manual conversion: does not exist in peer-type return nil } -// Convert_config_Target_To_v1alpha1_Target is an autogenerated conversion function. -func Convert_config_Target_To_v1alpha1_Target(in *config.Target, out *Target, s conversion.Scope) error { - return autoConvert_config_Target_To_v1alpha1_Target(in, out, s) -} - func autoConvert_v1alpha1_TargetList_To_config_TargetList(in *TargetList, out *config.TargetList, s conversion.Scope) error { out.ListMeta = in.ListMeta if in.Items != nil { diff --git a/apis/config/zz_generated.deepcopy.go b/apis/config/zz_generated.deepcopy.go index 733769a4..5b9419f7 100644 --- a/apis/config/zz_generated.deepcopy.go +++ b/apis/config/zz_generated.deepcopy.go @@ -1107,6 +1107,7 @@ func (in *Target) DeepCopyInto(out *Target) { in.ObjectMeta.DeepCopyInto(&out.ObjectMeta) in.Spec.DeepCopyInto(&out.Spec) in.Status.DeepCopyInto(&out.Status) + in.Running.DeepCopyInto(&out.Running) return } @@ -1177,6 +1178,23 @@ func (in *TargetList) DeepCopyObject() runtime.Object { return nil } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *TargetRunning) DeepCopyInto(out *TargetRunning) { + *out = *in + in.Value.DeepCopyInto(&out.Value) + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new TargetRunning. +func (in *TargetRunning) DeepCopy() *TargetRunning { + if in == nil { + return nil + } + out := new(TargetRunning) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *TargetSpec) DeepCopyInto(out *TargetSpec) { *out = *in From 0bbaee23815898be81c98d39986444e8b7bca032 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Mon, 2 Mar 2026 11:09:02 +0100 Subject: [PATCH 103/135] update genclient/deepcopy --- apis/config/v1alpha1/target_types.go | 29 ++++++++----- .../v1alpha1/zz_generated.conversion.go | 42 ++++++++++++++++++- apis/config/v1alpha1/zz_generated.deepcopy.go | 18 ++++++++ .../config/v1alpha1/target.go | 13 +++++- .../config/v1alpha1/targetrunning.go | 42 +++++++++++++++++++ pkg/generated/applyconfiguration/utils.go | 2 + pkg/generated/openapi/zz_generated.openapi.go | 29 ++++++++++++- 7 files changed, 160 insertions(+), 15 deletions(-) create mode 100644 pkg/generated/applyconfiguration/config/v1alpha1/targetrunning.go diff --git a/apis/config/v1alpha1/target_types.go b/apis/config/v1alpha1/target_types.go index e5d82b68..85f0f9cf 100644 --- a/apis/config/v1alpha1/target_types.go +++ b/apis/config/v1alpha1/target_types.go @@ -22,6 +22,7 @@ import ( condv1alpha1 "github.com/sdcio/config-server/apis/condition/v1alpha1" invv1alpha1 "github.com/sdcio/config-server/apis/inv/v1alpha1" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/runtime" "k8s.io/apimachinery/pkg/runtime/schema" ) @@ -68,10 +69,15 @@ type DiscoveryInfo struct { } type TargetStatusUsedReferences struct { - SecretResourceVersion string `json:"secretResourceVersion,omitempty" yaml:"secretResourceVersion,omitempty" protobuf:"bytes,1,opt,name=secretResourceVersion"` - TLSSecretResourceVersion string `json:"tlsSecretResourceVersion,omitempty" yaml:"tlsSecretResourceVersion,omitempty" protobuf:"bytes,2,opt,name=tlsSecretResourceVersion"` - ConnectionProfileResourceVersion string `json:"connectionProfileResourceVersion" yaml:"connectionProfileResourceVersion" protobuf:"bytes,3,opt,name=connectionProfileResourceVersion"` - SyncProfileResourceVersion string `json:"syncProfileResourceVersion" yaml:"syncProfileResourceVersion" protobuf:"bytes,4,opt,name=syncProfileResourceVersion"` + SecretResourceVersion string `json:"secretResourceVersion,omitempty" protobuf:"bytes,1,opt,name=secretResourceVersion"` + TLSSecretResourceVersion string `json:"tlsSecretResourceVersion,omitempty" protobuf:"bytes,2,opt,name=tlsSecretResourceVersion"` + ConnectionProfileResourceVersion string `json:"connectionProfileResourceVersion" protobuf:"bytes,3,opt,name=connectionProfileResourceVersion"` + SyncProfileResourceVersion string `json:"syncProfileResourceVersion" protobuf:"bytes,4,opt,name=syncProfileResourceVersion"` +} + +type TargetRunning struct { + //+kubebuilder:pruning:PreserveUnknownFields + Value runtime.RawExtension `json:"value" protobuf:"bytes,2,opt,name=value"` } // +genclient @@ -84,11 +90,12 @@ type TargetStatusUsedReferences struct { // Target is the Schema for the Target API // +k8s:openapi-gen=true type Target struct { - metav1.TypeMeta `json:",inline" yaml:",inline"` - metav1.ObjectMeta `json:"metadata,omitempty" yaml:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + metav1.TypeMeta `json:",inline"` + metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` - Spec TargetSpec `json:"spec,omitempty" yaml:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"` - Status TargetStatus `json:"status,omitempty" yaml:"status,omitempty" protobuf:"bytes,3,opt,name=status"` + Spec TargetSpec `json:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"` + Status TargetStatus `json:"status,omitempty" protobuf:"bytes,3,opt,name=status"` + Running TargetRunning `json:"running,omitempty" protobuf:"bytes,4,opt,name=running"` } // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object @@ -96,9 +103,9 @@ type Target struct { // TargetList contains a list of Targets type TargetList struct { - metav1.TypeMeta `json:",inline" yaml:",inline"` - metav1.ListMeta `json:"metadata,omitempty" yaml:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` - Items []Target `json:"items" yaml:"items" protobuf:"bytes,2,rep,name=items"` + metav1.TypeMeta `json:",inline"` + metav1.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + Items []Target `json:"items" protobuf:"bytes,2,rep,name=items"` } var ( diff --git a/apis/config/v1alpha1/zz_generated.conversion.go b/apis/config/v1alpha1/zz_generated.conversion.go index 967dcd26..f3ce9856 100644 --- a/apis/config/v1alpha1/zz_generated.conversion.go +++ b/apis/config/v1alpha1/zz_generated.conversion.go @@ -378,6 +378,16 @@ func RegisterConversions(s *runtime.Scheme) error { }); err != nil { return err } + if err := s.AddGeneratedConversionFunc((*TargetRunning)(nil), (*config.TargetRunning)(nil), func(a, b interface{}, scope conversion.Scope) error { + return Convert_v1alpha1_TargetRunning_To_config_TargetRunning(a.(*TargetRunning), b.(*config.TargetRunning), scope) + }); err != nil { + return err + } + if err := s.AddGeneratedConversionFunc((*config.TargetRunning)(nil), (*TargetRunning)(nil), func(a, b interface{}, scope conversion.Scope) error { + return Convert_config_TargetRunning_To_v1alpha1_TargetRunning(a.(*config.TargetRunning), b.(*TargetRunning), scope) + }); err != nil { + return err + } if err := s.AddGeneratedConversionFunc((*TargetSpec)(nil), (*config.TargetSpec)(nil), func(a, b interface{}, scope conversion.Scope) error { return Convert_v1alpha1_TargetSpec_To_config_TargetSpec(a.(*TargetSpec), b.(*config.TargetSpec), scope) }); err != nil { @@ -1349,6 +1359,9 @@ func autoConvert_v1alpha1_Target_To_config_Target(in *Target, out *config.Target if err := Convert_v1alpha1_TargetStatus_To_config_TargetStatus(&in.Status, &out.Status, s); err != nil { return err } + if err := Convert_v1alpha1_TargetRunning_To_config_TargetRunning(&in.Running, &out.Running, s); err != nil { + return err + } return nil } @@ -1365,10 +1378,17 @@ func autoConvert_config_Target_To_v1alpha1_Target(in *config.Target, out *Target if err := Convert_config_TargetStatus_To_v1alpha1_TargetStatus(&in.Status, &out.Status, s); err != nil { return err } - // WARNING: in.Running requires manual conversion: does not exist in peer-type + if err := Convert_config_TargetRunning_To_v1alpha1_TargetRunning(&in.Running, &out.Running, s); err != nil { + return err + } return nil } +// Convert_config_Target_To_v1alpha1_Target is an autogenerated conversion function. +func Convert_config_Target_To_v1alpha1_Target(in *config.Target, out *Target, s conversion.Scope) error { + return autoConvert_config_Target_To_v1alpha1_Target(in, out, s) +} + func autoConvert_v1alpha1_TargetList_To_config_TargetList(in *TargetList, out *config.TargetList, s conversion.Scope) error { out.ListMeta = in.ListMeta if in.Items != nil { @@ -1411,6 +1431,26 @@ func Convert_config_TargetList_To_v1alpha1_TargetList(in *config.TargetList, out return autoConvert_config_TargetList_To_v1alpha1_TargetList(in, out, s) } +func autoConvert_v1alpha1_TargetRunning_To_config_TargetRunning(in *TargetRunning, out *config.TargetRunning, s conversion.Scope) error { + out.Value = in.Value + return nil +} + +// Convert_v1alpha1_TargetRunning_To_config_TargetRunning is an autogenerated conversion function. +func Convert_v1alpha1_TargetRunning_To_config_TargetRunning(in *TargetRunning, out *config.TargetRunning, s conversion.Scope) error { + return autoConvert_v1alpha1_TargetRunning_To_config_TargetRunning(in, out, s) +} + +func autoConvert_config_TargetRunning_To_v1alpha1_TargetRunning(in *config.TargetRunning, out *TargetRunning, s conversion.Scope) error { + out.Value = in.Value + return nil +} + +// Convert_config_TargetRunning_To_v1alpha1_TargetRunning is an autogenerated conversion function. +func Convert_config_TargetRunning_To_v1alpha1_TargetRunning(in *config.TargetRunning, out *TargetRunning, s conversion.Scope) error { + return autoConvert_config_TargetRunning_To_v1alpha1_TargetRunning(in, out, s) +} + func autoConvert_v1alpha1_TargetSpec_To_config_TargetSpec(in *TargetSpec, out *config.TargetSpec, s conversion.Scope) error { out.Provider = in.Provider out.Address = in.Address diff --git a/apis/config/v1alpha1/zz_generated.deepcopy.go b/apis/config/v1alpha1/zz_generated.deepcopy.go index d5b1ca11..1c0b0e7a 100644 --- a/apis/config/v1alpha1/zz_generated.deepcopy.go +++ b/apis/config/v1alpha1/zz_generated.deepcopy.go @@ -848,6 +848,7 @@ func (in *Target) DeepCopyInto(out *Target) { in.ObjectMeta.DeepCopyInto(&out.ObjectMeta) in.Spec.DeepCopyInto(&out.Spec) in.Status.DeepCopyInto(&out.Status) + in.Running.DeepCopyInto(&out.Running) return } @@ -902,6 +903,23 @@ func (in *TargetList) DeepCopyObject() runtime.Object { return nil } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *TargetRunning) DeepCopyInto(out *TargetRunning) { + *out = *in + in.Value.DeepCopyInto(&out.Value) + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new TargetRunning. +func (in *TargetRunning) DeepCopy() *TargetRunning { + if in == nil { + return nil + } + out := new(TargetRunning) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *TargetSpec) DeepCopyInto(out *TargetSpec) { *out = *in diff --git a/pkg/generated/applyconfiguration/config/v1alpha1/target.go b/pkg/generated/applyconfiguration/config/v1alpha1/target.go index 36d91e10..d5a88231 100644 --- a/pkg/generated/applyconfiguration/config/v1alpha1/target.go +++ b/pkg/generated/applyconfiguration/config/v1alpha1/target.go @@ -30,8 +30,9 @@ import ( type TargetApplyConfiguration struct { v1.TypeMetaApplyConfiguration `json:",inline"` *v1.ObjectMetaApplyConfiguration `json:"metadata,omitempty"` - Spec *TargetSpecApplyConfiguration `json:"spec,omitempty"` - Status *TargetStatusApplyConfiguration `json:"status,omitempty"` + Spec *TargetSpecApplyConfiguration `json:"spec,omitempty"` + Status *TargetStatusApplyConfiguration `json:"status,omitempty"` + Running *TargetRunningApplyConfiguration `json:"running,omitempty"` } // Target constructs a declarative configuration of the Target type for use with @@ -221,6 +222,14 @@ func (b *TargetApplyConfiguration) WithStatus(value *TargetStatusApplyConfigurat return b } +// WithRunning sets the Running field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Running field is set to the value of the last call. +func (b *TargetApplyConfiguration) WithRunning(value *TargetRunningApplyConfiguration) *TargetApplyConfiguration { + b.Running = value + return b +} + // GetKind retrieves the value of the Kind field in the declarative configuration. func (b *TargetApplyConfiguration) GetKind() *string { return b.TypeMetaApplyConfiguration.Kind diff --git a/pkg/generated/applyconfiguration/config/v1alpha1/targetrunning.go b/pkg/generated/applyconfiguration/config/v1alpha1/targetrunning.go new file mode 100644 index 00000000..dd918d91 --- /dev/null +++ b/pkg/generated/applyconfiguration/config/v1alpha1/targetrunning.go @@ -0,0 +1,42 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ +// Code generated by applyconfiguration-gen. DO NOT EDIT. + +package v1alpha1 + +import ( + runtime "k8s.io/apimachinery/pkg/runtime" +) + +// TargetRunningApplyConfiguration represents a declarative configuration of the TargetRunning type for use +// with apply. +type TargetRunningApplyConfiguration struct { + Value *runtime.RawExtension `json:"value,omitempty"` +} + +// TargetRunningApplyConfiguration constructs a declarative configuration of the TargetRunning type for use with +// apply. +func TargetRunning() *TargetRunningApplyConfiguration { + return &TargetRunningApplyConfiguration{} +} + +// WithValue sets the Value field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Value field is set to the value of the last call. +func (b *TargetRunningApplyConfiguration) WithValue(value runtime.RawExtension) *TargetRunningApplyConfiguration { + b.Value = &value + return b +} diff --git a/pkg/generated/applyconfiguration/utils.go b/pkg/generated/applyconfiguration/utils.go index 354baa37..4012a32a 100644 --- a/pkg/generated/applyconfiguration/utils.go +++ b/pkg/generated/applyconfiguration/utils.go @@ -83,6 +83,8 @@ func ForKind(kind schema.GroupVersionKind) interface{} { return &configv1alpha1.SensitiveConfigStatusApplyConfiguration{} case v1alpha1.SchemeGroupVersion.WithKind("Target"): return &configv1alpha1.TargetApplyConfiguration{} + case v1alpha1.SchemeGroupVersion.WithKind("TargetRunning"): + return &configv1alpha1.TargetRunningApplyConfiguration{} case v1alpha1.SchemeGroupVersion.WithKind("TargetSpec"): return &configv1alpha1.TargetSpecApplyConfiguration{} case v1alpha1.SchemeGroupVersion.WithKind("TargetStatus"): diff --git a/pkg/generated/openapi/zz_generated.openapi.go b/pkg/generated/openapi/zz_generated.openapi.go index c84a233f..53becaee 100644 --- a/pkg/generated/openapi/zz_generated.openapi.go +++ b/pkg/generated/openapi/zz_generated.openapi.go @@ -69,6 +69,7 @@ func GetOpenAPIDefinitions(ref common.ReferenceCallback) map[string]common.OpenA "github.com/sdcio/config-server/apis/config/v1alpha1.SensitiveConfigStatus": schema_config_server_apis_config_v1alpha1_SensitiveConfigStatus(ref), "github.com/sdcio/config-server/apis/config/v1alpha1.Target": schema_config_server_apis_config_v1alpha1_Target(ref), "github.com/sdcio/config-server/apis/config/v1alpha1.TargetList": schema_config_server_apis_config_v1alpha1_TargetList(ref), + "github.com/sdcio/config-server/apis/config/v1alpha1.TargetRunning": schema_config_server_apis_config_v1alpha1_TargetRunning(ref), "github.com/sdcio/config-server/apis/config/v1alpha1.TargetSpec": schema_config_server_apis_config_v1alpha1_TargetSpec(ref), "github.com/sdcio/config-server/apis/config/v1alpha1.TargetStatus": schema_config_server_apis_config_v1alpha1_TargetStatus(ref), "github.com/sdcio/config-server/apis/config/v1alpha1.TargetStatusUsedReferences": schema_config_server_apis_config_v1alpha1_TargetStatusUsedReferences(ref), @@ -1993,6 +1994,12 @@ func schema_config_server_apis_config_v1alpha1_Target(ref common.ReferenceCallba Ref: ref("github.com/sdcio/config-server/apis/config/v1alpha1.TargetStatus"), }, }, + "running": { + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("github.com/sdcio/config-server/apis/config/v1alpha1.TargetRunning"), + }, + }, }, }, VendorExtensible: spec.VendorExtensible{ @@ -2004,7 +2011,7 @@ func schema_config_server_apis_config_v1alpha1_Target(ref common.ReferenceCallba }, }, Dependencies: []string{ - "github.com/sdcio/config-server/apis/config/v1alpha1.TargetSpec", "github.com/sdcio/config-server/apis/config/v1alpha1.TargetStatus", metav1.ObjectMeta{}.OpenAPIModelName()}, + "github.com/sdcio/config-server/apis/config/v1alpha1.TargetRunning", "github.com/sdcio/config-server/apis/config/v1alpha1.TargetSpec", "github.com/sdcio/config-server/apis/config/v1alpha1.TargetStatus", metav1.ObjectMeta{}.OpenAPIModelName()}, } } @@ -2057,6 +2064,26 @@ func schema_config_server_apis_config_v1alpha1_TargetList(ref common.ReferenceCa } } +func schema_config_server_apis_config_v1alpha1_TargetRunning(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "value": { + SchemaProps: spec.SchemaProps{ + Ref: ref(runtime.RawExtension{}.OpenAPIModelName()), + }, + }, + }, + Required: []string{"value"}, + }, + }, + Dependencies: []string{ + runtime.RawExtension{}.OpenAPIModelName()}, + } +} + func schema_config_server_apis_config_v1alpha1_TargetSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { return common.OpenAPIDefinition{ Schema: spec.Schema{ From 2e831662a26a53d468a857e3b9c17b9c64d75dbd Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Mon, 2 Mar 2026 11:11:30 +0100 Subject: [PATCH 104/135] update makefile robustness --- Makefile | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/Makefile b/Makefile index 0eb9444f..90a06f51 100644 --- a/Makefile +++ b/Makefile @@ -64,7 +64,8 @@ genclients: -g defaulter-gen \ -g conversion-gen \ -g applyconfiguration-gen \ - --module $(REPO) \ + --module $(REPO) + $(MAKE) fix-openapi-gvk .PHONY: genproto genproto: @@ -82,6 +83,7 @@ fix-openapi-gvk: .PHONY: generate generate: controller-gen $(CONTROLLER_GEN) object:headerFile="hack/boilerplate.go.txt" paths="./apis/inv/..." + $(MAKE) genclients .PHONY: manifests manifests: controller-gen crds artifacts ## Generate WebhookConfiguration, ClusterRole and CustomResourceDefinition objects. From e4f94d14135bd83986cf5bcd408a6d0582e96ab9 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Mon, 2 Mar 2026 18:34:33 +0100 Subject: [PATCH 105/135] added blame, running, cleardeviation --- apis/config/target_blame_resource.go | 125 +++++++ apis/config/target_blame_types.go | 34 ++ apis/config/target_cleardeviation_resource.go | 108 ++++++ apis/config/target_cleardeviation_types.go | 44 +++ apis/config/target_resource.go | 94 +---- apis/config/target_running_resource.go | 110 ++++++ apis/config/target_running_types.go | 34 ++ apis/config/target_types.go | 7 - apis/config/v1alpha1/target_blame_types.go | 34 ++ .../v1alpha1/target_cleardeviation_types.go | 44 +++ apis/config/v1alpha1/target_running_types.go | 34 ++ apis/config/v1alpha1/target_types.go | 11 +- .../v1alpha1/zz_generated.conversion.go | 144 ++++++- apis/config/v1alpha1/zz_generated.deepcopy.go | 103 ++++- apis/config/zz_generated.deepcopy.go | 103 ++++- apis/inv/v1alpha1/target_helpers.go | 153 -------- apis/inv/v1alpha1/target_types.go | 120 ------ artifacts/inv.sdcio.dev_discoveryrules.yaml | 5 + ...inv.sdcio.dev_discoveryvendorprofiles.yaml | 1 + artifacts/inv.sdcio.dev_rollouts.yaml | 13 +- artifacts/inv.sdcio.dev_schemas.yaml | 19 +- artifacts/inv.sdcio.dev_subscriptions.yaml | 3 + .../inv.sdcio.dev_targetsyncprofiles.yaml | 2 + artifacts/inv.sdcio.dev_workspaces.yaml | 12 +- crds/config.sdcio.dev_configblames.yaml | 2 +- crds/config.sdcio.dev_configs.yaml | 4 +- crds/config.sdcio.dev_configsets.yaml | 2 + .../config.sdcio.dev_deviationclears.yaml | 139 ++----- crds/config.sdcio.dev_deviations.yaml | 7 +- crds/config.sdcio.dev_runningconfigs.yaml | 2 +- crds/config.sdcio.dev_sensitiveconfigs.yaml | 5 +- crds/config.sdcio.dev_targetblames.yaml | 46 +++ ...onfig.sdcio.dev_targetcleardeviations.yaml | 63 ++++ crds/config.sdcio.dev_targetrunnings.yaml | 46 +++ crds/config.sdcio.dev_targets.yaml | 354 ++++++++++++++++++ crds/inv.sdcio.dev_discoveryrules.yaml | 5 + ...inv.sdcio.dev_discoveryvendorprofiles.yaml | 1 + crds/inv.sdcio.dev_rollouts.yaml | 13 +- crds/inv.sdcio.dev_schemas.yaml | 19 +- crds/inv.sdcio.dev_subscriptions.yaml | 3 + crds/inv.sdcio.dev_targetsyncprofiles.yaml | 2 + crds/inv.sdcio.dev_workspaces.yaml | 12 +- go.mod | 4 +- go.sum | 8 +- .../config/v1alpha1/target.go | 13 +- pkg/generated/applyconfiguration/utils.go | 2 - pkg/generated/openapi/zz_generated.openapi.go | 196 +++++++++- 47 files changed, 1744 insertions(+), 561 deletions(-) create mode 100644 apis/config/target_blame_resource.go create mode 100644 apis/config/target_blame_types.go create mode 100644 apis/config/target_cleardeviation_resource.go create mode 100644 apis/config/target_cleardeviation_types.go create mode 100644 apis/config/target_running_resource.go create mode 100644 apis/config/target_running_types.go create mode 100644 apis/config/v1alpha1/target_blame_types.go create mode 100644 apis/config/v1alpha1/target_cleardeviation_types.go create mode 100644 apis/config/v1alpha1/target_running_types.go delete mode 100644 apis/inv/v1alpha1/target_helpers.go delete mode 100644 apis/inv/v1alpha1/target_types.go rename artifacts/inv.sdcio.dev_targets.yaml => crds/config.sdcio.dev_deviationclears.yaml (52%) create mode 100644 crds/config.sdcio.dev_targetblames.yaml create mode 100644 crds/config.sdcio.dev_targetcleardeviations.yaml create mode 100644 crds/config.sdcio.dev_targetrunnings.yaml create mode 100644 crds/config.sdcio.dev_targets.yaml diff --git a/apis/config/target_blame_resource.go b/apis/config/target_blame_resource.go new file mode 100644 index 00000000..eb6d798f --- /dev/null +++ b/apis/config/target_blame_resource.go @@ -0,0 +1,125 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package config + +import ( + "context" + "fmt" + + "github.com/henderiw/apiserver-builder/pkg/builder/resource" + "github.com/henderiw/apiserver-store/pkg/storebackend" + "github.com/sdcio/config-server/apis/condition" + dsclient "github.com/sdcio/config-server/pkg/sdc/dataserver/client" + "github.com/sdcio/sdc-protos/sdcpb" + "google.golang.org/protobuf/encoding/protojson" + apierrors "k8s.io/apimachinery/pkg/api/errors" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apiserver/pkg/registry/rest" +) + +var _ resource.ArbitrarySubResource = &TargetClearDeviation{} + +func (TargetBlame) SubResourceName() string { + return "blame" +} + +func (TargetBlame) New() runtime.Object { + return &TargetBlame{} // returns parent type — GET returns the full Target +} + +func (TargetBlame) NewStorage(scheme *runtime.Scheme, parentStorage rest.Storage) (rest.Storage, error) { + return &targetRunningREST{ + parentStore: parentStorage, + }, nil +} + +// targetBlameREST implements rest.Storage + rest.Getter +type targetBlameREST struct { + parentStore rest.Storage +} + +func (r *targetBlameREST) New() runtime.Object { + return &TargetBlame{} +} + +func (r *targetBlameREST) Destroy() {} + +func (r *targetBlameREST) Get(ctx context.Context, name string, options *metav1.GetOptions) (runtime.Object, error) { + // Get the parent Target from the parent store + getter := r.parentStore.(rest.Getter) + + obj, err := getter.Get(ctx, name, options) + if err != nil { + return nil, err + } + target := obj.(*Target) + + if !target.IsReady() { + return nil, apierrors.NewServiceUnavailable( + fmt.Sprintf("target %s is not ready: %s", name, target.GetCondition(condition.ConditionTypeReady).Message)) + } + + cfg := &dsclient.Config{ + Address: dsclient.GetDataServerAddress(), + Insecure: true, + } + + dsclient, closeFn, err := dsclient.NewEphemeral(ctx, cfg) + if err != nil { + return nil, err + } + defer func() { + if err := closeFn(); err != nil { + // You can use your preferred logging framework here + fmt.Printf("failed to close connection: %v\n", err) + } + }() + + // check if the schema exists; this is == nil check; in case of err it does not exist + key := target.GetNamespacedName() + rsp, err := dsclient.BlameConfig(ctx, &sdcpb.BlameConfigRequest{ + DatastoreName: storebackend.KeyFromNSN(key).String(), + IncludeDefaults: true, + }) + if err != nil { + return nil, err + } + + if rsp == nil || rsp.ConfigTree == nil { + return &TargetBlame{ + ObjectMeta: metav1.ObjectMeta{ + Name: target.Name, + Namespace: target.Namespace, + }, + Value: runtime.RawExtension{Raw: nil}, + }, nil + } + + json, err := protojson.Marshal(rsp.ConfigTree) + if err != nil { + return nil, err + } + + return &TargetBlame{ + ObjectMeta: metav1.ObjectMeta{ + Name: target.Name, + Namespace: target.Namespace, + }, + Value: runtime.RawExtension{Raw: json}, + }, nil +} diff --git a/apis/config/target_blame_types.go b/apis/config/target_blame_types.go new file mode 100644 index 00000000..602fba73 --- /dev/null +++ b/apis/config/target_blame_types.go @@ -0,0 +1,34 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package config + +import ( + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/runtime" +) + +// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object +// +k8s:openapi-gen=true + +// TargetBlame is the Schema for the TargetBlame API +type TargetBlame struct { + metav1.TypeMeta `json:",inline"` + metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + + //+kubebuilder:pruning:PreserveUnknownFields + Value runtime.RawExtension `json:"value" protobuf:"bytes,2,opt,name=value"` +} diff --git a/apis/config/target_cleardeviation_resource.go b/apis/config/target_cleardeviation_resource.go new file mode 100644 index 00000000..dad1a746 --- /dev/null +++ b/apis/config/target_cleardeviation_resource.go @@ -0,0 +1,108 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package config + +import ( + "context" + "fmt" + + "github.com/henderiw/apiserver-builder/pkg/builder/resource" + dsclient "github.com/sdcio/config-server/pkg/sdc/dataserver/client" + apierrors "k8s.io/apimachinery/pkg/api/errors" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apiserver/pkg/registry/rest" +) + +var _ resource.ArbitrarySubResource = &TargetClearDeviation{} + +func (TargetClearDeviation) SubResourceName() string { + return "cleardeviation" +} + +func (TargetClearDeviation) New() runtime.Object { + return &TargetClearDeviation{} +} + +func (TargetClearDeviation) NewStorage(scheme *runtime.Scheme, parentStorage rest.Storage) (rest.Storage, error) { + return &targetClearDeviationREST{ + parentStore: parentStorage, + }, nil +} + +// storage +type targetClearDeviationREST struct { + parentStore rest.Storage +} + +func (r *targetClearDeviationREST) New() runtime.Object { + return &TargetClearDeviation{} +} + +func (r *targetClearDeviationREST) Destroy() {} + +// Create handles POST /apis/.../targets/{name}/cleardeviation +func (r *targetClearDeviationREST) Create( + ctx context.Context, + obj runtime.Object, + createValidation rest.ValidateObjectFunc, + options *metav1.CreateOptions, +) (runtime.Object, error) { + req := obj.(*TargetClearDeviation) + + // Get parent target name from the request object's name + name := req.Name + + // Get the parent target to validate it exists and is ready + getter := r.parentStore.(rest.Getter) + parentObj, err := getter.Get(ctx, name, &metav1.GetOptions{}) + if err != nil { + return nil, err + } + target := parentObj.(*Target) + + if !target.IsReady() { + return nil, apierrors.NewServiceUnavailable( + fmt.Sprintf("target %s is not ready", name)) + } + + // Do the actual clear deviation work + // e.g. call dataserver to clear deviations + key := target.GetNamespacedName() + cfg := &dsclient.Config{ + Address: dsclient.GetDataServerAddress(), + Insecure: true, + } + client, closeFn, err := dsclient.NewEphemeral(ctx, cfg) + if err != nil { + return nil, err + } + defer closeFn() + + // Your actual clear deviation RPC call here + _ = client + _ = key + _ = req.Spec + + // TODO update status + req.Status = TargetClearDeviationStatus{ + Cleared: 3, + Message: "successfully cleared deviations", + } + + return req, nil +} diff --git a/apis/config/target_cleardeviation_types.go b/apis/config/target_cleardeviation_types.go new file mode 100644 index 00000000..83564c1c --- /dev/null +++ b/apis/config/target_cleardeviation_types.go @@ -0,0 +1,44 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package config + +import ( + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" +) + +// TargetClearDeviationSpec defines the desired state of Target +type TargetClearDeviationSpec struct { + // Paths provide the path of the deviation to be cleared + Paths []string `json:"paths" protobuf:"bytes,1,rep,name=paths"` +} + +type TargetClearDeviationStatus struct { + Cleared int `json:"cleared" protobuf:"bytes,1,opt,name=cleared"` + Message string `json:"message" protobuf:"bytes,2,opt,name=message"` +} + +// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object + +// TargetClearDeviation is the Schema for the TargetClearDeviation API +// +k8s:openapi-gen=true +type TargetClearDeviation struct { + metav1.TypeMeta `json:",inline"` + metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + + Spec TargetClearDeviationSpec `json:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"` + Status TargetClearDeviationStatus `json:"status,omitempty" protobuf:"bytes,3,opt,name=status"` +} diff --git a/apis/config/target_resource.go b/apis/config/target_resource.go index 684d9c1b..61b5cf2a 100644 --- a/apis/config/target_resource.go +++ b/apis/config/target_resource.go @@ -23,10 +23,7 @@ import ( "github.com/henderiw/apiserver-builder/pkg/builder/resource" "github.com/henderiw/apiserver-store/pkg/generic/registry" - "github.com/henderiw/apiserver-store/pkg/storebackend" "github.com/sdcio/config-server/apis/condition" - dsclient "github.com/sdcio/config-server/pkg/sdc/dataserver/client" - "github.com/sdcio/sdc-protos/sdcpb" apiequality "k8s.io/apimachinery/pkg/api/equality" apierrors "k8s.io/apimachinery/pkg/api/errors" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" @@ -55,6 +52,16 @@ var _ resource.ObjectList = &TargetList{} var _ resource.ObjectWithStatusSubResource = &Target{} var _ resource.StatusSubResource = &TargetStatus{} +var _ resource.ObjectWithArbitrarySubResource = &Target{} + +func (r *Target) GetArbitrarySubResources() []resource.ArbitrarySubResource { + return []resource.ArbitrarySubResource{ + &TargetRunning{}, + &TargetClearDeviation{}, + &TargetBlame{}, + } +} + func (Target) GetGroupVersionResource() schema.GroupVersionResource { return schema.GroupVersionResource{ Group: SchemeGroupVersion.Group, @@ -309,84 +316,3 @@ func (r *Target) ValidateUpdate(ctx context.Context, obj, old runtime.Object) fi return allErrs } - -var _ resource.ObjectWithArbitrarySubResource = &Target{} - -func (r *Target) GetArbitrarySubResources() []resource.ArbitrarySubResource { - return []resource.ArbitrarySubResource{ - &TargetRunning{}, - } -} - -func (TargetRunning) SubResourceName() string { - return "running" -} - -func (TargetRunning) New() runtime.Object { - return &Target{} // returns parent type — GET returns the full Target -} - -func (TargetRunning) NewStorage(scheme *runtime.Scheme, parentStorage rest.Storage) (rest.Storage, error) { - return &targetRunningREST{ - parentStore: parentStorage, - }, nil -} - -// targetRunningREST implements rest.Storage + rest.Getter -type targetRunningREST struct { - parentStore rest.Storage -} - -func (r *targetRunningREST) New() runtime.Object { - return &Target{} -} - -func (r *targetRunningREST) Destroy() {} - -func (r *targetRunningREST) Get(ctx context.Context, name string, options *metav1.GetOptions) (runtime.Object, error) { - // Get the parent Target from the parent store - getter := r.parentStore.(rest.Getter) - obj, err := getter.Get(ctx, name, options) - if err != nil { - return nil, err - } - target := obj.(*Target) - - if !target.IsReady() { - return nil, apierrors.NewServiceUnavailable( - fmt.Sprintf("target %s is not ready: %s", name, target.GetCondition(condition.ConditionTypeReady).Message)) - } - - cfg := &dsclient.Config{ - Address: dsclient.GetDataServerAddress(), - Insecure: true, - } - - dsclient, closeFn, err := dsclient.NewEphemeral(ctx, cfg) - if err != nil { - return nil, err - } - defer func() { - if err := closeFn(); err != nil { - // You can use your preferred logging framework here - fmt.Printf("failed to close connection: %v\n", err) - } - }() - - // check if the schema exists; this is == nil check; in case of err it does not exist - key := target.GetNamespacedName() - rsp, err := dsclient.GetIntent(ctx, &sdcpb.GetIntentRequest{ - DatastoreName: storebackend.KeyFromNSN(key).String(), - Intent: "running", - Format: sdcpb.Format_Intent_Format_JSON, - }) - if err != nil { - return nil, err - } - - fmt.Printf("runnning config: %s", rsp.GetBlob()) - - target.Running.Value.Raw = rsp.GetBlob() - - return target, nil -} diff --git a/apis/config/target_running_resource.go b/apis/config/target_running_resource.go new file mode 100644 index 00000000..571a9bc0 --- /dev/null +++ b/apis/config/target_running_resource.go @@ -0,0 +1,110 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package config + +import ( + "context" + "fmt" + + "github.com/henderiw/apiserver-builder/pkg/builder/resource" + "github.com/henderiw/apiserver-store/pkg/storebackend" + "github.com/sdcio/config-server/apis/condition" + dsclient "github.com/sdcio/config-server/pkg/sdc/dataserver/client" + "github.com/sdcio/sdc-protos/sdcpb" + apierrors "k8s.io/apimachinery/pkg/api/errors" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apiserver/pkg/registry/rest" +) + +var _ resource.ArbitrarySubResource = &TargetClearDeviation{} + +func (TargetRunning) SubResourceName() string { + return "running" +} + +func (TargetRunning) New() runtime.Object { + return &TargetRunning{} // returns parent type — GET returns the full Target +} + +func (TargetRunning) NewStorage(scheme *runtime.Scheme, parentStorage rest.Storage) (rest.Storage, error) { + return &targetRunningREST{ + parentStore: parentStorage, + }, nil +} + +// targetRunningREST implements rest.Storage + rest.Getter +type targetRunningREST struct { + parentStore rest.Storage +} + +func (r *targetRunningREST) New() runtime.Object { + return &TargetRunning{} +} + +func (r *targetRunningREST) Destroy() {} + +func (r *targetRunningREST) Get(ctx context.Context, name string, options *metav1.GetOptions) (runtime.Object, error) { + // Get the parent Target from the parent store + getter := r.parentStore.(rest.Getter) + obj, err := getter.Get(ctx, name, options) + if err != nil { + return nil, err + } + target := obj.(*Target) + + if !target.IsReady() { + return nil, apierrors.NewServiceUnavailable( + fmt.Sprintf("target %s is not ready: %s", name, + target.GetCondition(condition.ConditionTypeReady).Message)) + } + + cfg := &dsclient.Config{ + Address: dsclient.GetDataServerAddress(), + Insecure: true, + } + + dsclient, closeFn, err := dsclient.NewEphemeral(ctx, cfg) + if err != nil { + return nil, err + } + defer func() { + if err := closeFn(); err != nil { + // You can use your preferred logging framework here + fmt.Printf("failed to close connection: %v\n", err) + } + }() + + // check if the schema exists; this is == nil check; in case of err it does not exist + key := target.GetNamespacedName() + rsp, err := dsclient.GetIntent(ctx, &sdcpb.GetIntentRequest{ + DatastoreName: storebackend.KeyFromNSN(key).String(), + Intent: "running", + Format: sdcpb.Format_Intent_Format_JSON, + }) + if err != nil { + return nil, err + } + + return &TargetRunning{ + ObjectMeta: metav1.ObjectMeta{ + Name: target.Name, + Namespace: target.Namespace, + }, + Value: runtime.RawExtension{Raw: rsp.GetBlob()}, + }, nil +} diff --git a/apis/config/target_running_types.go b/apis/config/target_running_types.go new file mode 100644 index 00000000..cbf62afb --- /dev/null +++ b/apis/config/target_running_types.go @@ -0,0 +1,34 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package config + +import ( + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/runtime" +) + +// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object +// +k8s:openapi-gen=true + +// TargetRunning is the Schema for the TargetRunning API +type TargetRunning struct { + metav1.TypeMeta `json:",inline"` + metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + + //+kubebuilder:pruning:PreserveUnknownFields + Value runtime.RawExtension `json:"value" protobuf:"bytes,2,opt,name=value"` +} diff --git a/apis/config/target_types.go b/apis/config/target_types.go index 8149c47b..143e2b27 100644 --- a/apis/config/target_types.go +++ b/apis/config/target_types.go @@ -22,7 +22,6 @@ import ( "github.com/sdcio/config-server/apis/condition" invv1alpha1 "github.com/sdcio/config-server/apis/inv/v1alpha1" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" - "k8s.io/apimachinery/pkg/runtime" "k8s.io/apimachinery/pkg/runtime/schema" ) @@ -68,11 +67,6 @@ type DiscoveryInfo struct { //LastSeen metav1.Time `json:"lastSeen,omitempty"` } -type TargetRunning struct { - //+kubebuilder:pruning:PreserveUnknownFields - Value runtime.RawExtension `json:"value" protobuf:"bytes,2,opt,name=value"` -} - type TargetStatusUsedReferences struct { SecretResourceVersion string `json:"secretResourceVersion,omitempty" protobuf:"bytes,1,opt,name=secretResourceVersion"` TLSSecretResourceVersion string `json:"tlsSecretResourceVersion,omitempty" protobuf:"bytes,2,opt,name=tlsSecretResourceVersion"` @@ -94,7 +88,6 @@ type Target struct { Spec TargetSpec `json:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"` Status TargetStatus `json:"status,omitempty" protobuf:"bytes,3,opt,name=status"` - Running TargetRunning `json:"running,omitempty" protobuf:"bytes,4,opt,name=running"` } // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object diff --git a/apis/config/v1alpha1/target_blame_types.go b/apis/config/v1alpha1/target_blame_types.go new file mode 100644 index 00000000..2d584500 --- /dev/null +++ b/apis/config/v1alpha1/target_blame_types.go @@ -0,0 +1,34 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1alpha1 + +import ( + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/runtime" +) + +// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object +// +k8s:openapi-gen=true + +// TargetBlame is the Schema for the TargetBlame API +type TargetBlame struct { + metav1.TypeMeta `json:",inline"` + metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + + //+kubebuilder:pruning:PreserveUnknownFields + Value runtime.RawExtension `json:"value" protobuf:"bytes,2,opt,name=value"` +} diff --git a/apis/config/v1alpha1/target_cleardeviation_types.go b/apis/config/v1alpha1/target_cleardeviation_types.go new file mode 100644 index 00000000..c2fb349f --- /dev/null +++ b/apis/config/v1alpha1/target_cleardeviation_types.go @@ -0,0 +1,44 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1alpha1 + +import ( + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" +) + +// TargetClearDeviationSpec defines the desired state of Target +type TargetClearDeviationSpec struct { + // Paths provide the path of the deviation to be cleared + Paths []string `json:"paths" protobuf:"bytes,1,rep,name=paths"` +} + +type TargetClearDeviationStatus struct { + Cleared int `json:"cleared" protobuf:"bytes,1,opt,name=cleared"` + Message string `json:"message" protobuf:"bytes,2,opt,name=message"` +} + +// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object + +// TargetClearDeviation is the Schema for the TargetClearDeviation API +// +k8s:openapi-gen=true +type TargetClearDeviation struct { + metav1.TypeMeta `json:",inline"` + metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + + Spec TargetClearDeviationSpec `json:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"` + Status TargetClearDeviationStatus `json:"status,omitempty" protobuf:"bytes,3,opt,name=status"` +} diff --git a/apis/config/v1alpha1/target_running_types.go b/apis/config/v1alpha1/target_running_types.go new file mode 100644 index 00000000..1d6e59cf --- /dev/null +++ b/apis/config/v1alpha1/target_running_types.go @@ -0,0 +1,34 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1alpha1 + +import ( + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/runtime" +) + +// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object +// +k8s:openapi-gen=true + +// TargetRunning is the Schema for the TargetRunning API +type TargetRunning struct { + metav1.TypeMeta `json:",inline"` + metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + + //+kubebuilder:pruning:PreserveUnknownFields + Value runtime.RawExtension `json:"value" protobuf:"bytes,2,opt,name=value"` +} diff --git a/apis/config/v1alpha1/target_types.go b/apis/config/v1alpha1/target_types.go index 85f0f9cf..d2b90de0 100644 --- a/apis/config/v1alpha1/target_types.go +++ b/apis/config/v1alpha1/target_types.go @@ -22,7 +22,6 @@ import ( condv1alpha1 "github.com/sdcio/config-server/apis/condition/v1alpha1" invv1alpha1 "github.com/sdcio/config-server/apis/inv/v1alpha1" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" - "k8s.io/apimachinery/pkg/runtime" "k8s.io/apimachinery/pkg/runtime/schema" ) @@ -75,11 +74,6 @@ type TargetStatusUsedReferences struct { SyncProfileResourceVersion string `json:"syncProfileResourceVersion" protobuf:"bytes,4,opt,name=syncProfileResourceVersion"` } -type TargetRunning struct { - //+kubebuilder:pruning:PreserveUnknownFields - Value runtime.RawExtension `json:"value" protobuf:"bytes,2,opt,name=value"` -} - // +genclient // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object // +kubebuilder:object:root=true @@ -93,9 +87,8 @@ type Target struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` - Spec TargetSpec `json:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"` - Status TargetStatus `json:"status,omitempty" protobuf:"bytes,3,opt,name=status"` - Running TargetRunning `json:"running,omitempty" protobuf:"bytes,4,opt,name=running"` + Spec TargetSpec `json:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"` + Status TargetStatus `json:"status,omitempty" protobuf:"bytes,3,opt,name=status"` } // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object diff --git a/apis/config/v1alpha1/zz_generated.conversion.go b/apis/config/v1alpha1/zz_generated.conversion.go index f3ce9856..3dff6def 100644 --- a/apis/config/v1alpha1/zz_generated.conversion.go +++ b/apis/config/v1alpha1/zz_generated.conversion.go @@ -368,6 +368,46 @@ func RegisterConversions(s *runtime.Scheme) error { }); err != nil { return err } + if err := s.AddGeneratedConversionFunc((*TargetBlame)(nil), (*config.TargetBlame)(nil), func(a, b interface{}, scope conversion.Scope) error { + return Convert_v1alpha1_TargetBlame_To_config_TargetBlame(a.(*TargetBlame), b.(*config.TargetBlame), scope) + }); err != nil { + return err + } + if err := s.AddGeneratedConversionFunc((*config.TargetBlame)(nil), (*TargetBlame)(nil), func(a, b interface{}, scope conversion.Scope) error { + return Convert_config_TargetBlame_To_v1alpha1_TargetBlame(a.(*config.TargetBlame), b.(*TargetBlame), scope) + }); err != nil { + return err + } + if err := s.AddGeneratedConversionFunc((*TargetClearDeviation)(nil), (*config.TargetClearDeviation)(nil), func(a, b interface{}, scope conversion.Scope) error { + return Convert_v1alpha1_TargetClearDeviation_To_config_TargetClearDeviation(a.(*TargetClearDeviation), b.(*config.TargetClearDeviation), scope) + }); err != nil { + return err + } + if err := s.AddGeneratedConversionFunc((*config.TargetClearDeviation)(nil), (*TargetClearDeviation)(nil), func(a, b interface{}, scope conversion.Scope) error { + return Convert_config_TargetClearDeviation_To_v1alpha1_TargetClearDeviation(a.(*config.TargetClearDeviation), b.(*TargetClearDeviation), scope) + }); err != nil { + return err + } + if err := s.AddGeneratedConversionFunc((*TargetClearDeviationSpec)(nil), (*config.TargetClearDeviationSpec)(nil), func(a, b interface{}, scope conversion.Scope) error { + return Convert_v1alpha1_TargetClearDeviationSpec_To_config_TargetClearDeviationSpec(a.(*TargetClearDeviationSpec), b.(*config.TargetClearDeviationSpec), scope) + }); err != nil { + return err + } + if err := s.AddGeneratedConversionFunc((*config.TargetClearDeviationSpec)(nil), (*TargetClearDeviationSpec)(nil), func(a, b interface{}, scope conversion.Scope) error { + return Convert_config_TargetClearDeviationSpec_To_v1alpha1_TargetClearDeviationSpec(a.(*config.TargetClearDeviationSpec), b.(*TargetClearDeviationSpec), scope) + }); err != nil { + return err + } + if err := s.AddGeneratedConversionFunc((*TargetClearDeviationStatus)(nil), (*config.TargetClearDeviationStatus)(nil), func(a, b interface{}, scope conversion.Scope) error { + return Convert_v1alpha1_TargetClearDeviationStatus_To_config_TargetClearDeviationStatus(a.(*TargetClearDeviationStatus), b.(*config.TargetClearDeviationStatus), scope) + }); err != nil { + return err + } + if err := s.AddGeneratedConversionFunc((*config.TargetClearDeviationStatus)(nil), (*TargetClearDeviationStatus)(nil), func(a, b interface{}, scope conversion.Scope) error { + return Convert_config_TargetClearDeviationStatus_To_v1alpha1_TargetClearDeviationStatus(a.(*config.TargetClearDeviationStatus), b.(*TargetClearDeviationStatus), scope) + }); err != nil { + return err + } if err := s.AddGeneratedConversionFunc((*TargetList)(nil), (*config.TargetList)(nil), func(a, b interface{}, scope conversion.Scope) error { return Convert_v1alpha1_TargetList_To_config_TargetList(a.(*TargetList), b.(*config.TargetList), scope) }); err != nil { @@ -1359,9 +1399,6 @@ func autoConvert_v1alpha1_Target_To_config_Target(in *Target, out *config.Target if err := Convert_v1alpha1_TargetStatus_To_config_TargetStatus(&in.Status, &out.Status, s); err != nil { return err } - if err := Convert_v1alpha1_TargetRunning_To_config_TargetRunning(&in.Running, &out.Running, s); err != nil { - return err - } return nil } @@ -1378,9 +1415,6 @@ func autoConvert_config_Target_To_v1alpha1_Target(in *config.Target, out *Target if err := Convert_config_TargetStatus_To_v1alpha1_TargetStatus(&in.Status, &out.Status, s); err != nil { return err } - if err := Convert_config_TargetRunning_To_v1alpha1_TargetRunning(&in.Running, &out.Running, s); err != nil { - return err - } return nil } @@ -1389,6 +1423,102 @@ func Convert_config_Target_To_v1alpha1_Target(in *config.Target, out *Target, s return autoConvert_config_Target_To_v1alpha1_Target(in, out, s) } +func autoConvert_v1alpha1_TargetBlame_To_config_TargetBlame(in *TargetBlame, out *config.TargetBlame, s conversion.Scope) error { + out.ObjectMeta = in.ObjectMeta + out.Value = in.Value + return nil +} + +// Convert_v1alpha1_TargetBlame_To_config_TargetBlame is an autogenerated conversion function. +func Convert_v1alpha1_TargetBlame_To_config_TargetBlame(in *TargetBlame, out *config.TargetBlame, s conversion.Scope) error { + return autoConvert_v1alpha1_TargetBlame_To_config_TargetBlame(in, out, s) +} + +func autoConvert_config_TargetBlame_To_v1alpha1_TargetBlame(in *config.TargetBlame, out *TargetBlame, s conversion.Scope) error { + out.ObjectMeta = in.ObjectMeta + out.Value = in.Value + return nil +} + +// Convert_config_TargetBlame_To_v1alpha1_TargetBlame is an autogenerated conversion function. +func Convert_config_TargetBlame_To_v1alpha1_TargetBlame(in *config.TargetBlame, out *TargetBlame, s conversion.Scope) error { + return autoConvert_config_TargetBlame_To_v1alpha1_TargetBlame(in, out, s) +} + +func autoConvert_v1alpha1_TargetClearDeviation_To_config_TargetClearDeviation(in *TargetClearDeviation, out *config.TargetClearDeviation, s conversion.Scope) error { + out.ObjectMeta = in.ObjectMeta + if err := Convert_v1alpha1_TargetClearDeviationSpec_To_config_TargetClearDeviationSpec(&in.Spec, &out.Spec, s); err != nil { + return err + } + if err := Convert_v1alpha1_TargetClearDeviationStatus_To_config_TargetClearDeviationStatus(&in.Status, &out.Status, s); err != nil { + return err + } + return nil +} + +// Convert_v1alpha1_TargetClearDeviation_To_config_TargetClearDeviation is an autogenerated conversion function. +func Convert_v1alpha1_TargetClearDeviation_To_config_TargetClearDeviation(in *TargetClearDeviation, out *config.TargetClearDeviation, s conversion.Scope) error { + return autoConvert_v1alpha1_TargetClearDeviation_To_config_TargetClearDeviation(in, out, s) +} + +func autoConvert_config_TargetClearDeviation_To_v1alpha1_TargetClearDeviation(in *config.TargetClearDeviation, out *TargetClearDeviation, s conversion.Scope) error { + out.ObjectMeta = in.ObjectMeta + if err := Convert_config_TargetClearDeviationSpec_To_v1alpha1_TargetClearDeviationSpec(&in.Spec, &out.Spec, s); err != nil { + return err + } + if err := Convert_config_TargetClearDeviationStatus_To_v1alpha1_TargetClearDeviationStatus(&in.Status, &out.Status, s); err != nil { + return err + } + return nil +} + +// Convert_config_TargetClearDeviation_To_v1alpha1_TargetClearDeviation is an autogenerated conversion function. +func Convert_config_TargetClearDeviation_To_v1alpha1_TargetClearDeviation(in *config.TargetClearDeviation, out *TargetClearDeviation, s conversion.Scope) error { + return autoConvert_config_TargetClearDeviation_To_v1alpha1_TargetClearDeviation(in, out, s) +} + +func autoConvert_v1alpha1_TargetClearDeviationSpec_To_config_TargetClearDeviationSpec(in *TargetClearDeviationSpec, out *config.TargetClearDeviationSpec, s conversion.Scope) error { + out.Paths = *(*[]string)(unsafe.Pointer(&in.Paths)) + return nil +} + +// Convert_v1alpha1_TargetClearDeviationSpec_To_config_TargetClearDeviationSpec is an autogenerated conversion function. +func Convert_v1alpha1_TargetClearDeviationSpec_To_config_TargetClearDeviationSpec(in *TargetClearDeviationSpec, out *config.TargetClearDeviationSpec, s conversion.Scope) error { + return autoConvert_v1alpha1_TargetClearDeviationSpec_To_config_TargetClearDeviationSpec(in, out, s) +} + +func autoConvert_config_TargetClearDeviationSpec_To_v1alpha1_TargetClearDeviationSpec(in *config.TargetClearDeviationSpec, out *TargetClearDeviationSpec, s conversion.Scope) error { + out.Paths = *(*[]string)(unsafe.Pointer(&in.Paths)) + return nil +} + +// Convert_config_TargetClearDeviationSpec_To_v1alpha1_TargetClearDeviationSpec is an autogenerated conversion function. +func Convert_config_TargetClearDeviationSpec_To_v1alpha1_TargetClearDeviationSpec(in *config.TargetClearDeviationSpec, out *TargetClearDeviationSpec, s conversion.Scope) error { + return autoConvert_config_TargetClearDeviationSpec_To_v1alpha1_TargetClearDeviationSpec(in, out, s) +} + +func autoConvert_v1alpha1_TargetClearDeviationStatus_To_config_TargetClearDeviationStatus(in *TargetClearDeviationStatus, out *config.TargetClearDeviationStatus, s conversion.Scope) error { + out.Cleared = in.Cleared + out.Message = in.Message + return nil +} + +// Convert_v1alpha1_TargetClearDeviationStatus_To_config_TargetClearDeviationStatus is an autogenerated conversion function. +func Convert_v1alpha1_TargetClearDeviationStatus_To_config_TargetClearDeviationStatus(in *TargetClearDeviationStatus, out *config.TargetClearDeviationStatus, s conversion.Scope) error { + return autoConvert_v1alpha1_TargetClearDeviationStatus_To_config_TargetClearDeviationStatus(in, out, s) +} + +func autoConvert_config_TargetClearDeviationStatus_To_v1alpha1_TargetClearDeviationStatus(in *config.TargetClearDeviationStatus, out *TargetClearDeviationStatus, s conversion.Scope) error { + out.Cleared = in.Cleared + out.Message = in.Message + return nil +} + +// Convert_config_TargetClearDeviationStatus_To_v1alpha1_TargetClearDeviationStatus is an autogenerated conversion function. +func Convert_config_TargetClearDeviationStatus_To_v1alpha1_TargetClearDeviationStatus(in *config.TargetClearDeviationStatus, out *TargetClearDeviationStatus, s conversion.Scope) error { + return autoConvert_config_TargetClearDeviationStatus_To_v1alpha1_TargetClearDeviationStatus(in, out, s) +} + func autoConvert_v1alpha1_TargetList_To_config_TargetList(in *TargetList, out *config.TargetList, s conversion.Scope) error { out.ListMeta = in.ListMeta if in.Items != nil { @@ -1432,6 +1562,7 @@ func Convert_config_TargetList_To_v1alpha1_TargetList(in *config.TargetList, out } func autoConvert_v1alpha1_TargetRunning_To_config_TargetRunning(in *TargetRunning, out *config.TargetRunning, s conversion.Scope) error { + out.ObjectMeta = in.ObjectMeta out.Value = in.Value return nil } @@ -1442,6 +1573,7 @@ func Convert_v1alpha1_TargetRunning_To_config_TargetRunning(in *TargetRunning, o } func autoConvert_config_TargetRunning_To_v1alpha1_TargetRunning(in *config.TargetRunning, out *TargetRunning, s conversion.Scope) error { + out.ObjectMeta = in.ObjectMeta out.Value = in.Value return nil } diff --git a/apis/config/v1alpha1/zz_generated.deepcopy.go b/apis/config/v1alpha1/zz_generated.deepcopy.go index 1c0b0e7a..57582beb 100644 --- a/apis/config/v1alpha1/zz_generated.deepcopy.go +++ b/apis/config/v1alpha1/zz_generated.deepcopy.go @@ -848,7 +848,6 @@ func (in *Target) DeepCopyInto(out *Target) { in.ObjectMeta.DeepCopyInto(&out.ObjectMeta) in.Spec.DeepCopyInto(&out.Spec) in.Status.DeepCopyInto(&out.Status) - in.Running.DeepCopyInto(&out.Running) return } @@ -870,6 +869,98 @@ func (in *Target) DeepCopyObject() runtime.Object { return nil } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *TargetBlame) DeepCopyInto(out *TargetBlame) { + *out = *in + out.TypeMeta = in.TypeMeta + in.ObjectMeta.DeepCopyInto(&out.ObjectMeta) + in.Value.DeepCopyInto(&out.Value) + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new TargetBlame. +func (in *TargetBlame) DeepCopy() *TargetBlame { + if in == nil { + return nil + } + out := new(TargetBlame) + in.DeepCopyInto(out) + return out +} + +// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. +func (in *TargetBlame) DeepCopyObject() runtime.Object { + if c := in.DeepCopy(); c != nil { + return c + } + return nil +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *TargetClearDeviation) DeepCopyInto(out *TargetClearDeviation) { + *out = *in + out.TypeMeta = in.TypeMeta + in.ObjectMeta.DeepCopyInto(&out.ObjectMeta) + in.Spec.DeepCopyInto(&out.Spec) + out.Status = in.Status + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new TargetClearDeviation. +func (in *TargetClearDeviation) DeepCopy() *TargetClearDeviation { + if in == nil { + return nil + } + out := new(TargetClearDeviation) + in.DeepCopyInto(out) + return out +} + +// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. +func (in *TargetClearDeviation) DeepCopyObject() runtime.Object { + if c := in.DeepCopy(); c != nil { + return c + } + return nil +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *TargetClearDeviationSpec) DeepCopyInto(out *TargetClearDeviationSpec) { + *out = *in + if in.Paths != nil { + in, out := &in.Paths, &out.Paths + *out = make([]string, len(*in)) + copy(*out, *in) + } + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new TargetClearDeviationSpec. +func (in *TargetClearDeviationSpec) DeepCopy() *TargetClearDeviationSpec { + if in == nil { + return nil + } + out := new(TargetClearDeviationSpec) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *TargetClearDeviationStatus) DeepCopyInto(out *TargetClearDeviationStatus) { + *out = *in + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new TargetClearDeviationStatus. +func (in *TargetClearDeviationStatus) DeepCopy() *TargetClearDeviationStatus { + if in == nil { + return nil + } + out := new(TargetClearDeviationStatus) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *TargetList) DeepCopyInto(out *TargetList) { *out = *in @@ -906,6 +997,8 @@ func (in *TargetList) DeepCopyObject() runtime.Object { // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *TargetRunning) DeepCopyInto(out *TargetRunning) { *out = *in + out.TypeMeta = in.TypeMeta + in.ObjectMeta.DeepCopyInto(&out.ObjectMeta) in.Value.DeepCopyInto(&out.Value) return } @@ -920,6 +1013,14 @@ func (in *TargetRunning) DeepCopy() *TargetRunning { return out } +// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. +func (in *TargetRunning) DeepCopyObject() runtime.Object { + if c := in.DeepCopy(); c != nil { + return c + } + return nil +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *TargetSpec) DeepCopyInto(out *TargetSpec) { *out = *in diff --git a/apis/config/zz_generated.deepcopy.go b/apis/config/zz_generated.deepcopy.go index 5b9419f7..0f7f8761 100644 --- a/apis/config/zz_generated.deepcopy.go +++ b/apis/config/zz_generated.deepcopy.go @@ -1107,7 +1107,6 @@ func (in *Target) DeepCopyInto(out *Target) { in.ObjectMeta.DeepCopyInto(&out.ObjectMeta) in.Spec.DeepCopyInto(&out.Spec) in.Status.DeepCopyInto(&out.Status) - in.Running.DeepCopyInto(&out.Running) return } @@ -1129,6 +1128,98 @@ func (in *Target) DeepCopyObject() runtime.Object { return nil } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *TargetBlame) DeepCopyInto(out *TargetBlame) { + *out = *in + out.TypeMeta = in.TypeMeta + in.ObjectMeta.DeepCopyInto(&out.ObjectMeta) + in.Value.DeepCopyInto(&out.Value) + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new TargetBlame. +func (in *TargetBlame) DeepCopy() *TargetBlame { + if in == nil { + return nil + } + out := new(TargetBlame) + in.DeepCopyInto(out) + return out +} + +// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. +func (in *TargetBlame) DeepCopyObject() runtime.Object { + if c := in.DeepCopy(); c != nil { + return c + } + return nil +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *TargetClearDeviation) DeepCopyInto(out *TargetClearDeviation) { + *out = *in + out.TypeMeta = in.TypeMeta + in.ObjectMeta.DeepCopyInto(&out.ObjectMeta) + in.Spec.DeepCopyInto(&out.Spec) + out.Status = in.Status + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new TargetClearDeviation. +func (in *TargetClearDeviation) DeepCopy() *TargetClearDeviation { + if in == nil { + return nil + } + out := new(TargetClearDeviation) + in.DeepCopyInto(out) + return out +} + +// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. +func (in *TargetClearDeviation) DeepCopyObject() runtime.Object { + if c := in.DeepCopy(); c != nil { + return c + } + return nil +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *TargetClearDeviationSpec) DeepCopyInto(out *TargetClearDeviationSpec) { + *out = *in + if in.Paths != nil { + in, out := &in.Paths, &out.Paths + *out = make([]string, len(*in)) + copy(*out, *in) + } + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new TargetClearDeviationSpec. +func (in *TargetClearDeviationSpec) DeepCopy() *TargetClearDeviationSpec { + if in == nil { + return nil + } + out := new(TargetClearDeviationSpec) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *TargetClearDeviationStatus) DeepCopyInto(out *TargetClearDeviationStatus) { + *out = *in + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new TargetClearDeviationStatus. +func (in *TargetClearDeviationStatus) DeepCopy() *TargetClearDeviationStatus { + if in == nil { + return nil + } + out := new(TargetClearDeviationStatus) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *TargetFilter) DeepCopyInto(out *TargetFilter) { *out = *in @@ -1181,6 +1272,8 @@ func (in *TargetList) DeepCopyObject() runtime.Object { // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *TargetRunning) DeepCopyInto(out *TargetRunning) { *out = *in + out.TypeMeta = in.TypeMeta + in.ObjectMeta.DeepCopyInto(&out.ObjectMeta) in.Value.DeepCopyInto(&out.Value) return } @@ -1195,6 +1288,14 @@ func (in *TargetRunning) DeepCopy() *TargetRunning { return out } +// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. +func (in *TargetRunning) DeepCopyObject() runtime.Object { + if c := in.DeepCopy(); c != nil { + return c + } + return nil +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *TargetSpec) DeepCopyInto(out *TargetSpec) { *out = *in diff --git a/apis/inv/v1alpha1/target_helpers.go b/apis/inv/v1alpha1/target_helpers.go deleted file mode 100644 index 7c459179..00000000 --- a/apis/inv/v1alpha1/target_helpers.go +++ /dev/null @@ -1,153 +0,0 @@ -/* -Copyright 2024 Nokia. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ - -package v1alpha1 - -/* -import ( - "fmt" - strings "strings" - - condv1alpha1 "github.com/sdcio/config-server/apis/condition/v1alpha1" - metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" - "k8s.io/apimachinery/pkg/types" - "sigs.k8s.io/controller-runtime/pkg/client" -) - -// GetCondition returns the condition based on the condition kind -func (r *Target) GetCondition(t condv1alpha1.ConditionType) condv1alpha1.Condition { - return r.Status.GetCondition(t) -} - -// SetConditions sets the conditions on the resource. it allows for 0, 1 or more conditions -// to be set at once -func (r *Target) SetConditions(c ...condv1alpha1.Condition) { - r.Status.SetConditions(c...) -} - -func (r *Target) GetNamespacedName() types.NamespacedName { - return types.NamespacedName{Namespace: r.Namespace, Name: r.Name} -} - -func (r *Target) SetOverallStatus(target *Target) { - ready := true - msg := "target ready" - if ready && !target.GetCondition(ConditionTypeDiscoveryReady).IsTrue() { - ready = false - msg = "discovery not ready" // target.GetCondition(ConditionTypeDiscoveryReady).Message) - } - if ready && !target.GetCondition(ConditionTypeDatastoreReady).IsTrue() { - ready = false - msg = "datastore not ready" // target.GetCondition(ConditionTypeDatastoreReady).Message) - } - if ready && !target.GetCondition(ConditionTypeConfigRecoveryReady).IsTrue() { - ready = false - msg = "config not ready" //, target.GetCondition(ConditionTypeConfigReady).Message) - } - if ready && !target.GetCondition(ConditionTypeTargetConnectionReady).IsTrue() { - ready = false - msg = "datastore connection not ready" // target.GetCondition(ConditionTypeTargetConnectionReady).Message) - } - if ready { - r.Status.SetConditions(condv1alpha1.Ready()) - } else { - r.Status.SetConditions(condv1alpha1.Failed(msg)) - } -} - -func GetOverallStatus(target *Target) condv1alpha1.Condition { - ready := true - msg := "target ready" - if ready && !target.GetCondition(ConditionTypeDiscoveryReady).IsTrue() { - ready = false - msg = "discovery not ready" // target.GetCondition(ConditionTypeDiscoveryReady).Message) - } - if ready && !target.GetCondition(ConditionTypeDatastoreReady).IsTrue() { - ready = false - msg = "datastore not ready" // target.GetCondition(ConditionTypeDatastoreReady).Message) - } - if ready && !target.GetCondition(ConditionTypeConfigRecoveryReady).IsTrue() { - ready = false - msg = "config not ready" //, target.GetCondition(ConditionTypeConfigReady).Message) - } - if ready && !target.GetCondition(ConditionTypeTargetConnectionReady).IsTrue() { - ready = false - msg = "datastore connection not ready" // target.GetCondition(ConditionTypeTargetConnectionReady).Message) - } - if !ready { - return condv1alpha1.Failed(msg) - } - return condv1alpha1.Ready() -} - -func (r *Target) IsDatastoreReady() bool { - return r.GetCondition(ConditionTypeDiscoveryReady).Status == metav1.ConditionTrue && - r.GetCondition(ConditionTypeDatastoreReady).Status == metav1.ConditionTrue && - r.GetCondition(ConditionTypeTargetConnectionReady).Status == metav1.ConditionTrue -} - -func (r *Target) IsReady() bool { - return r.GetCondition(condv1alpha1.ConditionTypeReady).Status == metav1.ConditionTrue && - r.GetCondition(ConditionTypeDiscoveryReady).Status == metav1.ConditionTrue && - r.GetCondition(ConditionTypeDatastoreReady).Status == metav1.ConditionTrue && - r.GetCondition(ConditionTypeTargetConnectionReady).Status == metav1.ConditionTrue -} - -func (r *Target) NotReadyReason() string { - reasons := []string{} - - check := func(name string, cond condv1alpha1.Condition) { - if cond.Status != metav1.ConditionTrue { - reasons = append(reasons, - fmt.Sprintf("%s: %s (Reason: %s, Msg: %s)", - name, cond.Status, cond.Reason, cond.Message)) - } - } - - check("DiscoveryReady", r.GetCondition(ConditionTypeDiscoveryReady)) - check("DatastoreReady", r.GetCondition(ConditionTypeDatastoreReady)) - check("ConfigReady", r.GetCondition(ConditionTypeConfigRecoveryReady)) - check("ConnectionReady", r.GetCondition(ConditionTypeTargetConnectionReady)) - - if len(reasons) == 0 { - return "All conditions are ready" - } - - return strings.Join(reasons, "; ") -} - -func (r *TargetList) GetItems() []client.Object { - objs := []client.Object{} - for _, r := range r.Items { - objs = append(objs, &r) - } - return objs -} - -// BuildTarget returns a Target from a client Object a crName and -// an Target Spec/Status -func BuildTarget(meta metav1.ObjectMeta, spec TargetSpec, status TargetStatus) *Target { - return &Target{ - TypeMeta: metav1.TypeMeta{ - APIVersion: localSchemeBuilder.GroupVersion.Identifier(), - Kind: TargetKind, - }, - ObjectMeta: meta, - Spec: spec, - Status: status, - } -} -*/ diff --git a/apis/inv/v1alpha1/target_types.go b/apis/inv/v1alpha1/target_types.go deleted file mode 100644 index c3de4648..00000000 --- a/apis/inv/v1alpha1/target_types.go +++ /dev/null @@ -1,120 +0,0 @@ -/* -Copyright 2024 Nokia. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ - -package v1alpha1 - -/* -import ( - "reflect" - - condv1alpha1 "github.com/sdcio/config-server/apis/condition/v1alpha1" - metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" - "k8s.io/apimachinery/pkg/runtime/schema" -) - -// TargetSpec defines the desired state of Target -type TargetSpec struct { - // Provider specifies the provider using this target. - Provider string `json:"provider" protobuf:"bytes,1,opt,name=provider"` - // Address defines the address to connect to the target - Address string `json:"address" protobuf:"bytes,2,opt,name=address"` - // TargetProfile defines the Credentials/TLSSecret and sync/connectivity profile to connect to the target - TargetProfile `json:",inline" protobuf:"bytes,3,opt,name=targetProfile"` -} - -// TargetStatus defines the observed state of Target -type TargetStatus struct { - // ConditionedStatus provides the status of the Target using conditions - condv1alpha1.ConditionedStatus `json:",inline" protobuf:"bytes,1,opt,name=conditionedStatus"` - // Discovery info defines the information retrieved during discovery - DiscoveryInfo *DiscoveryInfo `json:"discoveryInfo,omitempty" protobuf:"bytes,2,opt,name=discoveryInfo"` - // UsedReferences track the resource used to reconcile the cr - UsedReferences *TargetStatusUsedReferences `json:"usedReferences,omitempty" protobuf:"bytes,3,opt,name=usedReferences"` -} - -type DiscoveryInfo struct { - // Protocol used for discovery - Protocol string `json:"protocol,omitempty" protobuf:"bytes,1,opt,name=protocol"` - // Type associated with the target - Provider string `json:"provider,omitempty" protobuf:"bytes,2,opt,name=provider"` - // Version associated with the target - Version string `json:"version,omitempty" protobuf:"bytes,3,opt,name=version"` - // Hostname associated with the target - Hostname string `json:"hostname,omitempty" protobuf:"bytes,4,opt,name=hostname"` - // Platform associated with the target - Platform string `json:"platform,omitempty" protobuf:"bytes,5,opt,name=platform"` - // MacAddress associated with the target - MacAddress string `json:"macAddress,omitempty" protobuf:"bytes,6,opt,name=macAddress"` - // SerialNumber associated with the target - SerialNumber string `json:"serialNumber,omitempty" protobuf:"bytes,7,opt,name=serialNumber"` - // Supported Encodings of the target - // +listType=atomic - SupportedEncodings []string `json:"supportedEncodings,omitempty" protobuf:"bytes,8,rep,name=supportedEncodings"` - // Last discovery time - //LastSeen metav1.Time `json:"lastSeen,omitempty"` -} - -type TargetStatusUsedReferences struct { - SecretResourceVersion string `json:"secretResourceVersion,omitempty" yaml:"secretResourceVersion,omitempty" protobuf:"bytes,1,opt,name=secretResourceVersion"` - TLSSecretResourceVersion string `json:"tlsSecretResourceVersion,omitempty" yaml:"tlsSecretResourceVersion,omitempty" protobuf:"bytes,2,opt,name=tlsSecretResourceVersion"` - ConnectionProfileResourceVersion string `json:"connectionProfileResourceVersion" yaml:"connectionProfileResourceVersion" protobuf:"bytes,3,opt,name=connectionProfileResourceVersion"` - SyncProfileResourceVersion string `json:"syncProfileResourceVersion" yaml:"syncProfileResourceVersion" protobuf:"bytes,4,opt,name=syncProfileResourceVersion"` -} - -// +kubebuilder:object:root=true -// +genclient -// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object -// +kubebuilder:object:root=true -// +kubebuilder:subresource:status -// +kubebuilder:printcolumn:name="READY",type="string",JSONPath=".status.conditions[?(@.type=='Ready')].status" -// +kubebuilder:printcolumn:name="REASON",type="string",JSONPath=".status.conditions[?(@.type=='Ready')].message" -// +kubebuilder:printcolumn:name="PROVIDER",type="string",JSONPath=".spec.provider" -// +kubebuilder:printcolumn:name="VERSION",type="string",JSONPath=".status.discoveryInfo.version" -// +kubebuilder:printcolumn:name="ADDRESS",type="string",JSONPath=".spec.address" -// +kubebuilder:printcolumn:name="PLATFORM",type="string",JSONPath=".status.discoveryInfo.platform" -// +kubebuilder:printcolumn:name="SERIALNUMBER",type="string",JSONPath=".status.discoveryInfo.serialNumber" -// +kubebuilder:printcolumn:name="MACADDRESS",type="string",JSONPath=".status.discoveryInfo.macAddress" -// +kubebuilder:resource:categories={sdc,inv} -// Target is the Schema for the Target API -// +k8s:openapi-gen=true -type Target struct { - metav1.TypeMeta `json:",inline" yaml:",inline"` - metav1.ObjectMeta `json:"metadata,omitempty" yaml:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` - - Spec TargetSpec `json:"spec,omitempty" yaml:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"` - Status TargetStatus `json:"status,omitempty" yaml:"status,omitempty" protobuf:"bytes,3,opt,name=status"` -} - -// +kubebuilder:object:root=true -// TargetList contains a list of Targets -// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object -type TargetList struct { - metav1.TypeMeta `json:",inline" yaml:",inline"` - metav1.ListMeta `json:"metadata,omitempty" yaml:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` - Items []Target `json:"items" yaml:"items" protobuf:"bytes,2,rep,name=items"` -} - -func init() { - //localSchemeBuilder.Register(&Target{}, &TargetList{}) -} - -var ( - TargetKind = reflect.TypeOf(Target{}).Name() - TargetGroupKind = schema.GroupKind{Group: SchemeGroupVersion.Group, Kind: TargetKind}.String() - TargetKindAPIVersion = TargetKind + "." + SchemeGroupVersion.String() - TargetGroupVersionKind = SchemeGroupVersion.WithKind(TargetKind) -) -*/ diff --git a/artifacts/inv.sdcio.dev_discoveryrules.yaml b/artifacts/inv.sdcio.dev_discoveryrules.yaml index d0e68938..98c6b3ea 100644 --- a/artifacts/inv.sdcio.dev_discoveryrules.yaml +++ b/artifacts/inv.sdcio.dev_discoveryrules.yaml @@ -61,6 +61,7 @@ spec: - address type: object type: array + x-kubernetes-list-type: atomic concurrentScans: description: number of concurrent IP scan format: int64 @@ -91,6 +92,7 @@ spec: items: type: string type: array + x-kubernetes-list-type: atomic credentials: description: Credentials defines the name of the secret that holds the credentials to connect to the target @@ -163,6 +165,7 @@ spec: items: type: string type: array + x-kubernetes-list-type: atomic prefix: description: Prefix of the target/target(s) type: string @@ -170,6 +173,7 @@ spec: - prefix type: object type: array + x-kubernetes-list-type: atomic serviceDomain: description: |- ServiceDomain defines the service domain of the cluster, used by svc discovery to identify the @@ -249,6 +253,7 @@ spec: - credentials type: object type: array + x-kubernetes-list-type: atomic targetTemplate: description: TargetTemplate defines the template the discovery controller uses to create the targets as a result of the discovery diff --git a/artifacts/inv.sdcio.dev_discoveryvendorprofiles.yaml b/artifacts/inv.sdcio.dev_discoveryvendorprofiles.yaml index ae4f6b5d..6d51f13f 100644 --- a/artifacts/inv.sdcio.dev_discoveryvendorprofiles.yaml +++ b/artifacts/inv.sdcio.dev_discoveryvendorprofiles.yaml @@ -83,6 +83,7 @@ spec: - path type: object type: array + x-kubernetes-list-type: atomic preserveNamespace: default: true type: boolean diff --git a/artifacts/inv.sdcio.dev_rollouts.yaml b/artifacts/inv.sdcio.dev_rollouts.yaml index 006a73dc..9baa00b5 100644 --- a/artifacts/inv.sdcio.dev_rollouts.yaml +++ b/artifacts/inv.sdcio.dev_rollouts.yaml @@ -69,17 +69,17 @@ spec: description: Proxy defines the HTTP/HTTPS proxy to be used to connect to the repo. properties: - URL: - description: URL specifies the base URL of the HTTP/HTTPS proxy - server. - type: string credentials: description: Credentials defines the name of the secret that holds the credentials to connect to the proxy server type: string + url: + description: URL specifies the base URL of the HTTP/HTTPS proxy + server. + type: string required: - - URL - credentials + - url type: object ref: description: |- @@ -87,7 +87,7 @@ spec: provider schema version type: string repoURL: - description: RepositoryURL specifies the base URL for a given repository + description: RepoURL specifies the base URL for a given repository type: string skipUnavailableTarget: type: boolean @@ -230,6 +230,7 @@ spec: - name type: object type: array + x-kubernetes-list-type: atomic type: object type: object served: true diff --git a/artifacts/inv.sdcio.dev_schemas.yaml b/artifacts/inv.sdcio.dev_schemas.yaml index d6fb1dd4..4f11e5e1 100644 --- a/artifacts/inv.sdcio.dev_schemas.yaml +++ b/artifacts/inv.sdcio.dev_schemas.yaml @@ -96,6 +96,7 @@ spec: type: object maxItems: 10 type: array + x-kubernetes-list-type: atomic kind: default: tag description: Kind defines the that the BranchOrTag string is @@ -109,17 +110,17 @@ spec: description: Proxy defines the HTTP/HTTPS proxy to be used to connect to the repo. properties: - URL: - description: URL specifies the base URL of the HTTP/HTTPS - proxy server. - type: string credentials: description: Credentials defines the name of the secret that holds the credentials to connect to the proxy server type: string + url: + description: URL specifies the base URL of the HTTP/HTTPS + proxy server. + type: string required: - - URL - credentials + - url type: object ref: description: |- @@ -127,8 +128,7 @@ spec: provider schema version type: string repoURL: - description: RepositoryURL specifies the base URL for a given - repository + description: RepoURL specifies the base URL for a given repository type: string schema: description: |- @@ -142,6 +142,7 @@ spec: type: string maxItems: 64 type: array + x-kubernetes-list-type: atomic includes: description: Excludes defines the list of files/directories to be excluded @@ -149,6 +150,7 @@ spec: type: string maxItems: 64 type: array + x-kubernetes-list-type: atomic models: description: Models defines the list of files/directories to be used as a model @@ -156,6 +158,7 @@ spec: type: string maxItems: 64 type: array + x-kubernetes-list-type: atomic type: object required: - kind @@ -166,6 +169,7 @@ spec: maxItems: 10 minItems: 1 type: array + x-kubernetes-list-type: atomic version: description: Version defines the version of the schema type: string @@ -252,6 +256,7 @@ spec: type: string type: object type: array + x-kubernetes-list-type: atomic type: object type: object served: true diff --git a/artifacts/inv.sdcio.dev_subscriptions.yaml b/artifacts/inv.sdcio.dev_subscriptions.yaml index 302b0e4b..5a1d7b8d 100644 --- a/artifacts/inv.sdcio.dev_subscriptions.yaml +++ b/artifacts/inv.sdcio.dev_subscriptions.yaml @@ -125,6 +125,7 @@ spec: type: string maxItems: 128 type: array + x-kubernetes-list-type: atomic required: - mode - name @@ -132,6 +133,7 @@ spec: type: object maxItems: 128 type: array + x-kubernetes-list-type: atomic target: description: Targets defines the targets on which this Subscription applies @@ -255,6 +257,7 @@ spec: items: type: string type: array + x-kubernetes-list-type: atomic type: object type: object served: true diff --git a/artifacts/inv.sdcio.dev_targetsyncprofiles.yaml b/artifacts/inv.sdcio.dev_targetsyncprofiles.yaml index f3786d60..3f37ba12 100644 --- a/artifacts/inv.sdcio.dev_targetsyncprofiles.yaml +++ b/artifacts/inv.sdcio.dev_targetsyncprofiles.yaml @@ -98,6 +98,7 @@ spec: type: string maxItems: 10 type: array + x-kubernetes-list-type: atomic port: default: 57400 description: Port defines the port on which the scan runs @@ -120,6 +121,7 @@ spec: type: object maxItems: 10 type: array + x-kubernetes-list-type: atomic x-kubernetes-validations: - message: sync may only be added rule: oldSelf.all(x, x in self) diff --git a/artifacts/inv.sdcio.dev_workspaces.yaml b/artifacts/inv.sdcio.dev_workspaces.yaml index 9957ec18..8eb70407 100644 --- a/artifacts/inv.sdcio.dev_workspaces.yaml +++ b/artifacts/inv.sdcio.dev_workspaces.yaml @@ -69,17 +69,17 @@ spec: description: Proxy defines the HTTP/HTTPS proxy to be used to connect to the repo. properties: - URL: - description: URL specifies the base URL of the HTTP/HTTPS proxy - server. - type: string credentials: description: Credentials defines the name of the secret that holds the credentials to connect to the proxy server type: string + url: + description: URL specifies the base URL of the HTTP/HTTPS proxy + server. + type: string required: - - URL - credentials + - url type: object ref: description: |- @@ -87,7 +87,7 @@ spec: provider schema version type: string repoURL: - description: RepositoryURL specifies the base URL for a given repository + description: RepoURL specifies the base URL for a given repository type: string required: - kind diff --git a/crds/config.sdcio.dev_configblames.yaml b/crds/config.sdcio.dev_configblames.yaml index 90e18aea..03f8c86b 100644 --- a/crds/config.sdcio.dev_configblames.yaml +++ b/crds/config.sdcio.dev_configblames.yaml @@ -19,7 +19,7 @@ spec: - name: config schema: openAPIV3Schema: - description: "\tConfigBlame defines the Schema for the ConfigBlame API" + description: ConfigBlame defines the Schema for the ConfigBlame API properties: apiVersion: description: |- diff --git a/crds/config.sdcio.dev_configs.yaml b/crds/config.sdcio.dev_configs.yaml index 20bc1f16..fa12bb87 100644 --- a/crds/config.sdcio.dev_configs.yaml +++ b/crds/config.sdcio.dev_configs.yaml @@ -19,7 +19,7 @@ spec: - name: config schema: openAPIV3Schema: - description: "\tConfig defines the Schema for the Config API" + description: Config defines the Schema for the Config API properties: apiVersion: description: |- @@ -250,6 +250,7 @@ spec: - value type: object type: array + x-kubernetes-list-type: atomic x-kubernetes-preserve-unknown-fields: true lifecycle: description: |- @@ -300,6 +301,7 @@ spec: - value type: object type: array + x-kubernetes-list-type: atomic x-kubernetes-preserve-unknown-fields: true lifecycle: description: |- diff --git a/crds/config.sdcio.dev_configsets.yaml b/crds/config.sdcio.dev_configsets.yaml index 2df02784..e3bedae5 100644 --- a/crds/config.sdcio.dev_configsets.yaml +++ b/crds/config.sdcio.dev_configsets.yaml @@ -300,6 +300,7 @@ spec: - value type: object type: array + x-kubernetes-list-type: atomic x-kubernetes-preserve-unknown-fields: true lifecycle: description: |- @@ -500,6 +501,7 @@ spec: - type type: object type: array + x-kubernetes-list-type: atomic type: object type: object served: true diff --git a/artifacts/inv.sdcio.dev_targets.yaml b/crds/config.sdcio.dev_deviationclears.yaml similarity index 52% rename from artifacts/inv.sdcio.dev_targets.yaml rename to crds/config.sdcio.dev_deviationclears.yaml index ca896dc5..6f3d691e 100644 --- a/artifacts/inv.sdcio.dev_targets.yaml +++ b/crds/config.sdcio.dev_deviationclears.yaml @@ -4,48 +4,22 @@ kind: CustomResourceDefinition metadata: annotations: controller-gen.kubebuilder.io/version: v0.20.0 - name: targets.inv.sdcio.dev + name: deviationclears.config.sdcio.dev spec: - group: inv.sdcio.dev + group: config.sdcio.dev names: categories: - sdc - - inv - kind: Target - listKind: TargetList - plural: targets - singular: target + kind: DeviationClear + listKind: DeviationClearList + plural: deviationclears + singular: deviationclear scope: Namespaced versions: - - additionalPrinterColumns: - - jsonPath: .status.conditions[?(@.type=='Ready')].status - name: READY - type: string - - jsonPath: .status.conditions[?(@.type=='Ready')].message - name: REASON - type: string - - jsonPath: .spec.provider - name: PROVIDER - type: string - - jsonPath: .status.discoveryInfo.version - name: VERSION - type: string - - jsonPath: .spec.address - name: ADDRESS - type: string - - jsonPath: .status.discoveryInfo.platform - name: PLATFORM - type: string - - jsonPath: .status.discoveryInfo.serialNumber - name: SERIALNUMBER - type: string - - jsonPath: .status.discoveryInfo.macAddress - name: MACADDRESS - type: string - name: v1alpha1 + - name: config schema: openAPIV3Schema: - description: Target is the Schema for the Target API + description: DeviationClear is the Schema for the DeviationClear API properties: apiVersion: description: |- @@ -65,38 +39,32 @@ spec: metadata: type: object spec: - description: TargetSpec defines the desired state of Target + description: DeviationSpec defines the desired state of Deviation properties: - address: - description: Address defines the address to connect to the target - type: string - connectionProfile: - description: ConnectionProfile define the profile used to connect - to the target once discovered - type: string - credentials: - description: Credentials defines the name of the secret that holds - the credentials to connect to the target - type: string - provider: - description: Provider specifies the provider using this target. - type: string - syncProfile: - description: SyncProfile define the profile used to sync to the target - config once discovered - type: string - tlsSecret: - description: TLSSecret defines the name of the TLS secret to connect - to the target if mtls is used - type: string + items: + items: + properties: + configName: + description: Name of the config - mandatory if the type is config + - not applicable for the other types + type: string + paths: + description: Paths of the respective type that should be cleared + items: + type: string + type: array + type: + type: string + required: + - paths + - type + type: object + type: array required: - - address - - connectionProfile - - credentials - - provider + - items type: object status: - description: TargetStatus defines the observed state of Target + description: DeviationStatus defines the observed state of Deviationgit properties: conditions: description: Conditions of the resource. @@ -156,53 +124,6 @@ spec: x-kubernetes-list-map-keys: - type x-kubernetes-list-type: map - discoveryInfo: - description: Discovery info defines the information retrieved during - discovery - properties: - hostname: - description: HostName associated with the target - type: string - macAddress: - description: MacAddress associated with the target - type: string - platform: - description: Platform associated with the target - type: string - protocol: - description: Protocol used for discovery - type: string - provider: - description: Type associated with the target - type: string - serialNumber: - description: SerialNumber associated with the target - type: string - supportedEncodings: - description: Supported Encodings of the target - items: - type: string - type: array - version: - description: Version associated with the target - type: string - type: object - usedReferences: - description: UsedReferences track the resource used to reconcile the - cr - properties: - connectionProfileResourceVersion: - type: string - secretResourceVersion: - type: string - syncProfileResourceVersion: - type: string - tlsSecretResourceVersion: - type: string - required: - - connectionProfileResourceVersion - - syncProfileResourceVersion - type: object type: object type: object served: true diff --git a/crds/config.sdcio.dev_deviations.yaml b/crds/config.sdcio.dev_deviations.yaml index 88d48eb2..2d6ed5f9 100644 --- a/crds/config.sdcio.dev_deviations.yaml +++ b/crds/config.sdcio.dev_deviations.yaml @@ -19,7 +19,7 @@ spec: - name: config schema: openAPIV3Schema: - description: "\tDeviation is the Schema for the Deviation API" + description: Deviation is the Schema for the Deviation API properties: apiVersion: description: |- @@ -50,7 +50,7 @@ spec: properties: actualValue: description: |- - CurrentValue defines the current value of the config belonging to the path + ActualValue defines the current value of the config belonging to the path that is currently configured on the target type: string desiredValue: @@ -167,7 +167,7 @@ spec: properties: actualValue: description: |- - CurrentValue defines the current value of the config belonging to the path + ActualValue defines the current value of the config belonging to the path that is currently configured on the target type: string desiredValue: @@ -182,6 +182,7 @@ spec: type: string type: object type: array + x-kubernetes-list-type: atomic type: object status: description: DeviationStatus defines the observed state of Deviation diff --git a/crds/config.sdcio.dev_runningconfigs.yaml b/crds/config.sdcio.dev_runningconfigs.yaml index 6b440199..6d472cb7 100644 --- a/crds/config.sdcio.dev_runningconfigs.yaml +++ b/crds/config.sdcio.dev_runningconfigs.yaml @@ -19,7 +19,7 @@ spec: - name: config schema: openAPIV3Schema: - description: "\tRunningConfig defines the Schema for the RunningConfig API" + description: RunningConfig defines the Schema for the RunningConfig API properties: apiVersion: description: |- diff --git a/crds/config.sdcio.dev_sensitiveconfigs.yaml b/crds/config.sdcio.dev_sensitiveconfigs.yaml index 984bf0eb..c1d8edf5 100644 --- a/crds/config.sdcio.dev_sensitiveconfigs.yaml +++ b/crds/config.sdcio.dev_sensitiveconfigs.yaml @@ -19,8 +19,7 @@ spec: - name: config schema: openAPIV3Schema: - description: "\tSensitiveConfig defines the Schema for the SensitiveConfig - API" + description: SensitiveConfig defines the Schema for the SensitiveConfig API properties: apiVersion: description: |- @@ -320,6 +319,7 @@ spec: - secretKeyRef type: object type: array + x-kubernetes-list-type: atomic lifecycle: description: |- Lifecycle determines the lifecycle policies the resource e.g. delete is orphan or delete @@ -393,6 +393,7 @@ spec: - secretKeyRef type: object type: array + x-kubernetes-list-type: atomic lifecycle: description: |- Lifecycle determines the lifecycle policies the resource e.g. delete is orphan or delete diff --git a/crds/config.sdcio.dev_targetblames.yaml b/crds/config.sdcio.dev_targetblames.yaml new file mode 100644 index 00000000..ec47f21d --- /dev/null +++ b/crds/config.sdcio.dev_targetblames.yaml @@ -0,0 +1,46 @@ +--- +apiVersion: apiextensions.k8s.io/v1 +kind: CustomResourceDefinition +metadata: + annotations: + controller-gen.kubebuilder.io/version: v0.20.0 + name: targetblames.config.sdcio.dev +spec: + group: config.sdcio.dev + names: + kind: TargetBlame + listKind: TargetBlameList + plural: targetblames + singular: targetblame + scope: Namespaced + versions: + - name: config + schema: + openAPIV3Schema: + description: TargetBlame is the Schema for the TargetBlame API + properties: + apiVersion: + description: |- + APIVersion defines the versioned schema of this representation of an object. + Servers should convert recognized schemas to the latest internal value, and + may reject unrecognized values. + More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + type: string + kind: + description: |- + Kind is a string value representing the REST resource this object represents. + Servers may infer this from the endpoint the client submits requests to. + Cannot be updated. + In CamelCase. + More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + type: string + metadata: + type: object + value: + type: object + x-kubernetes-preserve-unknown-fields: true + required: + - value + type: object + served: true + storage: true diff --git a/crds/config.sdcio.dev_targetcleardeviations.yaml b/crds/config.sdcio.dev_targetcleardeviations.yaml new file mode 100644 index 00000000..0185015e --- /dev/null +++ b/crds/config.sdcio.dev_targetcleardeviations.yaml @@ -0,0 +1,63 @@ +--- +apiVersion: apiextensions.k8s.io/v1 +kind: CustomResourceDefinition +metadata: + annotations: + controller-gen.kubebuilder.io/version: v0.20.0 + name: targetcleardeviations.config.sdcio.dev +spec: + group: config.sdcio.dev + names: + kind: TargetClearDeviation + listKind: TargetClearDeviationList + plural: targetcleardeviations + singular: targetcleardeviation + scope: Namespaced + versions: + - name: config + schema: + openAPIV3Schema: + description: TargetClearDeviation is the Schema for the TargetClearDeviation + API + properties: + apiVersion: + description: |- + APIVersion defines the versioned schema of this representation of an object. + Servers should convert recognized schemas to the latest internal value, and + may reject unrecognized values. + More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + type: string + kind: + description: |- + Kind is a string value representing the REST resource this object represents. + Servers may infer this from the endpoint the client submits requests to. + Cannot be updated. + In CamelCase. + More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + type: string + metadata: + type: object + spec: + description: TargetClearDeviationSpec defines the desired state of Target + properties: + paths: + description: Paths provide the path of the deviation to be cleared + items: + type: string + type: array + required: + - paths + type: object + status: + properties: + cleared: + type: integer + message: + type: string + required: + - cleared + - message + type: object + type: object + served: true + storage: true diff --git a/crds/config.sdcio.dev_targetrunnings.yaml b/crds/config.sdcio.dev_targetrunnings.yaml new file mode 100644 index 00000000..10f917cb --- /dev/null +++ b/crds/config.sdcio.dev_targetrunnings.yaml @@ -0,0 +1,46 @@ +--- +apiVersion: apiextensions.k8s.io/v1 +kind: CustomResourceDefinition +metadata: + annotations: + controller-gen.kubebuilder.io/version: v0.20.0 + name: targetrunnings.config.sdcio.dev +spec: + group: config.sdcio.dev + names: + kind: TargetRunning + listKind: TargetRunningList + plural: targetrunnings + singular: targetrunning + scope: Namespaced + versions: + - name: config + schema: + openAPIV3Schema: + description: TargetRunning is the Schema for the TargetRunning API + properties: + apiVersion: + description: |- + APIVersion defines the versioned schema of this representation of an object. + Servers should convert recognized schemas to the latest internal value, and + may reject unrecognized values. + More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + type: string + kind: + description: |- + Kind is a string value representing the REST resource this object represents. + Servers may infer this from the endpoint the client submits requests to. + Cannot be updated. + In CamelCase. + More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + type: string + metadata: + type: object + value: + type: object + x-kubernetes-preserve-unknown-fields: true + required: + - value + type: object + served: true + storage: true diff --git a/crds/config.sdcio.dev_targets.yaml b/crds/config.sdcio.dev_targets.yaml new file mode 100644 index 00000000..599ae64d --- /dev/null +++ b/crds/config.sdcio.dev_targets.yaml @@ -0,0 +1,354 @@ +--- +apiVersion: apiextensions.k8s.io/v1 +kind: CustomResourceDefinition +metadata: + annotations: + controller-gen.kubebuilder.io/version: v0.20.0 + name: targets.config.sdcio.dev +spec: + group: config.sdcio.dev + names: + categories: + - sdc + kind: Target + listKind: TargetList + plural: targets + singular: target + scope: Namespaced + versions: + - name: config + schema: + openAPIV3Schema: + description: Target is the Schema for the Target API + properties: + apiVersion: + description: |- + APIVersion defines the versioned schema of this representation of an object. + Servers should convert recognized schemas to the latest internal value, and + may reject unrecognized values. + More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + type: string + kind: + description: |- + Kind is a string value representing the REST resource this object represents. + Servers may infer this from the endpoint the client submits requests to. + Cannot be updated. + In CamelCase. + More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + type: string + metadata: + type: object + spec: + description: TargetSpec defines the desired state of Target + properties: + address: + description: Address defines the address to connect to the target + type: string + connectionProfile: + description: ConnectionProfile define the profile used to connect + to the target once discovered + type: string + credentials: + description: Credentials defines the name of the secret that holds + the credentials to connect to the target + type: string + provider: + description: Provider specifies the provider using this target. + type: string + syncProfile: + description: SyncProfile define the profile used to sync to the target + config once discovered + type: string + tlsSecret: + description: TLSSecret defines the name of the TLS secret to connect + to the target if mtls is used + type: string + required: + - address + - connectionProfile + - credentials + - provider + type: object + status: + description: TargetStatus defines the observed state of Target + properties: + conditions: + description: Conditions of the resource. + items: + properties: + lastTransitionTime: + description: |- + lastTransitionTime is the last time the condition transitioned from one status to another. + This should be when the underlying condition changed. If that is not known, then using the time when the API field changed is acceptable. + format: date-time + type: string + message: + description: |- + message is a human readable message indicating details about the transition. + This may be an empty string. + maxLength: 32768 + type: string + observedGeneration: + description: |- + observedGeneration represents the .metadata.generation that the condition was set based upon. + For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date + with respect to the current state of the instance. + format: int64 + minimum: 0 + type: integer + reason: + description: |- + reason contains a programmatic identifier indicating the reason for the condition's last transition. + Producers of specific condition types may define expected values and meanings for this field, + and whether the values are considered a guaranteed API. + The value should be a CamelCase string. + This field may not be empty. + maxLength: 1024 + minLength: 1 + pattern: ^[A-Za-z]([A-Za-z0-9_,:]*[A-Za-z0-9_])?$ + type: string + status: + description: status of the condition, one of True, False, Unknown. + enum: + - "True" + - "False" + - Unknown + type: string + type: + description: type of condition in CamelCase or in foo.example.com/CamelCase. + maxLength: 316 + pattern: ^([a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*/)?(([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9])$ + type: string + required: + - lastTransitionTime + - message + - reason + - status + - type + type: object + type: array + x-kubernetes-list-map-keys: + - type + x-kubernetes-list-type: map + discoveryInfo: + description: Discovery info defines the information retrieved during + discovery + properties: + hostname: + description: Hostname associated with the target + type: string + macAddress: + description: MacAddress associated with the target + type: string + platform: + description: Platform associated with the target + type: string + protocol: + description: Protocol used for discovery + type: string + provider: + description: Type associated with the target + type: string + serialNumber: + description: SerialNumber associated with the target + type: string + supportedEncodings: + description: Supported Encodings of the target + items: + type: string + type: array + x-kubernetes-list-type: atomic + version: + description: Version associated with the target + type: string + type: object + usedReferences: + description: UsedReferences track the resource used to reconcile the + cr + properties: + connectionProfileResourceVersion: + type: string + secretResourceVersion: + type: string + syncProfileResourceVersion: + type: string + tlsSecretResourceVersion: + type: string + required: + - connectionProfileResourceVersion + - syncProfileResourceVersion + type: object + type: object + type: object + served: true + storage: true + subresources: + status: {} + - name: v1alpha1 + schema: + openAPIV3Schema: + description: Target is the Schema for the Target API + properties: + apiVersion: + description: |- + APIVersion defines the versioned schema of this representation of an object. + Servers should convert recognized schemas to the latest internal value, and + may reject unrecognized values. + More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + type: string + kind: + description: |- + Kind is a string value representing the REST resource this object represents. + Servers may infer this from the endpoint the client submits requests to. + Cannot be updated. + In CamelCase. + More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + type: string + metadata: + type: object + spec: + description: TargetSpec defines the desired state of Target + properties: + address: + description: Address defines the address to connect to the target + type: string + connectionProfile: + description: ConnectionProfile define the profile used to connect + to the target once discovered + type: string + credentials: + description: Credentials defines the name of the secret that holds + the credentials to connect to the target + type: string + provider: + description: Provider specifies the provider using this target. + type: string + syncProfile: + description: SyncProfile define the profile used to sync to the target + config once discovered + type: string + tlsSecret: + description: TLSSecret defines the name of the TLS secret to connect + to the target if mtls is used + type: string + required: + - address + - connectionProfile + - credentials + - provider + type: object + status: + description: TargetStatus defines the observed state of Target + properties: + conditions: + description: Conditions of the resource. + items: + properties: + lastTransitionTime: + description: |- + lastTransitionTime is the last time the condition transitioned from one status to another. + This should be when the underlying condition changed. If that is not known, then using the time when the API field changed is acceptable. + format: date-time + type: string + message: + description: |- + message is a human readable message indicating details about the transition. + This may be an empty string. + maxLength: 32768 + type: string + observedGeneration: + description: |- + observedGeneration represents the .metadata.generation that the condition was set based upon. + For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date + with respect to the current state of the instance. + format: int64 + minimum: 0 + type: integer + reason: + description: |- + reason contains a programmatic identifier indicating the reason for the condition's last transition. + Producers of specific condition types may define expected values and meanings for this field, + and whether the values are considered a guaranteed API. + The value should be a CamelCase string. + This field may not be empty. + maxLength: 1024 + minLength: 1 + pattern: ^[A-Za-z]([A-Za-z0-9_,:]*[A-Za-z0-9_])?$ + type: string + status: + description: status of the condition, one of True, False, Unknown. + enum: + - "True" + - "False" + - Unknown + type: string + type: + description: type of condition in CamelCase or in foo.example.com/CamelCase. + maxLength: 316 + pattern: ^([a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*/)?(([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9])$ + type: string + required: + - lastTransitionTime + - message + - reason + - status + - type + type: object + type: array + x-kubernetes-list-map-keys: + - type + x-kubernetes-list-type: map + discoveryInfo: + description: Discovery info defines the information retrieved during + discovery + properties: + hostname: + description: Hostname associated with the target + type: string + macAddress: + description: MacAddress associated with the target + type: string + platform: + description: Platform associated with the target + type: string + protocol: + description: Protocol used for discovery + type: string + provider: + description: Type associated with the target + type: string + serialNumber: + description: SerialNumber associated with the target + type: string + supportedEncodings: + description: Supported Encodings of the target + items: + type: string + type: array + x-kubernetes-list-type: atomic + version: + description: Version associated with the target + type: string + type: object + usedReferences: + description: UsedReferences track the resource used to reconcile the + cr + properties: + connectionProfileResourceVersion: + type: string + secretResourceVersion: + type: string + syncProfileResourceVersion: + type: string + tlsSecretResourceVersion: + type: string + required: + - connectionProfileResourceVersion + - syncProfileResourceVersion + type: object + type: object + type: object + served: true + storage: true + subresources: + status: {} diff --git a/crds/inv.sdcio.dev_discoveryrules.yaml b/crds/inv.sdcio.dev_discoveryrules.yaml index d0e68938..98c6b3ea 100644 --- a/crds/inv.sdcio.dev_discoveryrules.yaml +++ b/crds/inv.sdcio.dev_discoveryrules.yaml @@ -61,6 +61,7 @@ spec: - address type: object type: array + x-kubernetes-list-type: atomic concurrentScans: description: number of concurrent IP scan format: int64 @@ -91,6 +92,7 @@ spec: items: type: string type: array + x-kubernetes-list-type: atomic credentials: description: Credentials defines the name of the secret that holds the credentials to connect to the target @@ -163,6 +165,7 @@ spec: items: type: string type: array + x-kubernetes-list-type: atomic prefix: description: Prefix of the target/target(s) type: string @@ -170,6 +173,7 @@ spec: - prefix type: object type: array + x-kubernetes-list-type: atomic serviceDomain: description: |- ServiceDomain defines the service domain of the cluster, used by svc discovery to identify the @@ -249,6 +253,7 @@ spec: - credentials type: object type: array + x-kubernetes-list-type: atomic targetTemplate: description: TargetTemplate defines the template the discovery controller uses to create the targets as a result of the discovery diff --git a/crds/inv.sdcio.dev_discoveryvendorprofiles.yaml b/crds/inv.sdcio.dev_discoveryvendorprofiles.yaml index ae4f6b5d..6d51f13f 100644 --- a/crds/inv.sdcio.dev_discoveryvendorprofiles.yaml +++ b/crds/inv.sdcio.dev_discoveryvendorprofiles.yaml @@ -83,6 +83,7 @@ spec: - path type: object type: array + x-kubernetes-list-type: atomic preserveNamespace: default: true type: boolean diff --git a/crds/inv.sdcio.dev_rollouts.yaml b/crds/inv.sdcio.dev_rollouts.yaml index 006a73dc..9baa00b5 100644 --- a/crds/inv.sdcio.dev_rollouts.yaml +++ b/crds/inv.sdcio.dev_rollouts.yaml @@ -69,17 +69,17 @@ spec: description: Proxy defines the HTTP/HTTPS proxy to be used to connect to the repo. properties: - URL: - description: URL specifies the base URL of the HTTP/HTTPS proxy - server. - type: string credentials: description: Credentials defines the name of the secret that holds the credentials to connect to the proxy server type: string + url: + description: URL specifies the base URL of the HTTP/HTTPS proxy + server. + type: string required: - - URL - credentials + - url type: object ref: description: |- @@ -87,7 +87,7 @@ spec: provider schema version type: string repoURL: - description: RepositoryURL specifies the base URL for a given repository + description: RepoURL specifies the base URL for a given repository type: string skipUnavailableTarget: type: boolean @@ -230,6 +230,7 @@ spec: - name type: object type: array + x-kubernetes-list-type: atomic type: object type: object served: true diff --git a/crds/inv.sdcio.dev_schemas.yaml b/crds/inv.sdcio.dev_schemas.yaml index d6fb1dd4..4f11e5e1 100644 --- a/crds/inv.sdcio.dev_schemas.yaml +++ b/crds/inv.sdcio.dev_schemas.yaml @@ -96,6 +96,7 @@ spec: type: object maxItems: 10 type: array + x-kubernetes-list-type: atomic kind: default: tag description: Kind defines the that the BranchOrTag string is @@ -109,17 +110,17 @@ spec: description: Proxy defines the HTTP/HTTPS proxy to be used to connect to the repo. properties: - URL: - description: URL specifies the base URL of the HTTP/HTTPS - proxy server. - type: string credentials: description: Credentials defines the name of the secret that holds the credentials to connect to the proxy server type: string + url: + description: URL specifies the base URL of the HTTP/HTTPS + proxy server. + type: string required: - - URL - credentials + - url type: object ref: description: |- @@ -127,8 +128,7 @@ spec: provider schema version type: string repoURL: - description: RepositoryURL specifies the base URL for a given - repository + description: RepoURL specifies the base URL for a given repository type: string schema: description: |- @@ -142,6 +142,7 @@ spec: type: string maxItems: 64 type: array + x-kubernetes-list-type: atomic includes: description: Excludes defines the list of files/directories to be excluded @@ -149,6 +150,7 @@ spec: type: string maxItems: 64 type: array + x-kubernetes-list-type: atomic models: description: Models defines the list of files/directories to be used as a model @@ -156,6 +158,7 @@ spec: type: string maxItems: 64 type: array + x-kubernetes-list-type: atomic type: object required: - kind @@ -166,6 +169,7 @@ spec: maxItems: 10 minItems: 1 type: array + x-kubernetes-list-type: atomic version: description: Version defines the version of the schema type: string @@ -252,6 +256,7 @@ spec: type: string type: object type: array + x-kubernetes-list-type: atomic type: object type: object served: true diff --git a/crds/inv.sdcio.dev_subscriptions.yaml b/crds/inv.sdcio.dev_subscriptions.yaml index 302b0e4b..5a1d7b8d 100644 --- a/crds/inv.sdcio.dev_subscriptions.yaml +++ b/crds/inv.sdcio.dev_subscriptions.yaml @@ -125,6 +125,7 @@ spec: type: string maxItems: 128 type: array + x-kubernetes-list-type: atomic required: - mode - name @@ -132,6 +133,7 @@ spec: type: object maxItems: 128 type: array + x-kubernetes-list-type: atomic target: description: Targets defines the targets on which this Subscription applies @@ -255,6 +257,7 @@ spec: items: type: string type: array + x-kubernetes-list-type: atomic type: object type: object served: true diff --git a/crds/inv.sdcio.dev_targetsyncprofiles.yaml b/crds/inv.sdcio.dev_targetsyncprofiles.yaml index f3786d60..3f37ba12 100644 --- a/crds/inv.sdcio.dev_targetsyncprofiles.yaml +++ b/crds/inv.sdcio.dev_targetsyncprofiles.yaml @@ -98,6 +98,7 @@ spec: type: string maxItems: 10 type: array + x-kubernetes-list-type: atomic port: default: 57400 description: Port defines the port on which the scan runs @@ -120,6 +121,7 @@ spec: type: object maxItems: 10 type: array + x-kubernetes-list-type: atomic x-kubernetes-validations: - message: sync may only be added rule: oldSelf.all(x, x in self) diff --git a/crds/inv.sdcio.dev_workspaces.yaml b/crds/inv.sdcio.dev_workspaces.yaml index 9957ec18..8eb70407 100644 --- a/crds/inv.sdcio.dev_workspaces.yaml +++ b/crds/inv.sdcio.dev_workspaces.yaml @@ -69,17 +69,17 @@ spec: description: Proxy defines the HTTP/HTTPS proxy to be used to connect to the repo. properties: - URL: - description: URL specifies the base URL of the HTTP/HTTPS proxy - server. - type: string credentials: description: Credentials defines the name of the secret that holds the credentials to connect to the proxy server type: string + url: + description: URL specifies the base URL of the HTTP/HTTPS proxy + server. + type: string required: - - URL - credentials + - url type: object ref: description: |- @@ -87,7 +87,7 @@ spec: provider schema version type: string repoURL: - description: RepositoryURL specifies the base URL for a given repository + description: RepoURL specifies the base URL for a given repository type: string required: - kind diff --git a/go.mod b/go.mod index 0a389ceb..a27e1a1b 100644 --- a/go.mod +++ b/go.mod @@ -7,8 +7,8 @@ require ( github.com/go-git/go-git/v5 v5.16.5 github.com/google/go-cmp v0.7.0 github.com/google/uuid v1.6.0 - github.com/henderiw/apiserver-builder v0.0.7-0.20260302093549-7ef05fb00905 - github.com/henderiw/apiserver-store v0.0.4-0.20260302081117-f4f810bec88b + github.com/henderiw/apiserver-builder v0.0.7 + github.com/henderiw/apiserver-store v0.0.4 github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c github.com/henderiw/logger v0.0.0-20230911123436-8655829b1abe github.com/henderiw/store v0.0.2-0.20241030044529-f6baff74eab3 diff --git a/go.sum b/go.sum index ab944178..9327d46b 100644 --- a/go.sum +++ b/go.sum @@ -169,10 +169,10 @@ github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0 h1:Ovs26xHkKqVztRpIrF/92Bcuy github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0/go.mod h1:8NvIoxWQoOIhqOTXgfV/d3M/q6VIi02HzZEHgUlZvzk= github.com/grpc-ecosystem/grpc-gateway/v2 v2.27.3 h1:NmZ1PKzSTQbuGHw9DGPFomqkkLWMC+vZCkfs+FHv1Vg= github.com/grpc-ecosystem/grpc-gateway/v2 v2.27.3/go.mod h1:zQrxl1YP88HQlA6i9c63DSVPFklWpGX4OWAc9bFuaH4= -github.com/henderiw/apiserver-builder v0.0.7-0.20260302093549-7ef05fb00905 h1:PrVO840pQejbWI0/u4z3B/qAF6IB55gXVDSbr1sHaA4= -github.com/henderiw/apiserver-builder v0.0.7-0.20260302093549-7ef05fb00905/go.mod h1:Py2AD4oB1McoYpz4chBNAFo9bYeZ9N9cKPijzkMxk2U= -github.com/henderiw/apiserver-store v0.0.4-0.20260302081117-f4f810bec88b h1:iFG9vtD2eDR481k8/Y8rVBzNGXHsHdQLYS5aRk34lbA= -github.com/henderiw/apiserver-store v0.0.4-0.20260302081117-f4f810bec88b/go.mod h1:RuXLMHJwszn6LXgL6fO9fxMC7AW5wAc4zOddnnZpkKI= +github.com/henderiw/apiserver-builder v0.0.7 h1:GPbwEAHauK5nGVcD8r/h0hvRmnnaWj1L2vbQIzs8Iho= +github.com/henderiw/apiserver-builder v0.0.7/go.mod h1:Py2AD4oB1McoYpz4chBNAFo9bYeZ9N9cKPijzkMxk2U= +github.com/henderiw/apiserver-store v0.0.4 h1:IeawmDpcX4PzRxh0IW8j8IC++Vn1OOkUUBeq3laylPU= +github.com/henderiw/apiserver-store v0.0.4/go.mod h1:RuXLMHJwszn6LXgL6fO9fxMC7AW5wAc4zOddnnZpkKI= github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c h1:nFnCNyRV1Ej/zqV/gn8UnFESkoPUXhwpUCZyhSYGSYA= github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c/go.mod h1:PrPJdVAwtl5tL323wykHZ5L/b7tfJJsjhegza/wq4fQ= github.com/henderiw/logger v0.0.0-20230911123436-8655829b1abe h1:+R53KH7fW+pmqlfSYVTCGPn8pj6gqBGcQ0nq7L1h8+g= diff --git a/pkg/generated/applyconfiguration/config/v1alpha1/target.go b/pkg/generated/applyconfiguration/config/v1alpha1/target.go index d5a88231..36d91e10 100644 --- a/pkg/generated/applyconfiguration/config/v1alpha1/target.go +++ b/pkg/generated/applyconfiguration/config/v1alpha1/target.go @@ -30,9 +30,8 @@ import ( type TargetApplyConfiguration struct { v1.TypeMetaApplyConfiguration `json:",inline"` *v1.ObjectMetaApplyConfiguration `json:"metadata,omitempty"` - Spec *TargetSpecApplyConfiguration `json:"spec,omitempty"` - Status *TargetStatusApplyConfiguration `json:"status,omitempty"` - Running *TargetRunningApplyConfiguration `json:"running,omitempty"` + Spec *TargetSpecApplyConfiguration `json:"spec,omitempty"` + Status *TargetStatusApplyConfiguration `json:"status,omitempty"` } // Target constructs a declarative configuration of the Target type for use with @@ -222,14 +221,6 @@ func (b *TargetApplyConfiguration) WithStatus(value *TargetStatusApplyConfigurat return b } -// WithRunning sets the Running field in the declarative configuration to the given value -// and returns the receiver, so that objects can be built by chaining "With" function invocations. -// If called multiple times, the Running field is set to the value of the last call. -func (b *TargetApplyConfiguration) WithRunning(value *TargetRunningApplyConfiguration) *TargetApplyConfiguration { - b.Running = value - return b -} - // GetKind retrieves the value of the Kind field in the declarative configuration. func (b *TargetApplyConfiguration) GetKind() *string { return b.TypeMetaApplyConfiguration.Kind diff --git a/pkg/generated/applyconfiguration/utils.go b/pkg/generated/applyconfiguration/utils.go index 4012a32a..354baa37 100644 --- a/pkg/generated/applyconfiguration/utils.go +++ b/pkg/generated/applyconfiguration/utils.go @@ -83,8 +83,6 @@ func ForKind(kind schema.GroupVersionKind) interface{} { return &configv1alpha1.SensitiveConfigStatusApplyConfiguration{} case v1alpha1.SchemeGroupVersion.WithKind("Target"): return &configv1alpha1.TargetApplyConfiguration{} - case v1alpha1.SchemeGroupVersion.WithKind("TargetRunning"): - return &configv1alpha1.TargetRunningApplyConfiguration{} case v1alpha1.SchemeGroupVersion.WithKind("TargetSpec"): return &configv1alpha1.TargetSpecApplyConfiguration{} case v1alpha1.SchemeGroupVersion.WithKind("TargetStatus"): diff --git a/pkg/generated/openapi/zz_generated.openapi.go b/pkg/generated/openapi/zz_generated.openapi.go index 53becaee..aef2bf1c 100644 --- a/pkg/generated/openapi/zz_generated.openapi.go +++ b/pkg/generated/openapi/zz_generated.openapi.go @@ -68,6 +68,10 @@ func GetOpenAPIDefinitions(ref common.ReferenceCallback) map[string]common.OpenA "github.com/sdcio/config-server/apis/config/v1alpha1.SensitiveConfigSpec": schema_config_server_apis_config_v1alpha1_SensitiveConfigSpec(ref), "github.com/sdcio/config-server/apis/config/v1alpha1.SensitiveConfigStatus": schema_config_server_apis_config_v1alpha1_SensitiveConfigStatus(ref), "github.com/sdcio/config-server/apis/config/v1alpha1.Target": schema_config_server_apis_config_v1alpha1_Target(ref), + "github.com/sdcio/config-server/apis/config/v1alpha1.TargetBlame": schema_config_server_apis_config_v1alpha1_TargetBlame(ref), + "github.com/sdcio/config-server/apis/config/v1alpha1.TargetClearDeviation": schema_config_server_apis_config_v1alpha1_TargetClearDeviation(ref), + "github.com/sdcio/config-server/apis/config/v1alpha1.TargetClearDeviationSpec": schema_config_server_apis_config_v1alpha1_TargetClearDeviationSpec(ref), + "github.com/sdcio/config-server/apis/config/v1alpha1.TargetClearDeviationStatus": schema_config_server_apis_config_v1alpha1_TargetClearDeviationStatus(ref), "github.com/sdcio/config-server/apis/config/v1alpha1.TargetList": schema_config_server_apis_config_v1alpha1_TargetList(ref), "github.com/sdcio/config-server/apis/config/v1alpha1.TargetRunning": schema_config_server_apis_config_v1alpha1_TargetRunning(ref), "github.com/sdcio/config-server/apis/config/v1alpha1.TargetSpec": schema_config_server_apis_config_v1alpha1_TargetSpec(ref), @@ -1994,24 +1998,176 @@ func schema_config_server_apis_config_v1alpha1_Target(ref common.ReferenceCallba Ref: ref("github.com/sdcio/config-server/apis/config/v1alpha1.TargetStatus"), }, }, - "running": { + }, + }, + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-group-version-kind": []interface{}{ + map[string]interface{}{"group": "config.sdcio.dev", "kind": "Target", "version": "v1alpha1"}, + }, + }, + }, + }, + Dependencies: []string{ + "github.com/sdcio/config-server/apis/config/v1alpha1.TargetSpec", "github.com/sdcio/config-server/apis/config/v1alpha1.TargetStatus", metav1.ObjectMeta{}.OpenAPIModelName()}, + } +} + +func schema_config_server_apis_config_v1alpha1_TargetBlame(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "TargetBlame is the Schema for the TargetBlame API", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "metadata": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/sdcio/config-server/apis/config/v1alpha1.TargetRunning"), + Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), + }, + }, + "value": { + SchemaProps: spec.SchemaProps{ + Ref: ref(runtime.RawExtension{}.OpenAPIModelName()), }, }, }, + Required: []string{"value"}, }, VendorExtensible: spec.VendorExtensible{ Extensions: spec.Extensions{ "x-kubernetes-group-version-kind": []interface{}{ - map[string]interface{}{"group": "config.sdcio.dev", "kind": "Target", "version": "v1alpha1"}, + map[string]interface{}{"group": "config.sdcio.dev", "kind": "TargetBlame", "version": "v1alpha1"}, + }, + }, + }, + }, + Dependencies: []string{ + metav1.ObjectMeta{}.OpenAPIModelName(), runtime.RawExtension{}.OpenAPIModelName()}, + } +} + +func schema_config_server_apis_config_v1alpha1_TargetClearDeviation(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "TargetClearDeviation is the Schema for the TargetClearDeviation API", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "metadata": { + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), + }, + }, + "spec": { + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("github.com/sdcio/config-server/apis/config/v1alpha1.TargetClearDeviationSpec"), + }, + }, + "status": { + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("github.com/sdcio/config-server/apis/config/v1alpha1.TargetClearDeviationStatus"), + }, + }, + }, + }, + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-group-version-kind": []interface{}{ + map[string]interface{}{"group": "config.sdcio.dev", "kind": "TargetClearDeviation", "version": "v1alpha1"}, }, }, }, }, Dependencies: []string{ - "github.com/sdcio/config-server/apis/config/v1alpha1.TargetRunning", "github.com/sdcio/config-server/apis/config/v1alpha1.TargetSpec", "github.com/sdcio/config-server/apis/config/v1alpha1.TargetStatus", metav1.ObjectMeta{}.OpenAPIModelName()}, + "github.com/sdcio/config-server/apis/config/v1alpha1.TargetClearDeviationSpec", "github.com/sdcio/config-server/apis/config/v1alpha1.TargetClearDeviationStatus", metav1.ObjectMeta{}.OpenAPIModelName()}, + } +} + +func schema_config_server_apis_config_v1alpha1_TargetClearDeviationSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "TargetClearDeviationSpec defines the desired state of Target", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "paths": { + SchemaProps: spec.SchemaProps{ + Description: "Paths provide the path of the deviation to be cleared", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + }, + Required: []string{"paths"}, + }, + }, + } +} + +func schema_config_server_apis_config_v1alpha1_TargetClearDeviationStatus(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "cleared": { + SchemaProps: spec.SchemaProps{ + Default: 0, + Type: []string{"integer"}, + Format: "int32", + }, + }, + "message": { + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"cleared", "message"}, + }, + }, } } @@ -2068,8 +2224,29 @@ func schema_config_server_apis_config_v1alpha1_TargetRunning(ref common.Referenc return common.OpenAPIDefinition{ Schema: spec.Schema{ SchemaProps: spec.SchemaProps{ - Type: []string{"object"}, + Description: "TargetRunning is the Schema for the TargetRunning API", + Type: []string{"object"}, Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "metadata": { + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), + }, + }, "value": { SchemaProps: spec.SchemaProps{ Ref: ref(runtime.RawExtension{}.OpenAPIModelName()), @@ -2078,9 +2255,16 @@ func schema_config_server_apis_config_v1alpha1_TargetRunning(ref common.Referenc }, Required: []string{"value"}, }, + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-group-version-kind": []interface{}{ + map[string]interface{}{"group": "config.sdcio.dev", "kind": "TargetRunning", "version": "v1alpha1"}, + }, + }, + }, }, Dependencies: []string{ - runtime.RawExtension{}.OpenAPIModelName()}, + metav1.ObjectMeta{}.OpenAPIModelName(), runtime.RawExtension{}.OpenAPIModelName()}, } } From fcc62fdf7d6ee9be7b81ce795c19d6630aae9e50 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Mon, 2 Mar 2026 18:46:39 +0100 Subject: [PATCH 106/135] added blame, running, cleardeviation --- apis/config/register.go | 3 +++ apis/config/v1alpha1/register.go | 3 +++ apis/config/v1alpha1/target_running_types.go | 1 + 3 files changed, 7 insertions(+) diff --git a/apis/config/register.go b/apis/config/register.go index 16fc8fcd..4aebf506 100644 --- a/apis/config/register.go +++ b/apis/config/register.go @@ -54,6 +54,9 @@ func addKnownTypes(scheme *runtime.Scheme) error { &ConfigBlameList{}, &Target{}, &TargetList{}, + &TargetBlame{}, + &TargetRunning{}, + &TargetClearDeviation{}, ) return nil } diff --git a/apis/config/v1alpha1/register.go b/apis/config/v1alpha1/register.go index 559f9d88..5b099efc 100644 --- a/apis/config/v1alpha1/register.go +++ b/apis/config/v1alpha1/register.go @@ -65,6 +65,9 @@ func addKnownTypes(scheme *runtime.Scheme) error { &ConfigBlameList{}, &Target{}, &TargetList{}, + &TargetBlame{}, + &TargetRunning{}, + &TargetClearDeviation{}, ) metav1.AddToGroupVersion(scheme, SchemeGroupVersion) diff --git a/apis/config/v1alpha1/target_running_types.go b/apis/config/v1alpha1/target_running_types.go index 1d6e59cf..bf9baabb 100644 --- a/apis/config/v1alpha1/target_running_types.go +++ b/apis/config/v1alpha1/target_running_types.go @@ -21,6 +21,7 @@ import ( "k8s.io/apimachinery/pkg/runtime" ) +// +genclient // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object // +k8s:openapi-gen=true From 3672c4f277fe71c537a5cbf705485030030dd3dc Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Mon, 2 Mar 2026 18:47:35 +0100 Subject: [PATCH 107/135] added blame, running, cleardeviation --- .../config/v1alpha1/targetrunning.go | 202 +++++++++++++++++- pkg/generated/applyconfiguration/utils.go | 2 + .../typed/config/v1alpha1/config_client.go | 5 + .../v1alpha1/fake/fake_config_client.go | 4 + .../v1alpha1/fake/fake_targetrunning.go | 51 +++++ .../config/v1alpha1/generated_expansion.go | 2 + .../typed/config/v1alpha1/targetrunning.go | 67 ++++++ .../config/v1alpha1/interface.go | 7 + .../config/v1alpha1/targetrunning.go | 101 +++++++++ .../informers/externalversions/generic.go | 2 + .../config/v1alpha1/expansion_generated.go | 8 + .../listers/config/v1alpha1/targetrunning.go | 69 ++++++ 12 files changed, 516 insertions(+), 4 deletions(-) create mode 100644 pkg/generated/clientset/versioned/typed/config/v1alpha1/fake/fake_targetrunning.go create mode 100644 pkg/generated/clientset/versioned/typed/config/v1alpha1/targetrunning.go create mode 100644 pkg/generated/informers/externalversions/config/v1alpha1/targetrunning.go create mode 100644 pkg/generated/listers/config/v1alpha1/targetrunning.go diff --git a/pkg/generated/applyconfiguration/config/v1alpha1/targetrunning.go b/pkg/generated/applyconfiguration/config/v1alpha1/targetrunning.go index dd918d91..f90bbe80 100644 --- a/pkg/generated/applyconfiguration/config/v1alpha1/targetrunning.go +++ b/pkg/generated/applyconfiguration/config/v1alpha1/targetrunning.go @@ -18,19 +18,191 @@ limitations under the License. package v1alpha1 import ( + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" runtime "k8s.io/apimachinery/pkg/runtime" + types "k8s.io/apimachinery/pkg/types" + v1 "k8s.io/client-go/applyconfigurations/meta/v1" ) // TargetRunningApplyConfiguration represents a declarative configuration of the TargetRunning type for use // with apply. +// +// TargetRunning is the Schema for the TargetRunning API type TargetRunningApplyConfiguration struct { - Value *runtime.RawExtension `json:"value,omitempty"` + v1.TypeMetaApplyConfiguration `json:",inline"` + *v1.ObjectMetaApplyConfiguration `json:"metadata,omitempty"` + Value *runtime.RawExtension `json:"value,omitempty"` } -// TargetRunningApplyConfiguration constructs a declarative configuration of the TargetRunning type for use with +// TargetRunning constructs a declarative configuration of the TargetRunning type for use with // apply. -func TargetRunning() *TargetRunningApplyConfiguration { - return &TargetRunningApplyConfiguration{} +func TargetRunning(name, namespace string) *TargetRunningApplyConfiguration { + b := &TargetRunningApplyConfiguration{} + b.WithName(name) + b.WithNamespace(namespace) + b.WithKind("TargetRunning") + b.WithAPIVersion("config.sdcio.dev/v1alpha1") + return b +} + +func (b TargetRunningApplyConfiguration) IsApplyConfiguration() {} + +// WithKind sets the Kind field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Kind field is set to the value of the last call. +func (b *TargetRunningApplyConfiguration) WithKind(value string) *TargetRunningApplyConfiguration { + b.TypeMetaApplyConfiguration.Kind = &value + return b +} + +// WithAPIVersion sets the APIVersion field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the APIVersion field is set to the value of the last call. +func (b *TargetRunningApplyConfiguration) WithAPIVersion(value string) *TargetRunningApplyConfiguration { + b.TypeMetaApplyConfiguration.APIVersion = &value + return b +} + +// WithName sets the Name field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Name field is set to the value of the last call. +func (b *TargetRunningApplyConfiguration) WithName(value string) *TargetRunningApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.Name = &value + return b +} + +// WithGenerateName sets the GenerateName field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the GenerateName field is set to the value of the last call. +func (b *TargetRunningApplyConfiguration) WithGenerateName(value string) *TargetRunningApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.GenerateName = &value + return b +} + +// WithNamespace sets the Namespace field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Namespace field is set to the value of the last call. +func (b *TargetRunningApplyConfiguration) WithNamespace(value string) *TargetRunningApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.Namespace = &value + return b +} + +// WithUID sets the UID field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the UID field is set to the value of the last call. +func (b *TargetRunningApplyConfiguration) WithUID(value types.UID) *TargetRunningApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.UID = &value + return b +} + +// WithResourceVersion sets the ResourceVersion field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the ResourceVersion field is set to the value of the last call. +func (b *TargetRunningApplyConfiguration) WithResourceVersion(value string) *TargetRunningApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.ResourceVersion = &value + return b +} + +// WithGeneration sets the Generation field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the Generation field is set to the value of the last call. +func (b *TargetRunningApplyConfiguration) WithGeneration(value int64) *TargetRunningApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.Generation = &value + return b +} + +// WithCreationTimestamp sets the CreationTimestamp field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the CreationTimestamp field is set to the value of the last call. +func (b *TargetRunningApplyConfiguration) WithCreationTimestamp(value metav1.Time) *TargetRunningApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.CreationTimestamp = &value + return b +} + +// WithDeletionTimestamp sets the DeletionTimestamp field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the DeletionTimestamp field is set to the value of the last call. +func (b *TargetRunningApplyConfiguration) WithDeletionTimestamp(value metav1.Time) *TargetRunningApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.DeletionTimestamp = &value + return b +} + +// WithDeletionGracePeriodSeconds sets the DeletionGracePeriodSeconds field in the declarative configuration to the given value +// and returns the receiver, so that objects can be built by chaining "With" function invocations. +// If called multiple times, the DeletionGracePeriodSeconds field is set to the value of the last call. +func (b *TargetRunningApplyConfiguration) WithDeletionGracePeriodSeconds(value int64) *TargetRunningApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + b.ObjectMetaApplyConfiguration.DeletionGracePeriodSeconds = &value + return b +} + +// WithLabels puts the entries into the Labels field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, the entries provided by each call will be put on the Labels field, +// overwriting an existing map entries in Labels field with the same key. +func (b *TargetRunningApplyConfiguration) WithLabels(entries map[string]string) *TargetRunningApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + if b.ObjectMetaApplyConfiguration.Labels == nil && len(entries) > 0 { + b.ObjectMetaApplyConfiguration.Labels = make(map[string]string, len(entries)) + } + for k, v := range entries { + b.ObjectMetaApplyConfiguration.Labels[k] = v + } + return b +} + +// WithAnnotations puts the entries into the Annotations field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, the entries provided by each call will be put on the Annotations field, +// overwriting an existing map entries in Annotations field with the same key. +func (b *TargetRunningApplyConfiguration) WithAnnotations(entries map[string]string) *TargetRunningApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + if b.ObjectMetaApplyConfiguration.Annotations == nil && len(entries) > 0 { + b.ObjectMetaApplyConfiguration.Annotations = make(map[string]string, len(entries)) + } + for k, v := range entries { + b.ObjectMetaApplyConfiguration.Annotations[k] = v + } + return b +} + +// WithOwnerReferences adds the given value to the OwnerReferences field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, values provided by each call will be appended to the OwnerReferences field. +func (b *TargetRunningApplyConfiguration) WithOwnerReferences(values ...*v1.OwnerReferenceApplyConfiguration) *TargetRunningApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + for i := range values { + if values[i] == nil { + panic("nil value passed to WithOwnerReferences") + } + b.ObjectMetaApplyConfiguration.OwnerReferences = append(b.ObjectMetaApplyConfiguration.OwnerReferences, *values[i]) + } + return b +} + +// WithFinalizers adds the given value to the Finalizers field in the declarative configuration +// and returns the receiver, so that objects can be build by chaining "With" function invocations. +// If called multiple times, values provided by each call will be appended to the Finalizers field. +func (b *TargetRunningApplyConfiguration) WithFinalizers(values ...string) *TargetRunningApplyConfiguration { + b.ensureObjectMetaApplyConfigurationExists() + for i := range values { + b.ObjectMetaApplyConfiguration.Finalizers = append(b.ObjectMetaApplyConfiguration.Finalizers, values[i]) + } + return b +} + +func (b *TargetRunningApplyConfiguration) ensureObjectMetaApplyConfigurationExists() { + if b.ObjectMetaApplyConfiguration == nil { + b.ObjectMetaApplyConfiguration = &v1.ObjectMetaApplyConfiguration{} + } } // WithValue sets the Value field in the declarative configuration to the given value @@ -40,3 +212,25 @@ func (b *TargetRunningApplyConfiguration) WithValue(value runtime.RawExtension) b.Value = &value return b } + +// GetKind retrieves the value of the Kind field in the declarative configuration. +func (b *TargetRunningApplyConfiguration) GetKind() *string { + return b.TypeMetaApplyConfiguration.Kind +} + +// GetAPIVersion retrieves the value of the APIVersion field in the declarative configuration. +func (b *TargetRunningApplyConfiguration) GetAPIVersion() *string { + return b.TypeMetaApplyConfiguration.APIVersion +} + +// GetName retrieves the value of the Name field in the declarative configuration. +func (b *TargetRunningApplyConfiguration) GetName() *string { + b.ensureObjectMetaApplyConfigurationExists() + return b.ObjectMetaApplyConfiguration.Name +} + +// GetNamespace retrieves the value of the Namespace field in the declarative configuration. +func (b *TargetRunningApplyConfiguration) GetNamespace() *string { + b.ensureObjectMetaApplyConfigurationExists() + return b.ObjectMetaApplyConfiguration.Namespace +} diff --git a/pkg/generated/applyconfiguration/utils.go b/pkg/generated/applyconfiguration/utils.go index 354baa37..4012a32a 100644 --- a/pkg/generated/applyconfiguration/utils.go +++ b/pkg/generated/applyconfiguration/utils.go @@ -83,6 +83,8 @@ func ForKind(kind schema.GroupVersionKind) interface{} { return &configv1alpha1.SensitiveConfigStatusApplyConfiguration{} case v1alpha1.SchemeGroupVersion.WithKind("Target"): return &configv1alpha1.TargetApplyConfiguration{} + case v1alpha1.SchemeGroupVersion.WithKind("TargetRunning"): + return &configv1alpha1.TargetRunningApplyConfiguration{} case v1alpha1.SchemeGroupVersion.WithKind("TargetSpec"): return &configv1alpha1.TargetSpecApplyConfiguration{} case v1alpha1.SchemeGroupVersion.WithKind("TargetStatus"): diff --git a/pkg/generated/clientset/versioned/typed/config/v1alpha1/config_client.go b/pkg/generated/clientset/versioned/typed/config/v1alpha1/config_client.go index f9164671..68a13654 100644 --- a/pkg/generated/clientset/versioned/typed/config/v1alpha1/config_client.go +++ b/pkg/generated/clientset/versioned/typed/config/v1alpha1/config_client.go @@ -34,6 +34,7 @@ type ConfigV1alpha1Interface interface { RunningConfigsGetter SensitiveConfigsGetter TargetsGetter + TargetRunningsGetter } // ConfigV1alpha1Client is used to interact with features provided by the config.sdcio.dev group. @@ -69,6 +70,10 @@ func (c *ConfigV1alpha1Client) Targets(namespace string) TargetInterface { return newTargets(c, namespace) } +func (c *ConfigV1alpha1Client) TargetRunnings(namespace string) TargetRunningInterface { + return newTargetRunnings(c, namespace) +} + // NewForConfig creates a new ConfigV1alpha1Client for the given config. // NewForConfig is equivalent to NewForConfigAndClient(c, httpClient), // where httpClient was generated with rest.HTTPClientFor(c). diff --git a/pkg/generated/clientset/versioned/typed/config/v1alpha1/fake/fake_config_client.go b/pkg/generated/clientset/versioned/typed/config/v1alpha1/fake/fake_config_client.go index df4bc527..31b9421e 100644 --- a/pkg/generated/clientset/versioned/typed/config/v1alpha1/fake/fake_config_client.go +++ b/pkg/generated/clientset/versioned/typed/config/v1alpha1/fake/fake_config_client.go @@ -55,6 +55,10 @@ func (c *FakeConfigV1alpha1) Targets(namespace string) v1alpha1.TargetInterface return newFakeTargets(c, namespace) } +func (c *FakeConfigV1alpha1) TargetRunnings(namespace string) v1alpha1.TargetRunningInterface { + return newFakeTargetRunnings(c, namespace) +} + // RESTClient returns a RESTClient that is used to communicate // with API server by this client implementation. func (c *FakeConfigV1alpha1) RESTClient() rest.Interface { diff --git a/pkg/generated/clientset/versioned/typed/config/v1alpha1/fake/fake_targetrunning.go b/pkg/generated/clientset/versioned/typed/config/v1alpha1/fake/fake_targetrunning.go new file mode 100644 index 00000000..8672fa17 --- /dev/null +++ b/pkg/generated/clientset/versioned/typed/config/v1alpha1/fake/fake_targetrunning.go @@ -0,0 +1,51 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ +// Code generated by client-gen. DO NOT EDIT. + +package fake + +import ( + v1alpha1 "github.com/sdcio/config-server/apis/config/v1alpha1" + configv1alpha1 "github.com/sdcio/config-server/pkg/generated/clientset/versioned/typed/config/v1alpha1" + gentype "k8s.io/client-go/gentype" +) + +// fakeTargetRunnings implements TargetRunningInterface +type fakeTargetRunnings struct { + *gentype.FakeClientWithList[*v1alpha1.TargetRunning, *v1alpha1.TargetRunningList] + Fake *FakeConfigV1alpha1 +} + +func newFakeTargetRunnings(fake *FakeConfigV1alpha1, namespace string) configv1alpha1.TargetRunningInterface { + return &fakeTargetRunnings{ + gentype.NewFakeClientWithList[*v1alpha1.TargetRunning, *v1alpha1.TargetRunningList]( + fake.Fake, + namespace, + v1alpha1.SchemeGroupVersion.WithResource("targetrunnings"), + v1alpha1.SchemeGroupVersion.WithKind("TargetRunning"), + func() *v1alpha1.TargetRunning { return &v1alpha1.TargetRunning{} }, + func() *v1alpha1.TargetRunningList { return &v1alpha1.TargetRunningList{} }, + func(dst, src *v1alpha1.TargetRunningList) { dst.ListMeta = src.ListMeta }, + func(list *v1alpha1.TargetRunningList) []*v1alpha1.TargetRunning { + return gentype.ToPointerSlice(list.Items) + }, + func(list *v1alpha1.TargetRunningList, items []*v1alpha1.TargetRunning) { + list.Items = gentype.FromPointerSlice(items) + }, + ), + fake, + } +} diff --git a/pkg/generated/clientset/versioned/typed/config/v1alpha1/generated_expansion.go b/pkg/generated/clientset/versioned/typed/config/v1alpha1/generated_expansion.go index 2881f978..df2c952d 100644 --- a/pkg/generated/clientset/versioned/typed/config/v1alpha1/generated_expansion.go +++ b/pkg/generated/clientset/versioned/typed/config/v1alpha1/generated_expansion.go @@ -30,3 +30,5 @@ type RunningConfigExpansion interface{} type SensitiveConfigExpansion interface{} type TargetExpansion interface{} + +type TargetRunningExpansion interface{} diff --git a/pkg/generated/clientset/versioned/typed/config/v1alpha1/targetrunning.go b/pkg/generated/clientset/versioned/typed/config/v1alpha1/targetrunning.go new file mode 100644 index 00000000..fce337a6 --- /dev/null +++ b/pkg/generated/clientset/versioned/typed/config/v1alpha1/targetrunning.go @@ -0,0 +1,67 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ +// Code generated by client-gen. DO NOT EDIT. + +package v1alpha1 + +import ( + context "context" + + configv1alpha1 "github.com/sdcio/config-server/apis/config/v1alpha1" + scheme "github.com/sdcio/config-server/pkg/generated/clientset/versioned/scheme" + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + types "k8s.io/apimachinery/pkg/types" + watch "k8s.io/apimachinery/pkg/watch" + gentype "k8s.io/client-go/gentype" +) + +// TargetRunningsGetter has a method to return a TargetRunningInterface. +// A group's client should implement this interface. +type TargetRunningsGetter interface { + TargetRunnings(namespace string) TargetRunningInterface +} + +// TargetRunningInterface has methods to work with TargetRunning resources. +type TargetRunningInterface interface { + Create(ctx context.Context, targetRunning *configv1alpha1.TargetRunning, opts v1.CreateOptions) (*configv1alpha1.TargetRunning, error) + Update(ctx context.Context, targetRunning *configv1alpha1.TargetRunning, opts v1.UpdateOptions) (*configv1alpha1.TargetRunning, error) + Delete(ctx context.Context, name string, opts v1.DeleteOptions) error + DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error + Get(ctx context.Context, name string, opts v1.GetOptions) (*configv1alpha1.TargetRunning, error) + List(ctx context.Context, opts v1.ListOptions) (*configv1alpha1.TargetRunningList, error) + Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error) + Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *configv1alpha1.TargetRunning, err error) + TargetRunningExpansion +} + +// targetRunnings implements TargetRunningInterface +type targetRunnings struct { + *gentype.ClientWithList[*configv1alpha1.TargetRunning, *configv1alpha1.TargetRunningList] +} + +// newTargetRunnings returns a TargetRunnings +func newTargetRunnings(c *ConfigV1alpha1Client, namespace string) *targetRunnings { + return &targetRunnings{ + gentype.NewClientWithList[*configv1alpha1.TargetRunning, *configv1alpha1.TargetRunningList]( + "targetrunnings", + c.RESTClient(), + scheme.ParameterCodec, + namespace, + func() *configv1alpha1.TargetRunning { return &configv1alpha1.TargetRunning{} }, + func() *configv1alpha1.TargetRunningList { return &configv1alpha1.TargetRunningList{} }, + ), + } +} diff --git a/pkg/generated/informers/externalversions/config/v1alpha1/interface.go b/pkg/generated/informers/externalversions/config/v1alpha1/interface.go index abab3842..ca5d8099 100644 --- a/pkg/generated/informers/externalversions/config/v1alpha1/interface.go +++ b/pkg/generated/informers/externalversions/config/v1alpha1/interface.go @@ -37,6 +37,8 @@ type Interface interface { SensitiveConfigs() SensitiveConfigInformer // Targets returns a TargetInformer. Targets() TargetInformer + // TargetRunnings returns a TargetRunningInformer. + TargetRunnings() TargetRunningInformer } type version struct { @@ -84,3 +86,8 @@ func (v *version) SensitiveConfigs() SensitiveConfigInformer { func (v *version) Targets() TargetInformer { return &targetInformer{factory: v.factory, namespace: v.namespace, tweakListOptions: v.tweakListOptions} } + +// TargetRunnings returns a TargetRunningInformer. +func (v *version) TargetRunnings() TargetRunningInformer { + return &targetRunningInformer{factory: v.factory, namespace: v.namespace, tweakListOptions: v.tweakListOptions} +} diff --git a/pkg/generated/informers/externalversions/config/v1alpha1/targetrunning.go b/pkg/generated/informers/externalversions/config/v1alpha1/targetrunning.go new file mode 100644 index 00000000..29b70556 --- /dev/null +++ b/pkg/generated/informers/externalversions/config/v1alpha1/targetrunning.go @@ -0,0 +1,101 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ +// Code generated by informer-gen. DO NOT EDIT. + +package v1alpha1 + +import ( + context "context" + time "time" + + apisconfigv1alpha1 "github.com/sdcio/config-server/apis/config/v1alpha1" + versioned "github.com/sdcio/config-server/pkg/generated/clientset/versioned" + internalinterfaces "github.com/sdcio/config-server/pkg/generated/informers/externalversions/internalinterfaces" + configv1alpha1 "github.com/sdcio/config-server/pkg/generated/listers/config/v1alpha1" + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + runtime "k8s.io/apimachinery/pkg/runtime" + watch "k8s.io/apimachinery/pkg/watch" + cache "k8s.io/client-go/tools/cache" +) + +// TargetRunningInformer provides access to a shared informer and lister for +// TargetRunnings. +type TargetRunningInformer interface { + Informer() cache.SharedIndexInformer + Lister() configv1alpha1.TargetRunningLister +} + +type targetRunningInformer struct { + factory internalinterfaces.SharedInformerFactory + tweakListOptions internalinterfaces.TweakListOptionsFunc + namespace string +} + +// NewTargetRunningInformer constructs a new informer for TargetRunning type. +// Always prefer using an informer factory to get a shared informer instead of getting an independent +// one. This reduces memory footprint and number of connections to the server. +func NewTargetRunningInformer(client versioned.Interface, namespace string, resyncPeriod time.Duration, indexers cache.Indexers) cache.SharedIndexInformer { + return NewFilteredTargetRunningInformer(client, namespace, resyncPeriod, indexers, nil) +} + +// NewFilteredTargetRunningInformer constructs a new informer for TargetRunning type. +// Always prefer using an informer factory to get a shared informer instead of getting an independent +// one. This reduces memory footprint and number of connections to the server. +func NewFilteredTargetRunningInformer(client versioned.Interface, namespace string, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer { + return cache.NewSharedIndexInformer( + cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{ + ListFunc: func(options v1.ListOptions) (runtime.Object, error) { + if tweakListOptions != nil { + tweakListOptions(&options) + } + return client.ConfigV1alpha1().TargetRunnings(namespace).List(context.Background(), options) + }, + WatchFunc: func(options v1.ListOptions) (watch.Interface, error) { + if tweakListOptions != nil { + tweakListOptions(&options) + } + return client.ConfigV1alpha1().TargetRunnings(namespace).Watch(context.Background(), options) + }, + ListWithContextFunc: func(ctx context.Context, options v1.ListOptions) (runtime.Object, error) { + if tweakListOptions != nil { + tweakListOptions(&options) + } + return client.ConfigV1alpha1().TargetRunnings(namespace).List(ctx, options) + }, + WatchFuncWithContext: func(ctx context.Context, options v1.ListOptions) (watch.Interface, error) { + if tweakListOptions != nil { + tweakListOptions(&options) + } + return client.ConfigV1alpha1().TargetRunnings(namespace).Watch(ctx, options) + }, + }, client), + &apisconfigv1alpha1.TargetRunning{}, + resyncPeriod, + indexers, + ) +} + +func (f *targetRunningInformer) defaultInformer(client versioned.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer { + return NewFilteredTargetRunningInformer(client, f.namespace, resyncPeriod, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, f.tweakListOptions) +} + +func (f *targetRunningInformer) Informer() cache.SharedIndexInformer { + return f.factory.InformerFor(&apisconfigv1alpha1.TargetRunning{}, f.defaultInformer) +} + +func (f *targetRunningInformer) Lister() configv1alpha1.TargetRunningLister { + return configv1alpha1.NewTargetRunningLister(f.Informer().GetIndexer()) +} diff --git a/pkg/generated/informers/externalversions/generic.go b/pkg/generated/informers/externalversions/generic.go index f9e678aa..985e54da 100644 --- a/pkg/generated/informers/externalversions/generic.go +++ b/pkg/generated/informers/externalversions/generic.go @@ -67,6 +67,8 @@ func (f *sharedInformerFactory) ForResource(resource schema.GroupVersionResource return &genericInformer{resource: resource.GroupResource(), informer: f.Config().V1alpha1().SensitiveConfigs().Informer()}, nil case v1alpha1.SchemeGroupVersion.WithResource("targets"): return &genericInformer{resource: resource.GroupResource(), informer: f.Config().V1alpha1().Targets().Informer()}, nil + case v1alpha1.SchemeGroupVersion.WithResource("targetrunnings"): + return &genericInformer{resource: resource.GroupResource(), informer: f.Config().V1alpha1().TargetRunnings().Informer()}, nil // Group=inv.sdcio.dev, Version=v1alpha1 case invv1alpha1.SchemeGroupVersion.WithResource("discoveryrules"): diff --git a/pkg/generated/listers/config/v1alpha1/expansion_generated.go b/pkg/generated/listers/config/v1alpha1/expansion_generated.go index bd3358d3..149ae6ac 100644 --- a/pkg/generated/listers/config/v1alpha1/expansion_generated.go +++ b/pkg/generated/listers/config/v1alpha1/expansion_generated.go @@ -72,3 +72,11 @@ type TargetListerExpansion interface{} // TargetNamespaceListerExpansion allows custom methods to be added to // TargetNamespaceLister. type TargetNamespaceListerExpansion interface{} + +// TargetRunningListerExpansion allows custom methods to be added to +// TargetRunningLister. +type TargetRunningListerExpansion interface{} + +// TargetRunningNamespaceListerExpansion allows custom methods to be added to +// TargetRunningNamespaceLister. +type TargetRunningNamespaceListerExpansion interface{} diff --git a/pkg/generated/listers/config/v1alpha1/targetrunning.go b/pkg/generated/listers/config/v1alpha1/targetrunning.go new file mode 100644 index 00000000..2d4c4e90 --- /dev/null +++ b/pkg/generated/listers/config/v1alpha1/targetrunning.go @@ -0,0 +1,69 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ +// Code generated by lister-gen. DO NOT EDIT. + +package v1alpha1 + +import ( + configv1alpha1 "github.com/sdcio/config-server/apis/config/v1alpha1" + labels "k8s.io/apimachinery/pkg/labels" + listers "k8s.io/client-go/listers" + cache "k8s.io/client-go/tools/cache" +) + +// TargetRunningLister helps list TargetRunnings. +// All objects returned here must be treated as read-only. +type TargetRunningLister interface { + // List lists all TargetRunnings in the indexer. + // Objects returned here must be treated as read-only. + List(selector labels.Selector) (ret []*configv1alpha1.TargetRunning, err error) + // TargetRunnings returns an object that can list and get TargetRunnings. + TargetRunnings(namespace string) TargetRunningNamespaceLister + TargetRunningListerExpansion +} + +// targetRunningLister implements the TargetRunningLister interface. +type targetRunningLister struct { + listers.ResourceIndexer[*configv1alpha1.TargetRunning] +} + +// NewTargetRunningLister returns a new TargetRunningLister. +func NewTargetRunningLister(indexer cache.Indexer) TargetRunningLister { + return &targetRunningLister{listers.New[*configv1alpha1.TargetRunning](indexer, configv1alpha1.Resource("targetrunning"))} +} + +// TargetRunnings returns an object that can list and get TargetRunnings. +func (s *targetRunningLister) TargetRunnings(namespace string) TargetRunningNamespaceLister { + return targetRunningNamespaceLister{listers.NewNamespaced[*configv1alpha1.TargetRunning](s.ResourceIndexer, namespace)} +} + +// TargetRunningNamespaceLister helps list and get TargetRunnings. +// All objects returned here must be treated as read-only. +type TargetRunningNamespaceLister interface { + // List lists all TargetRunnings in the indexer for a given namespace. + // Objects returned here must be treated as read-only. + List(selector labels.Selector) (ret []*configv1alpha1.TargetRunning, err error) + // Get retrieves the TargetRunning from the indexer for a given namespace and name. + // Objects returned here must be treated as read-only. + Get(name string) (*configv1alpha1.TargetRunning, error) + TargetRunningNamespaceListerExpansion +} + +// targetRunningNamespaceLister implements the TargetRunningNamespaceLister +// interface. +type targetRunningNamespaceLister struct { + listers.ResourceIndexer[*configv1alpha1.TargetRunning] +} From eee902e1522a622b11550303b04c29aed63e6e7b Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Mon, 2 Mar 2026 18:50:13 +0100 Subject: [PATCH 108/135] added blame, running, cleardeviation --- apis/config/v1alpha1/target_running_types.go | 1 - pkg/generated/applyconfiguration/utils.go | 2 - .../typed/config/v1alpha1/config_client.go | 5 - .../v1alpha1/fake/fake_config_client.go | 4 - .../v1alpha1/fake/fake_targetrunning.go | 51 --------- .../config/v1alpha1/generated_expansion.go | 2 - .../typed/config/v1alpha1/targetrunning.go | 67 ------------ .../config/v1alpha1/interface.go | 7 -- .../config/v1alpha1/targetrunning.go | 101 ------------------ .../informers/externalversions/generic.go | 2 - .../config/v1alpha1/expansion_generated.go | 8 -- .../listers/config/v1alpha1/targetrunning.go | 69 ------------ 12 files changed, 319 deletions(-) delete mode 100644 pkg/generated/clientset/versioned/typed/config/v1alpha1/fake/fake_targetrunning.go delete mode 100644 pkg/generated/clientset/versioned/typed/config/v1alpha1/targetrunning.go delete mode 100644 pkg/generated/informers/externalversions/config/v1alpha1/targetrunning.go delete mode 100644 pkg/generated/listers/config/v1alpha1/targetrunning.go diff --git a/apis/config/v1alpha1/target_running_types.go b/apis/config/v1alpha1/target_running_types.go index bf9baabb..1d6e59cf 100644 --- a/apis/config/v1alpha1/target_running_types.go +++ b/apis/config/v1alpha1/target_running_types.go @@ -21,7 +21,6 @@ import ( "k8s.io/apimachinery/pkg/runtime" ) -// +genclient // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object // +k8s:openapi-gen=true diff --git a/pkg/generated/applyconfiguration/utils.go b/pkg/generated/applyconfiguration/utils.go index 4012a32a..354baa37 100644 --- a/pkg/generated/applyconfiguration/utils.go +++ b/pkg/generated/applyconfiguration/utils.go @@ -83,8 +83,6 @@ func ForKind(kind schema.GroupVersionKind) interface{} { return &configv1alpha1.SensitiveConfigStatusApplyConfiguration{} case v1alpha1.SchemeGroupVersion.WithKind("Target"): return &configv1alpha1.TargetApplyConfiguration{} - case v1alpha1.SchemeGroupVersion.WithKind("TargetRunning"): - return &configv1alpha1.TargetRunningApplyConfiguration{} case v1alpha1.SchemeGroupVersion.WithKind("TargetSpec"): return &configv1alpha1.TargetSpecApplyConfiguration{} case v1alpha1.SchemeGroupVersion.WithKind("TargetStatus"): diff --git a/pkg/generated/clientset/versioned/typed/config/v1alpha1/config_client.go b/pkg/generated/clientset/versioned/typed/config/v1alpha1/config_client.go index 68a13654..f9164671 100644 --- a/pkg/generated/clientset/versioned/typed/config/v1alpha1/config_client.go +++ b/pkg/generated/clientset/versioned/typed/config/v1alpha1/config_client.go @@ -34,7 +34,6 @@ type ConfigV1alpha1Interface interface { RunningConfigsGetter SensitiveConfigsGetter TargetsGetter - TargetRunningsGetter } // ConfigV1alpha1Client is used to interact with features provided by the config.sdcio.dev group. @@ -70,10 +69,6 @@ func (c *ConfigV1alpha1Client) Targets(namespace string) TargetInterface { return newTargets(c, namespace) } -func (c *ConfigV1alpha1Client) TargetRunnings(namespace string) TargetRunningInterface { - return newTargetRunnings(c, namespace) -} - // NewForConfig creates a new ConfigV1alpha1Client for the given config. // NewForConfig is equivalent to NewForConfigAndClient(c, httpClient), // where httpClient was generated with rest.HTTPClientFor(c). diff --git a/pkg/generated/clientset/versioned/typed/config/v1alpha1/fake/fake_config_client.go b/pkg/generated/clientset/versioned/typed/config/v1alpha1/fake/fake_config_client.go index 31b9421e..df4bc527 100644 --- a/pkg/generated/clientset/versioned/typed/config/v1alpha1/fake/fake_config_client.go +++ b/pkg/generated/clientset/versioned/typed/config/v1alpha1/fake/fake_config_client.go @@ -55,10 +55,6 @@ func (c *FakeConfigV1alpha1) Targets(namespace string) v1alpha1.TargetInterface return newFakeTargets(c, namespace) } -func (c *FakeConfigV1alpha1) TargetRunnings(namespace string) v1alpha1.TargetRunningInterface { - return newFakeTargetRunnings(c, namespace) -} - // RESTClient returns a RESTClient that is used to communicate // with API server by this client implementation. func (c *FakeConfigV1alpha1) RESTClient() rest.Interface { diff --git a/pkg/generated/clientset/versioned/typed/config/v1alpha1/fake/fake_targetrunning.go b/pkg/generated/clientset/versioned/typed/config/v1alpha1/fake/fake_targetrunning.go deleted file mode 100644 index 8672fa17..00000000 --- a/pkg/generated/clientset/versioned/typed/config/v1alpha1/fake/fake_targetrunning.go +++ /dev/null @@ -1,51 +0,0 @@ -/* -Copyright 2024 Nokia. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ -// Code generated by client-gen. DO NOT EDIT. - -package fake - -import ( - v1alpha1 "github.com/sdcio/config-server/apis/config/v1alpha1" - configv1alpha1 "github.com/sdcio/config-server/pkg/generated/clientset/versioned/typed/config/v1alpha1" - gentype "k8s.io/client-go/gentype" -) - -// fakeTargetRunnings implements TargetRunningInterface -type fakeTargetRunnings struct { - *gentype.FakeClientWithList[*v1alpha1.TargetRunning, *v1alpha1.TargetRunningList] - Fake *FakeConfigV1alpha1 -} - -func newFakeTargetRunnings(fake *FakeConfigV1alpha1, namespace string) configv1alpha1.TargetRunningInterface { - return &fakeTargetRunnings{ - gentype.NewFakeClientWithList[*v1alpha1.TargetRunning, *v1alpha1.TargetRunningList]( - fake.Fake, - namespace, - v1alpha1.SchemeGroupVersion.WithResource("targetrunnings"), - v1alpha1.SchemeGroupVersion.WithKind("TargetRunning"), - func() *v1alpha1.TargetRunning { return &v1alpha1.TargetRunning{} }, - func() *v1alpha1.TargetRunningList { return &v1alpha1.TargetRunningList{} }, - func(dst, src *v1alpha1.TargetRunningList) { dst.ListMeta = src.ListMeta }, - func(list *v1alpha1.TargetRunningList) []*v1alpha1.TargetRunning { - return gentype.ToPointerSlice(list.Items) - }, - func(list *v1alpha1.TargetRunningList, items []*v1alpha1.TargetRunning) { - list.Items = gentype.FromPointerSlice(items) - }, - ), - fake, - } -} diff --git a/pkg/generated/clientset/versioned/typed/config/v1alpha1/generated_expansion.go b/pkg/generated/clientset/versioned/typed/config/v1alpha1/generated_expansion.go index df2c952d..2881f978 100644 --- a/pkg/generated/clientset/versioned/typed/config/v1alpha1/generated_expansion.go +++ b/pkg/generated/clientset/versioned/typed/config/v1alpha1/generated_expansion.go @@ -30,5 +30,3 @@ type RunningConfigExpansion interface{} type SensitiveConfigExpansion interface{} type TargetExpansion interface{} - -type TargetRunningExpansion interface{} diff --git a/pkg/generated/clientset/versioned/typed/config/v1alpha1/targetrunning.go b/pkg/generated/clientset/versioned/typed/config/v1alpha1/targetrunning.go deleted file mode 100644 index fce337a6..00000000 --- a/pkg/generated/clientset/versioned/typed/config/v1alpha1/targetrunning.go +++ /dev/null @@ -1,67 +0,0 @@ -/* -Copyright 2024 Nokia. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ -// Code generated by client-gen. DO NOT EDIT. - -package v1alpha1 - -import ( - context "context" - - configv1alpha1 "github.com/sdcio/config-server/apis/config/v1alpha1" - scheme "github.com/sdcio/config-server/pkg/generated/clientset/versioned/scheme" - v1 "k8s.io/apimachinery/pkg/apis/meta/v1" - types "k8s.io/apimachinery/pkg/types" - watch "k8s.io/apimachinery/pkg/watch" - gentype "k8s.io/client-go/gentype" -) - -// TargetRunningsGetter has a method to return a TargetRunningInterface. -// A group's client should implement this interface. -type TargetRunningsGetter interface { - TargetRunnings(namespace string) TargetRunningInterface -} - -// TargetRunningInterface has methods to work with TargetRunning resources. -type TargetRunningInterface interface { - Create(ctx context.Context, targetRunning *configv1alpha1.TargetRunning, opts v1.CreateOptions) (*configv1alpha1.TargetRunning, error) - Update(ctx context.Context, targetRunning *configv1alpha1.TargetRunning, opts v1.UpdateOptions) (*configv1alpha1.TargetRunning, error) - Delete(ctx context.Context, name string, opts v1.DeleteOptions) error - DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error - Get(ctx context.Context, name string, opts v1.GetOptions) (*configv1alpha1.TargetRunning, error) - List(ctx context.Context, opts v1.ListOptions) (*configv1alpha1.TargetRunningList, error) - Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error) - Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *configv1alpha1.TargetRunning, err error) - TargetRunningExpansion -} - -// targetRunnings implements TargetRunningInterface -type targetRunnings struct { - *gentype.ClientWithList[*configv1alpha1.TargetRunning, *configv1alpha1.TargetRunningList] -} - -// newTargetRunnings returns a TargetRunnings -func newTargetRunnings(c *ConfigV1alpha1Client, namespace string) *targetRunnings { - return &targetRunnings{ - gentype.NewClientWithList[*configv1alpha1.TargetRunning, *configv1alpha1.TargetRunningList]( - "targetrunnings", - c.RESTClient(), - scheme.ParameterCodec, - namespace, - func() *configv1alpha1.TargetRunning { return &configv1alpha1.TargetRunning{} }, - func() *configv1alpha1.TargetRunningList { return &configv1alpha1.TargetRunningList{} }, - ), - } -} diff --git a/pkg/generated/informers/externalversions/config/v1alpha1/interface.go b/pkg/generated/informers/externalversions/config/v1alpha1/interface.go index ca5d8099..abab3842 100644 --- a/pkg/generated/informers/externalversions/config/v1alpha1/interface.go +++ b/pkg/generated/informers/externalversions/config/v1alpha1/interface.go @@ -37,8 +37,6 @@ type Interface interface { SensitiveConfigs() SensitiveConfigInformer // Targets returns a TargetInformer. Targets() TargetInformer - // TargetRunnings returns a TargetRunningInformer. - TargetRunnings() TargetRunningInformer } type version struct { @@ -86,8 +84,3 @@ func (v *version) SensitiveConfigs() SensitiveConfigInformer { func (v *version) Targets() TargetInformer { return &targetInformer{factory: v.factory, namespace: v.namespace, tweakListOptions: v.tweakListOptions} } - -// TargetRunnings returns a TargetRunningInformer. -func (v *version) TargetRunnings() TargetRunningInformer { - return &targetRunningInformer{factory: v.factory, namespace: v.namespace, tweakListOptions: v.tweakListOptions} -} diff --git a/pkg/generated/informers/externalversions/config/v1alpha1/targetrunning.go b/pkg/generated/informers/externalversions/config/v1alpha1/targetrunning.go deleted file mode 100644 index 29b70556..00000000 --- a/pkg/generated/informers/externalversions/config/v1alpha1/targetrunning.go +++ /dev/null @@ -1,101 +0,0 @@ -/* -Copyright 2024 Nokia. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ -// Code generated by informer-gen. DO NOT EDIT. - -package v1alpha1 - -import ( - context "context" - time "time" - - apisconfigv1alpha1 "github.com/sdcio/config-server/apis/config/v1alpha1" - versioned "github.com/sdcio/config-server/pkg/generated/clientset/versioned" - internalinterfaces "github.com/sdcio/config-server/pkg/generated/informers/externalversions/internalinterfaces" - configv1alpha1 "github.com/sdcio/config-server/pkg/generated/listers/config/v1alpha1" - v1 "k8s.io/apimachinery/pkg/apis/meta/v1" - runtime "k8s.io/apimachinery/pkg/runtime" - watch "k8s.io/apimachinery/pkg/watch" - cache "k8s.io/client-go/tools/cache" -) - -// TargetRunningInformer provides access to a shared informer and lister for -// TargetRunnings. -type TargetRunningInformer interface { - Informer() cache.SharedIndexInformer - Lister() configv1alpha1.TargetRunningLister -} - -type targetRunningInformer struct { - factory internalinterfaces.SharedInformerFactory - tweakListOptions internalinterfaces.TweakListOptionsFunc - namespace string -} - -// NewTargetRunningInformer constructs a new informer for TargetRunning type. -// Always prefer using an informer factory to get a shared informer instead of getting an independent -// one. This reduces memory footprint and number of connections to the server. -func NewTargetRunningInformer(client versioned.Interface, namespace string, resyncPeriod time.Duration, indexers cache.Indexers) cache.SharedIndexInformer { - return NewFilteredTargetRunningInformer(client, namespace, resyncPeriod, indexers, nil) -} - -// NewFilteredTargetRunningInformer constructs a new informer for TargetRunning type. -// Always prefer using an informer factory to get a shared informer instead of getting an independent -// one. This reduces memory footprint and number of connections to the server. -func NewFilteredTargetRunningInformer(client versioned.Interface, namespace string, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer { - return cache.NewSharedIndexInformer( - cache.ToListWatcherWithWatchListSemantics(&cache.ListWatch{ - ListFunc: func(options v1.ListOptions) (runtime.Object, error) { - if tweakListOptions != nil { - tweakListOptions(&options) - } - return client.ConfigV1alpha1().TargetRunnings(namespace).List(context.Background(), options) - }, - WatchFunc: func(options v1.ListOptions) (watch.Interface, error) { - if tweakListOptions != nil { - tweakListOptions(&options) - } - return client.ConfigV1alpha1().TargetRunnings(namespace).Watch(context.Background(), options) - }, - ListWithContextFunc: func(ctx context.Context, options v1.ListOptions) (runtime.Object, error) { - if tweakListOptions != nil { - tweakListOptions(&options) - } - return client.ConfigV1alpha1().TargetRunnings(namespace).List(ctx, options) - }, - WatchFuncWithContext: func(ctx context.Context, options v1.ListOptions) (watch.Interface, error) { - if tweakListOptions != nil { - tweakListOptions(&options) - } - return client.ConfigV1alpha1().TargetRunnings(namespace).Watch(ctx, options) - }, - }, client), - &apisconfigv1alpha1.TargetRunning{}, - resyncPeriod, - indexers, - ) -} - -func (f *targetRunningInformer) defaultInformer(client versioned.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer { - return NewFilteredTargetRunningInformer(client, f.namespace, resyncPeriod, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, f.tweakListOptions) -} - -func (f *targetRunningInformer) Informer() cache.SharedIndexInformer { - return f.factory.InformerFor(&apisconfigv1alpha1.TargetRunning{}, f.defaultInformer) -} - -func (f *targetRunningInformer) Lister() configv1alpha1.TargetRunningLister { - return configv1alpha1.NewTargetRunningLister(f.Informer().GetIndexer()) -} diff --git a/pkg/generated/informers/externalversions/generic.go b/pkg/generated/informers/externalversions/generic.go index 985e54da..f9e678aa 100644 --- a/pkg/generated/informers/externalversions/generic.go +++ b/pkg/generated/informers/externalversions/generic.go @@ -67,8 +67,6 @@ func (f *sharedInformerFactory) ForResource(resource schema.GroupVersionResource return &genericInformer{resource: resource.GroupResource(), informer: f.Config().V1alpha1().SensitiveConfigs().Informer()}, nil case v1alpha1.SchemeGroupVersion.WithResource("targets"): return &genericInformer{resource: resource.GroupResource(), informer: f.Config().V1alpha1().Targets().Informer()}, nil - case v1alpha1.SchemeGroupVersion.WithResource("targetrunnings"): - return &genericInformer{resource: resource.GroupResource(), informer: f.Config().V1alpha1().TargetRunnings().Informer()}, nil // Group=inv.sdcio.dev, Version=v1alpha1 case invv1alpha1.SchemeGroupVersion.WithResource("discoveryrules"): diff --git a/pkg/generated/listers/config/v1alpha1/expansion_generated.go b/pkg/generated/listers/config/v1alpha1/expansion_generated.go index 149ae6ac..bd3358d3 100644 --- a/pkg/generated/listers/config/v1alpha1/expansion_generated.go +++ b/pkg/generated/listers/config/v1alpha1/expansion_generated.go @@ -72,11 +72,3 @@ type TargetListerExpansion interface{} // TargetNamespaceListerExpansion allows custom methods to be added to // TargetNamespaceLister. type TargetNamespaceListerExpansion interface{} - -// TargetRunningListerExpansion allows custom methods to be added to -// TargetRunningLister. -type TargetRunningListerExpansion interface{} - -// TargetRunningNamespaceListerExpansion allows custom methods to be added to -// TargetRunningNamespaceLister. -type TargetRunningNamespaceListerExpansion interface{} diff --git a/pkg/generated/listers/config/v1alpha1/targetrunning.go b/pkg/generated/listers/config/v1alpha1/targetrunning.go deleted file mode 100644 index 2d4c4e90..00000000 --- a/pkg/generated/listers/config/v1alpha1/targetrunning.go +++ /dev/null @@ -1,69 +0,0 @@ -/* -Copyright 2024 Nokia. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ -// Code generated by lister-gen. DO NOT EDIT. - -package v1alpha1 - -import ( - configv1alpha1 "github.com/sdcio/config-server/apis/config/v1alpha1" - labels "k8s.io/apimachinery/pkg/labels" - listers "k8s.io/client-go/listers" - cache "k8s.io/client-go/tools/cache" -) - -// TargetRunningLister helps list TargetRunnings. -// All objects returned here must be treated as read-only. -type TargetRunningLister interface { - // List lists all TargetRunnings in the indexer. - // Objects returned here must be treated as read-only. - List(selector labels.Selector) (ret []*configv1alpha1.TargetRunning, err error) - // TargetRunnings returns an object that can list and get TargetRunnings. - TargetRunnings(namespace string) TargetRunningNamespaceLister - TargetRunningListerExpansion -} - -// targetRunningLister implements the TargetRunningLister interface. -type targetRunningLister struct { - listers.ResourceIndexer[*configv1alpha1.TargetRunning] -} - -// NewTargetRunningLister returns a new TargetRunningLister. -func NewTargetRunningLister(indexer cache.Indexer) TargetRunningLister { - return &targetRunningLister{listers.New[*configv1alpha1.TargetRunning](indexer, configv1alpha1.Resource("targetrunning"))} -} - -// TargetRunnings returns an object that can list and get TargetRunnings. -func (s *targetRunningLister) TargetRunnings(namespace string) TargetRunningNamespaceLister { - return targetRunningNamespaceLister{listers.NewNamespaced[*configv1alpha1.TargetRunning](s.ResourceIndexer, namespace)} -} - -// TargetRunningNamespaceLister helps list and get TargetRunnings. -// All objects returned here must be treated as read-only. -type TargetRunningNamespaceLister interface { - // List lists all TargetRunnings in the indexer for a given namespace. - // Objects returned here must be treated as read-only. - List(selector labels.Selector) (ret []*configv1alpha1.TargetRunning, err error) - // Get retrieves the TargetRunning from the indexer for a given namespace and name. - // Objects returned here must be treated as read-only. - Get(name string) (*configv1alpha1.TargetRunning, error) - TargetRunningNamespaceListerExpansion -} - -// targetRunningNamespaceLister implements the TargetRunningNamespaceLister -// interface. -type targetRunningNamespaceLister struct { - listers.ResourceIndexer[*configv1alpha1.TargetRunning] -} From 23a538d4c6e362a628ae798eed7a2f065e0c0421 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Mon, 2 Mar 2026 19:09:04 +0100 Subject: [PATCH 109/135] update target registration for v1alpha1 --- apis/config/v1alpha1/target_resource.go | 32 +++++++++++++++++++++++++ 1 file changed, 32 insertions(+) diff --git a/apis/config/v1alpha1/target_resource.go b/apis/config/v1alpha1/target_resource.go index 59856cc1..0d1a5499 100644 --- a/apis/config/v1alpha1/target_resource.go +++ b/apis/config/v1alpha1/target_resource.go @@ -17,11 +17,14 @@ limitations under the License. package v1alpha1 import ( + "fmt" + "github.com/henderiw/apiserver-builder/pkg/builder/resource" "github.com/sdcio/config-server/apis/config" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/apimachinery/pkg/runtime" "k8s.io/apimachinery/pkg/runtime/schema" + "k8s.io/apiserver/pkg/registry/rest" ) // +k8s:deepcopy-gen=false @@ -29,6 +32,16 @@ var _ resource.Object = &Target{} var _ resource.ObjectList = &TargetList{} var _ resource.MultiVersionObject = &Target{} +var _ resource.ObjectWithArbitrarySubResource = &Target{} + +func (r *Target) GetArbitrarySubResources() []resource.ArbitrarySubResource { + return []resource.ArbitrarySubResource{ + &TargetRunning{}, + &TargetClearDeviation{}, + &TargetBlame{}, + } +} + func (Target) GetGroupVersionResource() schema.GroupVersionResource { return schema.GroupVersionResource{ Group: SchemeGroupVersion.Group, @@ -77,3 +90,22 @@ func (r *TargetList) GetListMeta() *metav1.ListMeta { func (Target) RegisterConversions() func(s *runtime.Scheme) error { return RegisterConversions } + +// Minimal interface implementations for v1alpha1 types +func (TargetRunning) SubResourceName() string { return "running" } +func (TargetRunning) New() runtime.Object { return &TargetRunning{} } +func (TargetRunning) NewStorage(_ *runtime.Scheme, _ rest.Storage) (rest.Storage, error) { + return nil, fmt.Errorf("not implemented on versioned type") +} + +func (TargetClearDeviation) SubResourceName() string { return "cleardeviation" } +func (TargetClearDeviation) New() runtime.Object { return &TargetClearDeviation{} } +func (TargetClearDeviation) NewStorage(_ *runtime.Scheme, _ rest.Storage) (rest.Storage, error) { + return nil, fmt.Errorf("not implemented on versioned type") +} + +func (TargetBlame) SubResourceName() string { return "blame" } +func (TargetBlame) New() runtime.Object { return &TargetBlame{} } +func (TargetBlame) NewStorage(_ *runtime.Scheme, _ rest.Storage) (rest.Storage, error) { + return nil, fmt.Errorf("not implemented on versioned type") +} From d4d2be9ec2ef12e0f16124f0b93f1e7302b28dc7 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Mon, 2 Mar 2026 19:30:05 +0100 Subject: [PATCH 110/135] update names to runningconfig anad configblame --- apis/config/register.go | 4 +- ...urce.go => target_configblame_resource.go} | 26 ++--- ...e_types.go => target_configblame_types.go} | 4 +- apis/config/target_resource.go | 4 +- ...ce.go => target_runningconfig_resource.go} | 24 ++-- ...types.go => target_runningconfig_types.go} | 4 +- apis/config/v1alpha1/register.go | 4 +- .../target_cleardeviation_resource.go | 31 +++++ .../v1alpha1/target_configblame_resource.go | 30 +++++ ...e_types.go => target_configblame_types.go} | 4 +- apis/config/v1alpha1/target_resource.go | 26 +---- .../v1alpha1/target_runningconfig_resource.go | 31 +++++ ...types.go => target_runningconfig_types.go} | 4 +- .../v1alpha1/zz_generated.conversion.go | 88 +++++++-------- apis/config/v1alpha1/zz_generated.deepcopy.go | 64 +++++------ apis/config/zz_generated.deepcopy.go | 64 +++++------ pkg/generated/openapi/zz_generated.openapi.go | 106 +++++++++--------- 17 files changed, 294 insertions(+), 224 deletions(-) rename apis/config/{target_blame_resource.go => target_configblame_resource.go} (80%) rename apis/config/{target_blame_types.go => target_configblame_types.go} (91%) rename apis/config/{target_running_resource.go => target_runningconfig_resource.go} (78%) rename apis/config/{target_running_types.go => target_runningconfig_types.go} (91%) create mode 100644 apis/config/v1alpha1/target_cleardeviation_resource.go create mode 100644 apis/config/v1alpha1/target_configblame_resource.go rename apis/config/v1alpha1/{target_blame_types.go => target_configblame_types.go} (91%) create mode 100644 apis/config/v1alpha1/target_runningconfig_resource.go rename apis/config/v1alpha1/{target_running_types.go => target_runningconfig_types.go} (90%) diff --git a/apis/config/register.go b/apis/config/register.go index 4aebf506..ed630b83 100644 --- a/apis/config/register.go +++ b/apis/config/register.go @@ -54,8 +54,8 @@ func addKnownTypes(scheme *runtime.Scheme) error { &ConfigBlameList{}, &Target{}, &TargetList{}, - &TargetBlame{}, - &TargetRunning{}, + &TargetConfigBlame{}, + &TargetRunningConfig{}, &TargetClearDeviation{}, ) return nil diff --git a/apis/config/target_blame_resource.go b/apis/config/target_configblame_resource.go similarity index 80% rename from apis/config/target_blame_resource.go rename to apis/config/target_configblame_resource.go index eb6d798f..c5e70a5d 100644 --- a/apis/config/target_blame_resource.go +++ b/apis/config/target_configblame_resource.go @@ -34,32 +34,32 @@ import ( var _ resource.ArbitrarySubResource = &TargetClearDeviation{} -func (TargetBlame) SubResourceName() string { - return "blame" +func (TargetConfigBlame) SubResourceName() string { + return "configblame" } -func (TargetBlame) New() runtime.Object { - return &TargetBlame{} // returns parent type — GET returns the full Target +func (TargetConfigBlame) New() runtime.Object { + return &TargetConfigBlame{} // returns parent type — GET returns the full Target } -func (TargetBlame) NewStorage(scheme *runtime.Scheme, parentStorage rest.Storage) (rest.Storage, error) { - return &targetRunningREST{ +func (TargetConfigBlame) NewStorage(scheme *runtime.Scheme, parentStorage rest.Storage) (rest.Storage, error) { + return &targetConfigBlameREST{ parentStore: parentStorage, }, nil } // targetBlameREST implements rest.Storage + rest.Getter -type targetBlameREST struct { +type targetConfigBlameREST struct { parentStore rest.Storage } -func (r *targetBlameREST) New() runtime.Object { - return &TargetBlame{} +func (r *targetConfigBlameREST) New() runtime.Object { + return &TargetConfigBlame{} } -func (r *targetBlameREST) Destroy() {} +func (r *targetConfigBlameREST) Destroy() {} -func (r *targetBlameREST) Get(ctx context.Context, name string, options *metav1.GetOptions) (runtime.Object, error) { +func (r *targetConfigBlameREST) Get(ctx context.Context, name string, options *metav1.GetOptions) (runtime.Object, error) { // Get the parent Target from the parent store getter := r.parentStore.(rest.Getter) @@ -101,7 +101,7 @@ func (r *targetBlameREST) Get(ctx context.Context, name string, options *metav1. } if rsp == nil || rsp.ConfigTree == nil { - return &TargetBlame{ + return &TargetConfigBlame{ ObjectMeta: metav1.ObjectMeta{ Name: target.Name, Namespace: target.Namespace, @@ -115,7 +115,7 @@ func (r *targetBlameREST) Get(ctx context.Context, name string, options *metav1. return nil, err } - return &TargetBlame{ + return &TargetConfigBlame{ ObjectMeta: metav1.ObjectMeta{ Name: target.Name, Namespace: target.Namespace, diff --git a/apis/config/target_blame_types.go b/apis/config/target_configblame_types.go similarity index 91% rename from apis/config/target_blame_types.go rename to apis/config/target_configblame_types.go index 602fba73..e5462353 100644 --- a/apis/config/target_blame_types.go +++ b/apis/config/target_configblame_types.go @@ -24,8 +24,8 @@ import ( // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object // +k8s:openapi-gen=true -// TargetBlame is the Schema for the TargetBlame API -type TargetBlame struct { +// TargetConfigBlame is the Schema for the TargetConfigBlame API +type TargetConfigBlame struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` diff --git a/apis/config/target_resource.go b/apis/config/target_resource.go index 61b5cf2a..6a124826 100644 --- a/apis/config/target_resource.go +++ b/apis/config/target_resource.go @@ -56,9 +56,9 @@ var _ resource.ObjectWithArbitrarySubResource = &Target{} func (r *Target) GetArbitrarySubResources() []resource.ArbitrarySubResource { return []resource.ArbitrarySubResource{ - &TargetRunning{}, + &TargetRunningConfig{}, &TargetClearDeviation{}, - &TargetBlame{}, + &TargetConfigBlame{}, } } diff --git a/apis/config/target_running_resource.go b/apis/config/target_runningconfig_resource.go similarity index 78% rename from apis/config/target_running_resource.go rename to apis/config/target_runningconfig_resource.go index 571a9bc0..3f810ea4 100644 --- a/apis/config/target_running_resource.go +++ b/apis/config/target_runningconfig_resource.go @@ -33,32 +33,32 @@ import ( var _ resource.ArbitrarySubResource = &TargetClearDeviation{} -func (TargetRunning) SubResourceName() string { - return "running" +func (TargetRunningConfig) SubResourceName() string { + return "runningconfig" } -func (TargetRunning) New() runtime.Object { - return &TargetRunning{} // returns parent type — GET returns the full Target +func (TargetRunningConfig) New() runtime.Object { + return &TargetRunningConfig{} // returns parent type — GET returns the full Target } -func (TargetRunning) NewStorage(scheme *runtime.Scheme, parentStorage rest.Storage) (rest.Storage, error) { - return &targetRunningREST{ +func (TargetRunningConfig) NewStorage(scheme *runtime.Scheme, parentStorage rest.Storage) (rest.Storage, error) { + return &targetRunningConfigREST{ parentStore: parentStorage, }, nil } // targetRunningREST implements rest.Storage + rest.Getter -type targetRunningREST struct { +type targetRunningConfigREST struct { parentStore rest.Storage } -func (r *targetRunningREST) New() runtime.Object { - return &TargetRunning{} +func (r *targetRunningConfigREST) New() runtime.Object { + return &TargetRunningConfig{} } -func (r *targetRunningREST) Destroy() {} +func (r *targetRunningConfigREST) Destroy() {} -func (r *targetRunningREST) Get(ctx context.Context, name string, options *metav1.GetOptions) (runtime.Object, error) { +func (r *targetRunningConfigREST) Get(ctx context.Context, name string, options *metav1.GetOptions) (runtime.Object, error) { // Get the parent Target from the parent store getter := r.parentStore.(rest.Getter) obj, err := getter.Get(ctx, name, options) @@ -100,7 +100,7 @@ func (r *targetRunningREST) Get(ctx context.Context, name string, options *metav return nil, err } - return &TargetRunning{ + return &TargetRunningConfig{ ObjectMeta: metav1.ObjectMeta{ Name: target.Name, Namespace: target.Namespace, diff --git a/apis/config/target_running_types.go b/apis/config/target_runningconfig_types.go similarity index 91% rename from apis/config/target_running_types.go rename to apis/config/target_runningconfig_types.go index cbf62afb..195936f6 100644 --- a/apis/config/target_running_types.go +++ b/apis/config/target_runningconfig_types.go @@ -24,8 +24,8 @@ import ( // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object // +k8s:openapi-gen=true -// TargetRunning is the Schema for the TargetRunning API -type TargetRunning struct { +// TargetRunningConfig is the Schema for the TargetRunning API +type TargetRunningConfig struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` diff --git a/apis/config/v1alpha1/register.go b/apis/config/v1alpha1/register.go index 5b099efc..ff3e1ac8 100644 --- a/apis/config/v1alpha1/register.go +++ b/apis/config/v1alpha1/register.go @@ -65,8 +65,8 @@ func addKnownTypes(scheme *runtime.Scheme) error { &ConfigBlameList{}, &Target{}, &TargetList{}, - &TargetBlame{}, - &TargetRunning{}, + &TargetConfigBlame{}, + &TargetRunningConfig{}, &TargetClearDeviation{}, ) diff --git a/apis/config/v1alpha1/target_cleardeviation_resource.go b/apis/config/v1alpha1/target_cleardeviation_resource.go new file mode 100644 index 00000000..f0535ce9 --- /dev/null +++ b/apis/config/v1alpha1/target_cleardeviation_resource.go @@ -0,0 +1,31 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1alpha1 + +import ( + "fmt" + + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apiserver/pkg/registry/rest" +) + +// Minimal interface implementations for v1alpha1 types +func (TargetClearDeviation) SubResourceName() string { return "cleardeviation" } +func (TargetClearDeviation) New() runtime.Object { return &TargetClearDeviation{} } +func (TargetClearDeviation) NewStorage(_ *runtime.Scheme, _ rest.Storage) (rest.Storage, error) { + return nil, fmt.Errorf("not implemented on versioned type") +} diff --git a/apis/config/v1alpha1/target_configblame_resource.go b/apis/config/v1alpha1/target_configblame_resource.go new file mode 100644 index 00000000..9e9585a5 --- /dev/null +++ b/apis/config/v1alpha1/target_configblame_resource.go @@ -0,0 +1,30 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1alpha1 + +import ( + "fmt" + + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apiserver/pkg/registry/rest" +) + +func (TargetConfigBlame) SubResourceName() string { return "configblame" } +func (TargetConfigBlame) New() runtime.Object { return &TargetConfigBlame{} } +func (TargetConfigBlame) NewStorage(_ *runtime.Scheme, _ rest.Storage) (rest.Storage, error) { + return nil, fmt.Errorf("not implemented on versioned type") +} diff --git a/apis/config/v1alpha1/target_blame_types.go b/apis/config/v1alpha1/target_configblame_types.go similarity index 91% rename from apis/config/v1alpha1/target_blame_types.go rename to apis/config/v1alpha1/target_configblame_types.go index 2d584500..b9981579 100644 --- a/apis/config/v1alpha1/target_blame_types.go +++ b/apis/config/v1alpha1/target_configblame_types.go @@ -24,8 +24,8 @@ import ( // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object // +k8s:openapi-gen=true -// TargetBlame is the Schema for the TargetBlame API -type TargetBlame struct { +// TargetConfigBlame is the Schema for the TargetConfigBlame API +type TargetConfigBlame struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` diff --git a/apis/config/v1alpha1/target_resource.go b/apis/config/v1alpha1/target_resource.go index 0d1a5499..6d14a0d7 100644 --- a/apis/config/v1alpha1/target_resource.go +++ b/apis/config/v1alpha1/target_resource.go @@ -17,14 +17,11 @@ limitations under the License. package v1alpha1 import ( - "fmt" - "github.com/henderiw/apiserver-builder/pkg/builder/resource" "github.com/sdcio/config-server/apis/config" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/apimachinery/pkg/runtime" "k8s.io/apimachinery/pkg/runtime/schema" - "k8s.io/apiserver/pkg/registry/rest" ) // +k8s:deepcopy-gen=false @@ -36,9 +33,9 @@ var _ resource.ObjectWithArbitrarySubResource = &Target{} func (r *Target) GetArbitrarySubResources() []resource.ArbitrarySubResource { return []resource.ArbitrarySubResource{ - &TargetRunning{}, + &TargetRunningConfig{}, &TargetClearDeviation{}, - &TargetBlame{}, + &TargetConfigBlame{}, } } @@ -90,22 +87,3 @@ func (r *TargetList) GetListMeta() *metav1.ListMeta { func (Target) RegisterConversions() func(s *runtime.Scheme) error { return RegisterConversions } - -// Minimal interface implementations for v1alpha1 types -func (TargetRunning) SubResourceName() string { return "running" } -func (TargetRunning) New() runtime.Object { return &TargetRunning{} } -func (TargetRunning) NewStorage(_ *runtime.Scheme, _ rest.Storage) (rest.Storage, error) { - return nil, fmt.Errorf("not implemented on versioned type") -} - -func (TargetClearDeviation) SubResourceName() string { return "cleardeviation" } -func (TargetClearDeviation) New() runtime.Object { return &TargetClearDeviation{} } -func (TargetClearDeviation) NewStorage(_ *runtime.Scheme, _ rest.Storage) (rest.Storage, error) { - return nil, fmt.Errorf("not implemented on versioned type") -} - -func (TargetBlame) SubResourceName() string { return "blame" } -func (TargetBlame) New() runtime.Object { return &TargetBlame{} } -func (TargetBlame) NewStorage(_ *runtime.Scheme, _ rest.Storage) (rest.Storage, error) { - return nil, fmt.Errorf("not implemented on versioned type") -} diff --git a/apis/config/v1alpha1/target_runningconfig_resource.go b/apis/config/v1alpha1/target_runningconfig_resource.go new file mode 100644 index 00000000..ea4c829d --- /dev/null +++ b/apis/config/v1alpha1/target_runningconfig_resource.go @@ -0,0 +1,31 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1alpha1 + +import ( + "fmt" + + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apiserver/pkg/registry/rest" +) + +// Minimal interface implementations for v1alpha1 types +func (TargetRunningConfig) SubResourceName() string { return "runningconfig" } +func (TargetRunningConfig) New() runtime.Object { return &TargetRunningConfig{} } +func (TargetRunningConfig) NewStorage(_ *runtime.Scheme, _ rest.Storage) (rest.Storage, error) { + return nil, fmt.Errorf("not implemented on versioned type") +} diff --git a/apis/config/v1alpha1/target_running_types.go b/apis/config/v1alpha1/target_runningconfig_types.go similarity index 90% rename from apis/config/v1alpha1/target_running_types.go rename to apis/config/v1alpha1/target_runningconfig_types.go index 1d6e59cf..dd2bd018 100644 --- a/apis/config/v1alpha1/target_running_types.go +++ b/apis/config/v1alpha1/target_runningconfig_types.go @@ -24,8 +24,8 @@ import ( // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object // +k8s:openapi-gen=true -// TargetRunning is the Schema for the TargetRunning API -type TargetRunning struct { +// TargetRunningConfig is the Schema for the TargetRunningConfig API +type TargetRunningConfig struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` diff --git a/apis/config/v1alpha1/zz_generated.conversion.go b/apis/config/v1alpha1/zz_generated.conversion.go index 3dff6def..1c4f0420 100644 --- a/apis/config/v1alpha1/zz_generated.conversion.go +++ b/apis/config/v1alpha1/zz_generated.conversion.go @@ -368,16 +368,6 @@ func RegisterConversions(s *runtime.Scheme) error { }); err != nil { return err } - if err := s.AddGeneratedConversionFunc((*TargetBlame)(nil), (*config.TargetBlame)(nil), func(a, b interface{}, scope conversion.Scope) error { - return Convert_v1alpha1_TargetBlame_To_config_TargetBlame(a.(*TargetBlame), b.(*config.TargetBlame), scope) - }); err != nil { - return err - } - if err := s.AddGeneratedConversionFunc((*config.TargetBlame)(nil), (*TargetBlame)(nil), func(a, b interface{}, scope conversion.Scope) error { - return Convert_config_TargetBlame_To_v1alpha1_TargetBlame(a.(*config.TargetBlame), b.(*TargetBlame), scope) - }); err != nil { - return err - } if err := s.AddGeneratedConversionFunc((*TargetClearDeviation)(nil), (*config.TargetClearDeviation)(nil), func(a, b interface{}, scope conversion.Scope) error { return Convert_v1alpha1_TargetClearDeviation_To_config_TargetClearDeviation(a.(*TargetClearDeviation), b.(*config.TargetClearDeviation), scope) }); err != nil { @@ -408,6 +398,16 @@ func RegisterConversions(s *runtime.Scheme) error { }); err != nil { return err } + if err := s.AddGeneratedConversionFunc((*TargetConfigBlame)(nil), (*config.TargetConfigBlame)(nil), func(a, b interface{}, scope conversion.Scope) error { + return Convert_v1alpha1_TargetConfigBlame_To_config_TargetConfigBlame(a.(*TargetConfigBlame), b.(*config.TargetConfigBlame), scope) + }); err != nil { + return err + } + if err := s.AddGeneratedConversionFunc((*config.TargetConfigBlame)(nil), (*TargetConfigBlame)(nil), func(a, b interface{}, scope conversion.Scope) error { + return Convert_config_TargetConfigBlame_To_v1alpha1_TargetConfigBlame(a.(*config.TargetConfigBlame), b.(*TargetConfigBlame), scope) + }); err != nil { + return err + } if err := s.AddGeneratedConversionFunc((*TargetList)(nil), (*config.TargetList)(nil), func(a, b interface{}, scope conversion.Scope) error { return Convert_v1alpha1_TargetList_To_config_TargetList(a.(*TargetList), b.(*config.TargetList), scope) }); err != nil { @@ -418,13 +418,13 @@ func RegisterConversions(s *runtime.Scheme) error { }); err != nil { return err } - if err := s.AddGeneratedConversionFunc((*TargetRunning)(nil), (*config.TargetRunning)(nil), func(a, b interface{}, scope conversion.Scope) error { - return Convert_v1alpha1_TargetRunning_To_config_TargetRunning(a.(*TargetRunning), b.(*config.TargetRunning), scope) + if err := s.AddGeneratedConversionFunc((*TargetRunningConfig)(nil), (*config.TargetRunningConfig)(nil), func(a, b interface{}, scope conversion.Scope) error { + return Convert_v1alpha1_TargetRunningConfig_To_config_TargetRunningConfig(a.(*TargetRunningConfig), b.(*config.TargetRunningConfig), scope) }); err != nil { return err } - if err := s.AddGeneratedConversionFunc((*config.TargetRunning)(nil), (*TargetRunning)(nil), func(a, b interface{}, scope conversion.Scope) error { - return Convert_config_TargetRunning_To_v1alpha1_TargetRunning(a.(*config.TargetRunning), b.(*TargetRunning), scope) + if err := s.AddGeneratedConversionFunc((*config.TargetRunningConfig)(nil), (*TargetRunningConfig)(nil), func(a, b interface{}, scope conversion.Scope) error { + return Convert_config_TargetRunningConfig_To_v1alpha1_TargetRunningConfig(a.(*config.TargetRunningConfig), b.(*TargetRunningConfig), scope) }); err != nil { return err } @@ -1423,28 +1423,6 @@ func Convert_config_Target_To_v1alpha1_Target(in *config.Target, out *Target, s return autoConvert_config_Target_To_v1alpha1_Target(in, out, s) } -func autoConvert_v1alpha1_TargetBlame_To_config_TargetBlame(in *TargetBlame, out *config.TargetBlame, s conversion.Scope) error { - out.ObjectMeta = in.ObjectMeta - out.Value = in.Value - return nil -} - -// Convert_v1alpha1_TargetBlame_To_config_TargetBlame is an autogenerated conversion function. -func Convert_v1alpha1_TargetBlame_To_config_TargetBlame(in *TargetBlame, out *config.TargetBlame, s conversion.Scope) error { - return autoConvert_v1alpha1_TargetBlame_To_config_TargetBlame(in, out, s) -} - -func autoConvert_config_TargetBlame_To_v1alpha1_TargetBlame(in *config.TargetBlame, out *TargetBlame, s conversion.Scope) error { - out.ObjectMeta = in.ObjectMeta - out.Value = in.Value - return nil -} - -// Convert_config_TargetBlame_To_v1alpha1_TargetBlame is an autogenerated conversion function. -func Convert_config_TargetBlame_To_v1alpha1_TargetBlame(in *config.TargetBlame, out *TargetBlame, s conversion.Scope) error { - return autoConvert_config_TargetBlame_To_v1alpha1_TargetBlame(in, out, s) -} - func autoConvert_v1alpha1_TargetClearDeviation_To_config_TargetClearDeviation(in *TargetClearDeviation, out *config.TargetClearDeviation, s conversion.Scope) error { out.ObjectMeta = in.ObjectMeta if err := Convert_v1alpha1_TargetClearDeviationSpec_To_config_TargetClearDeviationSpec(&in.Spec, &out.Spec, s); err != nil { @@ -1519,6 +1497,28 @@ func Convert_config_TargetClearDeviationStatus_To_v1alpha1_TargetClearDeviationS return autoConvert_config_TargetClearDeviationStatus_To_v1alpha1_TargetClearDeviationStatus(in, out, s) } +func autoConvert_v1alpha1_TargetConfigBlame_To_config_TargetConfigBlame(in *TargetConfigBlame, out *config.TargetConfigBlame, s conversion.Scope) error { + out.ObjectMeta = in.ObjectMeta + out.Value = in.Value + return nil +} + +// Convert_v1alpha1_TargetConfigBlame_To_config_TargetConfigBlame is an autogenerated conversion function. +func Convert_v1alpha1_TargetConfigBlame_To_config_TargetConfigBlame(in *TargetConfigBlame, out *config.TargetConfigBlame, s conversion.Scope) error { + return autoConvert_v1alpha1_TargetConfigBlame_To_config_TargetConfigBlame(in, out, s) +} + +func autoConvert_config_TargetConfigBlame_To_v1alpha1_TargetConfigBlame(in *config.TargetConfigBlame, out *TargetConfigBlame, s conversion.Scope) error { + out.ObjectMeta = in.ObjectMeta + out.Value = in.Value + return nil +} + +// Convert_config_TargetConfigBlame_To_v1alpha1_TargetConfigBlame is an autogenerated conversion function. +func Convert_config_TargetConfigBlame_To_v1alpha1_TargetConfigBlame(in *config.TargetConfigBlame, out *TargetConfigBlame, s conversion.Scope) error { + return autoConvert_config_TargetConfigBlame_To_v1alpha1_TargetConfigBlame(in, out, s) +} + func autoConvert_v1alpha1_TargetList_To_config_TargetList(in *TargetList, out *config.TargetList, s conversion.Scope) error { out.ListMeta = in.ListMeta if in.Items != nil { @@ -1561,26 +1561,26 @@ func Convert_config_TargetList_To_v1alpha1_TargetList(in *config.TargetList, out return autoConvert_config_TargetList_To_v1alpha1_TargetList(in, out, s) } -func autoConvert_v1alpha1_TargetRunning_To_config_TargetRunning(in *TargetRunning, out *config.TargetRunning, s conversion.Scope) error { +func autoConvert_v1alpha1_TargetRunningConfig_To_config_TargetRunningConfig(in *TargetRunningConfig, out *config.TargetRunningConfig, s conversion.Scope) error { out.ObjectMeta = in.ObjectMeta out.Value = in.Value return nil } -// Convert_v1alpha1_TargetRunning_To_config_TargetRunning is an autogenerated conversion function. -func Convert_v1alpha1_TargetRunning_To_config_TargetRunning(in *TargetRunning, out *config.TargetRunning, s conversion.Scope) error { - return autoConvert_v1alpha1_TargetRunning_To_config_TargetRunning(in, out, s) +// Convert_v1alpha1_TargetRunningConfig_To_config_TargetRunningConfig is an autogenerated conversion function. +func Convert_v1alpha1_TargetRunningConfig_To_config_TargetRunningConfig(in *TargetRunningConfig, out *config.TargetRunningConfig, s conversion.Scope) error { + return autoConvert_v1alpha1_TargetRunningConfig_To_config_TargetRunningConfig(in, out, s) } -func autoConvert_config_TargetRunning_To_v1alpha1_TargetRunning(in *config.TargetRunning, out *TargetRunning, s conversion.Scope) error { +func autoConvert_config_TargetRunningConfig_To_v1alpha1_TargetRunningConfig(in *config.TargetRunningConfig, out *TargetRunningConfig, s conversion.Scope) error { out.ObjectMeta = in.ObjectMeta out.Value = in.Value return nil } -// Convert_config_TargetRunning_To_v1alpha1_TargetRunning is an autogenerated conversion function. -func Convert_config_TargetRunning_To_v1alpha1_TargetRunning(in *config.TargetRunning, out *TargetRunning, s conversion.Scope) error { - return autoConvert_config_TargetRunning_To_v1alpha1_TargetRunning(in, out, s) +// Convert_config_TargetRunningConfig_To_v1alpha1_TargetRunningConfig is an autogenerated conversion function. +func Convert_config_TargetRunningConfig_To_v1alpha1_TargetRunningConfig(in *config.TargetRunningConfig, out *TargetRunningConfig, s conversion.Scope) error { + return autoConvert_config_TargetRunningConfig_To_v1alpha1_TargetRunningConfig(in, out, s) } func autoConvert_v1alpha1_TargetSpec_To_config_TargetSpec(in *TargetSpec, out *config.TargetSpec, s conversion.Scope) error { diff --git a/apis/config/v1alpha1/zz_generated.deepcopy.go b/apis/config/v1alpha1/zz_generated.deepcopy.go index 57582beb..c8835909 100644 --- a/apis/config/v1alpha1/zz_generated.deepcopy.go +++ b/apis/config/v1alpha1/zz_generated.deepcopy.go @@ -869,33 +869,6 @@ func (in *Target) DeepCopyObject() runtime.Object { return nil } -// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *TargetBlame) DeepCopyInto(out *TargetBlame) { - *out = *in - out.TypeMeta = in.TypeMeta - in.ObjectMeta.DeepCopyInto(&out.ObjectMeta) - in.Value.DeepCopyInto(&out.Value) - return -} - -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new TargetBlame. -func (in *TargetBlame) DeepCopy() *TargetBlame { - if in == nil { - return nil - } - out := new(TargetBlame) - in.DeepCopyInto(out) - return out -} - -// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. -func (in *TargetBlame) DeepCopyObject() runtime.Object { - if c := in.DeepCopy(); c != nil { - return c - } - return nil -} - // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *TargetClearDeviation) DeepCopyInto(out *TargetClearDeviation) { *out = *in @@ -961,6 +934,33 @@ func (in *TargetClearDeviationStatus) DeepCopy() *TargetClearDeviationStatus { return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *TargetConfigBlame) DeepCopyInto(out *TargetConfigBlame) { + *out = *in + out.TypeMeta = in.TypeMeta + in.ObjectMeta.DeepCopyInto(&out.ObjectMeta) + in.Value.DeepCopyInto(&out.Value) + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new TargetConfigBlame. +func (in *TargetConfigBlame) DeepCopy() *TargetConfigBlame { + if in == nil { + return nil + } + out := new(TargetConfigBlame) + in.DeepCopyInto(out) + return out +} + +// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. +func (in *TargetConfigBlame) DeepCopyObject() runtime.Object { + if c := in.DeepCopy(); c != nil { + return c + } + return nil +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *TargetList) DeepCopyInto(out *TargetList) { *out = *in @@ -995,7 +995,7 @@ func (in *TargetList) DeepCopyObject() runtime.Object { } // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *TargetRunning) DeepCopyInto(out *TargetRunning) { +func (in *TargetRunningConfig) DeepCopyInto(out *TargetRunningConfig) { *out = *in out.TypeMeta = in.TypeMeta in.ObjectMeta.DeepCopyInto(&out.ObjectMeta) @@ -1003,18 +1003,18 @@ func (in *TargetRunning) DeepCopyInto(out *TargetRunning) { return } -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new TargetRunning. -func (in *TargetRunning) DeepCopy() *TargetRunning { +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new TargetRunningConfig. +func (in *TargetRunningConfig) DeepCopy() *TargetRunningConfig { if in == nil { return nil } - out := new(TargetRunning) + out := new(TargetRunningConfig) in.DeepCopyInto(out) return out } // DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. -func (in *TargetRunning) DeepCopyObject() runtime.Object { +func (in *TargetRunningConfig) DeepCopyObject() runtime.Object { if c := in.DeepCopy(); c != nil { return c } diff --git a/apis/config/zz_generated.deepcopy.go b/apis/config/zz_generated.deepcopy.go index 0f7f8761..75b278d1 100644 --- a/apis/config/zz_generated.deepcopy.go +++ b/apis/config/zz_generated.deepcopy.go @@ -1128,33 +1128,6 @@ func (in *Target) DeepCopyObject() runtime.Object { return nil } -// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *TargetBlame) DeepCopyInto(out *TargetBlame) { - *out = *in - out.TypeMeta = in.TypeMeta - in.ObjectMeta.DeepCopyInto(&out.ObjectMeta) - in.Value.DeepCopyInto(&out.Value) - return -} - -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new TargetBlame. -func (in *TargetBlame) DeepCopy() *TargetBlame { - if in == nil { - return nil - } - out := new(TargetBlame) - in.DeepCopyInto(out) - return out -} - -// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. -func (in *TargetBlame) DeepCopyObject() runtime.Object { - if c := in.DeepCopy(); c != nil { - return c - } - return nil -} - // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *TargetClearDeviation) DeepCopyInto(out *TargetClearDeviation) { *out = *in @@ -1220,6 +1193,33 @@ func (in *TargetClearDeviationStatus) DeepCopy() *TargetClearDeviationStatus { return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *TargetConfigBlame) DeepCopyInto(out *TargetConfigBlame) { + *out = *in + out.TypeMeta = in.TypeMeta + in.ObjectMeta.DeepCopyInto(&out.ObjectMeta) + in.Value.DeepCopyInto(&out.Value) + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new TargetConfigBlame. +func (in *TargetConfigBlame) DeepCopy() *TargetConfigBlame { + if in == nil { + return nil + } + out := new(TargetConfigBlame) + in.DeepCopyInto(out) + return out +} + +// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. +func (in *TargetConfigBlame) DeepCopyObject() runtime.Object { + if c := in.DeepCopy(); c != nil { + return c + } + return nil +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *TargetFilter) DeepCopyInto(out *TargetFilter) { *out = *in @@ -1270,7 +1270,7 @@ func (in *TargetList) DeepCopyObject() runtime.Object { } // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *TargetRunning) DeepCopyInto(out *TargetRunning) { +func (in *TargetRunningConfig) DeepCopyInto(out *TargetRunningConfig) { *out = *in out.TypeMeta = in.TypeMeta in.ObjectMeta.DeepCopyInto(&out.ObjectMeta) @@ -1278,18 +1278,18 @@ func (in *TargetRunning) DeepCopyInto(out *TargetRunning) { return } -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new TargetRunning. -func (in *TargetRunning) DeepCopy() *TargetRunning { +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new TargetRunningConfig. +func (in *TargetRunningConfig) DeepCopy() *TargetRunningConfig { if in == nil { return nil } - out := new(TargetRunning) + out := new(TargetRunningConfig) in.DeepCopyInto(out) return out } // DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. -func (in *TargetRunning) DeepCopyObject() runtime.Object { +func (in *TargetRunningConfig) DeepCopyObject() runtime.Object { if c := in.DeepCopy(); c != nil { return c } diff --git a/pkg/generated/openapi/zz_generated.openapi.go b/pkg/generated/openapi/zz_generated.openapi.go index aef2bf1c..90a82367 100644 --- a/pkg/generated/openapi/zz_generated.openapi.go +++ b/pkg/generated/openapi/zz_generated.openapi.go @@ -68,12 +68,12 @@ func GetOpenAPIDefinitions(ref common.ReferenceCallback) map[string]common.OpenA "github.com/sdcio/config-server/apis/config/v1alpha1.SensitiveConfigSpec": schema_config_server_apis_config_v1alpha1_SensitiveConfigSpec(ref), "github.com/sdcio/config-server/apis/config/v1alpha1.SensitiveConfigStatus": schema_config_server_apis_config_v1alpha1_SensitiveConfigStatus(ref), "github.com/sdcio/config-server/apis/config/v1alpha1.Target": schema_config_server_apis_config_v1alpha1_Target(ref), - "github.com/sdcio/config-server/apis/config/v1alpha1.TargetBlame": schema_config_server_apis_config_v1alpha1_TargetBlame(ref), "github.com/sdcio/config-server/apis/config/v1alpha1.TargetClearDeviation": schema_config_server_apis_config_v1alpha1_TargetClearDeviation(ref), "github.com/sdcio/config-server/apis/config/v1alpha1.TargetClearDeviationSpec": schema_config_server_apis_config_v1alpha1_TargetClearDeviationSpec(ref), "github.com/sdcio/config-server/apis/config/v1alpha1.TargetClearDeviationStatus": schema_config_server_apis_config_v1alpha1_TargetClearDeviationStatus(ref), + "github.com/sdcio/config-server/apis/config/v1alpha1.TargetConfigBlame": schema_config_server_apis_config_v1alpha1_TargetConfigBlame(ref), "github.com/sdcio/config-server/apis/config/v1alpha1.TargetList": schema_config_server_apis_config_v1alpha1_TargetList(ref), - "github.com/sdcio/config-server/apis/config/v1alpha1.TargetRunning": schema_config_server_apis_config_v1alpha1_TargetRunning(ref), + "github.com/sdcio/config-server/apis/config/v1alpha1.TargetRunningConfig": schema_config_server_apis_config_v1alpha1_TargetRunningConfig(ref), "github.com/sdcio/config-server/apis/config/v1alpha1.TargetSpec": schema_config_server_apis_config_v1alpha1_TargetSpec(ref), "github.com/sdcio/config-server/apis/config/v1alpha1.TargetStatus": schema_config_server_apis_config_v1alpha1_TargetStatus(ref), "github.com/sdcio/config-server/apis/config/v1alpha1.TargetStatusUsedReferences": schema_config_server_apis_config_v1alpha1_TargetStatusUsedReferences(ref), @@ -2013,54 +2013,6 @@ func schema_config_server_apis_config_v1alpha1_Target(ref common.ReferenceCallba } } -func schema_config_server_apis_config_v1alpha1_TargetBlame(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "TargetBlame is the Schema for the TargetBlame API", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "kind": { - SchemaProps: spec.SchemaProps{ - Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", - Type: []string{"string"}, - Format: "", - }, - }, - "apiVersion": { - SchemaProps: spec.SchemaProps{ - Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", - Type: []string{"string"}, - Format: "", - }, - }, - "metadata": { - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), - }, - }, - "value": { - SchemaProps: spec.SchemaProps{ - Ref: ref(runtime.RawExtension{}.OpenAPIModelName()), - }, - }, - }, - Required: []string{"value"}, - }, - VendorExtensible: spec.VendorExtensible{ - Extensions: spec.Extensions{ - "x-kubernetes-group-version-kind": []interface{}{ - map[string]interface{}{"group": "config.sdcio.dev", "kind": "TargetBlame", "version": "v1alpha1"}, - }, - }, - }, - }, - Dependencies: []string{ - metav1.ObjectMeta{}.OpenAPIModelName(), runtime.RawExtension{}.OpenAPIModelName()}, - } -} - func schema_config_server_apis_config_v1alpha1_TargetClearDeviation(ref common.ReferenceCallback) common.OpenAPIDefinition { return common.OpenAPIDefinition{ Schema: spec.Schema{ @@ -2171,6 +2123,54 @@ func schema_config_server_apis_config_v1alpha1_TargetClearDeviationStatus(ref co } } +func schema_config_server_apis_config_v1alpha1_TargetConfigBlame(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "TargetConfigBlame is the Schema for the TargetConfigBlame API", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "metadata": { + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref(metav1.ObjectMeta{}.OpenAPIModelName()), + }, + }, + "value": { + SchemaProps: spec.SchemaProps{ + Ref: ref(runtime.RawExtension{}.OpenAPIModelName()), + }, + }, + }, + Required: []string{"value"}, + }, + VendorExtensible: spec.VendorExtensible{ + Extensions: spec.Extensions{ + "x-kubernetes-group-version-kind": []interface{}{ + map[string]interface{}{"group": "config.sdcio.dev", "kind": "TargetConfigBlame", "version": "v1alpha1"}, + }, + }, + }, + }, + Dependencies: []string{ + metav1.ObjectMeta{}.OpenAPIModelName(), runtime.RawExtension{}.OpenAPIModelName()}, + } +} + func schema_config_server_apis_config_v1alpha1_TargetList(ref common.ReferenceCallback) common.OpenAPIDefinition { return common.OpenAPIDefinition{ Schema: spec.Schema{ @@ -2220,11 +2220,11 @@ func schema_config_server_apis_config_v1alpha1_TargetList(ref common.ReferenceCa } } -func schema_config_server_apis_config_v1alpha1_TargetRunning(ref common.ReferenceCallback) common.OpenAPIDefinition { +func schema_config_server_apis_config_v1alpha1_TargetRunningConfig(ref common.ReferenceCallback) common.OpenAPIDefinition { return common.OpenAPIDefinition{ Schema: spec.Schema{ SchemaProps: spec.SchemaProps{ - Description: "TargetRunning is the Schema for the TargetRunning API", + Description: "TargetRunningConfig is the Schema for the TargetRunningConfig API", Type: []string{"object"}, Properties: map[string]spec.Schema{ "kind": { @@ -2258,7 +2258,7 @@ func schema_config_server_apis_config_v1alpha1_TargetRunning(ref common.Referenc VendorExtensible: spec.VendorExtensible{ Extensions: spec.Extensions{ "x-kubernetes-group-version-kind": []interface{}{ - map[string]interface{}{"group": "config.sdcio.dev", "kind": "TargetRunning", "version": "v1alpha1"}, + map[string]interface{}{"group": "config.sdcio.dev", "kind": "TargetRunningConfig", "version": "v1alpha1"}, }, }, }, From c0bda3a51e6404f57e342a67f8544de08165af33 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Mon, 2 Mar 2026 20:37:41 +0100 Subject: [PATCH 111/135] fix lint issue --- apis/config/target_cleardeviation_resource.go | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/apis/config/target_cleardeviation_resource.go b/apis/config/target_cleardeviation_resource.go index dad1a746..a90a2810 100644 --- a/apis/config/target_cleardeviation_resource.go +++ b/apis/config/target_cleardeviation_resource.go @@ -91,7 +91,12 @@ func (r *targetClearDeviationREST) Create( if err != nil { return nil, err } - defer closeFn() + defer func() { + if err := closeFn(); err != nil { + // You can use your preferred logging framework here + fmt.Printf("failed to close connection: %v\n", err) + } + }() // Your actual clear deviation RPC call here _ = client From 7e965c3c52174833905b8e72ee2d886ce331c028 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Tue, 3 Mar 2026 09:40:00 +0100 Subject: [PATCH 112/135] add custom query params --- apis/config/target_runningconfig_resource.go | 27 ++++++++++++++++++-- 1 file changed, 25 insertions(+), 2 deletions(-) diff --git a/apis/config/target_runningconfig_resource.go b/apis/config/target_runningconfig_resource.go index 3f810ea4..503f38a8 100644 --- a/apis/config/target_runningconfig_resource.go +++ b/apis/config/target_runningconfig_resource.go @@ -58,10 +58,18 @@ func (r *targetRunningConfigREST) New() runtime.Object { func (r *targetRunningConfigREST) Destroy() {} -func (r *targetRunningConfigREST) Get(ctx context.Context, name string, options *metav1.GetOptions) (runtime.Object, error) { +func (r *targetRunningConfigREST) NewGetOptions() (runtime.Object, bool, string) { + // Returns: (options object, decode from body?, single query param name) + return &TargetRunningOptions{}, false, "" +} + +func (r *targetRunningConfigREST) Get(ctx context.Context, name string, options runtime.Object) (runtime.Object, error) { + opts := options.(*TargetRunningOptions) + fmt.Printf("path=%s format=%s\n", opts.Path, opts.Format) + // Get the parent Target from the parent store getter := r.parentStore.(rest.Getter) - obj, err := getter.Get(ctx, name, options) + obj, err := getter.Get(ctx, name, &metav1.GetOptions{}) if err != nil { return nil, err } @@ -108,3 +116,18 @@ func (r *targetRunningConfigREST) Get(ctx context.Context, name string, options Value: runtime.RawExtension{Raw: rsp.GetBlob()}, }, nil } + +// Define your options type +type TargetRunningOptions struct { + metav1.TypeMeta `json:",inline"` + + // Path filters the running config to a subtree + Path string `json:"path,omitempty"` + // Format controls output format + Format string `json:"format,omitempty"` +} + +func (o *TargetRunningOptions) DeepCopyObject() runtime.Object { + out := *o + return &out +} From c99875d2ad87b07c0d2496214a35ed550d711490 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Tue, 3 Mar 2026 09:50:52 +0100 Subject: [PATCH 113/135] updated query paramaters with registry --- apis/config/register.go | 1 + apis/config/target_runningconfig_resource.go | 15 ------- apis/config/target_runningconfig_types.go | 14 +++++++ apis/config/v1alpha1/register.go | 1 + .../v1alpha1/target_runningconfig_types.go | 12 ++++++ .../v1alpha1/zz_generated.conversion.go | 32 ++++++++++++++ apis/config/v1alpha1/zz_generated.deepcopy.go | 25 +++++++++++ apis/config/zz_generated.deepcopy.go | 25 +++++++++++ pkg/generated/openapi/zz_generated.openapi.go | 42 +++++++++++++++++++ 9 files changed, 152 insertions(+), 15 deletions(-) diff --git a/apis/config/register.go b/apis/config/register.go index ed630b83..0f9b6fa4 100644 --- a/apis/config/register.go +++ b/apis/config/register.go @@ -57,6 +57,7 @@ func addKnownTypes(scheme *runtime.Scheme) error { &TargetConfigBlame{}, &TargetRunningConfig{}, &TargetClearDeviation{}, + &TargetRunningOptions{}, ) return nil } diff --git a/apis/config/target_runningconfig_resource.go b/apis/config/target_runningconfig_resource.go index 503f38a8..04ad4afb 100644 --- a/apis/config/target_runningconfig_resource.go +++ b/apis/config/target_runningconfig_resource.go @@ -116,18 +116,3 @@ func (r *targetRunningConfigREST) Get(ctx context.Context, name string, options Value: runtime.RawExtension{Raw: rsp.GetBlob()}, }, nil } - -// Define your options type -type TargetRunningOptions struct { - metav1.TypeMeta `json:",inline"` - - // Path filters the running config to a subtree - Path string `json:"path,omitempty"` - // Format controls output format - Format string `json:"format,omitempty"` -} - -func (o *TargetRunningOptions) DeepCopyObject() runtime.Object { - out := *o - return &out -} diff --git a/apis/config/target_runningconfig_types.go b/apis/config/target_runningconfig_types.go index 195936f6..1b909232 100644 --- a/apis/config/target_runningconfig_types.go +++ b/apis/config/target_runningconfig_types.go @@ -32,3 +32,17 @@ type TargetRunningConfig struct { //+kubebuilder:pruning:PreserveUnknownFields Value runtime.RawExtension `json:"value" protobuf:"bytes,2,opt,name=value"` } + + +// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object +// +k8s:openapi-gen=true +// TargetRunningOptions is the Option Parametsrs for the TargetRunningOptions QueryParamters +type TargetRunningOptions struct { + metav1.TypeMeta `json:",inline"` + + // Path filters the running config to a subtree + Path string `json:"path,omitempty"` + // Format controls output format + Format string `json:"format,omitempty"` +} + diff --git a/apis/config/v1alpha1/register.go b/apis/config/v1alpha1/register.go index ff3e1ac8..96539b35 100644 --- a/apis/config/v1alpha1/register.go +++ b/apis/config/v1alpha1/register.go @@ -68,6 +68,7 @@ func addKnownTypes(scheme *runtime.Scheme) error { &TargetConfigBlame{}, &TargetRunningConfig{}, &TargetClearDeviation{}, + &TargetRunningOptions{}, ) metav1.AddToGroupVersion(scheme, SchemeGroupVersion) diff --git a/apis/config/v1alpha1/target_runningconfig_types.go b/apis/config/v1alpha1/target_runningconfig_types.go index dd2bd018..348a51a4 100644 --- a/apis/config/v1alpha1/target_runningconfig_types.go +++ b/apis/config/v1alpha1/target_runningconfig_types.go @@ -32,3 +32,15 @@ type TargetRunningConfig struct { //+kubebuilder:pruning:PreserveUnknownFields Value runtime.RawExtension `json:"value" protobuf:"bytes,2,opt,name=value"` } + +// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object +// +k8s:openapi-gen=true +// TargetRunningOptions is the Option Parametsrs for the TargetRunningOptions QueryParamters +type TargetRunningOptions struct { + metav1.TypeMeta `json:",inline"` + + // Path filters the running config to a subtree + Path string `json:"path,omitempty"` + // Format controls output format + Format string `json:"format,omitempty"` +} \ No newline at end of file diff --git a/apis/config/v1alpha1/zz_generated.conversion.go b/apis/config/v1alpha1/zz_generated.conversion.go index 1c4f0420..c6141265 100644 --- a/apis/config/v1alpha1/zz_generated.conversion.go +++ b/apis/config/v1alpha1/zz_generated.conversion.go @@ -428,6 +428,16 @@ func RegisterConversions(s *runtime.Scheme) error { }); err != nil { return err } + if err := s.AddGeneratedConversionFunc((*TargetRunningOptions)(nil), (*config.TargetRunningOptions)(nil), func(a, b interface{}, scope conversion.Scope) error { + return Convert_v1alpha1_TargetRunningOptions_To_config_TargetRunningOptions(a.(*TargetRunningOptions), b.(*config.TargetRunningOptions), scope) + }); err != nil { + return err + } + if err := s.AddGeneratedConversionFunc((*config.TargetRunningOptions)(nil), (*TargetRunningOptions)(nil), func(a, b interface{}, scope conversion.Scope) error { + return Convert_config_TargetRunningOptions_To_v1alpha1_TargetRunningOptions(a.(*config.TargetRunningOptions), b.(*TargetRunningOptions), scope) + }); err != nil { + return err + } if err := s.AddGeneratedConversionFunc((*TargetSpec)(nil), (*config.TargetSpec)(nil), func(a, b interface{}, scope conversion.Scope) error { return Convert_v1alpha1_TargetSpec_To_config_TargetSpec(a.(*TargetSpec), b.(*config.TargetSpec), scope) }); err != nil { @@ -1583,6 +1593,28 @@ func Convert_config_TargetRunningConfig_To_v1alpha1_TargetRunningConfig(in *conf return autoConvert_config_TargetRunningConfig_To_v1alpha1_TargetRunningConfig(in, out, s) } +func autoConvert_v1alpha1_TargetRunningOptions_To_config_TargetRunningOptions(in *TargetRunningOptions, out *config.TargetRunningOptions, s conversion.Scope) error { + out.Path = in.Path + out.Format = in.Format + return nil +} + +// Convert_v1alpha1_TargetRunningOptions_To_config_TargetRunningOptions is an autogenerated conversion function. +func Convert_v1alpha1_TargetRunningOptions_To_config_TargetRunningOptions(in *TargetRunningOptions, out *config.TargetRunningOptions, s conversion.Scope) error { + return autoConvert_v1alpha1_TargetRunningOptions_To_config_TargetRunningOptions(in, out, s) +} + +func autoConvert_config_TargetRunningOptions_To_v1alpha1_TargetRunningOptions(in *config.TargetRunningOptions, out *TargetRunningOptions, s conversion.Scope) error { + out.Path = in.Path + out.Format = in.Format + return nil +} + +// Convert_config_TargetRunningOptions_To_v1alpha1_TargetRunningOptions is an autogenerated conversion function. +func Convert_config_TargetRunningOptions_To_v1alpha1_TargetRunningOptions(in *config.TargetRunningOptions, out *TargetRunningOptions, s conversion.Scope) error { + return autoConvert_config_TargetRunningOptions_To_v1alpha1_TargetRunningOptions(in, out, s) +} + func autoConvert_v1alpha1_TargetSpec_To_config_TargetSpec(in *TargetSpec, out *config.TargetSpec, s conversion.Scope) error { out.Provider = in.Provider out.Address = in.Address diff --git a/apis/config/v1alpha1/zz_generated.deepcopy.go b/apis/config/v1alpha1/zz_generated.deepcopy.go index c8835909..1561bf0f 100644 --- a/apis/config/v1alpha1/zz_generated.deepcopy.go +++ b/apis/config/v1alpha1/zz_generated.deepcopy.go @@ -1021,6 +1021,31 @@ func (in *TargetRunningConfig) DeepCopyObject() runtime.Object { return nil } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *TargetRunningOptions) DeepCopyInto(out *TargetRunningOptions) { + *out = *in + out.TypeMeta = in.TypeMeta + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new TargetRunningOptions. +func (in *TargetRunningOptions) DeepCopy() *TargetRunningOptions { + if in == nil { + return nil + } + out := new(TargetRunningOptions) + in.DeepCopyInto(out) + return out +} + +// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. +func (in *TargetRunningOptions) DeepCopyObject() runtime.Object { + if c := in.DeepCopy(); c != nil { + return c + } + return nil +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *TargetSpec) DeepCopyInto(out *TargetSpec) { *out = *in diff --git a/apis/config/zz_generated.deepcopy.go b/apis/config/zz_generated.deepcopy.go index 75b278d1..7b2aba8a 100644 --- a/apis/config/zz_generated.deepcopy.go +++ b/apis/config/zz_generated.deepcopy.go @@ -1296,6 +1296,31 @@ func (in *TargetRunningConfig) DeepCopyObject() runtime.Object { return nil } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *TargetRunningOptions) DeepCopyInto(out *TargetRunningOptions) { + *out = *in + out.TypeMeta = in.TypeMeta + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new TargetRunningOptions. +func (in *TargetRunningOptions) DeepCopy() *TargetRunningOptions { + if in == nil { + return nil + } + out := new(TargetRunningOptions) + in.DeepCopyInto(out) + return out +} + +// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. +func (in *TargetRunningOptions) DeepCopyObject() runtime.Object { + if c := in.DeepCopy(); c != nil { + return c + } + return nil +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *TargetSpec) DeepCopyInto(out *TargetSpec) { *out = *in diff --git a/pkg/generated/openapi/zz_generated.openapi.go b/pkg/generated/openapi/zz_generated.openapi.go index 90a82367..576d3cdd 100644 --- a/pkg/generated/openapi/zz_generated.openapi.go +++ b/pkg/generated/openapi/zz_generated.openapi.go @@ -74,6 +74,7 @@ func GetOpenAPIDefinitions(ref common.ReferenceCallback) map[string]common.OpenA "github.com/sdcio/config-server/apis/config/v1alpha1.TargetConfigBlame": schema_config_server_apis_config_v1alpha1_TargetConfigBlame(ref), "github.com/sdcio/config-server/apis/config/v1alpha1.TargetList": schema_config_server_apis_config_v1alpha1_TargetList(ref), "github.com/sdcio/config-server/apis/config/v1alpha1.TargetRunningConfig": schema_config_server_apis_config_v1alpha1_TargetRunningConfig(ref), + "github.com/sdcio/config-server/apis/config/v1alpha1.TargetRunningOptions": schema_config_server_apis_config_v1alpha1_TargetRunningOptions(ref), "github.com/sdcio/config-server/apis/config/v1alpha1.TargetSpec": schema_config_server_apis_config_v1alpha1_TargetSpec(ref), "github.com/sdcio/config-server/apis/config/v1alpha1.TargetStatus": schema_config_server_apis_config_v1alpha1_TargetStatus(ref), "github.com/sdcio/config-server/apis/config/v1alpha1.TargetStatusUsedReferences": schema_config_server_apis_config_v1alpha1_TargetStatusUsedReferences(ref), @@ -2268,6 +2269,47 @@ func schema_config_server_apis_config_v1alpha1_TargetRunningConfig(ref common.Re } } +func schema_config_server_apis_config_v1alpha1_TargetRunningOptions(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "TargetRunningOptions is the Option Parametsrs for the TargetRunningOptions QueryParamters", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "path": { + SchemaProps: spec.SchemaProps{ + Description: "Path filters the running config to a subtree", + Type: []string{"string"}, + Format: "", + }, + }, + "format": { + SchemaProps: spec.SchemaProps{ + Description: "Format controls output format", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + } +} + func schema_config_server_apis_config_v1alpha1_TargetSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { return common.OpenAPIDefinition{ Schema: spec.Schema{ From 59c31cbf1974eebdf45a521fab11f0dd1b5d0820 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Tue, 3 Mar 2026 10:06:39 +0100 Subject: [PATCH 114/135] updated options for registry --- apis/config/target_configblame_resource.go | 2 +- apis/config/target_runningconfig_resource.go | 8 +++++++- apis/config/v1alpha1/target_cleardeviation_resource.go | 4 +++- apis/config/v1alpha1/target_configblame_resource.go | 3 +++ apis/config/v1alpha1/target_runningconfig_resource.go | 10 +++++++++- go.mod | 2 +- go.sum | 4 ++-- 7 files changed, 26 insertions(+), 7 deletions(-) diff --git a/apis/config/target_configblame_resource.go b/apis/config/target_configblame_resource.go index c5e70a5d..4d36e6d7 100644 --- a/apis/config/target_configblame_resource.go +++ b/apis/config/target_configblame_resource.go @@ -32,7 +32,7 @@ import ( "k8s.io/apiserver/pkg/registry/rest" ) -var _ resource.ArbitrarySubResource = &TargetClearDeviation{} +var _ resource.ArbitrarySubResource = &TargetConfigBlame{} func (TargetConfigBlame) SubResourceName() string { return "configblame" diff --git a/apis/config/target_runningconfig_resource.go b/apis/config/target_runningconfig_resource.go index 04ad4afb..8c0e4272 100644 --- a/apis/config/target_runningconfig_resource.go +++ b/apis/config/target_runningconfig_resource.go @@ -31,7 +31,7 @@ import ( "k8s.io/apiserver/pkg/registry/rest" ) -var _ resource.ArbitrarySubResource = &TargetClearDeviation{} +var _ resource.ArbitrarySubResource = &TargetRunningConfig{} func (TargetRunningConfig) SubResourceName() string { return "runningconfig" @@ -47,6 +47,12 @@ func (TargetRunningConfig) NewStorage(scheme *runtime.Scheme, parentStorage rest }, nil } +var _ resource.ArbitrarySubResourceWithOptions = &TargetRunningConfig{} + +func (TargetRunningConfig) NewGetOptions() runtime.Object { + return &TargetRunningOptions{} +} + // targetRunningREST implements rest.Storage + rest.Getter type targetRunningConfigREST struct { parentStore rest.Storage diff --git a/apis/config/v1alpha1/target_cleardeviation_resource.go b/apis/config/v1alpha1/target_cleardeviation_resource.go index f0535ce9..9ac6045c 100644 --- a/apis/config/v1alpha1/target_cleardeviation_resource.go +++ b/apis/config/v1alpha1/target_cleardeviation_resource.go @@ -19,11 +19,13 @@ package v1alpha1 import ( "fmt" + "github.com/henderiw/apiserver-builder/pkg/builder/resource" "k8s.io/apimachinery/pkg/runtime" "k8s.io/apiserver/pkg/registry/rest" ) -// Minimal interface implementations for v1alpha1 types +var _ resource.ArbitrarySubResource = &TargetClearDeviation{} + func (TargetClearDeviation) SubResourceName() string { return "cleardeviation" } func (TargetClearDeviation) New() runtime.Object { return &TargetClearDeviation{} } func (TargetClearDeviation) NewStorage(_ *runtime.Scheme, _ rest.Storage) (rest.Storage, error) { diff --git a/apis/config/v1alpha1/target_configblame_resource.go b/apis/config/v1alpha1/target_configblame_resource.go index 9e9585a5..2be75ae4 100644 --- a/apis/config/v1alpha1/target_configblame_resource.go +++ b/apis/config/v1alpha1/target_configblame_resource.go @@ -19,10 +19,13 @@ package v1alpha1 import ( "fmt" + "github.com/henderiw/apiserver-builder/pkg/builder/resource" "k8s.io/apimachinery/pkg/runtime" "k8s.io/apiserver/pkg/registry/rest" ) +var _ resource.ArbitrarySubResource = &TargetConfigBlame{} + func (TargetConfigBlame) SubResourceName() string { return "configblame" } func (TargetConfigBlame) New() runtime.Object { return &TargetConfigBlame{} } func (TargetConfigBlame) NewStorage(_ *runtime.Scheme, _ rest.Storage) (rest.Storage, error) { diff --git a/apis/config/v1alpha1/target_runningconfig_resource.go b/apis/config/v1alpha1/target_runningconfig_resource.go index ea4c829d..bb18c56a 100644 --- a/apis/config/v1alpha1/target_runningconfig_resource.go +++ b/apis/config/v1alpha1/target_runningconfig_resource.go @@ -19,13 +19,21 @@ package v1alpha1 import ( "fmt" + "github.com/henderiw/apiserver-builder/pkg/builder/resource" "k8s.io/apimachinery/pkg/runtime" "k8s.io/apiserver/pkg/registry/rest" ) -// Minimal interface implementations for v1alpha1 types +var _ resource.ArbitrarySubResource = &TargetRunningConfig{} + func (TargetRunningConfig) SubResourceName() string { return "runningconfig" } func (TargetRunningConfig) New() runtime.Object { return &TargetRunningConfig{} } func (TargetRunningConfig) NewStorage(_ *runtime.Scheme, _ rest.Storage) (rest.Storage, error) { return nil, fmt.Errorf("not implemented on versioned type") } + +var _ resource.ArbitrarySubResourceWithOptions = &TargetRunningConfig{} + +func (TargetRunningConfig) NewGetOptions() runtime.Object { + return &TargetRunningOptions{} +} diff --git a/go.mod b/go.mod index a27e1a1b..2a2f7119 100644 --- a/go.mod +++ b/go.mod @@ -7,7 +7,7 @@ require ( github.com/go-git/go-git/v5 v5.16.5 github.com/google/go-cmp v0.7.0 github.com/google/uuid v1.6.0 - github.com/henderiw/apiserver-builder v0.0.7 + github.com/henderiw/apiserver-builder v0.0.8-0.20260303090228-479e9f4e13d2 github.com/henderiw/apiserver-store v0.0.4 github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c github.com/henderiw/logger v0.0.0-20230911123436-8655829b1abe diff --git a/go.sum b/go.sum index 9327d46b..f4f07a15 100644 --- a/go.sum +++ b/go.sum @@ -169,8 +169,8 @@ github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0 h1:Ovs26xHkKqVztRpIrF/92Bcuy github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0/go.mod h1:8NvIoxWQoOIhqOTXgfV/d3M/q6VIi02HzZEHgUlZvzk= github.com/grpc-ecosystem/grpc-gateway/v2 v2.27.3 h1:NmZ1PKzSTQbuGHw9DGPFomqkkLWMC+vZCkfs+FHv1Vg= github.com/grpc-ecosystem/grpc-gateway/v2 v2.27.3/go.mod h1:zQrxl1YP88HQlA6i9c63DSVPFklWpGX4OWAc9bFuaH4= -github.com/henderiw/apiserver-builder v0.0.7 h1:GPbwEAHauK5nGVcD8r/h0hvRmnnaWj1L2vbQIzs8Iho= -github.com/henderiw/apiserver-builder v0.0.7/go.mod h1:Py2AD4oB1McoYpz4chBNAFo9bYeZ9N9cKPijzkMxk2U= +github.com/henderiw/apiserver-builder v0.0.8-0.20260303090228-479e9f4e13d2 h1:V51EoPUiu0A95nY4vNjn/H2xVT3uAlzgLuGAHjQJFnc= +github.com/henderiw/apiserver-builder v0.0.8-0.20260303090228-479e9f4e13d2/go.mod h1:7VrZxXPR54Urtg49taC7cNgo+AOzSxWEJXPDdDbKnCk= github.com/henderiw/apiserver-store v0.0.4 h1:IeawmDpcX4PzRxh0IW8j8IC++Vn1OOkUUBeq3laylPU= github.com/henderiw/apiserver-store v0.0.4/go.mod h1:RuXLMHJwszn6LXgL6fO9fxMC7AW5wAc4zOddnnZpkKI= github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c h1:nFnCNyRV1Ej/zqV/gn8UnFESkoPUXhwpUCZyhSYGSYA= From bdada2e0f980a92632553654a8e7c1ee9d672f6c Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Tue, 3 Mar 2026 10:23:18 +0100 Subject: [PATCH 115/135] updated options for registry --- go.mod | 2 +- go.sum | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/go.mod b/go.mod index 2a2f7119..1245c7c9 100644 --- a/go.mod +++ b/go.mod @@ -7,7 +7,7 @@ require ( github.com/go-git/go-git/v5 v5.16.5 github.com/google/go-cmp v0.7.0 github.com/google/uuid v1.6.0 - github.com/henderiw/apiserver-builder v0.0.8-0.20260303090228-479e9f4e13d2 + github.com/henderiw/apiserver-builder v0.0.8-0.20260303092131-a011d3478b44 github.com/henderiw/apiserver-store v0.0.4 github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c github.com/henderiw/logger v0.0.0-20230911123436-8655829b1abe diff --git a/go.sum b/go.sum index f4f07a15..0280bdc5 100644 --- a/go.sum +++ b/go.sum @@ -169,8 +169,8 @@ github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0 h1:Ovs26xHkKqVztRpIrF/92Bcuy github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0/go.mod h1:8NvIoxWQoOIhqOTXgfV/d3M/q6VIi02HzZEHgUlZvzk= github.com/grpc-ecosystem/grpc-gateway/v2 v2.27.3 h1:NmZ1PKzSTQbuGHw9DGPFomqkkLWMC+vZCkfs+FHv1Vg= github.com/grpc-ecosystem/grpc-gateway/v2 v2.27.3/go.mod h1:zQrxl1YP88HQlA6i9c63DSVPFklWpGX4OWAc9bFuaH4= -github.com/henderiw/apiserver-builder v0.0.8-0.20260303090228-479e9f4e13d2 h1:V51EoPUiu0A95nY4vNjn/H2xVT3uAlzgLuGAHjQJFnc= -github.com/henderiw/apiserver-builder v0.0.8-0.20260303090228-479e9f4e13d2/go.mod h1:7VrZxXPR54Urtg49taC7cNgo+AOzSxWEJXPDdDbKnCk= +github.com/henderiw/apiserver-builder v0.0.8-0.20260303092131-a011d3478b44 h1:xdIIkbLF7jA0fSFibUColJMOWt1a/SNMQ7GdKxZr70c= +github.com/henderiw/apiserver-builder v0.0.8-0.20260303092131-a011d3478b44/go.mod h1:7VrZxXPR54Urtg49taC7cNgo+AOzSxWEJXPDdDbKnCk= github.com/henderiw/apiserver-store v0.0.4 h1:IeawmDpcX4PzRxh0IW8j8IC++Vn1OOkUUBeq3laylPU= github.com/henderiw/apiserver-store v0.0.4/go.mod h1:RuXLMHJwszn6LXgL6fO9fxMC7AW5wAc4zOddnnZpkKI= github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c h1:nFnCNyRV1Ej/zqV/gn8UnFESkoPUXhwpUCZyhSYGSYA= From fc58c82f2dbc717ca5ba19187b2e31a5594467f5 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Tue, 3 Mar 2026 10:45:17 +0100 Subject: [PATCH 116/135] updated options conversion --- apis/config/target_runningconfig_resource.go | 16 +++++++++++++++- .../v1alpha1/target_runningconfig_resource.go | 14 ++++++++++++++ go.mod | 2 +- go.sum | 4 ++-- 4 files changed, 32 insertions(+), 4 deletions(-) diff --git a/apis/config/target_runningconfig_resource.go b/apis/config/target_runningconfig_resource.go index 8c0e4272..34e5b308 100644 --- a/apis/config/target_runningconfig_resource.go +++ b/apis/config/target_runningconfig_resource.go @@ -19,6 +19,7 @@ package config import ( "context" "fmt" + "net/url" "github.com/henderiw/apiserver-builder/pkg/builder/resource" "github.com/henderiw/apiserver-store/pkg/storebackend" @@ -27,6 +28,7 @@ import ( "github.com/sdcio/sdc-protos/sdcpb" apierrors "k8s.io/apimachinery/pkg/api/errors" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/conversion" "k8s.io/apimachinery/pkg/runtime" "k8s.io/apiserver/pkg/registry/rest" ) @@ -50,7 +52,19 @@ func (TargetRunningConfig) NewStorage(scheme *runtime.Scheme, parentStorage rest var _ resource.ArbitrarySubResourceWithOptions = &TargetRunningConfig{} func (TargetRunningConfig) NewGetOptions() runtime.Object { - return &TargetRunningOptions{} + return &TargetRunningOptions{} +} + +var _ resource.ArbitrarySubResourceWithOptionsConverter = &TargetRunningConfig{} + +func (TargetRunningConfig) ConvertFromURLValues() func(a, b interface{}, scope conversion.Scope) error { + return func(a, b interface{}, scope conversion.Scope) error { + values := a.(*url.Values) + out := b.(*TargetRunningOptions) + out.Path = values.Get("path") + out.Format = values.Get("format") + return nil + } } // targetRunningREST implements rest.Storage + rest.Getter diff --git a/apis/config/v1alpha1/target_runningconfig_resource.go b/apis/config/v1alpha1/target_runningconfig_resource.go index bb18c56a..f930c870 100644 --- a/apis/config/v1alpha1/target_runningconfig_resource.go +++ b/apis/config/v1alpha1/target_runningconfig_resource.go @@ -18,8 +18,10 @@ package v1alpha1 import ( "fmt" + "net/url" "github.com/henderiw/apiserver-builder/pkg/builder/resource" + conversion "k8s.io/apimachinery/pkg/conversion" "k8s.io/apimachinery/pkg/runtime" "k8s.io/apiserver/pkg/registry/rest" ) @@ -37,3 +39,15 @@ var _ resource.ArbitrarySubResourceWithOptions = &TargetRunningConfig{} func (TargetRunningConfig) NewGetOptions() runtime.Object { return &TargetRunningOptions{} } + +var _ resource.ArbitrarySubResourceWithOptionsConverter = &TargetRunningConfig{} + +func (TargetRunningConfig) ConvertFromURLValues() func(a, b interface{}, scope conversion.Scope) error { + return func(a, b interface{}, scope conversion.Scope) error { + values := a.(*url.Values) + out := b.(*TargetRunningOptions) + out.Path = values.Get("path") + out.Format = values.Get("format") + return nil + } +} diff --git a/go.mod b/go.mod index 1245c7c9..dd09f323 100644 --- a/go.mod +++ b/go.mod @@ -7,7 +7,7 @@ require ( github.com/go-git/go-git/v5 v5.16.5 github.com/google/go-cmp v0.7.0 github.com/google/uuid v1.6.0 - github.com/henderiw/apiserver-builder v0.0.8-0.20260303092131-a011d3478b44 + github.com/henderiw/apiserver-builder v0.0.8-0.20260303094009-e3c2ea3301a8 github.com/henderiw/apiserver-store v0.0.4 github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c github.com/henderiw/logger v0.0.0-20230911123436-8655829b1abe diff --git a/go.sum b/go.sum index 0280bdc5..9139e9bc 100644 --- a/go.sum +++ b/go.sum @@ -169,8 +169,8 @@ github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0 h1:Ovs26xHkKqVztRpIrF/92Bcuy github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0/go.mod h1:8NvIoxWQoOIhqOTXgfV/d3M/q6VIi02HzZEHgUlZvzk= github.com/grpc-ecosystem/grpc-gateway/v2 v2.27.3 h1:NmZ1PKzSTQbuGHw9DGPFomqkkLWMC+vZCkfs+FHv1Vg= github.com/grpc-ecosystem/grpc-gateway/v2 v2.27.3/go.mod h1:zQrxl1YP88HQlA6i9c63DSVPFklWpGX4OWAc9bFuaH4= -github.com/henderiw/apiserver-builder v0.0.8-0.20260303092131-a011d3478b44 h1:xdIIkbLF7jA0fSFibUColJMOWt1a/SNMQ7GdKxZr70c= -github.com/henderiw/apiserver-builder v0.0.8-0.20260303092131-a011d3478b44/go.mod h1:7VrZxXPR54Urtg49taC7cNgo+AOzSxWEJXPDdDbKnCk= +github.com/henderiw/apiserver-builder v0.0.8-0.20260303094009-e3c2ea3301a8 h1:sygL8g90xE6bme3j+q/MmjgQ75cmRTO1O1wVsTXTNXI= +github.com/henderiw/apiserver-builder v0.0.8-0.20260303094009-e3c2ea3301a8/go.mod h1:7VrZxXPR54Urtg49taC7cNgo+AOzSxWEJXPDdDbKnCk= github.com/henderiw/apiserver-store v0.0.4 h1:IeawmDpcX4PzRxh0IW8j8IC++Vn1OOkUUBeq3laylPU= github.com/henderiw/apiserver-store v0.0.4/go.mod h1:RuXLMHJwszn6LXgL6fO9fxMC7AW5wAc4zOddnnZpkKI= github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c h1:nFnCNyRV1Ej/zqV/gn8UnFESkoPUXhwpUCZyhSYGSYA= From 85ac4f24a99ed6951473d51e79f7d325986692d3 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Tue, 3 Mar 2026 11:02:28 +0100 Subject: [PATCH 117/135] updated options conversion --- go.mod | 2 +- go.sum | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/go.mod b/go.mod index dd09f323..d1ac3785 100644 --- a/go.mod +++ b/go.mod @@ -7,7 +7,7 @@ require ( github.com/go-git/go-git/v5 v5.16.5 github.com/google/go-cmp v0.7.0 github.com/google/uuid v1.6.0 - github.com/henderiw/apiserver-builder v0.0.8-0.20260303094009-e3c2ea3301a8 + github.com/henderiw/apiserver-builder v0.0.8-0.20260303100124-abbfad151749 github.com/henderiw/apiserver-store v0.0.4 github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c github.com/henderiw/logger v0.0.0-20230911123436-8655829b1abe diff --git a/go.sum b/go.sum index 9139e9bc..a41bda65 100644 --- a/go.sum +++ b/go.sum @@ -169,8 +169,8 @@ github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0 h1:Ovs26xHkKqVztRpIrF/92Bcuy github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0/go.mod h1:8NvIoxWQoOIhqOTXgfV/d3M/q6VIi02HzZEHgUlZvzk= github.com/grpc-ecosystem/grpc-gateway/v2 v2.27.3 h1:NmZ1PKzSTQbuGHw9DGPFomqkkLWMC+vZCkfs+FHv1Vg= github.com/grpc-ecosystem/grpc-gateway/v2 v2.27.3/go.mod h1:zQrxl1YP88HQlA6i9c63DSVPFklWpGX4OWAc9bFuaH4= -github.com/henderiw/apiserver-builder v0.0.8-0.20260303094009-e3c2ea3301a8 h1:sygL8g90xE6bme3j+q/MmjgQ75cmRTO1O1wVsTXTNXI= -github.com/henderiw/apiserver-builder v0.0.8-0.20260303094009-e3c2ea3301a8/go.mod h1:7VrZxXPR54Urtg49taC7cNgo+AOzSxWEJXPDdDbKnCk= +github.com/henderiw/apiserver-builder v0.0.8-0.20260303100124-abbfad151749 h1:PaHyLCu3L/Qg4YMPqkcSyMvvtHXg9AN1eztuz3w7fEc= +github.com/henderiw/apiserver-builder v0.0.8-0.20260303100124-abbfad151749/go.mod h1:7VrZxXPR54Urtg49taC7cNgo+AOzSxWEJXPDdDbKnCk= github.com/henderiw/apiserver-store v0.0.4 h1:IeawmDpcX4PzRxh0IW8j8IC++Vn1OOkUUBeq3laylPU= github.com/henderiw/apiserver-store v0.0.4/go.mod h1:RuXLMHJwszn6LXgL6fO9fxMC7AW5wAc4zOddnnZpkKI= github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c h1:nFnCNyRV1Ej/zqV/gn8UnFESkoPUXhwpUCZyhSYGSYA= From 9c896e45490a725699556b22c7e96c81899d4ef9 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Tue, 3 Mar 2026 11:15:22 +0100 Subject: [PATCH 118/135] updated options conversion --- apis/config/register.go | 2 +- apis/config/target_runningconfig_resource.go | 8 ++--- apis/config/target_runningconfig_types.go | 2 +- apis/config/v1alpha1/register.go | 2 +- .../v1alpha1/target_runningconfig_resource.go | 32 +++++++++++++++++-- .../v1alpha1/target_runningconfig_types.go | 2 +- .../v1alpha1/zz_generated.conversion.go | 24 +++++++------- apis/config/v1alpha1/zz_generated.deepcopy.go | 10 +++--- apis/config/zz_generated.deepcopy.go | 10 +++--- go.mod | 2 +- go.sum | 4 +-- pkg/generated/openapi/zz_generated.openapi.go | 4 +-- 12 files changed, 65 insertions(+), 37 deletions(-) diff --git a/apis/config/register.go b/apis/config/register.go index 0f9b6fa4..06433b53 100644 --- a/apis/config/register.go +++ b/apis/config/register.go @@ -57,7 +57,7 @@ func addKnownTypes(scheme *runtime.Scheme) error { &TargetConfigBlame{}, &TargetRunningConfig{}, &TargetClearDeviation{}, - &TargetRunningOptions{}, + &TargetRunningConfigOptions{}, ) return nil } diff --git a/apis/config/target_runningconfig_resource.go b/apis/config/target_runningconfig_resource.go index 34e5b308..7860bd3c 100644 --- a/apis/config/target_runningconfig_resource.go +++ b/apis/config/target_runningconfig_resource.go @@ -52,7 +52,7 @@ func (TargetRunningConfig) NewStorage(scheme *runtime.Scheme, parentStorage rest var _ resource.ArbitrarySubResourceWithOptions = &TargetRunningConfig{} func (TargetRunningConfig) NewGetOptions() runtime.Object { - return &TargetRunningOptions{} + return &TargetRunningConfigOptions{} } var _ resource.ArbitrarySubResourceWithOptionsConverter = &TargetRunningConfig{} @@ -60,7 +60,7 @@ var _ resource.ArbitrarySubResourceWithOptionsConverter = &TargetRunningConfig{} func (TargetRunningConfig) ConvertFromURLValues() func(a, b interface{}, scope conversion.Scope) error { return func(a, b interface{}, scope conversion.Scope) error { values := a.(*url.Values) - out := b.(*TargetRunningOptions) + out := b.(*TargetRunningConfigOptions) out.Path = values.Get("path") out.Format = values.Get("format") return nil @@ -80,11 +80,11 @@ func (r *targetRunningConfigREST) Destroy() {} func (r *targetRunningConfigREST) NewGetOptions() (runtime.Object, bool, string) { // Returns: (options object, decode from body?, single query param name) - return &TargetRunningOptions{}, false, "" + return &TargetRunningConfigOptions{}, false, "" } func (r *targetRunningConfigREST) Get(ctx context.Context, name string, options runtime.Object) (runtime.Object, error) { - opts := options.(*TargetRunningOptions) + opts := options.(*TargetRunningConfigOptions) fmt.Printf("path=%s format=%s\n", opts.Path, opts.Format) // Get the parent Target from the parent store diff --git a/apis/config/target_runningconfig_types.go b/apis/config/target_runningconfig_types.go index 1b909232..db09c535 100644 --- a/apis/config/target_runningconfig_types.go +++ b/apis/config/target_runningconfig_types.go @@ -37,7 +37,7 @@ type TargetRunningConfig struct { // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object // +k8s:openapi-gen=true // TargetRunningOptions is the Option Parametsrs for the TargetRunningOptions QueryParamters -type TargetRunningOptions struct { +type TargetRunningConfigOptions struct { metav1.TypeMeta `json:",inline"` // Path filters the running config to a subtree diff --git a/apis/config/v1alpha1/register.go b/apis/config/v1alpha1/register.go index 96539b35..507dc7bd 100644 --- a/apis/config/v1alpha1/register.go +++ b/apis/config/v1alpha1/register.go @@ -68,7 +68,7 @@ func addKnownTypes(scheme *runtime.Scheme) error { &TargetConfigBlame{}, &TargetRunningConfig{}, &TargetClearDeviation{}, - &TargetRunningOptions{}, + &TargetRunningConfigOptions{}, ) metav1.AddToGroupVersion(scheme, SchemeGroupVersion) diff --git a/apis/config/v1alpha1/target_runningconfig_resource.go b/apis/config/v1alpha1/target_runningconfig_resource.go index f930c870..b7c83608 100644 --- a/apis/config/v1alpha1/target_runningconfig_resource.go +++ b/apis/config/v1alpha1/target_runningconfig_resource.go @@ -21,6 +21,7 @@ import ( "net/url" "github.com/henderiw/apiserver-builder/pkg/builder/resource" + "github.com/sdcio/config-server/apis/config" conversion "k8s.io/apimachinery/pkg/conversion" "k8s.io/apimachinery/pkg/runtime" "k8s.io/apiserver/pkg/registry/rest" @@ -37,7 +38,7 @@ func (TargetRunningConfig) NewStorage(_ *runtime.Scheme, _ rest.Storage) (rest.S var _ resource.ArbitrarySubResourceWithOptions = &TargetRunningConfig{} func (TargetRunningConfig) NewGetOptions() runtime.Object { - return &TargetRunningOptions{} + return &TargetRunningConfigOptions{} } var _ resource.ArbitrarySubResourceWithOptionsConverter = &TargetRunningConfig{} @@ -45,9 +46,36 @@ var _ resource.ArbitrarySubResourceWithOptionsConverter = &TargetRunningConfig{} func (TargetRunningConfig) ConvertFromURLValues() func(a, b interface{}, scope conversion.Scope) error { return func(a, b interface{}, scope conversion.Scope) error { values := a.(*url.Values) - out := b.(*TargetRunningOptions) + out := b.(*TargetRunningConfigOptions) out.Path = values.Get("path") out.Format = values.Get("format") return nil } } + +var _ resource.ArbitrarySubResourceWithVersionConverter = &TargetRunningConfig{} + +func (TargetRunningConfig) ParameterSchemeConversions() []func(*runtime.Scheme) error { + return []func(*runtime.Scheme) error{ + func(s *runtime.Scheme) error { + return s.AddConversionFunc((*TargetRunningConfigOptions)(nil), (*config.TargetRunningConfigOptions)(nil), + func(a, b interface{}, scope conversion.Scope) error { + in := a.(*TargetRunningConfigOptions) + out := b.(*config.TargetRunningConfigOptions) + out.Path = in.Path + out.Format = in.Format + return nil + }) + }, + func(s *runtime.Scheme) error { + return s.AddConversionFunc((*config.TargetRunningConfigOptions)(nil), (*TargetRunningConfigOptions)(nil), + func(a, b interface{}, scope conversion.Scope) error { + in := a.(*config.TargetRunningConfigOptions) + out := b.(*TargetRunningConfigOptions) + out.Path = in.Path + out.Format = in.Format + return nil + }) + }, + } +} diff --git a/apis/config/v1alpha1/target_runningconfig_types.go b/apis/config/v1alpha1/target_runningconfig_types.go index 348a51a4..0ac6e6c2 100644 --- a/apis/config/v1alpha1/target_runningconfig_types.go +++ b/apis/config/v1alpha1/target_runningconfig_types.go @@ -36,7 +36,7 @@ type TargetRunningConfig struct { // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object // +k8s:openapi-gen=true // TargetRunningOptions is the Option Parametsrs for the TargetRunningOptions QueryParamters -type TargetRunningOptions struct { +type TargetRunningConfigOptions struct { metav1.TypeMeta `json:",inline"` // Path filters the running config to a subtree diff --git a/apis/config/v1alpha1/zz_generated.conversion.go b/apis/config/v1alpha1/zz_generated.conversion.go index c6141265..2e2daf29 100644 --- a/apis/config/v1alpha1/zz_generated.conversion.go +++ b/apis/config/v1alpha1/zz_generated.conversion.go @@ -428,13 +428,13 @@ func RegisterConversions(s *runtime.Scheme) error { }); err != nil { return err } - if err := s.AddGeneratedConversionFunc((*TargetRunningOptions)(nil), (*config.TargetRunningOptions)(nil), func(a, b interface{}, scope conversion.Scope) error { - return Convert_v1alpha1_TargetRunningOptions_To_config_TargetRunningOptions(a.(*TargetRunningOptions), b.(*config.TargetRunningOptions), scope) + if err := s.AddGeneratedConversionFunc((*TargetRunningConfigOptions)(nil), (*config.TargetRunningConfigOptions)(nil), func(a, b interface{}, scope conversion.Scope) error { + return Convert_v1alpha1_TargetRunningConfigOptions_To_config_TargetRunningConfigOptions(a.(*TargetRunningConfigOptions), b.(*config.TargetRunningConfigOptions), scope) }); err != nil { return err } - if err := s.AddGeneratedConversionFunc((*config.TargetRunningOptions)(nil), (*TargetRunningOptions)(nil), func(a, b interface{}, scope conversion.Scope) error { - return Convert_config_TargetRunningOptions_To_v1alpha1_TargetRunningOptions(a.(*config.TargetRunningOptions), b.(*TargetRunningOptions), scope) + if err := s.AddGeneratedConversionFunc((*config.TargetRunningConfigOptions)(nil), (*TargetRunningConfigOptions)(nil), func(a, b interface{}, scope conversion.Scope) error { + return Convert_config_TargetRunningConfigOptions_To_v1alpha1_TargetRunningConfigOptions(a.(*config.TargetRunningConfigOptions), b.(*TargetRunningConfigOptions), scope) }); err != nil { return err } @@ -1593,26 +1593,26 @@ func Convert_config_TargetRunningConfig_To_v1alpha1_TargetRunningConfig(in *conf return autoConvert_config_TargetRunningConfig_To_v1alpha1_TargetRunningConfig(in, out, s) } -func autoConvert_v1alpha1_TargetRunningOptions_To_config_TargetRunningOptions(in *TargetRunningOptions, out *config.TargetRunningOptions, s conversion.Scope) error { +func autoConvert_v1alpha1_TargetRunningConfigOptions_To_config_TargetRunningConfigOptions(in *TargetRunningConfigOptions, out *config.TargetRunningConfigOptions, s conversion.Scope) error { out.Path = in.Path out.Format = in.Format return nil } -// Convert_v1alpha1_TargetRunningOptions_To_config_TargetRunningOptions is an autogenerated conversion function. -func Convert_v1alpha1_TargetRunningOptions_To_config_TargetRunningOptions(in *TargetRunningOptions, out *config.TargetRunningOptions, s conversion.Scope) error { - return autoConvert_v1alpha1_TargetRunningOptions_To_config_TargetRunningOptions(in, out, s) +// Convert_v1alpha1_TargetRunningConfigOptions_To_config_TargetRunningConfigOptions is an autogenerated conversion function. +func Convert_v1alpha1_TargetRunningConfigOptions_To_config_TargetRunningConfigOptions(in *TargetRunningConfigOptions, out *config.TargetRunningConfigOptions, s conversion.Scope) error { + return autoConvert_v1alpha1_TargetRunningConfigOptions_To_config_TargetRunningConfigOptions(in, out, s) } -func autoConvert_config_TargetRunningOptions_To_v1alpha1_TargetRunningOptions(in *config.TargetRunningOptions, out *TargetRunningOptions, s conversion.Scope) error { +func autoConvert_config_TargetRunningConfigOptions_To_v1alpha1_TargetRunningConfigOptions(in *config.TargetRunningConfigOptions, out *TargetRunningConfigOptions, s conversion.Scope) error { out.Path = in.Path out.Format = in.Format return nil } -// Convert_config_TargetRunningOptions_To_v1alpha1_TargetRunningOptions is an autogenerated conversion function. -func Convert_config_TargetRunningOptions_To_v1alpha1_TargetRunningOptions(in *config.TargetRunningOptions, out *TargetRunningOptions, s conversion.Scope) error { - return autoConvert_config_TargetRunningOptions_To_v1alpha1_TargetRunningOptions(in, out, s) +// Convert_config_TargetRunningConfigOptions_To_v1alpha1_TargetRunningConfigOptions is an autogenerated conversion function. +func Convert_config_TargetRunningConfigOptions_To_v1alpha1_TargetRunningConfigOptions(in *config.TargetRunningConfigOptions, out *TargetRunningConfigOptions, s conversion.Scope) error { + return autoConvert_config_TargetRunningConfigOptions_To_v1alpha1_TargetRunningConfigOptions(in, out, s) } func autoConvert_v1alpha1_TargetSpec_To_config_TargetSpec(in *TargetSpec, out *config.TargetSpec, s conversion.Scope) error { diff --git a/apis/config/v1alpha1/zz_generated.deepcopy.go b/apis/config/v1alpha1/zz_generated.deepcopy.go index 1561bf0f..8ea451ae 100644 --- a/apis/config/v1alpha1/zz_generated.deepcopy.go +++ b/apis/config/v1alpha1/zz_generated.deepcopy.go @@ -1022,24 +1022,24 @@ func (in *TargetRunningConfig) DeepCopyObject() runtime.Object { } // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *TargetRunningOptions) DeepCopyInto(out *TargetRunningOptions) { +func (in *TargetRunningConfigOptions) DeepCopyInto(out *TargetRunningConfigOptions) { *out = *in out.TypeMeta = in.TypeMeta return } -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new TargetRunningOptions. -func (in *TargetRunningOptions) DeepCopy() *TargetRunningOptions { +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new TargetRunningConfigOptions. +func (in *TargetRunningConfigOptions) DeepCopy() *TargetRunningConfigOptions { if in == nil { return nil } - out := new(TargetRunningOptions) + out := new(TargetRunningConfigOptions) in.DeepCopyInto(out) return out } // DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. -func (in *TargetRunningOptions) DeepCopyObject() runtime.Object { +func (in *TargetRunningConfigOptions) DeepCopyObject() runtime.Object { if c := in.DeepCopy(); c != nil { return c } diff --git a/apis/config/zz_generated.deepcopy.go b/apis/config/zz_generated.deepcopy.go index 7b2aba8a..66ce0234 100644 --- a/apis/config/zz_generated.deepcopy.go +++ b/apis/config/zz_generated.deepcopy.go @@ -1297,24 +1297,24 @@ func (in *TargetRunningConfig) DeepCopyObject() runtime.Object { } // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *TargetRunningOptions) DeepCopyInto(out *TargetRunningOptions) { +func (in *TargetRunningConfigOptions) DeepCopyInto(out *TargetRunningConfigOptions) { *out = *in out.TypeMeta = in.TypeMeta return } -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new TargetRunningOptions. -func (in *TargetRunningOptions) DeepCopy() *TargetRunningOptions { +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new TargetRunningConfigOptions. +func (in *TargetRunningConfigOptions) DeepCopy() *TargetRunningConfigOptions { if in == nil { return nil } - out := new(TargetRunningOptions) + out := new(TargetRunningConfigOptions) in.DeepCopyInto(out) return out } // DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. -func (in *TargetRunningOptions) DeepCopyObject() runtime.Object { +func (in *TargetRunningConfigOptions) DeepCopyObject() runtime.Object { if c := in.DeepCopy(); c != nil { return c } diff --git a/go.mod b/go.mod index d1ac3785..02e58556 100644 --- a/go.mod +++ b/go.mod @@ -7,7 +7,7 @@ require ( github.com/go-git/go-git/v5 v5.16.5 github.com/google/go-cmp v0.7.0 github.com/google/uuid v1.6.0 - github.com/henderiw/apiserver-builder v0.0.8-0.20260303100124-abbfad151749 + github.com/henderiw/apiserver-builder v0.0.8-0.20260303101118-65b82049cc85 github.com/henderiw/apiserver-store v0.0.4 github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c github.com/henderiw/logger v0.0.0-20230911123436-8655829b1abe diff --git a/go.sum b/go.sum index a41bda65..445898ec 100644 --- a/go.sum +++ b/go.sum @@ -169,8 +169,8 @@ github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0 h1:Ovs26xHkKqVztRpIrF/92Bcuy github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0/go.mod h1:8NvIoxWQoOIhqOTXgfV/d3M/q6VIi02HzZEHgUlZvzk= github.com/grpc-ecosystem/grpc-gateway/v2 v2.27.3 h1:NmZ1PKzSTQbuGHw9DGPFomqkkLWMC+vZCkfs+FHv1Vg= github.com/grpc-ecosystem/grpc-gateway/v2 v2.27.3/go.mod h1:zQrxl1YP88HQlA6i9c63DSVPFklWpGX4OWAc9bFuaH4= -github.com/henderiw/apiserver-builder v0.0.8-0.20260303100124-abbfad151749 h1:PaHyLCu3L/Qg4YMPqkcSyMvvtHXg9AN1eztuz3w7fEc= -github.com/henderiw/apiserver-builder v0.0.8-0.20260303100124-abbfad151749/go.mod h1:7VrZxXPR54Urtg49taC7cNgo+AOzSxWEJXPDdDbKnCk= +github.com/henderiw/apiserver-builder v0.0.8-0.20260303101118-65b82049cc85 h1:Q6spkgooANaMF0SNeP2VPUoHYTtdsQgxzboodekIMzo= +github.com/henderiw/apiserver-builder v0.0.8-0.20260303101118-65b82049cc85/go.mod h1:7VrZxXPR54Urtg49taC7cNgo+AOzSxWEJXPDdDbKnCk= github.com/henderiw/apiserver-store v0.0.4 h1:IeawmDpcX4PzRxh0IW8j8IC++Vn1OOkUUBeq3laylPU= github.com/henderiw/apiserver-store v0.0.4/go.mod h1:RuXLMHJwszn6LXgL6fO9fxMC7AW5wAc4zOddnnZpkKI= github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c h1:nFnCNyRV1Ej/zqV/gn8UnFESkoPUXhwpUCZyhSYGSYA= diff --git a/pkg/generated/openapi/zz_generated.openapi.go b/pkg/generated/openapi/zz_generated.openapi.go index 576d3cdd..88fef915 100644 --- a/pkg/generated/openapi/zz_generated.openapi.go +++ b/pkg/generated/openapi/zz_generated.openapi.go @@ -74,7 +74,7 @@ func GetOpenAPIDefinitions(ref common.ReferenceCallback) map[string]common.OpenA "github.com/sdcio/config-server/apis/config/v1alpha1.TargetConfigBlame": schema_config_server_apis_config_v1alpha1_TargetConfigBlame(ref), "github.com/sdcio/config-server/apis/config/v1alpha1.TargetList": schema_config_server_apis_config_v1alpha1_TargetList(ref), "github.com/sdcio/config-server/apis/config/v1alpha1.TargetRunningConfig": schema_config_server_apis_config_v1alpha1_TargetRunningConfig(ref), - "github.com/sdcio/config-server/apis/config/v1alpha1.TargetRunningOptions": schema_config_server_apis_config_v1alpha1_TargetRunningOptions(ref), + "github.com/sdcio/config-server/apis/config/v1alpha1.TargetRunningConfigOptions": schema_config_server_apis_config_v1alpha1_TargetRunningConfigOptions(ref), "github.com/sdcio/config-server/apis/config/v1alpha1.TargetSpec": schema_config_server_apis_config_v1alpha1_TargetSpec(ref), "github.com/sdcio/config-server/apis/config/v1alpha1.TargetStatus": schema_config_server_apis_config_v1alpha1_TargetStatus(ref), "github.com/sdcio/config-server/apis/config/v1alpha1.TargetStatusUsedReferences": schema_config_server_apis_config_v1alpha1_TargetStatusUsedReferences(ref), @@ -2269,7 +2269,7 @@ func schema_config_server_apis_config_v1alpha1_TargetRunningConfig(ref common.Re } } -func schema_config_server_apis_config_v1alpha1_TargetRunningOptions(ref common.ReferenceCallback) common.OpenAPIDefinition { +func schema_config_server_apis_config_v1alpha1_TargetRunningConfigOptions(ref common.ReferenceCallback) common.OpenAPIDefinition { return common.OpenAPIDefinition{ Schema: spec.Schema{ SchemaProps: spec.SchemaProps{ From eb233a0561a4e03d93d2d216ee3a0a6b6eb4fd01 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Tue, 3 Mar 2026 19:26:51 +0100 Subject: [PATCH 119/135] update logic for running config and clear deviations --- apis/config/handlers/confighandler.go | 11 +- apis/config/target_cleardeviation_resource.go | 81 ++-- apis/config/target_cleardeviation_types.go | 38 +- apis/config/target_configblame_resource.go | 69 +-- apis/config/target_helpers.go | 411 ++++++++++++++++++ apis/config/target_resource.go | 10 +- apis/config/target_runningconfig_resource.go | 64 +-- apis/config/target_runningconfig_types.go | 17 +- .../v1alpha1/target_cleardeviation_types.go | 38 +- .../v1alpha1/target_runningconfig_resource.go | 16 +- .../v1alpha1/target_runningconfig_types.go | 19 +- .../v1alpha1/zz_generated.conversion.go | 102 ++++- apis/config/v1alpha1/zz_generated.deepcopy.go | 80 +++- apis/config/zz_generated.deepcopy.go | 80 +++- cmd/api-server/main.go | 5 + go.mod | 4 +- go.sum | 8 +- pkg/generated/openapi/zz_generated.openapi.go | 170 +++++++- pkg/sdc/target/manager/dryrun.go | 2 +- pkg/sdc/target/manager/transactor.go | 28 +- pkg/sdc/target/manager/utils.go | 36 -- 21 files changed, 1004 insertions(+), 285 deletions(-) diff --git a/apis/config/handlers/confighandler.go b/apis/config/handlers/confighandler.go index 3ec7a693..710dfb50 100644 --- a/apis/config/handlers/confighandler.go +++ b/apis/config/handlers/confighandler.go @@ -4,7 +4,6 @@ import ( "context" "fmt" - "github.com/henderiw/apiserver-store/pkg/storebackend" "github.com/sdcio/config-server/apis/config" configv1alpha1 "github.com/sdcio/config-server/apis/config/v1alpha1" targetmanager "github.com/sdcio/config-server/pkg/sdc/target/manager" @@ -25,14 +24,14 @@ func (r *ConfigStoreHandler) DryRunCreateFn(ctx context.Context, key types.Names return obj, err } - updates, err := targetmanager.GetIntentUpdate(ctx, storebackend.KeyFromNSN(key), c, true) + updates, err := config.GetIntentUpdate(c, true) if err != nil { return nil, err } intents := []*sdcpb.TransactionIntent{ { - Intent: targetmanager.GetGVKNSN(c), + Intent: config.GetGVKNSN(c), Priority: int32(c.Spec.Priority), Update: updates, }, @@ -46,14 +45,14 @@ func (r *ConfigStoreHandler) DryRunUpdateFn(ctx context.Context, key types.Names return obj, err } - updates, err := targetmanager.GetIntentUpdate(ctx, storebackend.KeyFromNSN(key), c, true) + updates, err := config.GetIntentUpdate(c, true) if err != nil { return nil, err } intents := []*sdcpb.TransactionIntent{ { - Intent: targetmanager.GetGVKNSN(c), + Intent: config.GetGVKNSN(c), Priority: int32(c.Spec.Priority), Update: updates, }, @@ -69,7 +68,7 @@ func (r *ConfigStoreHandler) DryRunDeleteFn(ctx context.Context, key types.Names intents := []*sdcpb.TransactionIntent{ { - Intent: targetmanager.GetGVKNSN(c), + Intent: config.GetGVKNSN(c), Delete: true, }, } diff --git a/apis/config/target_cleardeviation_resource.go b/apis/config/target_cleardeviation_resource.go index a90a2810..0546cfbb 100644 --- a/apis/config/target_cleardeviation_resource.go +++ b/apis/config/target_cleardeviation_resource.go @@ -21,32 +21,43 @@ import ( "fmt" "github.com/henderiw/apiserver-builder/pkg/builder/resource" - dsclient "github.com/sdcio/config-server/pkg/sdc/dataserver/client" apierrors "k8s.io/apimachinery/pkg/api/errors" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/apimachinery/pkg/runtime" "k8s.io/apiserver/pkg/registry/rest" + "sigs.k8s.io/controller-runtime/pkg/client" ) -var _ resource.ArbitrarySubResource = &TargetClearDeviation{} +var _ resource.ArbitrarySubResource = &targetClearDeviationSubResource{} -func (TargetClearDeviation) SubResourceName() string { +type targetClearDeviationSubResource struct { + client client.Client +} + +func NewTargetClearDeviationSubResource(c client.Client) *targetClearDeviationSubResource { + return &targetClearDeviationSubResource{client: c} +} + +func (r *targetClearDeviationSubResource) SubResourceName() string { return "cleardeviation" } -func (TargetClearDeviation) New() runtime.Object { +func (r *targetClearDeviationSubResource) New() runtime.Object { return &TargetClearDeviation{} } -func (TargetClearDeviation) NewStorage(scheme *runtime.Scheme, parentStorage rest.Storage) (rest.Storage, error) { +func (r *targetClearDeviationSubResource) NewStorage(scheme *runtime.Scheme, parentStorage rest.Storage) (rest.Storage, error) { return &targetClearDeviationREST{ parentStore: parentStorage, + client: r.client, }, nil } -// storage +// --- REST handler --- + type targetClearDeviationREST struct { parentStore rest.Storage + client client.Client } func (r *targetClearDeviationREST) New() runtime.Object { @@ -62,52 +73,30 @@ func (r *targetClearDeviationREST) Create( createValidation rest.ValidateObjectFunc, options *metav1.CreateOptions, ) (runtime.Object, error) { - req := obj.(*TargetClearDeviation) + req, ok := obj.(*TargetClearDeviation) + if !ok { + return nil, apierrors.NewBadRequest( + fmt.Sprintf("expected *TargetClearDeviation, got %T", obj)) + } - // Get parent target name from the request object's name - name := req.Name + // Get the parent target + getter, ok := r.parentStore.(rest.Getter) + if !ok { + return nil, apierrors.NewInternalError( + fmt.Errorf("parent store %T does not implement rest.Getter", r.parentStore)) + } // Get the parent target to validate it exists and is ready - getter := r.parentStore.(rest.Getter) - parentObj, err := getter.Get(ctx, name, &metav1.GetOptions{}) + parentObj, err := getter.Get(ctx, req.Name, &metav1.GetOptions{}) if err != nil { return nil, err } - target := parentObj.(*Target) - - if !target.IsReady() { - return nil, apierrors.NewServiceUnavailable( - fmt.Sprintf("target %s is not ready", name)) + target, ok := parentObj.(*Target) + if !ok { + return nil, apierrors.NewInternalError( + fmt.Errorf("expected *Target, got %T", parentObj)) } - // Do the actual clear deviation work - // e.g. call dataserver to clear deviations - key := target.GetNamespacedName() - cfg := &dsclient.Config{ - Address: dsclient.GetDataServerAddress(), - Insecure: true, - } - client, closeFn, err := dsclient.NewEphemeral(ctx, cfg) - if err != nil { - return nil, err - } - defer func() { - if err := closeFn(); err != nil { - // You can use your preferred logging framework here - fmt.Printf("failed to close connection: %v\n", err) - } - }() - - // Your actual clear deviation RPC call here - _ = client - _ = key - _ = req.Spec - - // TODO update status - req.Status = TargetClearDeviationStatus{ - Cleared: 3, - Message: "successfully cleared deviations", - } - - return req, nil + return target.ClearDeviations(ctx, r.client, req) + } diff --git a/apis/config/target_cleardeviation_types.go b/apis/config/target_cleardeviation_types.go index 83564c1c..4a576da5 100644 --- a/apis/config/target_cleardeviation_types.go +++ b/apis/config/target_cleardeviation_types.go @@ -22,13 +22,41 @@ import ( // TargetClearDeviationSpec defines the desired state of Target type TargetClearDeviationSpec struct { + // IncludeConfigs when true includes all existing configs in the transaction, + // not just the ones referenced by Config. + // +kubebuilder:default=false + IncludeAllConfigs *bool `json:"includeAllConfigs,omitempty" protobuf:"bytes,1,opt,name=includeAllConfigs"` + // Config defines the clear deviations configs to applied on the taget + Config []TargetClearDeviationConfig `json:"config" protobuf:"bytes,2,rep,name=config"` +} + +type TargetClearDeviationConfig struct { + // Name of the config on which the paths should be cleared + Name string `json:"name" protobuf:"bytes,1,opt,name=paths"` // Paths provide the path of the deviation to be cleared - Paths []string `json:"paths" protobuf:"bytes,1,rep,name=paths"` + Paths []string `json:"paths" protobuf:"bytes,2,rep,name=paths"` } type TargetClearDeviationStatus struct { - Cleared int `json:"cleared" protobuf:"bytes,1,opt,name=cleared"` - Message string `json:"message" protobuf:"bytes,2,opt,name=message"` + // Message is a global message for the transaction + Message string `json:"message,omitempty" protobuf:"bytes,1,opt,name=message"` + // Warnings are global warnings from the transaction + Warnings []string `json:"warnings,omitempty" protobuf:"bytes,2,rep,name=warnings"` + // Results holds per-config outcomes, keyed by intent name + Results []TargetClearDeviationConfigResult `json:"results,omitempty" protobuf:"bytes,3,rep,name=results"` +} + +type TargetClearDeviationConfigResult struct { + // Name of the config on which the paths should be cleared + Name string `json:"name" protobuf:"bytes,1,rep,name=paths"` + // Success indicates whether the clear deviation was successful + Success bool `json:"success"` + // Message provides detail on the outcome + Message string `json:"message,omitempty"` + // Errors lists any errors for this specific config + Errors []string `json:"errors,omitempty"` + // Warnings lists any warnings for this specific config + Warnings []string `json:"warnings,omitempty"` } // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object @@ -39,6 +67,6 @@ type TargetClearDeviation struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` - Spec TargetClearDeviationSpec `json:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"` - Status TargetClearDeviationStatus `json:"status,omitempty" protobuf:"bytes,3,opt,name=status"` + Spec *TargetClearDeviationSpec `json:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"` + Status *TargetClearDeviationStatus `json:"status,omitempty" protobuf:"bytes,3,opt,name=status"` } diff --git a/apis/config/target_configblame_resource.go b/apis/config/target_configblame_resource.go index 4d36e6d7..49201fd7 100644 --- a/apis/config/target_configblame_resource.go +++ b/apis/config/target_configblame_resource.go @@ -21,11 +21,6 @@ import ( "fmt" "github.com/henderiw/apiserver-builder/pkg/builder/resource" - "github.com/henderiw/apiserver-store/pkg/storebackend" - "github.com/sdcio/config-server/apis/condition" - dsclient "github.com/sdcio/config-server/pkg/sdc/dataserver/client" - "github.com/sdcio/sdc-protos/sdcpb" - "google.golang.org/protobuf/encoding/protojson" apierrors "k8s.io/apimachinery/pkg/api/errors" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/apimachinery/pkg/runtime" @@ -61,65 +56,21 @@ func (r *targetConfigBlameREST) Destroy() {} func (r *targetConfigBlameREST) Get(ctx context.Context, name string, options *metav1.GetOptions) (runtime.Object, error) { // Get the parent Target from the parent store - getter := r.parentStore.(rest.Getter) - - obj, err := getter.Get(ctx, name, options) - if err != nil { - return nil, err + getter, ok := r.parentStore.(rest.Getter) + if !ok { + return nil, apierrors.NewInternalError( + fmt.Errorf("parent store %T does not implement rest.Getter", r.parentStore)) } - target := obj.(*Target) - if !target.IsReady() { - return nil, apierrors.NewServiceUnavailable( - fmt.Sprintf("target %s is not ready: %s", name, target.GetCondition(condition.ConditionTypeReady).Message)) - } - - cfg := &dsclient.Config{ - Address: dsclient.GetDataServerAddress(), - Insecure: true, - } - - dsclient, closeFn, err := dsclient.NewEphemeral(ctx, cfg) - if err != nil { - return nil, err - } - defer func() { - if err := closeFn(); err != nil { - // You can use your preferred logging framework here - fmt.Printf("failed to close connection: %v\n", err) - } - }() - - // check if the schema exists; this is == nil check; in case of err it does not exist - key := target.GetNamespacedName() - rsp, err := dsclient.BlameConfig(ctx, &sdcpb.BlameConfigRequest{ - DatastoreName: storebackend.KeyFromNSN(key).String(), - IncludeDefaults: true, - }) + obj, err := getter.Get(ctx, name, options) if err != nil { return nil, err } - - if rsp == nil || rsp.ConfigTree == nil { - return &TargetConfigBlame{ - ObjectMeta: metav1.ObjectMeta{ - Name: target.Name, - Namespace: target.Namespace, - }, - Value: runtime.RawExtension{Raw: nil}, - }, nil + target, ok := obj.(*Target) + if !ok { + return nil, apierrors.NewInternalError( + fmt.Errorf("expected *Target, got %T", obj)) } - json, err := protojson.Marshal(rsp.ConfigTree) - if err != nil { - return nil, err - } - - return &TargetConfigBlame{ - ObjectMeta: metav1.ObjectMeta{ - Name: target.Name, - Namespace: target.Namespace, - }, - Value: runtime.RawExtension{Raw: json}, - }, nil + return target.GetConfigBlame(ctx) } diff --git a/apis/config/target_helpers.go b/apis/config/target_helpers.go index 37f2b935..958a6866 100644 --- a/apis/config/target_helpers.go +++ b/apis/config/target_helpers.go @@ -17,9 +17,22 @@ limitations under the License. package config import ( + "context" + "fmt" + + "github.com/google/uuid" + "github.com/henderiw/apiserver-store/pkg/storebackend" + "github.com/henderiw/logger/log" "github.com/sdcio/config-server/apis/condition" + dsclient "github.com/sdcio/config-server/pkg/sdc/dataserver/client" + "github.com/sdcio/sdc-protos/sdcpb" + "google.golang.org/protobuf/encoding/protojson" + apierrors "k8s.io/apimachinery/pkg/api/errors" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/runtime" "k8s.io/apimachinery/pkg/types" + "k8s.io/utils/ptr" + "sigs.k8s.io/controller-runtime/pkg/client" ) // GetCondition returns the condition based on the condition kind @@ -80,3 +93,401 @@ func (r *Target) IsReady() bool { func (r *Target) GetNamespacedName() types.NamespacedName { return types.NamespacedName{Namespace: r.Namespace, Name: r.Name} } + +func (r *Target) GetRunningConfig(ctx context.Context, opts *TargetRunningConfigOptions) (runtime.Object, error) { + targetKey := r.GetNamespacedName() + if !r.IsReady() { + return nil, apierrors.NewServiceUnavailable( + fmt.Sprintf("target %s is not ready: %s", targetKey, + r.GetCondition(condition.ConditionTypeReady).Message)) + } + + var format TargetFormat + if opts != nil { + format = opts.Format + } + + cfg := &dsclient.Config{ + Address: dsclient.GetDataServerAddress(), + Insecure: true, + } + + dsclient, closeFn, err := dsclient.NewEphemeral(ctx, cfg) + if err != nil { + return nil, err + } + defer func() { + if err := closeFn(); err != nil { + log.FromContext(ctx).Error("failed to close connection", "Error", err) + } + }() + + rsp, err := dsclient.GetIntent(ctx, &sdcpb.GetIntentRequest{ + DatastoreName: storebackend.KeyFromNSN(targetKey).String(), + Intent: "running", + Format: FormatToProto(format), + }) + if err != nil { + return nil, err + } + + return &TargetRunningConfig{ + ObjectMeta: metav1.ObjectMeta{ + Name: r.Name, + Namespace: r.Namespace, + }, + Value: runtime.RawExtension{Raw: rsp.GetBlob()}, + }, nil +} + +func FormatToProto(f TargetFormat) sdcpb.Format { + switch f { + case Format_JSON_IETF: + return sdcpb.Format_Intent_Format_JSON_IETF + case Format_XML: + return sdcpb.Format_Intent_Format_XML + case Format_PROTO: + return sdcpb.Format_Intent_Format_PROTO + default: + return sdcpb.Format_Intent_Format_JSON + } +} + +func (r *Target) GetConfigBlame(ctx context.Context) (runtime.Object, error) { + targetKey := r.GetNamespacedName() + if !r.IsReady() { + return nil, apierrors.NewServiceUnavailable( + fmt.Sprintf("target %s is not ready: %s", targetKey, + r.GetCondition(condition.ConditionTypeReady).Message)) + } + + cfg := &dsclient.Config{ + Address: dsclient.GetDataServerAddress(), + Insecure: true, + } + + dsclient, closeFn, err := dsclient.NewEphemeral(ctx, cfg) + if err != nil { + return nil, err + } + defer func() { + if err := closeFn(); err != nil { + // You can use your preferred logging framework here + log.FromContext(ctx).Error("failed to close connection", "Error", err) + } + }() + + rsp, err := dsclient.BlameConfig(ctx, &sdcpb.BlameConfigRequest{ + DatastoreName: storebackend.KeyFromNSN(targetKey).String(), + IncludeDefaults: true, + }) + if err != nil { + return nil, err + } + + if rsp == nil || rsp.ConfigTree == nil { + return &TargetConfigBlame{ + ObjectMeta: metav1.ObjectMeta{ + Name: r.Name, + Namespace: r.Namespace, + }, + Value: runtime.RawExtension{Raw: nil}, + }, nil + } + + json, err := protojson.Marshal(rsp.ConfigTree) + if err != nil { + return nil, err + } + + return &TargetConfigBlame{ + ObjectMeta: metav1.ObjectMeta{ + Name: targetKey.Name, + Namespace: targetKey.Namespace, + }, + Value: runtime.RawExtension{Raw: json}, + }, nil +} + +func (r *Target) ClearDeviations(ctx context.Context, c client.Client, req *TargetClearDeviation) (runtime.Object, error) { + targetKey := r.GetNamespacedName() + if !r.IsReady() { + return nil, apierrors.NewServiceUnavailable( + fmt.Sprintf("target %s is not ready: %s", targetKey, + r.GetCondition(condition.ConditionTypeReady).Message)) + } + + spec := req.Spec + if spec == nil { + return nil, apierrors.NewBadRequest("spec is required") + } + + // Fetch existing configs for the target + configsByName, err := listConfigsByTarget(ctx, c, r) + if err != nil { + return nil, err + } + + // Build the TransactionSetRequest + txReq, validationErrors := buildClearDeviationTxRequest(targetKey, spec, configsByName) + if len(validationErrors) > 0 { + return &TargetClearDeviation{ + ObjectMeta: metav1.ObjectMeta{Name: r.Name, Namespace: r.Namespace}, + Status: &TargetClearDeviationStatus{ + Message: "validation failed: unknown config names", + Results: validationErrors, + }, + }, nil + } + if len(txReq.Intents) == 0 { + return &TargetClearDeviation{ + ObjectMeta: metav1.ObjectMeta{Name: r.Name, Namespace: r.Namespace}, + Status: &TargetClearDeviationStatus{ + Message: "no configs to process", + }, + }, nil + } + + // Execute the transaction + rsp, txErr := executeClearDeviationTx(ctx, txReq) + + // Build the response + return &TargetClearDeviation{ + ObjectMeta: metav1.ObjectMeta{Name: r.Name, Namespace: r.Namespace}, + Status: buildClearDeviationStatus(spec.Config, configsByName, rsp, txErr), + }, nil +} + +// listConfigsByIntent fetches all configs for a target and indexes them +// by their intent name (GetGVKNSN). This is the same key the dataserver uses. +func listConfigsByTarget(ctx context.Context, c client.Client, target *Target) (map[string]*Config, error) { + configList := &ConfigList{} + if err := c.List(ctx, configList, + client.InNamespace(target.Namespace), + client.MatchingLabels{ + TargetNamespaceKey: target.Namespace, + TargetNameKey: target.Name, + }, + ); err != nil { + return nil, err + } + + result := make(map[string]*Config, len(configList.Items)) + for i := range configList.Items { + cfg := &configList.Items[i] + result[cfg.Name] = cfg + } + return result, nil +} + +// buildClearDeviationTxRequest constructs the TransactionSetRequest from +// the clear deviation configs. It validates that every requested config name +// exists as a known intent. Unknown names are returned as validation errors. +func buildClearDeviationTxRequest( + targetKey types.NamespacedName, + spec *TargetClearDeviationSpec, + configsByName map[string]*Config, +) (*sdcpb.TransactionSetRequest, []TargetClearDeviationConfigResult) { + + var validationErrors []TargetClearDeviationConfigResult + intents := make([]*sdcpb.TransactionIntent, 0, len(spec.Config)) + for _, clearCfg := range spec.Config { + cfg, found := configsByName[clearCfg.Name] + if !found { + validationErrors = append(validationErrors, TargetClearDeviationConfigResult{ + Name: clearCfg.Name, + Success: false, + Errors: []string{fmt.Sprintf("config %q not found for target %s", clearCfg.Name, targetKey.Name)}, + }) + continue + } + + revertPaths := make([]*sdcpb.Path, 0, len(clearCfg.Paths)) + var pathErrors []string + for _, p := range clearCfg.Paths { + path, err := sdcpb.ParsePath(p) + if err != nil { + pathErrors = append(pathErrors, fmt.Sprintf("invalid path %q: %v", p, err)) + continue + } + revertPaths = append(revertPaths, path) + } + + if len(pathErrors) > 0 { + validationErrors = append(validationErrors, TargetClearDeviationConfigResult{ + Name: clearCfg.Name, + Success: false, + Errors: pathErrors, + }) + continue + } + + intents = append(intents, &sdcpb.TransactionIntent{ + Intent: GetGVKNSN(cfg), + Priority: int32(cfg.Spec.Priority), + RevertPaths: revertPaths, + }) + } + + // Early exit on validation errors + if len(validationErrors) > 0 { + return nil, validationErrors + } + + // If IncludeAllConfigs, add configs as no-op intents + // so the dataserver evaluates reverts in the full context + if spec.IncludeAllConfigs != nil && *spec.IncludeAllConfigs { + for name, cfg := range configsByName { + update, err := GetIntentUpdate(cfg, true) + if err != nil { + validationErrors = append(validationErrors, TargetClearDeviationConfigResult{ + Name: name, + Success: false, + Errors: []string{fmt.Sprintf("failed to build intent update for config %q: %v", name, err)}, + }) + continue + } + intents = append(intents, &sdcpb.TransactionIntent{ + Intent: GetGVKNSN(cfg), + Priority: int32(cfg.Spec.Priority), + Update: update, + NonRevertive: !cfg.IsRevertive(), + }) + } + } + + return &sdcpb.TransactionSetRequest{ + TransactionId: uuid.New().String(), + DatastoreName: storebackend.KeyFromNSN(targetKey).String(), + DryRun: false, + Timeout: ptr.To(int32(60)), + Intents: intents, + }, nil +} + +func GetGVKNSN(obj client.Object) string { + return fmt.Sprintf("%s.%s", obj.GetNamespace(), obj.GetName()) +} + +// executeClearDeviationTx opens a connection to the dataserver, +// sends the TransactionSetRequest, and confirms on success. +func executeClearDeviationTx( + ctx context.Context, + txReq *sdcpb.TransactionSetRequest, +) (*sdcpb.TransactionSetResponse, error) { + cfg := &dsclient.Config{ + Address: dsclient.GetDataServerAddress(), + Insecure: true, + } + dsClient, closeFn, err := dsclient.NewEphemeral(ctx, cfg) + if err != nil { + return nil, err + } + defer func() { + if err := closeFn(); err != nil { + log.FromContext(ctx).Error("failed to close connection", "error", err) + } + }() + + rsp, err := dsClient.TransactionSet(ctx, txReq) + if err != nil { + return rsp, err + } + + // Confirm the transaction + if _, err := dsClient.TransactionConfirm(ctx, &sdcpb.TransactionConfirmRequest{ + DatastoreName: txReq.DatastoreName, + TransactionId: txReq.TransactionId, + }); err != nil { + return rsp, fmt.Errorf("transaction confirm failed: %w", err) + } + + return rsp, nil +} + +// buildClearDeviationStatus assembles the response status from the +// transaction response and any error. +func buildClearDeviationStatus( + clearConfigs []TargetClearDeviationConfig, + configsByName map[string]*Config, + rsp *sdcpb.TransactionSetResponse, + err error, +) *TargetClearDeviationStatus { + status := &TargetClearDeviationStatus{} + + if err != nil { + status.Message = err.Error() + } + + if rsp == nil { + for _, cfg := range clearConfigs { + status.Results = append(status.Results, TargetClearDeviationConfigResult{ + Name: cfg.Name, + Success: false, + Errors: []string{status.Message}, + }) + } + return status + } + + status.Warnings = rsp.Warnings + + // Map intent names (GVKNSN) back to config names for the response + intentToName := make(map[string]string, len(configsByName)) + for name, cfg := range configsByName { + intentToName[GetGVKNSN(cfg)] = name + } + + responded := make(map[string]bool, len(rsp.Intents)) + for intentKey, intent := range rsp.Intents { + name := intentKey + if mapped, ok := intentToName[intentKey]; ok { + name = mapped + } + responded[name] = true + status.Results = append(status.Results, TargetClearDeviationConfigResult{ + Name: name, + Success: len(intent.Errors) == 0, + Errors: intent.Errors, + }) + } + + // Configs not in response succeeded silently + for _, cfg := range clearConfigs { + if !responded[cfg.Name] { + status.Results = append(status.Results, TargetClearDeviationConfigResult{ + Name: cfg.Name, + Success: err == nil, + }) + } + } + + return status +} + +// useSpec indicates to use the spec as the confifSpec, typically set to true; when set to false it means we are recovering +// the config +func GetIntentUpdate(config *Config, useSpec bool) ([]*sdcpb.Update, error) { + update := make([]*sdcpb.Update, 0, len(config.Spec.Config)) + configSpec := config.Spec.Config + if !useSpec && config.Status.AppliedConfig != nil { + update = make([]*sdcpb.Update, 0, len(config.Status.AppliedConfig.Config)) + configSpec = config.Status.AppliedConfig.Config + } + + for _, config := range configSpec { + path, err := sdcpb.ParsePath(config.Path) + if err != nil { + return nil, err + } + update = append(update, &sdcpb.Update{ + Path: path, + Value: &sdcpb.TypedValue{ + Value: &sdcpb.TypedValue_JsonVal{ + JsonVal: config.Value.Raw, + }, + }, + }) + } + return update, nil +} diff --git a/apis/config/target_resource.go b/apis/config/target_resource.go index 6a124826..c6abbf6f 100644 --- a/apis/config/target_resource.go +++ b/apis/config/target_resource.go @@ -34,6 +34,7 @@ import ( "k8s.io/apimachinery/pkg/util/validation/field" genericapirequest "k8s.io/apiserver/pkg/endpoints/request" "k8s.io/apiserver/pkg/registry/rest" + "sigs.k8s.io/controller-runtime/pkg/client" ) const ( @@ -46,6 +47,13 @@ var ( TargetCategories = []string{"sdc", "knet"} ) +var subResourceClient client.Client + +// SetSubResourceClient is called once during server init to inject the client +func SetSubResourceClient(c client.Client) { + subResourceClient = c +} + // +k8s:deepcopy-gen=false var _ resource.InternalObject = &Target{} var _ resource.ObjectList = &TargetList{} @@ -57,7 +65,7 @@ var _ resource.ObjectWithArbitrarySubResource = &Target{} func (r *Target) GetArbitrarySubResources() []resource.ArbitrarySubResource { return []resource.ArbitrarySubResource{ &TargetRunningConfig{}, - &TargetClearDeviation{}, + NewTargetClearDeviationSubResource(subResourceClient), &TargetConfigBlame{}, } } diff --git a/apis/config/target_runningconfig_resource.go b/apis/config/target_runningconfig_resource.go index 7860bd3c..223f25e8 100644 --- a/apis/config/target_runningconfig_resource.go +++ b/apis/config/target_runningconfig_resource.go @@ -22,10 +22,6 @@ import ( "net/url" "github.com/henderiw/apiserver-builder/pkg/builder/resource" - "github.com/henderiw/apiserver-store/pkg/storebackend" - "github.com/sdcio/config-server/apis/condition" - dsclient "github.com/sdcio/config-server/pkg/sdc/dataserver/client" - "github.com/sdcio/sdc-protos/sdcpb" apierrors "k8s.io/apimachinery/pkg/api/errors" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/apimachinery/pkg/conversion" @@ -62,7 +58,7 @@ func (TargetRunningConfig) ConvertFromURLValues() func(a, b interface{}, scope c values := a.(*url.Values) out := b.(*TargetRunningConfigOptions) out.Path = values.Get("path") - out.Format = values.Get("format") + out.Format = TargetFormat(values.Get("format")) return nil } } @@ -84,55 +80,29 @@ func (r *targetRunningConfigREST) NewGetOptions() (runtime.Object, bool, string) } func (r *targetRunningConfigREST) Get(ctx context.Context, name string, options runtime.Object) (runtime.Object, error) { - opts := options.(*TargetRunningConfigOptions) - fmt.Printf("path=%s format=%s\n", opts.Path, opts.Format) + opts, ok := options.(*TargetRunningConfigOptions) + if !ok { + return nil, apierrors.NewBadRequest( + fmt.Sprintf("expected TargetRunningConfigOptions, got %T", options)) + } // Get the parent Target from the parent store - getter := r.parentStore.(rest.Getter) + // Get the parent Target from the parent store + getter, ok := r.parentStore.(rest.Getter) + if !ok { + return nil, apierrors.NewInternalError( + fmt.Errorf("parent store %T does not implement rest.Getter", r.parentStore)) + } obj, err := getter.Get(ctx, name, &metav1.GetOptions{}) if err != nil { return nil, err } - target := obj.(*Target) - - if !target.IsReady() { - return nil, apierrors.NewServiceUnavailable( - fmt.Sprintf("target %s is not ready: %s", name, - target.GetCondition(condition.ConditionTypeReady).Message)) + target, ok := obj.(*Target) + if !ok { + return nil, apierrors.NewInternalError( + fmt.Errorf("expected *Target, got %T", obj)) } - cfg := &dsclient.Config{ - Address: dsclient.GetDataServerAddress(), - Insecure: true, - } + return target.GetRunningConfig(ctx, opts) - dsclient, closeFn, err := dsclient.NewEphemeral(ctx, cfg) - if err != nil { - return nil, err - } - defer func() { - if err := closeFn(); err != nil { - // You can use your preferred logging framework here - fmt.Printf("failed to close connection: %v\n", err) - } - }() - - // check if the schema exists; this is == nil check; in case of err it does not exist - key := target.GetNamespacedName() - rsp, err := dsclient.GetIntent(ctx, &sdcpb.GetIntentRequest{ - DatastoreName: storebackend.KeyFromNSN(key).String(), - Intent: "running", - Format: sdcpb.Format_Intent_Format_JSON, - }) - if err != nil { - return nil, err - } - - return &TargetRunningConfig{ - ObjectMeta: metav1.ObjectMeta{ - Name: target.Name, - Namespace: target.Namespace, - }, - Value: runtime.RawExtension{Raw: rsp.GetBlob()}, - }, nil } diff --git a/apis/config/target_runningconfig_types.go b/apis/config/target_runningconfig_types.go index db09c535..4eb77b2b 100644 --- a/apis/config/target_runningconfig_types.go +++ b/apis/config/target_runningconfig_types.go @@ -33,7 +33,6 @@ type TargetRunningConfig struct { Value runtime.RawExtension `json:"value" protobuf:"bytes,2,opt,name=value"` } - // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object // +k8s:openapi-gen=true // TargetRunningOptions is the Option Parametsrs for the TargetRunningOptions QueryParamters @@ -42,7 +41,19 @@ type TargetRunningConfigOptions struct { // Path filters the running config to a subtree Path string `json:"path,omitempty"` - // Format controls output format - Format string `json:"format,omitempty"` + // Format controls output format (json, json_ietf, xml, proto) + // +kubebuilder:validation:Enum=json;json_ietf;xml;proto + // +kubebuilder:default=json + Format TargetFormat `json:"format,omitempty"` } +// Format defines the output encoding format for running config +// +enum +type TargetFormat string + +const ( + Format_JSON TargetFormat = "json" + Format_JSON_IETF TargetFormat = "json_ietf" + Format_XML TargetFormat = "xml" + Format_PROTO TargetFormat = "proto" +) diff --git a/apis/config/v1alpha1/target_cleardeviation_types.go b/apis/config/v1alpha1/target_cleardeviation_types.go index c2fb349f..bf68e6c4 100644 --- a/apis/config/v1alpha1/target_cleardeviation_types.go +++ b/apis/config/v1alpha1/target_cleardeviation_types.go @@ -22,13 +22,41 @@ import ( // TargetClearDeviationSpec defines the desired state of Target type TargetClearDeviationSpec struct { + // IncludeConfigs when true includes all existing configs in the transaction, + // not just the ones referenced by Config. + // +kubebuilder:default=false + IncludeAllConfigs *bool `json:"includeAllConfigs,omitempty" protobuf:"bytes,1,opt,name=includeAllConfigs"` + // Config defines the clear deviations configs to applied on the taget + Config []TargetClearDeviationConfig `json:"config" protobuf:"bytes,2,rep,name=config"` +} + +type TargetClearDeviationConfig struct { + // Name of the config on which the paths should be cleared + Name string `json:"name" protobuf:"bytes,1,opt,name=paths"` // Paths provide the path of the deviation to be cleared - Paths []string `json:"paths" protobuf:"bytes,1,rep,name=paths"` + Paths []string `json:"paths" protobuf:"bytes,2,rep,name=paths"` } type TargetClearDeviationStatus struct { - Cleared int `json:"cleared" protobuf:"bytes,1,opt,name=cleared"` - Message string `json:"message" protobuf:"bytes,2,opt,name=message"` + // Message is a global message for the transaction + Message string `json:"message,omitempty" protobuf:"bytes,1,opt,name=message"` + // Warnings are global warnings from the transaction + Warnings []string `json:"warnings,omitempty" protobuf:"bytes,2,rep,name=warnings"` + // Results holds per-config outcomes, keyed by intent name + Results []TargetClearDeviationConfigResult `json:"results,omitempty" protobuf:"bytes,3,rep,name=results"` +} + +type TargetClearDeviationConfigResult struct { + // Name of the config on which the paths should be cleared + Name string `json:"name" protobuf:"bytes,1,rep,name=paths"` + // Success indicates whether the clear deviation was successful + Success bool `json:"success"` + // Message provides detail on the outcome + Message string `json:"message,omitempty"` + // Errors lists any errors for this specific config + Errors []string `json:"errors,omitempty"` + // Warnings lists any warnings for this specific config + Warnings []string `json:"warnings,omitempty"` } // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object @@ -39,6 +67,6 @@ type TargetClearDeviation struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` - Spec TargetClearDeviationSpec `json:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"` - Status TargetClearDeviationStatus `json:"status,omitempty" protobuf:"bytes,3,opt,name=status"` + Spec *TargetClearDeviationSpec `json:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"` + Status *TargetClearDeviationStatus `json:"status,omitempty" protobuf:"bytes,3,opt,name=status"` } diff --git a/apis/config/v1alpha1/target_runningconfig_resource.go b/apis/config/v1alpha1/target_runningconfig_resource.go index b7c83608..e0418b0a 100644 --- a/apis/config/v1alpha1/target_runningconfig_resource.go +++ b/apis/config/v1alpha1/target_runningconfig_resource.go @@ -48,7 +48,7 @@ func (TargetRunningConfig) ConvertFromURLValues() func(a, b interface{}, scope c values := a.(*url.Values) out := b.(*TargetRunningConfigOptions) out.Path = values.Get("path") - out.Format = values.Get("format") + out.Format = TargetFormat(values.Get("format")) return nil } } @@ -60,21 +60,15 @@ func (TargetRunningConfig) ParameterSchemeConversions() []func(*runtime.Scheme) func(s *runtime.Scheme) error { return s.AddConversionFunc((*TargetRunningConfigOptions)(nil), (*config.TargetRunningConfigOptions)(nil), func(a, b interface{}, scope conversion.Scope) error { - in := a.(*TargetRunningConfigOptions) - out := b.(*config.TargetRunningConfigOptions) - out.Path = in.Path - out.Format = in.Format - return nil + return Convert_v1alpha1_TargetRunningConfigOptions_To_config_TargetRunningConfigOptions( + a.(*TargetRunningConfigOptions), b.(*config.TargetRunningConfigOptions), scope) }) }, func(s *runtime.Scheme) error { return s.AddConversionFunc((*config.TargetRunningConfigOptions)(nil), (*TargetRunningConfigOptions)(nil), func(a, b interface{}, scope conversion.Scope) error { - in := a.(*config.TargetRunningConfigOptions) - out := b.(*TargetRunningConfigOptions) - out.Path = in.Path - out.Format = in.Format - return nil + return Convert_config_TargetRunningConfigOptions_To_v1alpha1_TargetRunningConfigOptions( + a.(*config.TargetRunningConfigOptions), b.(*TargetRunningConfigOptions), scope) }) }, } diff --git a/apis/config/v1alpha1/target_runningconfig_types.go b/apis/config/v1alpha1/target_runningconfig_types.go index 0ac6e6c2..e06fea4e 100644 --- a/apis/config/v1alpha1/target_runningconfig_types.go +++ b/apis/config/v1alpha1/target_runningconfig_types.go @@ -41,6 +41,19 @@ type TargetRunningConfigOptions struct { // Path filters the running config to a subtree Path string `json:"path,omitempty"` - // Format controls output format - Format string `json:"format,omitempty"` -} \ No newline at end of file + // Format controls output format (json, json_ietf, xml, proto) + // +kubebuilder:validation:Enum=json;json_ietf;xml;proto + // +kubebuilder:default=json + Format TargetFormat `json:"format,omitempty"` +} + +// Format defines the output encoding format for running config +// +enum +type TargetFormat string + +const ( + Format_JSON TargetFormat = "json" + Format_JSON_IETF TargetFormat = "json_ietf" + Format_XML TargetFormat = "xml" + Format_PROTO TargetFormat = "proto" +) \ No newline at end of file diff --git a/apis/config/v1alpha1/zz_generated.conversion.go b/apis/config/v1alpha1/zz_generated.conversion.go index 2e2daf29..d642ab1f 100644 --- a/apis/config/v1alpha1/zz_generated.conversion.go +++ b/apis/config/v1alpha1/zz_generated.conversion.go @@ -378,6 +378,26 @@ func RegisterConversions(s *runtime.Scheme) error { }); err != nil { return err } + if err := s.AddGeneratedConversionFunc((*TargetClearDeviationConfig)(nil), (*config.TargetClearDeviationConfig)(nil), func(a, b interface{}, scope conversion.Scope) error { + return Convert_v1alpha1_TargetClearDeviationConfig_To_config_TargetClearDeviationConfig(a.(*TargetClearDeviationConfig), b.(*config.TargetClearDeviationConfig), scope) + }); err != nil { + return err + } + if err := s.AddGeneratedConversionFunc((*config.TargetClearDeviationConfig)(nil), (*TargetClearDeviationConfig)(nil), func(a, b interface{}, scope conversion.Scope) error { + return Convert_config_TargetClearDeviationConfig_To_v1alpha1_TargetClearDeviationConfig(a.(*config.TargetClearDeviationConfig), b.(*TargetClearDeviationConfig), scope) + }); err != nil { + return err + } + if err := s.AddGeneratedConversionFunc((*TargetClearDeviationConfigResult)(nil), (*config.TargetClearDeviationConfigResult)(nil), func(a, b interface{}, scope conversion.Scope) error { + return Convert_v1alpha1_TargetClearDeviationConfigResult_To_config_TargetClearDeviationConfigResult(a.(*TargetClearDeviationConfigResult), b.(*config.TargetClearDeviationConfigResult), scope) + }); err != nil { + return err + } + if err := s.AddGeneratedConversionFunc((*config.TargetClearDeviationConfigResult)(nil), (*TargetClearDeviationConfigResult)(nil), func(a, b interface{}, scope conversion.Scope) error { + return Convert_config_TargetClearDeviationConfigResult_To_v1alpha1_TargetClearDeviationConfigResult(a.(*config.TargetClearDeviationConfigResult), b.(*TargetClearDeviationConfigResult), scope) + }); err != nil { + return err + } if err := s.AddGeneratedConversionFunc((*TargetClearDeviationSpec)(nil), (*config.TargetClearDeviationSpec)(nil), func(a, b interface{}, scope conversion.Scope) error { return Convert_v1alpha1_TargetClearDeviationSpec_To_config_TargetClearDeviationSpec(a.(*TargetClearDeviationSpec), b.(*config.TargetClearDeviationSpec), scope) }); err != nil { @@ -1435,12 +1455,8 @@ func Convert_config_Target_To_v1alpha1_Target(in *config.Target, out *Target, s func autoConvert_v1alpha1_TargetClearDeviation_To_config_TargetClearDeviation(in *TargetClearDeviation, out *config.TargetClearDeviation, s conversion.Scope) error { out.ObjectMeta = in.ObjectMeta - if err := Convert_v1alpha1_TargetClearDeviationSpec_To_config_TargetClearDeviationSpec(&in.Spec, &out.Spec, s); err != nil { - return err - } - if err := Convert_v1alpha1_TargetClearDeviationStatus_To_config_TargetClearDeviationStatus(&in.Status, &out.Status, s); err != nil { - return err - } + out.Spec = (*config.TargetClearDeviationSpec)(unsafe.Pointer(in.Spec)) + out.Status = (*config.TargetClearDeviationStatus)(unsafe.Pointer(in.Status)) return nil } @@ -1451,12 +1467,8 @@ func Convert_v1alpha1_TargetClearDeviation_To_config_TargetClearDeviation(in *Ta func autoConvert_config_TargetClearDeviation_To_v1alpha1_TargetClearDeviation(in *config.TargetClearDeviation, out *TargetClearDeviation, s conversion.Scope) error { out.ObjectMeta = in.ObjectMeta - if err := Convert_config_TargetClearDeviationSpec_To_v1alpha1_TargetClearDeviationSpec(&in.Spec, &out.Spec, s); err != nil { - return err - } - if err := Convert_config_TargetClearDeviationStatus_To_v1alpha1_TargetClearDeviationStatus(&in.Status, &out.Status, s); err != nil { - return err - } + out.Spec = (*TargetClearDeviationSpec)(unsafe.Pointer(in.Spec)) + out.Status = (*TargetClearDeviationStatus)(unsafe.Pointer(in.Status)) return nil } @@ -1465,18 +1477,70 @@ func Convert_config_TargetClearDeviation_To_v1alpha1_TargetClearDeviation(in *co return autoConvert_config_TargetClearDeviation_To_v1alpha1_TargetClearDeviation(in, out, s) } -func autoConvert_v1alpha1_TargetClearDeviationSpec_To_config_TargetClearDeviationSpec(in *TargetClearDeviationSpec, out *config.TargetClearDeviationSpec, s conversion.Scope) error { +func autoConvert_v1alpha1_TargetClearDeviationConfig_To_config_TargetClearDeviationConfig(in *TargetClearDeviationConfig, out *config.TargetClearDeviationConfig, s conversion.Scope) error { + out.Name = in.Name + out.Paths = *(*[]string)(unsafe.Pointer(&in.Paths)) + return nil +} + +// Convert_v1alpha1_TargetClearDeviationConfig_To_config_TargetClearDeviationConfig is an autogenerated conversion function. +func Convert_v1alpha1_TargetClearDeviationConfig_To_config_TargetClearDeviationConfig(in *TargetClearDeviationConfig, out *config.TargetClearDeviationConfig, s conversion.Scope) error { + return autoConvert_v1alpha1_TargetClearDeviationConfig_To_config_TargetClearDeviationConfig(in, out, s) +} + +func autoConvert_config_TargetClearDeviationConfig_To_v1alpha1_TargetClearDeviationConfig(in *config.TargetClearDeviationConfig, out *TargetClearDeviationConfig, s conversion.Scope) error { + out.Name = in.Name out.Paths = *(*[]string)(unsafe.Pointer(&in.Paths)) return nil } +// Convert_config_TargetClearDeviationConfig_To_v1alpha1_TargetClearDeviationConfig is an autogenerated conversion function. +func Convert_config_TargetClearDeviationConfig_To_v1alpha1_TargetClearDeviationConfig(in *config.TargetClearDeviationConfig, out *TargetClearDeviationConfig, s conversion.Scope) error { + return autoConvert_config_TargetClearDeviationConfig_To_v1alpha1_TargetClearDeviationConfig(in, out, s) +} + +func autoConvert_v1alpha1_TargetClearDeviationConfigResult_To_config_TargetClearDeviationConfigResult(in *TargetClearDeviationConfigResult, out *config.TargetClearDeviationConfigResult, s conversion.Scope) error { + out.Name = in.Name + out.Success = in.Success + out.Message = in.Message + out.Errors = *(*[]string)(unsafe.Pointer(&in.Errors)) + out.Warnings = *(*[]string)(unsafe.Pointer(&in.Warnings)) + return nil +} + +// Convert_v1alpha1_TargetClearDeviationConfigResult_To_config_TargetClearDeviationConfigResult is an autogenerated conversion function. +func Convert_v1alpha1_TargetClearDeviationConfigResult_To_config_TargetClearDeviationConfigResult(in *TargetClearDeviationConfigResult, out *config.TargetClearDeviationConfigResult, s conversion.Scope) error { + return autoConvert_v1alpha1_TargetClearDeviationConfigResult_To_config_TargetClearDeviationConfigResult(in, out, s) +} + +func autoConvert_config_TargetClearDeviationConfigResult_To_v1alpha1_TargetClearDeviationConfigResult(in *config.TargetClearDeviationConfigResult, out *TargetClearDeviationConfigResult, s conversion.Scope) error { + out.Name = in.Name + out.Success = in.Success + out.Message = in.Message + out.Errors = *(*[]string)(unsafe.Pointer(&in.Errors)) + out.Warnings = *(*[]string)(unsafe.Pointer(&in.Warnings)) + return nil +} + +// Convert_config_TargetClearDeviationConfigResult_To_v1alpha1_TargetClearDeviationConfigResult is an autogenerated conversion function. +func Convert_config_TargetClearDeviationConfigResult_To_v1alpha1_TargetClearDeviationConfigResult(in *config.TargetClearDeviationConfigResult, out *TargetClearDeviationConfigResult, s conversion.Scope) error { + return autoConvert_config_TargetClearDeviationConfigResult_To_v1alpha1_TargetClearDeviationConfigResult(in, out, s) +} + +func autoConvert_v1alpha1_TargetClearDeviationSpec_To_config_TargetClearDeviationSpec(in *TargetClearDeviationSpec, out *config.TargetClearDeviationSpec, s conversion.Scope) error { + out.IncludeAllConfigs = (*bool)(unsafe.Pointer(in.IncludeAllConfigs)) + out.Config = *(*[]config.TargetClearDeviationConfig)(unsafe.Pointer(&in.Config)) + return nil +} + // Convert_v1alpha1_TargetClearDeviationSpec_To_config_TargetClearDeviationSpec is an autogenerated conversion function. func Convert_v1alpha1_TargetClearDeviationSpec_To_config_TargetClearDeviationSpec(in *TargetClearDeviationSpec, out *config.TargetClearDeviationSpec, s conversion.Scope) error { return autoConvert_v1alpha1_TargetClearDeviationSpec_To_config_TargetClearDeviationSpec(in, out, s) } func autoConvert_config_TargetClearDeviationSpec_To_v1alpha1_TargetClearDeviationSpec(in *config.TargetClearDeviationSpec, out *TargetClearDeviationSpec, s conversion.Scope) error { - out.Paths = *(*[]string)(unsafe.Pointer(&in.Paths)) + out.IncludeAllConfigs = (*bool)(unsafe.Pointer(in.IncludeAllConfigs)) + out.Config = *(*[]TargetClearDeviationConfig)(unsafe.Pointer(&in.Config)) return nil } @@ -1486,8 +1550,9 @@ func Convert_config_TargetClearDeviationSpec_To_v1alpha1_TargetClearDeviationSpe } func autoConvert_v1alpha1_TargetClearDeviationStatus_To_config_TargetClearDeviationStatus(in *TargetClearDeviationStatus, out *config.TargetClearDeviationStatus, s conversion.Scope) error { - out.Cleared = in.Cleared out.Message = in.Message + out.Warnings = *(*[]string)(unsafe.Pointer(&in.Warnings)) + out.Results = *(*[]config.TargetClearDeviationConfigResult)(unsafe.Pointer(&in.Results)) return nil } @@ -1497,8 +1562,9 @@ func Convert_v1alpha1_TargetClearDeviationStatus_To_config_TargetClearDeviationS } func autoConvert_config_TargetClearDeviationStatus_To_v1alpha1_TargetClearDeviationStatus(in *config.TargetClearDeviationStatus, out *TargetClearDeviationStatus, s conversion.Scope) error { - out.Cleared = in.Cleared out.Message = in.Message + out.Warnings = *(*[]string)(unsafe.Pointer(&in.Warnings)) + out.Results = *(*[]TargetClearDeviationConfigResult)(unsafe.Pointer(&in.Results)) return nil } @@ -1595,7 +1661,7 @@ func Convert_config_TargetRunningConfig_To_v1alpha1_TargetRunningConfig(in *conf func autoConvert_v1alpha1_TargetRunningConfigOptions_To_config_TargetRunningConfigOptions(in *TargetRunningConfigOptions, out *config.TargetRunningConfigOptions, s conversion.Scope) error { out.Path = in.Path - out.Format = in.Format + out.Format = config.TargetFormat(in.Format) return nil } @@ -1606,7 +1672,7 @@ func Convert_v1alpha1_TargetRunningConfigOptions_To_config_TargetRunningConfigOp func autoConvert_config_TargetRunningConfigOptions_To_v1alpha1_TargetRunningConfigOptions(in *config.TargetRunningConfigOptions, out *TargetRunningConfigOptions, s conversion.Scope) error { out.Path = in.Path - out.Format = in.Format + out.Format = TargetFormat(in.Format) return nil } diff --git a/apis/config/v1alpha1/zz_generated.deepcopy.go b/apis/config/v1alpha1/zz_generated.deepcopy.go index 8ea451ae..e913b710 100644 --- a/apis/config/v1alpha1/zz_generated.deepcopy.go +++ b/apis/config/v1alpha1/zz_generated.deepcopy.go @@ -874,8 +874,16 @@ func (in *TargetClearDeviation) DeepCopyInto(out *TargetClearDeviation) { *out = *in out.TypeMeta = in.TypeMeta in.ObjectMeta.DeepCopyInto(&out.ObjectMeta) - in.Spec.DeepCopyInto(&out.Spec) - out.Status = in.Status + if in.Spec != nil { + in, out := &in.Spec, &out.Spec + *out = new(TargetClearDeviationSpec) + (*in).DeepCopyInto(*out) + } + if in.Status != nil { + in, out := &in.Status, &out.Status + *out = new(TargetClearDeviationStatus) + (*in).DeepCopyInto(*out) + } return } @@ -898,7 +906,7 @@ func (in *TargetClearDeviation) DeepCopyObject() runtime.Object { } // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *TargetClearDeviationSpec) DeepCopyInto(out *TargetClearDeviationSpec) { +func (in *TargetClearDeviationConfig) DeepCopyInto(out *TargetClearDeviationConfig) { *out = *in if in.Paths != nil { in, out := &in.Paths, &out.Paths @@ -908,6 +916,60 @@ func (in *TargetClearDeviationSpec) DeepCopyInto(out *TargetClearDeviationSpec) return } +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new TargetClearDeviationConfig. +func (in *TargetClearDeviationConfig) DeepCopy() *TargetClearDeviationConfig { + if in == nil { + return nil + } + out := new(TargetClearDeviationConfig) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *TargetClearDeviationConfigResult) DeepCopyInto(out *TargetClearDeviationConfigResult) { + *out = *in + if in.Errors != nil { + in, out := &in.Errors, &out.Errors + *out = make([]string, len(*in)) + copy(*out, *in) + } + if in.Warnings != nil { + in, out := &in.Warnings, &out.Warnings + *out = make([]string, len(*in)) + copy(*out, *in) + } + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new TargetClearDeviationConfigResult. +func (in *TargetClearDeviationConfigResult) DeepCopy() *TargetClearDeviationConfigResult { + if in == nil { + return nil + } + out := new(TargetClearDeviationConfigResult) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *TargetClearDeviationSpec) DeepCopyInto(out *TargetClearDeviationSpec) { + *out = *in + if in.IncludeAllConfigs != nil { + in, out := &in.IncludeAllConfigs, &out.IncludeAllConfigs + *out = new(bool) + **out = **in + } + if in.Config != nil { + in, out := &in.Config, &out.Config + *out = make([]TargetClearDeviationConfig, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + return +} + // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new TargetClearDeviationSpec. func (in *TargetClearDeviationSpec) DeepCopy() *TargetClearDeviationSpec { if in == nil { @@ -921,6 +983,18 @@ func (in *TargetClearDeviationSpec) DeepCopy() *TargetClearDeviationSpec { // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *TargetClearDeviationStatus) DeepCopyInto(out *TargetClearDeviationStatus) { *out = *in + if in.Warnings != nil { + in, out := &in.Warnings, &out.Warnings + *out = make([]string, len(*in)) + copy(*out, *in) + } + if in.Results != nil { + in, out := &in.Results, &out.Results + *out = make([]TargetClearDeviationConfigResult, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } return } diff --git a/apis/config/zz_generated.deepcopy.go b/apis/config/zz_generated.deepcopy.go index 66ce0234..8530213f 100644 --- a/apis/config/zz_generated.deepcopy.go +++ b/apis/config/zz_generated.deepcopy.go @@ -1133,8 +1133,16 @@ func (in *TargetClearDeviation) DeepCopyInto(out *TargetClearDeviation) { *out = *in out.TypeMeta = in.TypeMeta in.ObjectMeta.DeepCopyInto(&out.ObjectMeta) - in.Spec.DeepCopyInto(&out.Spec) - out.Status = in.Status + if in.Spec != nil { + in, out := &in.Spec, &out.Spec + *out = new(TargetClearDeviationSpec) + (*in).DeepCopyInto(*out) + } + if in.Status != nil { + in, out := &in.Status, &out.Status + *out = new(TargetClearDeviationStatus) + (*in).DeepCopyInto(*out) + } return } @@ -1157,7 +1165,7 @@ func (in *TargetClearDeviation) DeepCopyObject() runtime.Object { } // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *TargetClearDeviationSpec) DeepCopyInto(out *TargetClearDeviationSpec) { +func (in *TargetClearDeviationConfig) DeepCopyInto(out *TargetClearDeviationConfig) { *out = *in if in.Paths != nil { in, out := &in.Paths, &out.Paths @@ -1167,6 +1175,60 @@ func (in *TargetClearDeviationSpec) DeepCopyInto(out *TargetClearDeviationSpec) return } +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new TargetClearDeviationConfig. +func (in *TargetClearDeviationConfig) DeepCopy() *TargetClearDeviationConfig { + if in == nil { + return nil + } + out := new(TargetClearDeviationConfig) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *TargetClearDeviationConfigResult) DeepCopyInto(out *TargetClearDeviationConfigResult) { + *out = *in + if in.Errors != nil { + in, out := &in.Errors, &out.Errors + *out = make([]string, len(*in)) + copy(*out, *in) + } + if in.Warnings != nil { + in, out := &in.Warnings, &out.Warnings + *out = make([]string, len(*in)) + copy(*out, *in) + } + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new TargetClearDeviationConfigResult. +func (in *TargetClearDeviationConfigResult) DeepCopy() *TargetClearDeviationConfigResult { + if in == nil { + return nil + } + out := new(TargetClearDeviationConfigResult) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *TargetClearDeviationSpec) DeepCopyInto(out *TargetClearDeviationSpec) { + *out = *in + if in.IncludeAllConfigs != nil { + in, out := &in.IncludeAllConfigs, &out.IncludeAllConfigs + *out = new(bool) + **out = **in + } + if in.Config != nil { + in, out := &in.Config, &out.Config + *out = make([]TargetClearDeviationConfig, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + return +} + // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new TargetClearDeviationSpec. func (in *TargetClearDeviationSpec) DeepCopy() *TargetClearDeviationSpec { if in == nil { @@ -1180,6 +1242,18 @@ func (in *TargetClearDeviationSpec) DeepCopy() *TargetClearDeviationSpec { // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *TargetClearDeviationStatus) DeepCopyInto(out *TargetClearDeviationStatus) { *out = *in + if in.Warnings != nil { + in, out := &in.Warnings, &out.Warnings + *out = make([]string, len(*in)) + copy(*out, *in) + } + if in.Results != nil { + in, out := &in.Results, &out.Results + *out = make([]TargetClearDeviationConfigResult, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } return } diff --git a/cmd/api-server/main.go b/cmd/api-server/main.go index afb226f3..c0ffefbd 100644 --- a/cmd/api-server/main.go +++ b/cmd/api-server/main.go @@ -28,9 +28,11 @@ import ( "github.com/henderiw/apiserver-builder/pkg/builder" "github.com/henderiw/apiserver-store/pkg/db/badgerdb" "github.com/henderiw/logger/log" + "github.com/sdcio/config-server/apis/config" sdcconfig "github.com/sdcio/config-server/apis/config" "github.com/sdcio/config-server/apis/config/handlers" configv1alpha1 "github.com/sdcio/config-server/apis/config/v1alpha1" + //invv1alpha1 "github.com/sdcio/config-server/apis/inv/v1alpha1" "github.com/sdcio/config-server/pkg/generated/openapi" _ "github.com/sdcio/config-server/pkg/reconcilers/all" @@ -124,10 +126,13 @@ func main() { os.Exit(1) } + config.SetSubResourceClient(mgr.GetClient()) + registryOptions := &options.Options{ Prefix: configDir, Type: options.StorageType_KV, DB: db, + Client: mgr.GetClient(), } configHandler := handlers.ConfigStoreHandler{ diff --git a/go.mod b/go.mod index 02e58556..5703da00 100644 --- a/go.mod +++ b/go.mod @@ -7,7 +7,7 @@ require ( github.com/go-git/go-git/v5 v5.16.5 github.com/google/go-cmp v0.7.0 github.com/google/uuid v1.6.0 - github.com/henderiw/apiserver-builder v0.0.8-0.20260303101118-65b82049cc85 + github.com/henderiw/apiserver-builder v0.0.8 github.com/henderiw/apiserver-store v0.0.4 github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c github.com/henderiw/logger v0.0.0-20230911123436-8655829b1abe @@ -20,7 +20,7 @@ require ( github.com/prometheus/client_golang v1.23.2 github.com/prometheus/client_model v0.6.2 github.com/prometheus/prometheus v0.309.1 - github.com/sdcio/sdc-protos v0.0.50 + github.com/sdcio/sdc-protos v0.0.51-0.20260224122709-ca10362f11ba github.com/spf13/cobra v1.10.2 github.com/stretchr/testify v1.11.1 go.opentelemetry.io/otel v1.39.0 diff --git a/go.sum b/go.sum index 445898ec..26fc2174 100644 --- a/go.sum +++ b/go.sum @@ -169,8 +169,8 @@ github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0 h1:Ovs26xHkKqVztRpIrF/92Bcuy github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0/go.mod h1:8NvIoxWQoOIhqOTXgfV/d3M/q6VIi02HzZEHgUlZvzk= github.com/grpc-ecosystem/grpc-gateway/v2 v2.27.3 h1:NmZ1PKzSTQbuGHw9DGPFomqkkLWMC+vZCkfs+FHv1Vg= github.com/grpc-ecosystem/grpc-gateway/v2 v2.27.3/go.mod h1:zQrxl1YP88HQlA6i9c63DSVPFklWpGX4OWAc9bFuaH4= -github.com/henderiw/apiserver-builder v0.0.8-0.20260303101118-65b82049cc85 h1:Q6spkgooANaMF0SNeP2VPUoHYTtdsQgxzboodekIMzo= -github.com/henderiw/apiserver-builder v0.0.8-0.20260303101118-65b82049cc85/go.mod h1:7VrZxXPR54Urtg49taC7cNgo+AOzSxWEJXPDdDbKnCk= +github.com/henderiw/apiserver-builder v0.0.8 h1:TxJnhISBgrhw1HJ1cSNAz7nveu86y3jy4dvcmNQdsVc= +github.com/henderiw/apiserver-builder v0.0.8/go.mod h1:7VrZxXPR54Urtg49taC7cNgo+AOzSxWEJXPDdDbKnCk= github.com/henderiw/apiserver-store v0.0.4 h1:IeawmDpcX4PzRxh0IW8j8IC++Vn1OOkUUBeq3laylPU= github.com/henderiw/apiserver-store v0.0.4/go.mod h1:RuXLMHJwszn6LXgL6fO9fxMC7AW5wAc4zOddnnZpkKI= github.com/henderiw/iputil v0.0.0-20231218081610-37f78ad9c81c h1:nFnCNyRV1Ej/zqV/gn8UnFESkoPUXhwpUCZyhSYGSYA= @@ -270,8 +270,8 @@ github.com/rogpeppe/go-internal v1.14.1/go.mod h1:MaRKkUm5W0goXpeCfT7UZI6fk/L7L7 github.com/russross/blackfriday/v2 v2.1.0/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM= github.com/sdcio/logger v0.0.3 h1:IFUbObObGry+S8lHGwOQKKRxJSuOphgRU/hxVhOdMOM= github.com/sdcio/logger v0.0.3/go.mod h1:yWaOxK/G6vszjg8tKZiMqiEjlZouHsjFME4zSk+SAEA= -github.com/sdcio/sdc-protos v0.0.50 h1:aR6Av1QMTFNXKKxnrz8vlIXQ0y21lxQJEMut1oLd2Bg= -github.com/sdcio/sdc-protos v0.0.50/go.mod h1:huh1QVE023w+reU2Gt6h1f83R3lJidcFLbQje7cMY1M= +github.com/sdcio/sdc-protos v0.0.51-0.20260224122709-ca10362f11ba h1:WcWzmAzwXWYBvmbJRTbgFR55W30kx7TKBdLPpAndB7c= +github.com/sdcio/sdc-protos v0.0.51-0.20260224122709-ca10362f11ba/go.mod h1:huh1QVE023w+reU2Gt6h1f83R3lJidcFLbQje7cMY1M= github.com/sergi/go-diff v1.3.2-0.20230802210424-5b0b94c5c0d3 h1:n661drycOFuPLCN3Uc8sB6B/s6Z4t2xvBgU1htSHuq8= github.com/sergi/go-diff v1.3.2-0.20230802210424-5b0b94c5c0d3/go.mod h1:A0bzQcvG0E7Rwjx0REVgAGH58e96+X0MeOfepqsbeW4= github.com/sirupsen/logrus v1.7.0/go.mod h1:yWOB1SBYBC5VeMP7gHvWumXLIWorT60ONWic61uBYv0= diff --git a/pkg/generated/openapi/zz_generated.openapi.go b/pkg/generated/openapi/zz_generated.openapi.go index 88fef915..c997aa13 100644 --- a/pkg/generated/openapi/zz_generated.openapi.go +++ b/pkg/generated/openapi/zz_generated.openapi.go @@ -69,6 +69,8 @@ func GetOpenAPIDefinitions(ref common.ReferenceCallback) map[string]common.OpenA "github.com/sdcio/config-server/apis/config/v1alpha1.SensitiveConfigStatus": schema_config_server_apis_config_v1alpha1_SensitiveConfigStatus(ref), "github.com/sdcio/config-server/apis/config/v1alpha1.Target": schema_config_server_apis_config_v1alpha1_Target(ref), "github.com/sdcio/config-server/apis/config/v1alpha1.TargetClearDeviation": schema_config_server_apis_config_v1alpha1_TargetClearDeviation(ref), + "github.com/sdcio/config-server/apis/config/v1alpha1.TargetClearDeviationConfig": schema_config_server_apis_config_v1alpha1_TargetClearDeviationConfig(ref), + "github.com/sdcio/config-server/apis/config/v1alpha1.TargetClearDeviationConfigResult": schema_config_server_apis_config_v1alpha1_TargetClearDeviationConfigResult(ref), "github.com/sdcio/config-server/apis/config/v1alpha1.TargetClearDeviationSpec": schema_config_server_apis_config_v1alpha1_TargetClearDeviationSpec(ref), "github.com/sdcio/config-server/apis/config/v1alpha1.TargetClearDeviationStatus": schema_config_server_apis_config_v1alpha1_TargetClearDeviationStatus(ref), "github.com/sdcio/config-server/apis/config/v1alpha1.TargetConfigBlame": schema_config_server_apis_config_v1alpha1_TargetConfigBlame(ref), @@ -2043,14 +2045,12 @@ func schema_config_server_apis_config_v1alpha1_TargetClearDeviation(ref common.R }, "spec": { SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref("github.com/sdcio/config-server/apis/config/v1alpha1.TargetClearDeviationSpec"), + Ref: ref("github.com/sdcio/config-server/apis/config/v1alpha1.TargetClearDeviationSpec"), }, }, "status": { SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref("github.com/sdcio/config-server/apis/config/v1alpha1.TargetClearDeviationStatus"), + Ref: ref("github.com/sdcio/config-server/apis/config/v1alpha1.TargetClearDeviationStatus"), }, }, }, @@ -2068,13 +2068,20 @@ func schema_config_server_apis_config_v1alpha1_TargetClearDeviation(ref common.R } } -func schema_config_server_apis_config_v1alpha1_TargetClearDeviationSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { +func schema_config_server_apis_config_v1alpha1_TargetClearDeviationConfig(ref common.ReferenceCallback) common.OpenAPIDefinition { return common.OpenAPIDefinition{ Schema: spec.Schema{ SchemaProps: spec.SchemaProps{ - Description: "TargetClearDeviationSpec defines the desired state of Target", - Type: []string{"object"}, + Type: []string{"object"}, Properties: map[string]spec.Schema{ + "name": { + SchemaProps: spec.SchemaProps{ + Description: "Name of the config on which the paths should be cleared", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, "paths": { SchemaProps: spec.SchemaProps{ Description: "Paths provide the path of the deviation to be cleared", @@ -2091,36 +2098,162 @@ func schema_config_server_apis_config_v1alpha1_TargetClearDeviationSpec(ref comm }, }, }, - Required: []string{"paths"}, + Required: []string{"name", "paths"}, }, }, } } -func schema_config_server_apis_config_v1alpha1_TargetClearDeviationStatus(ref common.ReferenceCallback) common.OpenAPIDefinition { +func schema_config_server_apis_config_v1alpha1_TargetClearDeviationConfigResult(ref common.ReferenceCallback) common.OpenAPIDefinition { return common.OpenAPIDefinition{ Schema: spec.Schema{ SchemaProps: spec.SchemaProps{ Type: []string{"object"}, Properties: map[string]spec.Schema{ - "cleared": { + "name": { SchemaProps: spec.SchemaProps{ - Default: 0, - Type: []string{"integer"}, - Format: "int32", + Description: "Name of the config on which the paths should be cleared", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "success": { + SchemaProps: spec.SchemaProps{ + Description: "Success indicates whether the clear deviation was successful", + Default: false, + Type: []string{"boolean"}, + Format: "", }, }, "message": { SchemaProps: spec.SchemaProps{ - Default: "", - Type: []string{"string"}, - Format: "", + Description: "Message provides detail on the outcome", + Type: []string{"string"}, + Format: "", + }, + }, + "errors": { + SchemaProps: spec.SchemaProps{ + Description: "Errors lists any errors for this specific config", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + "warnings": { + SchemaProps: spec.SchemaProps{ + Description: "Warnings lists any warnings for this specific config", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + }, + Required: []string{"name", "success"}, + }, + }, + } +} + +func schema_config_server_apis_config_v1alpha1_TargetClearDeviationSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "TargetClearDeviationSpec defines the desired state of Target", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "includeAllConfigs": { + SchemaProps: spec.SchemaProps{ + Description: "IncludeConfigs when true includes all existing configs in the transaction, not just the ones referenced by Config.", + Type: []string{"boolean"}, + Format: "", + }, + }, + "config": { + SchemaProps: spec.SchemaProps{ + Description: "Config defines the clear deviations configs to applied on the taget", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("github.com/sdcio/config-server/apis/config/v1alpha1.TargetClearDeviationConfig"), + }, + }, + }, }, }, }, - Required: []string{"cleared", "message"}, + Required: []string{"config"}, }, }, + Dependencies: []string{ + "github.com/sdcio/config-server/apis/config/v1alpha1.TargetClearDeviationConfig"}, + } +} + +func schema_config_server_apis_config_v1alpha1_TargetClearDeviationStatus(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "message": { + SchemaProps: spec.SchemaProps{ + Description: "Message is a global message for the transaction", + Type: []string{"string"}, + Format: "", + }, + }, + "warnings": { + SchemaProps: spec.SchemaProps{ + Description: "Warnings are global warnings from the transaction", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + "results": { + SchemaProps: spec.SchemaProps{ + Description: "Results holds per-config outcomes, keyed by intent name", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("github.com/sdcio/config-server/apis/config/v1alpha1.TargetClearDeviationConfigResult"), + }, + }, + }, + }, + }, + }, + }, + }, + Dependencies: []string{ + "github.com/sdcio/config-server/apis/config/v1alpha1.TargetClearDeviationConfigResult"}, } } @@ -2299,9 +2432,10 @@ func schema_config_server_apis_config_v1alpha1_TargetRunningConfigOptions(ref co }, "format": { SchemaProps: spec.SchemaProps{ - Description: "Format controls output format", + Description: "Format controls output format (json, json_ietf, xml, proto)\n\nPossible enum values:\n - `\"json\"`\n - `\"json_ietf\"`\n - `\"proto\"`\n - `\"xml\"`", Type: []string{"string"}, Format: "", + Enum: []interface{}{"json", "json_ietf", "proto", "xml"}, }, }, }, diff --git a/pkg/sdc/target/manager/dryrun.go b/pkg/sdc/target/manager/dryrun.go index 07097185..d2deddf0 100644 --- a/pkg/sdc/target/manager/dryrun.go +++ b/pkg/sdc/target/manager/dryrun.go @@ -58,7 +58,7 @@ func RunDryRunTransaction( }() req := &sdcpb.TransactionSetRequest{ - TransactionId: GetGVKNSN(c), + TransactionId: config.GetGVKNSN(c), DatastoreName: key.String(), DryRun: dryrun, Timeout: ptr.To(int32(60)), diff --git a/pkg/sdc/target/manager/transactor.go b/pkg/sdc/target/manager/transactor.go index 240b1cd3..57973bd5 100644 --- a/pkg/sdc/target/manager/transactor.go +++ b/pkg/sdc/target/manager/transactor.go @@ -123,16 +123,16 @@ func (r *Transactor) recoverIntents( } intents := make([]*sdcpb.TransactionIntent, 0, len(configs)) - for _, config := range configs { - update, err := GetIntentUpdate(ctx, key, config, false) + for _, cfg := range configs { + update, err := config.GetIntentUpdate(cfg, false) if err != nil { return "", err } intents = append(intents, &sdcpb.TransactionIntent{ - Intent: GetGVKNSN(config), - Priority: int32(config.Spec.Priority), + Intent: config.GetGVKNSN(cfg), + Priority: int32(cfg.Spec.Priority), Update: update, - NonRevertive: !config.IsRevertive(), + NonRevertive: !cfg.IsRevertive(), PreviouslyApplied: true, }) } @@ -289,28 +289,28 @@ func (r *Transactor) setIntents( intents := make([]*sdcpb.TransactionIntent, 0) - for key, config := range configsToUpdate { + for key, cfg := range configsToUpdate { configsToUpdateSet.Insert(key) - update, err := GetIntentUpdate(ctx, targetKey, config, true) + update, err := config.GetIntentUpdate(cfg, true) if err != nil { log.Error("Transaction getIntentUpdate config", "error", err) return nil, err } intents = append(intents, &sdcpb.TransactionIntent{ - Intent: GetGVKNSN(config), - Priority: int32(config.Spec.Priority), + Intent: config.GetGVKNSN(cfg), + Priority: int32(cfg.Spec.Priority), Update: update, - NonRevertive: !config.IsRevertive(), + NonRevertive: !cfg.IsRevertive(), }) } - for key, config := range configsToDelete { + for key, cfg := range configsToDelete { configsToDeleteSet.Insert(key) intents = append(intents, &sdcpb.TransactionIntent{ - Intent: GetGVKNSN(config), + Intent: config.GetGVKNSN(cfg), //Priority: int32(config.Spec.Priority), Delete: true, DeleteIgnoreNoExist: true, - Orphan: config.Orphan(), + Orphan: cfg.Orphan(), }) } @@ -525,7 +525,7 @@ func getConfigsToTransact( // Classify configs: update / delete / non-recoverable / noop for i := range configList.Items { cfg := &configList.Items[i] - key := GetGVKNSN(cfg) + key := config.GetGVKNSN(cfg) switch { case !cfg.IsRecoverable(ctx): diff --git a/pkg/sdc/target/manager/utils.go b/pkg/sdc/target/manager/utils.go index cf4f39de..9cb12038 100644 --- a/pkg/sdc/target/manager/utils.go +++ b/pkg/sdc/target/manager/utils.go @@ -22,49 +22,13 @@ import ( "fmt" "strings" - "github.com/henderiw/apiserver-store/pkg/storebackend" "github.com/henderiw/logger/log" - "github.com/sdcio/config-server/apis/config" sdcpb "github.com/sdcio/sdc-protos/sdcpb" "google.golang.org/grpc/codes" "google.golang.org/grpc/status" "google.golang.org/protobuf/encoding/prototext" - "sigs.k8s.io/controller-runtime/pkg/client" ) -func GetGVKNSN(obj client.Object) string { - return fmt.Sprintf("%s.%s", obj.GetNamespace(), obj.GetName()) -} - -// useSpec indicates to use the spec as the confifSpec, typically set to true; when set to false it means we are recovering -// the config -func GetIntentUpdate(ctx context.Context, key storebackend.Key, config *config.Config, useSpec bool) ([]*sdcpb.Update, error) { - logger := log.FromContext(ctx) - update := make([]*sdcpb.Update, 0, len(config.Spec.Config)) - configSpec := config.Spec.Config - if !useSpec && config.Status.AppliedConfig != nil { - update = make([]*sdcpb.Update, 0, len(config.Status.AppliedConfig.Config)) - configSpec = config.Status.AppliedConfig.Config - } - - for _, config := range configSpec { - path, err := sdcpb.ParsePath(config.Path) - if err != nil { - return nil, fmt.Errorf("create data failed for target %s, path %s invalid", key.String(), config.Path) - } - logger.Debug("setIntent", "configSpec", string(config.Value.Raw)) - update = append(update, &sdcpb.Update{ - Path: path, - Value: &sdcpb.TypedValue{ - Value: &sdcpb.TypedValue_JsonVal{ - JsonVal: config.Value.Raw, - }, - }, - }) - } - return update, nil -} - // processTransactionResponse returns the warnings as a string and aggregates the errors in a single error and classifies them // as recoverable or non recoverable. func processTransactionResponse(ctx context.Context, rsp *sdcpb.TransactionSetResponse, rsperr error) (string, error) { From 2171ca92eebc85c3c8880efabcbf2f1d581eda15 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Tue, 3 Mar 2026 19:39:09 +0100 Subject: [PATCH 120/135] update enum to simple string --- apis/config/target_helpers.go | 2 +- apis/config/target_runningconfig_resource.go | 2 +- apis/config/target_runningconfig_types.go | 12 +++++++++++- .../config/v1alpha1/target_runningconfig_resource.go | 2 +- apis/config/v1alpha1/target_runningconfig_types.go | 2 +- apis/config/v1alpha1/zz_generated.conversion.go | 4 ++-- pkg/generated/openapi/zz_generated.openapi.go | 3 +-- 7 files changed, 18 insertions(+), 9 deletions(-) diff --git a/apis/config/target_helpers.go b/apis/config/target_helpers.go index 958a6866..0adf9189 100644 --- a/apis/config/target_helpers.go +++ b/apis/config/target_helpers.go @@ -104,7 +104,7 @@ func (r *Target) GetRunningConfig(ctx context.Context, opts *TargetRunningConfig var format TargetFormat if opts != nil { - format = opts.Format + format = ParseTargetFormat(opts.Format) } cfg := &dsclient.Config{ diff --git a/apis/config/target_runningconfig_resource.go b/apis/config/target_runningconfig_resource.go index 223f25e8..2823da2b 100644 --- a/apis/config/target_runningconfig_resource.go +++ b/apis/config/target_runningconfig_resource.go @@ -58,7 +58,7 @@ func (TargetRunningConfig) ConvertFromURLValues() func(a, b interface{}, scope c values := a.(*url.Values) out := b.(*TargetRunningConfigOptions) out.Path = values.Get("path") - out.Format = TargetFormat(values.Get("format")) + out.Format = values.Get("format") return nil } } diff --git a/apis/config/target_runningconfig_types.go b/apis/config/target_runningconfig_types.go index 4eb77b2b..89d75430 100644 --- a/apis/config/target_runningconfig_types.go +++ b/apis/config/target_runningconfig_types.go @@ -44,7 +44,7 @@ type TargetRunningConfigOptions struct { // Format controls output format (json, json_ietf, xml, proto) // +kubebuilder:validation:Enum=json;json_ietf;xml;proto // +kubebuilder:default=json - Format TargetFormat `json:"format,omitempty"` + Format string `json:"format,omitempty"` } // Format defines the output encoding format for running config @@ -57,3 +57,13 @@ const ( Format_XML TargetFormat = "xml" Format_PROTO TargetFormat = "proto" ) + +// ParseTargetFormat converts a string to TargetFormat, defaulting to JSON for unknown values. +func ParseTargetFormat(s string) TargetFormat { + switch TargetFormat(s) { + case Format_JSON, Format_JSON_IETF, Format_XML, Format_PROTO: + return TargetFormat(s) + default: + return Format_JSON + } +} diff --git a/apis/config/v1alpha1/target_runningconfig_resource.go b/apis/config/v1alpha1/target_runningconfig_resource.go index e0418b0a..23c47bf9 100644 --- a/apis/config/v1alpha1/target_runningconfig_resource.go +++ b/apis/config/v1alpha1/target_runningconfig_resource.go @@ -48,7 +48,7 @@ func (TargetRunningConfig) ConvertFromURLValues() func(a, b interface{}, scope c values := a.(*url.Values) out := b.(*TargetRunningConfigOptions) out.Path = values.Get("path") - out.Format = TargetFormat(values.Get("format")) + out.Format = values.Get("format") return nil } } diff --git a/apis/config/v1alpha1/target_runningconfig_types.go b/apis/config/v1alpha1/target_runningconfig_types.go index e06fea4e..685a6821 100644 --- a/apis/config/v1alpha1/target_runningconfig_types.go +++ b/apis/config/v1alpha1/target_runningconfig_types.go @@ -44,7 +44,7 @@ type TargetRunningConfigOptions struct { // Format controls output format (json, json_ietf, xml, proto) // +kubebuilder:validation:Enum=json;json_ietf;xml;proto // +kubebuilder:default=json - Format TargetFormat `json:"format,omitempty"` + Format string `json:"format,omitempty"` } // Format defines the output encoding format for running config diff --git a/apis/config/v1alpha1/zz_generated.conversion.go b/apis/config/v1alpha1/zz_generated.conversion.go index d642ab1f..754c609d 100644 --- a/apis/config/v1alpha1/zz_generated.conversion.go +++ b/apis/config/v1alpha1/zz_generated.conversion.go @@ -1661,7 +1661,7 @@ func Convert_config_TargetRunningConfig_To_v1alpha1_TargetRunningConfig(in *conf func autoConvert_v1alpha1_TargetRunningConfigOptions_To_config_TargetRunningConfigOptions(in *TargetRunningConfigOptions, out *config.TargetRunningConfigOptions, s conversion.Scope) error { out.Path = in.Path - out.Format = config.TargetFormat(in.Format) + out.Format = in.Format return nil } @@ -1672,7 +1672,7 @@ func Convert_v1alpha1_TargetRunningConfigOptions_To_config_TargetRunningConfigOp func autoConvert_config_TargetRunningConfigOptions_To_v1alpha1_TargetRunningConfigOptions(in *config.TargetRunningConfigOptions, out *TargetRunningConfigOptions, s conversion.Scope) error { out.Path = in.Path - out.Format = TargetFormat(in.Format) + out.Format = in.Format return nil } diff --git a/pkg/generated/openapi/zz_generated.openapi.go b/pkg/generated/openapi/zz_generated.openapi.go index c997aa13..9ef0badb 100644 --- a/pkg/generated/openapi/zz_generated.openapi.go +++ b/pkg/generated/openapi/zz_generated.openapi.go @@ -2432,10 +2432,9 @@ func schema_config_server_apis_config_v1alpha1_TargetRunningConfigOptions(ref co }, "format": { SchemaProps: spec.SchemaProps{ - Description: "Format controls output format (json, json_ietf, xml, proto)\n\nPossible enum values:\n - `\"json\"`\n - `\"json_ietf\"`\n - `\"proto\"`\n - `\"xml\"`", + Description: "Format controls output format (json, json_ietf, xml, proto)", Type: []string{"string"}, Format: "", - Enum: []interface{}{"json", "json_ietf", "proto", "xml"}, }, }, }, From 4e3d6bf8d37d64c4a5f6f2ee25b7aaced9431644 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Wed, 4 Mar 2026 21:13:58 +0100 Subject: [PATCH 121/135] update namespace handling --- apis/config/handlers/confighandler.go | 16 ++++++ apis/config/handlers/targethandler.go | 50 +++++++++++++++++++ apis/config/target_cleardeviation_types.go | 4 +- apis/config/target_helpers.go | 32 ++++-------- apis/config/target_resource.go | 9 ++++ .../v1alpha1/target_cleardeviation_types.go | 4 +- cmd/api-server/main.go | 4 +- 7 files changed, 90 insertions(+), 29 deletions(-) create mode 100644 apis/config/handlers/targethandler.go diff --git a/apis/config/handlers/confighandler.go b/apis/config/handlers/confighandler.go index 710dfb50..a3dc9e80 100644 --- a/apis/config/handlers/confighandler.go +++ b/apis/config/handlers/confighandler.go @@ -1,3 +1,19 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + package handlers import ( diff --git a/apis/config/handlers/targethandler.go b/apis/config/handlers/targethandler.go new file mode 100644 index 00000000..59e15827 --- /dev/null +++ b/apis/config/handlers/targethandler.go @@ -0,0 +1,50 @@ +/* +Copyright 2024 Nokia. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package handlers + +import ( + "context" + + "github.com/sdcio/config-server/apis/config" + configv1alpha1 "github.com/sdcio/config-server/apis/config/v1alpha1" + "sigs.k8s.io/controller-runtime/pkg/client" +) + +func ListConfigsByTarget(ctx context.Context, c client.Client, targetNamespace, targetName, lookupNamespace string) (map[string]*config.Config, error) { + v1alpha1List := &configv1alpha1.ConfigList{} + if err := c.List(ctx, v1alpha1List, + client.InNamespace(lookupNamespace), + client.MatchingLabels{ + config.TargetNamespaceKey: targetNamespace, + config.TargetNameKey: targetName, + }, + ); err != nil { + return nil, err + } + + configList := &config.ConfigList{} + if err := configv1alpha1.Convert_v1alpha1_ConfigList_To_config_ConfigList(v1alpha1List, configList, nil); err != nil { + return nil, err + } + + result := make(map[string]*config.Config, len(configList.Items)) + for i := range configList.Items { + cfg := &configList.Items[i] + result[cfg.Name] = cfg + } + return result, nil +} diff --git a/apis/config/target_cleardeviation_types.go b/apis/config/target_cleardeviation_types.go index 4a576da5..dbcf07a3 100644 --- a/apis/config/target_cleardeviation_types.go +++ b/apis/config/target_cleardeviation_types.go @@ -25,9 +25,9 @@ type TargetClearDeviationSpec struct { // IncludeConfigs when true includes all existing configs in the transaction, // not just the ones referenced by Config. // +kubebuilder:default=false - IncludeAllConfigs *bool `json:"includeAllConfigs,omitempty" protobuf:"bytes,1,opt,name=includeAllConfigs"` + IncludeAllConfigs *bool `json:"includeAllConfigs,omitempty" protobuf:"bytes,2,opt,name=includeAllConfigs"` // Config defines the clear deviations configs to applied on the taget - Config []TargetClearDeviationConfig `json:"config" protobuf:"bytes,2,rep,name=config"` + Config []TargetClearDeviationConfig `json:"config" protobuf:"bytes,3,rep,name=config"` } type TargetClearDeviationConfig struct { diff --git a/apis/config/target_helpers.go b/apis/config/target_helpers.go index 0adf9189..66b21c65 100644 --- a/apis/config/target_helpers.go +++ b/apis/config/target_helpers.go @@ -222,8 +222,15 @@ func (r *Target) ClearDeviations(ctx context.Context, c client.Client, req *Targ return nil, apierrors.NewBadRequest("spec is required") } + // Use spec namespace if provided, otherwise target's namespace + lookupNamespace := r.Namespace + + if configLister == nil { + return nil, apierrors.NewInternalError(fmt.Errorf("config lister not initialized")) + } + // Fetch existing configs for the target - configsByName, err := listConfigsByTarget(ctx, c, r) + configsByName, err := configLister(ctx, c, r.Namespace, r.Name, lookupNamespace) if err != nil { return nil, err } @@ -258,28 +265,6 @@ func (r *Target) ClearDeviations(ctx context.Context, c client.Client, req *Targ }, nil } -// listConfigsByIntent fetches all configs for a target and indexes them -// by their intent name (GetGVKNSN). This is the same key the dataserver uses. -func listConfigsByTarget(ctx context.Context, c client.Client, target *Target) (map[string]*Config, error) { - configList := &ConfigList{} - if err := c.List(ctx, configList, - client.InNamespace(target.Namespace), - client.MatchingLabels{ - TargetNamespaceKey: target.Namespace, - TargetNameKey: target.Name, - }, - ); err != nil { - return nil, err - } - - result := make(map[string]*Config, len(configList.Items)) - for i := range configList.Items { - cfg := &configList.Items[i] - result[cfg.Name] = cfg - } - return result, nil -} - // buildClearDeviationTxRequest constructs the TransactionSetRequest from // the clear deviation configs. It validates that every requested config name // exists as a known intent. Unknown names are returned as validation errors. @@ -491,3 +476,4 @@ func GetIntentUpdate(config *Config, useSpec bool) ([]*sdcpb.Update, error) { } return update, nil } + diff --git a/apis/config/target_resource.go b/apis/config/target_resource.go index c6abbf6f..0db7e980 100644 --- a/apis/config/target_resource.go +++ b/apis/config/target_resource.go @@ -54,6 +54,15 @@ func SetSubResourceClient(c client.Client) { subResourceClient = c } +// ConfigListerFn lists configs for a target, returning them indexed by name. +type ConfigListerFn func(ctx context.Context, c client.Client, targetNamespace, targetName, lookupNamespace string) (map[string]*Config, error) + +var configLister ConfigListerFn + +func SetConfigLister(fn ConfigListerFn) { + configLister = fn +} + // +k8s:deepcopy-gen=false var _ resource.InternalObject = &Target{} var _ resource.ObjectList = &TargetList{} diff --git a/apis/config/v1alpha1/target_cleardeviation_types.go b/apis/config/v1alpha1/target_cleardeviation_types.go index bf68e6c4..7cee2045 100644 --- a/apis/config/v1alpha1/target_cleardeviation_types.go +++ b/apis/config/v1alpha1/target_cleardeviation_types.go @@ -25,9 +25,9 @@ type TargetClearDeviationSpec struct { // IncludeConfigs when true includes all existing configs in the transaction, // not just the ones referenced by Config. // +kubebuilder:default=false - IncludeAllConfigs *bool `json:"includeAllConfigs,omitempty" protobuf:"bytes,1,opt,name=includeAllConfigs"` + IncludeAllConfigs *bool `json:"includeAllConfigs,omitempty" protobuf:"bytes,2,opt,name=includeAllConfigs"` // Config defines the clear deviations configs to applied on the taget - Config []TargetClearDeviationConfig `json:"config" protobuf:"bytes,2,rep,name=config"` + Config []TargetClearDeviationConfig `json:"config" protobuf:"bytes,3,rep,name=config"` } type TargetClearDeviationConfig struct { diff --git a/cmd/api-server/main.go b/cmd/api-server/main.go index c0ffefbd..03895e00 100644 --- a/cmd/api-server/main.go +++ b/cmd/api-server/main.go @@ -32,8 +32,6 @@ import ( sdcconfig "github.com/sdcio/config-server/apis/config" "github.com/sdcio/config-server/apis/config/handlers" configv1alpha1 "github.com/sdcio/config-server/apis/config/v1alpha1" - - //invv1alpha1 "github.com/sdcio/config-server/apis/inv/v1alpha1" "github.com/sdcio/config-server/pkg/generated/openapi" _ "github.com/sdcio/config-server/pkg/reconcilers/all" configblameregistry "github.com/sdcio/config-server/pkg/registry/configblame" @@ -126,7 +124,9 @@ func main() { os.Exit(1) } + // setting client for subresources config.SetSubResourceClient(mgr.GetClient()) + config.SetConfigLister(handlers.ListConfigsByTarget) registryOptions := &options.Options{ Prefix: configDir, From bb4a2fb5a6d5c741fc446d8a04b09c502bc9e326 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Thu, 5 Mar 2026 05:50:23 +0100 Subject: [PATCH 122/135] fix lin issue --- cmd/api-server/main.go | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/cmd/api-server/main.go b/cmd/api-server/main.go index 03895e00..1abf63f5 100644 --- a/cmd/api-server/main.go +++ b/cmd/api-server/main.go @@ -28,7 +28,6 @@ import ( "github.com/henderiw/apiserver-builder/pkg/builder" "github.com/henderiw/apiserver-store/pkg/db/badgerdb" "github.com/henderiw/logger/log" - "github.com/sdcio/config-server/apis/config" sdcconfig "github.com/sdcio/config-server/apis/config" "github.com/sdcio/config-server/apis/config/handlers" configv1alpha1 "github.com/sdcio/config-server/apis/config/v1alpha1" @@ -125,8 +124,8 @@ func main() { } // setting client for subresources - config.SetSubResourceClient(mgr.GetClient()) - config.SetConfigLister(handlers.ListConfigsByTarget) + sdcconfig.SetSubResourceClient(mgr.GetClient()) + sdcconfig.SetConfigLister(handlers.ListConfigsByTarget) registryOptions := &options.Options{ Prefix: configDir, From 2a49fa6cfa41a92281366f9d510ea984e140fb3f Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Thu, 5 Mar 2026 14:37:25 +0100 Subject: [PATCH 123/135] updated sdc proto --- go.mod | 2 +- go.sum | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/go.mod b/go.mod index 5703da00..fa257f3b 100644 --- a/go.mod +++ b/go.mod @@ -20,7 +20,7 @@ require ( github.com/prometheus/client_golang v1.23.2 github.com/prometheus/client_model v0.6.2 github.com/prometheus/prometheus v0.309.1 - github.com/sdcio/sdc-protos v0.0.51-0.20260224122709-ca10362f11ba + github.com/sdcio/sdc-protos v0.0.51-0.20260304120533-f0e62d96331e github.com/spf13/cobra v1.10.2 github.com/stretchr/testify v1.11.1 go.opentelemetry.io/otel v1.39.0 diff --git a/go.sum b/go.sum index 26fc2174..344b6ca3 100644 --- a/go.sum +++ b/go.sum @@ -270,8 +270,8 @@ github.com/rogpeppe/go-internal v1.14.1/go.mod h1:MaRKkUm5W0goXpeCfT7UZI6fk/L7L7 github.com/russross/blackfriday/v2 v2.1.0/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM= github.com/sdcio/logger v0.0.3 h1:IFUbObObGry+S8lHGwOQKKRxJSuOphgRU/hxVhOdMOM= github.com/sdcio/logger v0.0.3/go.mod h1:yWaOxK/G6vszjg8tKZiMqiEjlZouHsjFME4zSk+SAEA= -github.com/sdcio/sdc-protos v0.0.51-0.20260224122709-ca10362f11ba h1:WcWzmAzwXWYBvmbJRTbgFR55W30kx7TKBdLPpAndB7c= -github.com/sdcio/sdc-protos v0.0.51-0.20260224122709-ca10362f11ba/go.mod h1:huh1QVE023w+reU2Gt6h1f83R3lJidcFLbQje7cMY1M= +github.com/sdcio/sdc-protos v0.0.51-0.20260304120533-f0e62d96331e h1:oe0q40PuBLd4M7X9D5UHnfhN0Tv/RXZE/eQOKOSIlCw= +github.com/sdcio/sdc-protos v0.0.51-0.20260304120533-f0e62d96331e/go.mod h1:huh1QVE023w+reU2Gt6h1f83R3lJidcFLbQje7cMY1M= github.com/sergi/go-diff v1.3.2-0.20230802210424-5b0b94c5c0d3 h1:n661drycOFuPLCN3Uc8sB6B/s6Z4t2xvBgU1htSHuq8= github.com/sergi/go-diff v1.3.2-0.20230802210424-5b0b94c5c0d3/go.mod h1:A0bzQcvG0E7Rwjx0REVgAGH58e96+X0MeOfepqsbeW4= github.com/sirupsen/logrus v1.7.0/go.mod h1:yWOB1SBYBC5VeMP7gHvWumXLIWorT60ONWic61uBYv0= From 4f6af3cd1fe50cc545450f60c491d81be524e496 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Fri, 6 Mar 2026 13:06:47 +0100 Subject: [PATCH 124/135] update dataserver address --- cmd/controller/main.go | 2 +- pkg/sdc/dataserver/client/client.go | 45 ++++++++++++++++++++--------- 2 files changed, 33 insertions(+), 14 deletions(-) diff --git a/cmd/controller/main.go b/cmd/controller/main.go index 09a20e83..ca31d002 100644 --- a/cmd/controller/main.go +++ b/cmd/controller/main.go @@ -135,7 +135,7 @@ func main() { if IsLocalDataServerEnabled() { // Create the DS connection manager and register it with controller-runtime. dsCfg := &dsclient.Config{ - Address: dsclient.GetDataServerAddress(), + Address: dsclient.GetLocalDataServerAddress(), // Insecure/TLS settings etc if needed } dsConnMgr := dsmanager.New(ctx, dsCfg) diff --git a/pkg/sdc/dataserver/client/client.go b/pkg/sdc/dataserver/client/client.go index 4810d7f5..50208522 100644 --- a/pkg/sdc/dataserver/client/client.go +++ b/pkg/sdc/dataserver/client/client.go @@ -31,21 +31,40 @@ import ( //"google.golang.org/grpc/keepalive" ) -const dataServerAddress = "data-server.sdc-system.svc.cluster.local:56000" -const localDataServerAddress = "localhost:56000" +const ( + defaultDataServerService = "data-server" + defaultDataServerPort = "56000" + defaultNamespace = "sdc-system" +) func GetDataServerAddress() string { - if address, found := os.LookupEnv("SDC_DATA_SERVER"); found { - return address - } - return dataServerAddress + return getDataServerAddress(false) } func GetLocalDataServerAddress() string { + return getDataServerAddress(true) +} + +func getDataServerAddress(local bool) string { if address, found := os.LookupEnv("SDC_DATA_SERVER"); found { - return address + return address + } + + ns := envOrDefault("POD_NAMESPACE", defaultNamespace) + svc := envOrDefault("SDC_DATA_SERVER_SERVICE", defaultDataServerService) + port := envOrDefault("SDC_DATA_SERVER_PORT", defaultDataServerPort) + + if local { + fmt.Sprintf("localhost:%s", port) } - return localDataServerAddress + return fmt.Sprintf("%s.%s.svc.cluster.local:%s", svc, ns, port) +} + +func envOrDefault(key, fallback string) string { + if v, ok := os.LookupEnv(key); ok && v != "" { + return v + } + return fallback } type Config struct { @@ -62,7 +81,7 @@ type Config struct { MaxMsgSize int } -func defaukltConfig(cfg *Config) { +func defaultConfig(cfg *Config) { if cfg == nil { cfg = &Config{Address: GetDataServerAddress()} } @@ -99,7 +118,7 @@ func OneShot( cfg *Config, fn func(ctx context.Context, c sdcpb.DataServerClient) error, ) error { - defaukltConfig(cfg) + defaultConfig(cfg) conn, err := dial(ctx, cfg) if err != nil { return err @@ -144,7 +163,7 @@ func NewEphemeral( ctx context.Context, cfg *Config, ) (sdcpb.DataServerClient, func() error, error) { - defaukltConfig(cfg) + defaultConfig(cfg) conn, err := dial(ctx, cfg) if err != nil { return nil, nil, err @@ -171,7 +190,7 @@ type Client interface { } func New(cfg *Config) (Client, error) { - defaukltConfig(cfg) + defaultConfig(cfg) // default cancel is a no-op so Stop() is always safe return &client{cfg: cfg, cancel: func() {}}, nil } @@ -188,7 +207,7 @@ const DSConnectionStatusNotConnected = "DATASERVER_NOT_CONNECTED" // dial creates a gRPC connection with a timeout and proper options, // using the modern grpc.NewClient API. func dial(ctx context.Context, cfg *Config) (*grpc.ClientConn, error) { - defaukltConfig(cfg) + defaultConfig(cfg) dialCtx, cancel := context.WithTimeout(ctx, 10*time.Second) defer cancel() From 74b62e0c492a4fd0f34b8750eb0fce87a4fa9f21 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Fri, 6 Mar 2026 13:15:14 +0100 Subject: [PATCH 125/135] update deviaton type --- pkg/sdc/target/manager/deviation_watcher.go | 1 + 1 file changed, 1 insertion(+) diff --git a/pkg/sdc/target/manager/deviation_watcher.go b/pkg/sdc/target/manager/deviation_watcher.go index 72526992..7f055587 100644 --- a/pkg/sdc/target/manager/deviation_watcher.go +++ b/pkg/sdc/target/manager/deviation_watcher.go @@ -245,6 +245,7 @@ func (r *DeviationWatcher) processConfigDeviations( applyConfig := configv1alpha1apply.Deviation(nsn.Name, nsn.Namespace). WithSpec(configv1alpha1apply.DeviationSpec(). + WithDeviationType(configv1alpha1.DeviationType_CONFIG). WithDeviations(configDeviationsToApply(deviations)...), ) From 036f632d2a7b786ba6f5fcc77ac495ebbb4daff6 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Fri, 6 Mar 2026 14:14:00 +0100 Subject: [PATCH 126/135] add targetClearDeviationKind --- apis/config/v1alpha1/target_cleardeviation_types.go | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/apis/config/v1alpha1/target_cleardeviation_types.go b/apis/config/v1alpha1/target_cleardeviation_types.go index 7cee2045..f8f2699c 100644 --- a/apis/config/v1alpha1/target_cleardeviation_types.go +++ b/apis/config/v1alpha1/target_cleardeviation_types.go @@ -17,6 +17,8 @@ limitations under the License. package v1alpha1 import ( + "reflect" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" ) @@ -70,3 +72,7 @@ type TargetClearDeviation struct { Spec *TargetClearDeviationSpec `json:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"` Status *TargetClearDeviationStatus `json:"status,omitempty" protobuf:"bytes,3,opt,name=status"` } + +var ( + TargetClearDeviationKind = reflect.TypeOf(TargetClearDeviation{}).Name() +) From e2e0b3dfc82f66eb858c57c81f8b2186f920703f Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Fri, 6 Mar 2026 14:19:13 +0100 Subject: [PATCH 127/135] fix local address --- apis/config/target_cleardeviation_types.go | 6 ++++++ apis/config/target_configblame_types.go | 6 ++++++ apis/config/target_runningconfig_types.go | 6 ++++++ apis/config/v1alpha1/target_configblame_types.go | 6 ++++++ apis/config/v1alpha1/target_runningconfig_types.go | 8 +++++++- pkg/sdc/dataserver/client/client.go | 2 +- 6 files changed, 32 insertions(+), 2 deletions(-) diff --git a/apis/config/target_cleardeviation_types.go b/apis/config/target_cleardeviation_types.go index dbcf07a3..899e0282 100644 --- a/apis/config/target_cleardeviation_types.go +++ b/apis/config/target_cleardeviation_types.go @@ -17,6 +17,8 @@ limitations under the License. package config import ( + "reflect" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" ) @@ -70,3 +72,7 @@ type TargetClearDeviation struct { Spec *TargetClearDeviationSpec `json:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"` Status *TargetClearDeviationStatus `json:"status,omitempty" protobuf:"bytes,3,opt,name=status"` } + +var ( + TargetClearDeviationKind = reflect.TypeOf(TargetClearDeviation{}).Name() +) diff --git a/apis/config/target_configblame_types.go b/apis/config/target_configblame_types.go index e5462353..48d97861 100644 --- a/apis/config/target_configblame_types.go +++ b/apis/config/target_configblame_types.go @@ -17,6 +17,8 @@ limitations under the License. package config import ( + "reflect" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/apimachinery/pkg/runtime" ) @@ -32,3 +34,7 @@ type TargetConfigBlame struct { //+kubebuilder:pruning:PreserveUnknownFields Value runtime.RawExtension `json:"value" protobuf:"bytes,2,opt,name=value"` } + +var ( + TargetConfigBlameKind = reflect.TypeOf(TargetConfigBlame{}).Name() +) diff --git a/apis/config/target_runningconfig_types.go b/apis/config/target_runningconfig_types.go index 89d75430..28bf0e20 100644 --- a/apis/config/target_runningconfig_types.go +++ b/apis/config/target_runningconfig_types.go @@ -17,6 +17,8 @@ limitations under the License. package config import ( + "reflect" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/apimachinery/pkg/runtime" ) @@ -67,3 +69,7 @@ func ParseTargetFormat(s string) TargetFormat { return Format_JSON } } + +var ( + TargetRunningConfigKind = reflect.TypeOf(TargetRunningConfig{}).Name() +) diff --git a/apis/config/v1alpha1/target_configblame_types.go b/apis/config/v1alpha1/target_configblame_types.go index b9981579..c189215a 100644 --- a/apis/config/v1alpha1/target_configblame_types.go +++ b/apis/config/v1alpha1/target_configblame_types.go @@ -17,6 +17,8 @@ limitations under the License. package v1alpha1 import ( + "reflect" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/apimachinery/pkg/runtime" ) @@ -32,3 +34,7 @@ type TargetConfigBlame struct { //+kubebuilder:pruning:PreserveUnknownFields Value runtime.RawExtension `json:"value" protobuf:"bytes,2,opt,name=value"` } + +var ( + TargetConfigBlameKind = reflect.TypeOf(TargetConfigBlame{}).Name() +) diff --git a/apis/config/v1alpha1/target_runningconfig_types.go b/apis/config/v1alpha1/target_runningconfig_types.go index 685a6821..1aa5adc3 100644 --- a/apis/config/v1alpha1/target_runningconfig_types.go +++ b/apis/config/v1alpha1/target_runningconfig_types.go @@ -17,6 +17,8 @@ limitations under the License. package v1alpha1 import ( + "reflect" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/apimachinery/pkg/runtime" ) @@ -56,4 +58,8 @@ const ( Format_JSON_IETF TargetFormat = "json_ietf" Format_XML TargetFormat = "xml" Format_PROTO TargetFormat = "proto" -) \ No newline at end of file +) + +var ( + TargetRunningConfigKind = reflect.TypeOf(TargetRunningConfig{}).Name() +) diff --git a/pkg/sdc/dataserver/client/client.go b/pkg/sdc/dataserver/client/client.go index 50208522..60f5167d 100644 --- a/pkg/sdc/dataserver/client/client.go +++ b/pkg/sdc/dataserver/client/client.go @@ -55,7 +55,7 @@ func getDataServerAddress(local bool) string { port := envOrDefault("SDC_DATA_SERVER_PORT", defaultDataServerPort) if local { - fmt.Sprintf("localhost:%s", port) + return fmt.Sprintf("localhost:%s", port) } return fmt.Sprintf("%s.%s.svc.cluster.local:%s", svc, ns, port) } From 8579bb8fee2d773ddba7b683bc3244bd045a4e53 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Fri, 6 Mar 2026 14:20:58 +0100 Subject: [PATCH 128/135] update force deviation updata --- pkg/sdc/target/manager/deviation_watcher.go | 1 + 1 file changed, 1 insertion(+) diff --git a/pkg/sdc/target/manager/deviation_watcher.go b/pkg/sdc/target/manager/deviation_watcher.go index 7f055587..2780b5bc 100644 --- a/pkg/sdc/target/manager/deviation_watcher.go +++ b/pkg/sdc/target/manager/deviation_watcher.go @@ -253,6 +253,7 @@ func (r *DeviationWatcher) processConfigDeviations( if err := r.client.Apply(ctx, applyConfig, &client.ApplyOptions{ FieldManager: fieldManagerDeviation, + Force: ptr.To(true), }); err != nil { log.Error("cannot update intent for received deviation", "config", nsn, "err", err) } From db4da69664158920022fbd329aa22a7d7cc6e0bd Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Fri, 6 Mar 2026 14:52:27 +0100 Subject: [PATCH 129/135] fix revertive flag in config set --- apis/config/handlers/confighandler.go | 14 ++++++++------ pkg/reconcilers/configset/reconciler.go | 3 ++- pkg/sdc/target/manager/deviation_watcher.go | 5 +++++ pkg/sdc/target/manager/transactor.go | 2 +- 4 files changed, 16 insertions(+), 8 deletions(-) diff --git a/apis/config/handlers/confighandler.go b/apis/config/handlers/confighandler.go index a3dc9e80..6f8266a6 100644 --- a/apis/config/handlers/confighandler.go +++ b/apis/config/handlers/confighandler.go @@ -47,9 +47,10 @@ func (r *ConfigStoreHandler) DryRunCreateFn(ctx context.Context, key types.Names intents := []*sdcpb.TransactionIntent{ { - Intent: config.GetGVKNSN(c), - Priority: int32(c.Spec.Priority), - Update: updates, + Intent: config.GetGVKNSN(c), + Priority: int32(c.Spec.Priority), + Update: updates, + // Dont set not Revertive }, } @@ -68,9 +69,10 @@ func (r *ConfigStoreHandler) DryRunUpdateFn(ctx context.Context, key types.Names intents := []*sdcpb.TransactionIntent{ { - Intent: config.GetGVKNSN(c), - Priority: int32(c.Spec.Priority), - Update: updates, + Intent: config.GetGVKNSN(c), + Priority: int32(c.Spec.Priority), + Update: updates, + // Dont set not Revertive }, } diff --git a/pkg/reconcilers/configset/reconciler.go b/pkg/reconcilers/configset/reconciler.go index b38c22de..308f3555 100644 --- a/pkg/reconcilers/configset/reconciler.go +++ b/pkg/reconcilers/configset/reconciler.go @@ -333,7 +333,7 @@ func buildConfig(_ context.Context, configSet *configv1alpha1.ConfigSet, target Kind: configSet.Kind, Name: configSet.Name, UID: configSet.UID, - Controller: ptr.To[bool](true), + Controller: ptr.To(true), }, }, }, @@ -341,6 +341,7 @@ func buildConfig(_ context.Context, configSet *configv1alpha1.ConfigSet, target Lifecycle: configSet.Spec.Lifecycle, Priority: configSet.Spec.Priority, Config: configSet.Spec.Config, + Revertive: configSet.Spec.Revertive, }, configv1alpha1.ConfigStatus{}, ) diff --git a/pkg/sdc/target/manager/deviation_watcher.go b/pkg/sdc/target/manager/deviation_watcher.go index 2780b5bc..4754b83b 100644 --- a/pkg/sdc/target/manager/deviation_watcher.go +++ b/pkg/sdc/target/manager/deviation_watcher.go @@ -26,6 +26,7 @@ import ( "github.com/henderiw/apiserver-store/pkg/storebackend" "github.com/henderiw/logger/log" "github.com/pkg/errors" + "github.com/sdcio/config-server/apis/config" configv1alpha1 "github.com/sdcio/config-server/apis/config/v1alpha1" configv1alpha1apply "github.com/sdcio/config-server/pkg/generated/applyconfiguration/config/v1alpha1" dsclient "github.com/sdcio/config-server/pkg/sdc/dataserver/client" @@ -244,6 +245,10 @@ func (r *DeviationWatcher) processConfigDeviations( }) applyConfig := configv1alpha1apply.Deviation(nsn.Name, nsn.Namespace). + WithLabels(map[string]string{ + config.TargetNameKey: r.key.Name, + config.TargetNamespaceKey: r.key.Namespace, + }). WithSpec(configv1alpha1apply.DeviationSpec(). WithDeviationType(configv1alpha1.DeviationType_CONFIG). WithDeviations(configDeviationsToApply(deviations)...), diff --git a/pkg/sdc/target/manager/transactor.go b/pkg/sdc/target/manager/transactor.go index 57973bd5..63770424 100644 --- a/pkg/sdc/target/manager/transactor.go +++ b/pkg/sdc/target/manager/transactor.go @@ -307,10 +307,10 @@ func (r *Transactor) setIntents( configsToDeleteSet.Insert(key) intents = append(intents, &sdcpb.TransactionIntent{ Intent: config.GetGVKNSN(cfg), - //Priority: int32(config.Spec.Priority), Delete: true, DeleteIgnoreNoExist: true, Orphan: cfg.Orphan(), + // Dont set priority, dont set non revertive }) } From 14eb585878bb15858ba8ccde2a7c68e227bf4a40 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Fri, 6 Mar 2026 20:32:11 +0100 Subject: [PATCH 130/135] combined cleardeviation and deviation content in 1 transaction --- apis/config/target_cleardeviation_types.go | 6 +-- apis/config/target_helpers.go | 49 +++++++++---------- .../v1alpha1/target_cleardeviation_types.go | 6 +-- .../v1alpha1/zz_generated.conversion.go | 2 - apis/config/v1alpha1/zz_generated.deepcopy.go | 5 -- apis/config/zz_generated.deepcopy.go | 5 -- pkg/generated/openapi/zz_generated.openapi.go | 7 --- 7 files changed, 25 insertions(+), 55 deletions(-) diff --git a/apis/config/target_cleardeviation_types.go b/apis/config/target_cleardeviation_types.go index 899e0282..879cbde6 100644 --- a/apis/config/target_cleardeviation_types.go +++ b/apis/config/target_cleardeviation_types.go @@ -24,12 +24,8 @@ import ( // TargetClearDeviationSpec defines the desired state of Target type TargetClearDeviationSpec struct { - // IncludeConfigs when true includes all existing configs in the transaction, - // not just the ones referenced by Config. - // +kubebuilder:default=false - IncludeAllConfigs *bool `json:"includeAllConfigs,omitempty" protobuf:"bytes,2,opt,name=includeAllConfigs"` // Config defines the clear deviations configs to applied on the taget - Config []TargetClearDeviationConfig `json:"config" protobuf:"bytes,3,rep,name=config"` + Config []TargetClearDeviationConfig `json:"config" protobuf:"bytes,1,rep,name=config"` } type TargetClearDeviationConfig struct { diff --git a/apis/config/target_helpers.go b/apis/config/target_helpers.go index 66b21c65..2937dfe2 100644 --- a/apis/config/target_helpers.go +++ b/apis/config/target_helpers.go @@ -287,6 +287,15 @@ func buildClearDeviationTxRequest( continue } + if cfg.IsRevertive() { + validationErrors = append(validationErrors, TargetClearDeviationConfigResult{ + Name: clearCfg.Name, + Success: false, + Errors: []string{fmt.Sprintf("config %q is revertive for target %s, not expecting clearDeviations", clearCfg.Name, targetKey.Name)}, + }) + continue + } + revertPaths := make([]*sdcpb.Path, 0, len(clearCfg.Paths)) var pathErrors []string for _, p := range clearCfg.Paths { @@ -306,11 +315,22 @@ func buildClearDeviationTxRequest( }) continue } + update, err := GetIntentUpdate(cfg, true) + if err != nil { + validationErrors = append(validationErrors, TargetClearDeviationConfigResult{ + Name: clearCfg.Name, + Success: false, + Errors: []string{fmt.Sprintf("failed to build intent update for config %q: %v", clearCfg.Name, err)}, + }) + continue + } intents = append(intents, &sdcpb.TransactionIntent{ - Intent: GetGVKNSN(cfg), - Priority: int32(cfg.Spec.Priority), - RevertPaths: revertPaths, + Intent: GetGVKNSN(cfg), + Priority: int32(cfg.Spec.Priority), + RevertPaths: revertPaths, + Update: update, + NonRevertive: !cfg.IsRevertive(), }) } @@ -319,28 +339,6 @@ func buildClearDeviationTxRequest( return nil, validationErrors } - // If IncludeAllConfigs, add configs as no-op intents - // so the dataserver evaluates reverts in the full context - if spec.IncludeAllConfigs != nil && *spec.IncludeAllConfigs { - for name, cfg := range configsByName { - update, err := GetIntentUpdate(cfg, true) - if err != nil { - validationErrors = append(validationErrors, TargetClearDeviationConfigResult{ - Name: name, - Success: false, - Errors: []string{fmt.Sprintf("failed to build intent update for config %q: %v", name, err)}, - }) - continue - } - intents = append(intents, &sdcpb.TransactionIntent{ - Intent: GetGVKNSN(cfg), - Priority: int32(cfg.Spec.Priority), - Update: update, - NonRevertive: !cfg.IsRevertive(), - }) - } - } - return &sdcpb.TransactionSetRequest{ TransactionId: uuid.New().String(), DatastoreName: storebackend.KeyFromNSN(targetKey).String(), @@ -476,4 +474,3 @@ func GetIntentUpdate(config *Config, useSpec bool) ([]*sdcpb.Update, error) { } return update, nil } - diff --git a/apis/config/v1alpha1/target_cleardeviation_types.go b/apis/config/v1alpha1/target_cleardeviation_types.go index f8f2699c..79107efb 100644 --- a/apis/config/v1alpha1/target_cleardeviation_types.go +++ b/apis/config/v1alpha1/target_cleardeviation_types.go @@ -24,12 +24,8 @@ import ( // TargetClearDeviationSpec defines the desired state of Target type TargetClearDeviationSpec struct { - // IncludeConfigs when true includes all existing configs in the transaction, - // not just the ones referenced by Config. - // +kubebuilder:default=false - IncludeAllConfigs *bool `json:"includeAllConfigs,omitempty" protobuf:"bytes,2,opt,name=includeAllConfigs"` // Config defines the clear deviations configs to applied on the taget - Config []TargetClearDeviationConfig `json:"config" protobuf:"bytes,3,rep,name=config"` + Config []TargetClearDeviationConfig `json:"config" protobuf:"bytes,1,rep,name=config"` } type TargetClearDeviationConfig struct { diff --git a/apis/config/v1alpha1/zz_generated.conversion.go b/apis/config/v1alpha1/zz_generated.conversion.go index 754c609d..139a4c24 100644 --- a/apis/config/v1alpha1/zz_generated.conversion.go +++ b/apis/config/v1alpha1/zz_generated.conversion.go @@ -1528,7 +1528,6 @@ func Convert_config_TargetClearDeviationConfigResult_To_v1alpha1_TargetClearDevi } func autoConvert_v1alpha1_TargetClearDeviationSpec_To_config_TargetClearDeviationSpec(in *TargetClearDeviationSpec, out *config.TargetClearDeviationSpec, s conversion.Scope) error { - out.IncludeAllConfigs = (*bool)(unsafe.Pointer(in.IncludeAllConfigs)) out.Config = *(*[]config.TargetClearDeviationConfig)(unsafe.Pointer(&in.Config)) return nil } @@ -1539,7 +1538,6 @@ func Convert_v1alpha1_TargetClearDeviationSpec_To_config_TargetClearDeviationSpe } func autoConvert_config_TargetClearDeviationSpec_To_v1alpha1_TargetClearDeviationSpec(in *config.TargetClearDeviationSpec, out *TargetClearDeviationSpec, s conversion.Scope) error { - out.IncludeAllConfigs = (*bool)(unsafe.Pointer(in.IncludeAllConfigs)) out.Config = *(*[]TargetClearDeviationConfig)(unsafe.Pointer(&in.Config)) return nil } diff --git a/apis/config/v1alpha1/zz_generated.deepcopy.go b/apis/config/v1alpha1/zz_generated.deepcopy.go index e913b710..4a61c239 100644 --- a/apis/config/v1alpha1/zz_generated.deepcopy.go +++ b/apis/config/v1alpha1/zz_generated.deepcopy.go @@ -955,11 +955,6 @@ func (in *TargetClearDeviationConfigResult) DeepCopy() *TargetClearDeviationConf // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *TargetClearDeviationSpec) DeepCopyInto(out *TargetClearDeviationSpec) { *out = *in - if in.IncludeAllConfigs != nil { - in, out := &in.IncludeAllConfigs, &out.IncludeAllConfigs - *out = new(bool) - **out = **in - } if in.Config != nil { in, out := &in.Config, &out.Config *out = make([]TargetClearDeviationConfig, len(*in)) diff --git a/apis/config/zz_generated.deepcopy.go b/apis/config/zz_generated.deepcopy.go index 8530213f..471474a0 100644 --- a/apis/config/zz_generated.deepcopy.go +++ b/apis/config/zz_generated.deepcopy.go @@ -1214,11 +1214,6 @@ func (in *TargetClearDeviationConfigResult) DeepCopy() *TargetClearDeviationConf // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *TargetClearDeviationSpec) DeepCopyInto(out *TargetClearDeviationSpec) { *out = *in - if in.IncludeAllConfigs != nil { - in, out := &in.IncludeAllConfigs, &out.IncludeAllConfigs - *out = new(bool) - **out = **in - } if in.Config != nil { in, out := &in.Config, &out.Config *out = make([]TargetClearDeviationConfig, len(*in)) diff --git a/pkg/generated/openapi/zz_generated.openapi.go b/pkg/generated/openapi/zz_generated.openapi.go index 9ef0badb..306b917b 100644 --- a/pkg/generated/openapi/zz_generated.openapi.go +++ b/pkg/generated/openapi/zz_generated.openapi.go @@ -2177,13 +2177,6 @@ func schema_config_server_apis_config_v1alpha1_TargetClearDeviationSpec(ref comm Description: "TargetClearDeviationSpec defines the desired state of Target", Type: []string{"object"}, Properties: map[string]spec.Schema{ - "includeAllConfigs": { - SchemaProps: spec.SchemaProps{ - Description: "IncludeConfigs when true includes all existing configs in the transaction, not just the ones referenced by Config.", - Type: []string{"boolean"}, - Format: "", - }, - }, "config": { SchemaProps: spec.SchemaProps{ Description: "Config defines the clear deviations configs to applied on the taget", From 594c967cfdd8a707400000c3359036038769119a Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Wed, 11 Mar 2026 08:36:09 -0700 Subject: [PATCH 131/135] fix typ for deviation reporting --- pkg/sdc/target/manager/deviation_watcher.go | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/pkg/sdc/target/manager/deviation_watcher.go b/pkg/sdc/target/manager/deviation_watcher.go index 4754b83b..09a25496 100644 --- a/pkg/sdc/target/manager/deviation_watcher.go +++ b/pkg/sdc/target/manager/deviation_watcher.go @@ -215,8 +215,10 @@ func (r *DeviationWatcher) processDeviations(ctx context.Context, deviations map configDevs := ConvertSdcpbDeviations2ConfigDeviations(ctx, devs) nsn := r.key.NamespacedName + typ := configv1alpha1.DeviationType_CONFIG if configName == unManagedConfigDeviation { log.Info("target device deviations", "devs", len(configDevs)) + typ = configv1alpha1.DeviationType_TARGET } else { parts := strings.SplitN(configName, ".", 2) nsn = types.NamespacedName{ @@ -229,7 +231,7 @@ func (r *DeviationWatcher) processDeviations(ctx context.Context, deviations map } log.Info("config deviations", "nsn", nsn, "devs", len(configDevs)) } - r.processConfigDeviations(ctx, nsn, configDevs) + r.processConfigDeviations(ctx, nsn, configDevs, typ) } } @@ -237,6 +239,7 @@ func (r *DeviationWatcher) processConfigDeviations( ctx context.Context, nsn types.NamespacedName, deviations []configv1alpha1.ConfigDeviation, + typ configv1alpha1.DeviationType, ) { log := log.FromContext(ctx) @@ -250,7 +253,7 @@ func (r *DeviationWatcher) processConfigDeviations( config.TargetNamespaceKey: r.key.Namespace, }). WithSpec(configv1alpha1apply.DeviationSpec(). - WithDeviationType(configv1alpha1.DeviationType_CONFIG). + WithDeviationType(typ). WithDeviations(configDeviationsToApply(deviations)...), ) From adb809a42fe1ce819c53dc76feab24c5c3f534c4 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Fri, 13 Mar 2026 18:26:17 +0100 Subject: [PATCH 132/135] Update apis/config/v1alpha1/condition.go Co-authored-by: Alexander North --- apis/config/v1alpha1/condition.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/apis/config/v1alpha1/condition.go b/apis/config/v1alpha1/condition.go index 03d69411..b825e61a 100644 --- a/apis/config/v1alpha1/condition.go +++ b/apis/config/v1alpha1/condition.go @@ -108,7 +108,7 @@ func TargetForConfigReady(msg string) condv1alpha1.Condition { }} } -// ConfigFailed returns a condition that indicates the config +// TargetForConfigFailed returns a condition that indicates the config // is in failed condition due to a dependency func TargetForConfigFailed(msg string) condv1alpha1.Condition { return condv1alpha1.Condition{Condition: metav1.Condition{ From 0607599cb7e828494a8726e3779be3ce63fc6cc5 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Fri, 13 Mar 2026 18:26:50 +0100 Subject: [PATCH 133/135] Update apis/config/v1alpha1/condition.go Co-authored-by: Alexander North --- apis/config/v1alpha1/condition.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/apis/config/v1alpha1/condition.go b/apis/config/v1alpha1/condition.go index b825e61a..c90593da 100644 --- a/apis/config/v1alpha1/condition.go +++ b/apis/config/v1alpha1/condition.go @@ -132,7 +132,7 @@ func TargetDatastoreReady() condv1alpha1.Condition { }} } -// DatastoreFailed returns a condition that indicates the datastore +// TargetDatastoreFailed returns a condition that indicates the datastore // failed to get reconciled. func TargetDatastoreFailed(msg string) condv1alpha1.Condition { return condv1alpha1.Condition{Condition: metav1.Condition{ From 6c08a312ebf8c0f8346e9c6bf39448dea7a2d962 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Fri, 13 Mar 2026 18:27:07 +0100 Subject: [PATCH 134/135] Update apis/config/v1alpha1/target_resource.go Co-authored-by: Alexander North --- apis/config/v1alpha1/target_resource.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/apis/config/v1alpha1/target_resource.go b/apis/config/v1alpha1/target_resource.go index 6d14a0d7..68a346da 100644 --- a/apis/config/v1alpha1/target_resource.go +++ b/apis/config/v1alpha1/target_resource.go @@ -53,7 +53,7 @@ func (Target) IsStorageVersion() bool { return false } -// NamespaceScoped returns true to indicate Fortune is a namespaced resource. +// NamespaceScoped returns true to indicate Target is a namespaced resource. // NamespaceScoped implements resource.Object func (Target) NamespaceScoped() bool { return true From 8ce22fc77422c7c9c75c10ae6b47c2d469981aa1 Mon Sep 17 00:00:00 2001 From: Wim Henderickx Date: Fri, 13 Mar 2026 18:36:45 +0100 Subject: [PATCH 135/135] review comments alex --- apis/config/condition.go | 7 ------- apis/config/v1alpha1/condition.go | 4 ---- apis/config/v1alpha1/target_resource.go | 2 +- tools/apiserver-runtime-gen/main.go | 2 +- 4 files changed, 2 insertions(+), 13 deletions(-) diff --git a/apis/config/condition.go b/apis/config/condition.go index 5c25b5b9..15e15f95 100644 --- a/apis/config/condition.go +++ b/apis/config/condition.go @@ -36,13 +36,6 @@ const ( ConditionTypeTargetConfigRecoveryReady cond.ConditionType = "TargetConfigRecoveryReady" // ConditionTypeTargetConnectionReady represents the resource target ready condition ConditionTypeTargetConnectionReady cond.ConditionType = "TargetConnectionReady" - - //ConditionTypeConfigApply cond.ConditionType = "ConfigApply" - //ConditionTypeConfigConfirm cond.ConditionType = "ConfigConfirm" - //ConditionTypeConfigCancel cond.ConditionType = "ConfigCancel" - - //ConditionTypeSchemaServerReady cond.ConditionType = "SchemaServerReady" - ) // A ConditionReason represents the reason a resource is in a condition. diff --git a/apis/config/v1alpha1/condition.go b/apis/config/v1alpha1/condition.go index c90593da..6b4d5c22 100644 --- a/apis/config/v1alpha1/condition.go +++ b/apis/config/v1alpha1/condition.go @@ -40,12 +40,8 @@ const ( // Reasons a resource is ready or not const ( - //ConditionReasonDeleting condv1alpha1.ConditionReason = "deleting" ConditionReasonCreating condv1alpha1.ConditionReason = "creating" ConditionReasonUpdating condv1alpha1.ConditionReason = "updating" - //ConditionReasonTargetDeleted condv1alpha1.ConditionReason = "target Deleted" - //ConditionReasonTargetNotReady condv1alpha1.ConditionReason = "target not ready" - //ConditionReasonTargetNotFound condv1alpha1.ConditionReason = "target not found" ) // Creating returns a condition that indicates a create transaction diff --git a/apis/config/v1alpha1/target_resource.go b/apis/config/v1alpha1/target_resource.go index 68a346da..fe81a18b 100644 --- a/apis/config/v1alpha1/target_resource.go +++ b/apis/config/v1alpha1/target_resource.go @@ -47,7 +47,7 @@ func (Target) GetGroupVersionResource() schema.GroupVersionResource { } } -// IsStorageVersion returns true -- Target is used as the internal version. +// IsStorageVersion returns false -- Target is used as the internal version. // IsStorageVersion implements resource.Object func (Target) IsStorageVersion() bool { return false diff --git a/tools/apiserver-runtime-gen/main.go b/tools/apiserver-runtime-gen/main.go index 366682fa..6a38ca4b 100644 --- a/tools/apiserver-runtime-gen/main.go +++ b/tools/apiserver-runtime-gen/main.go @@ -65,7 +65,7 @@ func runE(cmd *cobra.Command, args []string) error { for _, gen := range generators { // nolint:gosec if gen == "openapi-gen" { - err := run(exec.Command("go", "install", "k8s.io/kube-openapi/cmd/openapi-gen")) + err := run(exec.Command("go", "install", "k8s.io/kube-openapi/cmd/openapi-gen@latest")) if err != nil { return err }