Skip to content

Commit

Permalink
Sync charts with latest changes (gardener#31)
Browse files Browse the repository at this point in the history
* Update VPA's `apiVersion`

from `autoscaling.k8s.io/v1beta2` to `autoscaling.k8s.io/v1`

Similar to gardener/gardener-extension-provider-aws@5c0592e

* Add liveness and readiness probe to the extension Pods

Similar to gardener/gardener-extension-provider-aws#497

* Remove `minAllowed.cpu` from the registry-cache extension and admission VPAs

Similar to gardener/gardener-extension-provider-aws#711

* Make the `gardener-extension-registry-cache-admission` Service topology-aware

Similar to gardener/gardener-extension-provider-aws#732 and gardener/gardener-extension-provider-aws#750

* Make the metrics port configurable

Follow-up after gardener#12

* Adapt `NetworkPolicy`s for the admission

Similar to gardener/gardener-extension-provider-aws@02182f9
  • Loading branch information
ialidzhikov authored Sep 4, 2023
1 parent 3bd9dd5 commit 815bb0c
Show file tree
Hide file tree
Showing 12 changed files with 61 additions and 11 deletions.
3 changes: 3 additions & 0 deletions charts/admission/charts/runtime/templates/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,9 @@ spec:
checksum/secret-kubeconfig: {{ include (print $.Template.BasePath "/secret-kubeconfig.yaml") . | sha256sum }}
{{- end }}
labels:
# TODO(ialidzhikov): Double check whether we need these NetworkPolicy labels.
networking.gardener.cloud/to-dns: allowed
networking.resources.gardener.cloud/to-virtual-garden-kube-apiserver-tcp-443: allowed
{{ include "labels" . | indent 8 }}
spec:
{{- if not .Values.global.virtualGarden.enabled }}
Expand Down
12 changes: 12 additions & 0 deletions charts/admission/charts/runtime/templates/service.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,20 @@ kind: Service
metadata:
name: {{ include "name" . }}
namespace: {{ .Release.Namespace }}
annotations:
networking.resources.gardener.cloud/from-all-webhook-targets-allowed-ports: '[{"protocol":"TCP","port":{{ .Values.global.webhookConfig.serverPort }}}]'
{{- if .Values.global.service.topologyAwareRouting.enabled }}
{{- if semverCompare ">= 1.27-0" .Capabilities.KubeVersion.GitVersion }}
service.kubernetes.io/topology-mode: "auto"
{{- else }}
service.kubernetes.io/topology-aware-hints: "auto"
{{- end }}
{{- end }}
labels:
{{ include "labels" . | indent 4 }}
{{- if .Values.global.service.topologyAwareRouting.enabled }}
endpoint-slice-hints.resources.gardener.cloud/consider: "true"
{{- end }}
spec:
type: ClusterIP
selector:
Expand Down
1 change: 0 additions & 1 deletion charts/admission/charts/runtime/templates/vpa.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@ spec:
containerPolicies:
- containerName: '*'
minAllowed:
cpu: {{ required ".Values.global.vpa.resourcePolicy.minAllowed.cpu is required" .Values.global.vpa.resourcePolicy.minAllowed.cpu }}
memory: {{ required ".Values.global.vpa.resourcePolicy.minAllowed.memory is required" .Values.global.vpa.resourcePolicy.minAllowed.memory }}
{{- end }}
targetRef:
Expand Down
4 changes: 3 additions & 1 deletion charts/admission/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,6 @@ global:
enabled: true
resourcePolicy:
minAllowed:
cpu: 50m
memory: 64Mi
updatePolicy:
updateMode: "Auto"
Expand All @@ -42,3 +41,6 @@ global:
enabled: false
expirationSeconds: 43200
audience: ""
service:
topologyAwareRouting:
enabled: false
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,10 @@ spec:
- --webhook-config-namespace={{ .Release.Namespace }}
- --webhook-config-service-port={{ .Values.webhookConfig.servicePort }}
- --webhook-config-server-port={{ .Values.webhookConfig.serverPort }}
{{- if .Values.metrics.port }}
- --metrics-bind-address=:{{ .Values.metrics.port }}
{{- end }}
- --health-bind-address=:{{ .Values.healthPort }}
- --gardener-version={{ .Values.gardener.version }}
env:
- name: LEADER_ELECTION_NAMESPACE
Expand All @@ -63,11 +67,23 @@ spec:
- name: IMAGEVECTOR_OVERWRITE
value: /charts_overwrite/images_overwrite.yaml
{{- end }}
{{- if .Values.resources }}
livenessProbe:
httpGet:
path: /healthz
port: {{ .Values.healthPort }}
scheme: HTTP
initialDelaySeconds: 10
readinessProbe:
httpGet:
path: /readyz
port: {{ .Values.healthPort }}
scheme: HTTP
initialDelaySeconds: 5
ports:
- name: webhook-server
containerPort: {{ .Values.webhookConfig.serverPort }}
protocol: TCP
{{- if .Values.resources }}
resources:
{{ toYaml .Values.resources | trim | indent 10 }}
{{- end }}
Expand Down
3 changes: 1 addition & 2 deletions charts/gardener-extension-registry-cache/templates/vpa.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{{- if .Values.vpa.enabled}}
apiVersion: "autoscaling.k8s.io/v1beta2"
apiVersion: autoscaling.k8s.io/v1
kind: VerticalPodAutoscaler
metadata:
name: gardener-extension-registry-cache-vpa
Expand All @@ -10,7 +10,6 @@ spec:
containerPolicies:
- containerName: '*'
minAllowed:
cpu: {{ required ".Values.vpa.resourcePolicy.minAllowed.cpu is required" .Values.vpa.resourcePolicy.minAllowed.cpu }}
memory: {{ required ".Values.vpa.resourcePolicy.minAllowed.memory is required" .Values.vpa.resourcePolicy.minAllowed.memory }}
{{- end }}
targetRef:
Expand Down
3 changes: 2 additions & 1 deletion charts/gardener-extension-registry-cache/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20,11 +20,12 @@ vpa:
enabled: true
# resourcePolicy:
# minAllowed:
# cpu: 100m
# memory: 128Mi
updatePolicy:
updateMode: "Auto"

healthPort: 8081

controllers:
concurrentSyncs: 5
ignoreOperationAnnotation: false
Expand Down
2 changes: 1 addition & 1 deletion charts/registration/templates/controller-registration.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ metadata:
name: extension-registry-cache
type: helm
providerConfig:
chart: H4sIAAAAAAAAA+0ca2/jNnI/61fwlBa7W0TyI46zp0OB8yZpG9xuEsRpiqIoFrRE22pkUUdKzrrbvd9+w4dkSrbjR9Kki2oQxDZFDocznAeHpEaYBSQmzCEfUxLzkMYOI6OQp2zm+Ngfk8aLB0MT4OjwUH4CVD/l99ZBp9U+bHe7orzVbXcPXqDDh3e9HjKeYobQC0Zpel+9d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8DapGNELGKasLarS8x63kAoT3EsvWsHVTKIng2oGFfV4Pw5A4mw4H+9zQbRcS4ZgBFqG2e/K2WKVtjHI2Cwsg8MlM+Uoefn3/z3CoOlMyipK/CdPOIygzWI0wdQS7fz2RvJspdYnFVU7EGKlraW4azpmX9ZQFFRFeeLFx3wUeUr1zyWR622cd0qnSvyVFVos7aGJGkGIVZ2V3Wq73c4KnV4U8Hu+2/eg3TfV4Ausv+947q539a3ePm/X+PAuqqhTSQxetIfERydxIwYeLL6aFfebt8HZqxs7xiGOSrs2TMIExKatzQOB9f0Gwg3hcI1saqnp/3DTMtjtD7xe6VZV55E4dyrOUuF/r02bKeIU4ysbnM5Zuz9Or6FSLuxEW8WJ6PFkjmaZZXlixdU/RcXcuXZyyfFQcIC6zCUqVU3PWSbwVcvvNL3QuyiiX5m9ablmWB5VsiDw2sq/7o2YpveVbxLO3Om/fRTqtrCwdsW9by2LEkBXhmXKbQL2Awr6OoI8YbL1kUca0IsfXen6+uh6y7O+KjoxayrEoCwbfKe0WKqm73SBcVZ5Pbrc6xFK6aTst2uqT00A5yXdeyVq+c+OjfP4vpsO5MqriwLTiqjrH71jPt6pW/KzrVxUCYFM+VoRXG2wHLNySKV8CZP8rmpjqt4Jb6YXfcN24bRFWolK82U/XLd+3GFzbQQAMNNNBAAw000EADDTTQQAMNNNBAAw000EADd4P/AXifyUQAeAAA
values:
{{ toYaml .Values.values | indent 4 }}

Expand Down
6 changes: 3 additions & 3 deletions cmd/gardener-extension-registry-cache-admission/app/app.go
Original file line number Diff line number Diff line change
Expand Up @@ -79,15 +79,15 @@ func NewAdmissionCommand(ctx context.Context) *cobra.Command {
}

if err := mgr.AddReadyzCheck("informer-sync", gardenerhealthz.NewCacheSyncHealthz(mgr.GetCache())); err != nil {
return fmt.Errorf("could not add readycheck for informers: %w", err)
return fmt.Errorf("could not add ready check for informers: %w", err)
}

if err := mgr.AddHealthzCheck("ping", healthz.Ping); err != nil {
return fmt.Errorf("could not add healthcheck: %w", err)
return fmt.Errorf("could not add health check to manager: %w", err)
}

if err := mgr.AddReadyzCheck("webhook-server", mgr.GetWebhookServer().StartedChecker()); err != nil {
return fmt.Errorf("could not add readycheck of webhook to manager: %w", err)
return fmt.Errorf("could not add ready check for webhook server to manager: %w", err)
}

return mgr.Start(ctx)
Expand Down
14 changes: 14 additions & 0 deletions cmd/gardener-extension-registry-cache/app/app.go
Original file line number Diff line number Diff line change
Expand Up @@ -21,10 +21,12 @@ import (
extensionscontroller "github.com/gardener/gardener/extensions/pkg/controller"
"github.com/gardener/gardener/extensions/pkg/controller/heartbeat"
"github.com/gardener/gardener/extensions/pkg/util"
gardenerhealthz "github.com/gardener/gardener/pkg/healthz"
"github.com/spf13/cobra"
corev1 "k8s.io/api/core/v1"
componentbaseconfig "k8s.io/component-base/config"
"sigs.k8s.io/controller-runtime/pkg/client"
"sigs.k8s.io/controller-runtime/pkg/healthz"
"sigs.k8s.io/controller-runtime/pkg/manager"

registryinstall "github.com/gardener/gardener-extension-registry-cache/pkg/apis/registry/install"
Expand Down Expand Up @@ -99,6 +101,18 @@ func (o *Options) run(ctx context.Context) error {
return fmt.Errorf("could not add the mutating webhook to manager: %s", err)
}

if err := mgr.AddReadyzCheck("informer-sync", gardenerhealthz.NewCacheSyncHealthz(mgr.GetCache())); err != nil {
return fmt.Errorf("could not add ready check for informers: %w", err)
}

if err := mgr.AddHealthzCheck("ping", healthz.Ping); err != nil {
return fmt.Errorf("could not add health check to manager: %w", err)
}

if err := mgr.AddReadyzCheck("webhook-server", mgr.GetWebhookServer().StartedChecker()); err != nil {
return fmt.Errorf("could not add ready check for webhook server to manager: %w", err)
}

if err := mgr.Start(ctx); err != nil {
return fmt.Errorf("error running manager: %w", err)
}
Expand Down
4 changes: 4 additions & 0 deletions cmd/gardener-extension-registry-cache/app/options.go
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,10 @@ func NewOptions() *Options {
LeaderElectionID: controllercmd.LeaderElectionNameID(ExtensionName),
LeaderElectionResourceLock: resourcelock.LeasesResourceLock,
LeaderElectionNamespace: os.Getenv("LEADER_ELECTION_NAMESPACE"),
WebhookServerPort: 443,
WebhookCertDir: "/tmp/gardener-extensions-cert",
MetricsBindAddress: ":8080",
HealthBindAddress: ":8081",
},
controllerOptions: &controllercmd.ControllerOptions{
// This is a default value.
Expand Down
Loading

0 comments on commit 815bb0c

Please sign in to comment.