Skip to content

Commit

Permalink
Generate remaining CRDs based on vendored APIs (gardener#8560)
Browse files Browse the repository at this point in the history
* Generate `druid.gardener.cloud` CRDs based on vendored `etcd-druid` version

* Generate HVPA `autoscaling.k8s.io` CRDs based on vendored `hvpa-controller` version

* Rename VPA CRD files

For better/easier Git diff in next commit

* Generate VPA `autoscaling.k8s.io` CRDs based on vendored `autoscaler` version

* Remove `/scale` subresource from `etcds.druid.gardener.cloud` CRD

/scale subresource is intentionally removed from this CRD, although it is specified in the original CRD from etcd-druid, due to adverse interaction with VPA.
See gardener#6850 and gardener#8560 (comment)

* Vendor `github.com/gardener/etcd-druid@v1.20.1`

follow-up of gardener#8605
  • Loading branch information
rfranzke authored Oct 6, 2023
1 parent c29e975 commit e5c479e
Show file tree
Hide file tree
Showing 35 changed files with 1,132 additions and 965 deletions.
2 changes: 1 addition & 1 deletion example/operator/doc.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.

//go:generate ../../hack/generate-crds.sh 10-crd- -allow-dangerous-types operator.gardener.cloud
//go:generate ../../hack/generate-crds.sh -p 10-crd- --allow-dangerous-types operator.gardener.cloud
//go:generate cp 10-crd-operator.gardener.cloud_gardens.yaml ../../charts/gardener/operator/templates/customresouredefintion.yaml

// Package operator contains example manifests for working on operator.
Expand Down
2 changes: 1 addition & 1 deletion example/resource-manager/doc.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.

//go:generate ../../hack/generate-crds.sh 10-crd- resources.gardener.cloud
//go:generate ../../hack/generate-crds.sh -p 10-crd- resources.gardener.cloud

// Package resource_manager contains example manifests for working on resource-manager.
package resource_manager
Original file line number Diff line number Diff line change
@@ -0,0 +1,110 @@
---
apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
annotations:
api-approved.kubernetes.io: unapproved, temporarily squatting
controller-gen.kubebuilder.io/version: v0.13.0
name: verticalpodautoscalercheckpoints.autoscaling.k8s.io
spec:
group: autoscaling.k8s.io
names:
kind: VerticalPodAutoscalerCheckpoint
listKind: VerticalPodAutoscalerCheckpointList
plural: verticalpodautoscalercheckpoints
shortNames:
- vpacheckpoint
singular: verticalpodautoscalercheckpoint
scope: Namespaced
versions:
- name: v1
schema:
openAPIV3Schema:
description: VerticalPodAutoscalerCheckpoint is the checkpoint of the internal
state of VPA that is used for recovery after recommender's restart.
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: 'Specification of the checkpoint. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status.'
properties:
containerName:
description: Name of the checkpointed container.
type: string
vpaObjectName:
description: Name of the VPA object that stored VerticalPodAutoscalerCheckpoint
object.
type: string
type: object
status:
description: Data of the checkpoint.
properties:
cpuHistogram:
description: Checkpoint of histogram for consumption of CPU.
properties:
bucketWeights:
description: Map from bucket index to bucket weight.
type: object
x-kubernetes-preserve-unknown-fields: true
referenceTimestamp:
description: Reference timestamp for samples collected within
this histogram.
format: date-time
nullable: true
type: string
totalWeight:
description: Sum of samples to be used as denominator for weights
from BucketWeights.
type: object
firstSampleStart:
description: Timestamp of the fist sample from the histograms.
format: date-time
nullable: true
type: string
lastSampleStart:
description: Timestamp of the last sample from the histograms.
format: date-time
nullable: true
type: string
lastUpdateTime:
description: The time when the status was last refreshed.
format: date-time
nullable: true
type: string
memoryHistogram:
description: Checkpoint of histogram for consumption of memory.
properties:
bucketWeights:
description: Map from bucket index to bucket weight.
type: object
x-kubernetes-preserve-unknown-fields: true
referenceTimestamp:
description: Reference timestamp for samples collected within
this histogram.
format: date-time
nullable: true
type: string
totalWeight:
description: Sum of samples to be used as denominator for weights
from BucketWeights.
type: object
totalSamplesCount:
description: Total number of samples in the histograms.
type: integer
version:
description: Version of the format of the stored data.
type: string
type: object
type: object
served: true
storage: true
Loading

0 comments on commit e5c479e

Please sign in to comment.