diff --git a/charts/eks/templates/syncer.yaml b/charts/eks/templates/syncer.yaml index 97762c487..ea437f179 100644 --- a/charts/eks/templates/syncer.yaml +++ b/charts/eks/templates/syncer.yaml @@ -266,14 +266,14 @@ spec: {{- if .Values.coredns.integrated }} - --integrated-coredns=true {{- end }} - {{- if .Values.admission.validatingWebhooks }} - {{- range .Values.admission.validatingWebhooks }} - - --enforce-validating-hook={{ . | b64enc }} + {{- if .Values.centralAdmission.validatingWebhooks }} + {{- range .Values.centralAdmission.validatingWebhooks }} + - --enforce-validating-hook={{ . | toYaml | b64enc }} {{- end }} {{- end }} - {{- if .Values.admission.mutatingWebhooks }} - {{- range .Values.admission.mutatingWebhooks }} - - --enforce-mutating-hook={{ . | b64enc }} + {{- if .Values.centralAdmission.mutatingWebhooks }} + {{- range .Values.centralAdmission.mutatingWebhooks }} + - --enforce-mutating-hook={{ . | toYaml | b64enc }} {{- end }} {{- end }} {{- if and .Values.coredns.integrated .Values.coredns.plugin.enabled }} diff --git a/charts/eks/values.yaml b/charts/eks/values.yaml index c3fbfd582..a58206882 100644 --- a/charts/eks/values.yaml +++ b/charts/eks/values.yaml @@ -486,7 +486,7 @@ multiNamespaceMode: # list of {validating/mutating}webhooks that the syncer should proxy. # This is a PRO only feature. -admission: +centralAdmission: validatingWebhooks: [] mutatingWebhooks: [] diff --git a/charts/k0s/templates/syncer.yaml b/charts/k0s/templates/syncer.yaml index b620d58d0..443120f8f 100644 --- a/charts/k0s/templates/syncer.yaml +++ b/charts/k0s/templates/syncer.yaml @@ -206,14 +206,14 @@ spec: {{- if and .Values.coredns.integrated .Values.coredns.plugin.enabled }} - --use-coredns-plugin=true {{- end }} - {{- if .Values.admission.validatingWebhooks }} - {{- range .Values.admission.validatingWebhooks }} - - --enforce-validating-hook={{ . | b64enc }} + {{- if .Values.centralAdmission.validatingWebhooks }} + {{- range .Values.centralAdmission.validatingWebhooks }} + - --enforce-validating-hook={{ . | toYaml | b64enc }} {{- end }} {{- end }} - {{- if .Values.admission.mutatingWebhooks }} - {{- range .Values.admission.mutatingWebhooks }} - - --enforce-mutating-hook={{ . | b64enc }} + {{- if .Values.centralAdmission.mutatingWebhooks }} + {{- range .Values.centralAdmission.mutatingWebhooks }} + - --enforce-mutating-hook={{ . | toYaml | b64enc }} {{- end }} {{- end }} {{- range $f := .Values.syncer.extraArgs }} diff --git a/charts/k0s/values.yaml b/charts/k0s/values.yaml index 0f7ff3786..8026e9259 100644 --- a/charts/k0s/values.yaml +++ b/charts/k0s/values.yaml @@ -493,7 +493,7 @@ multiNamespaceMode: # list of {validating/mutating}webhooks that the syncer should proxy. # This is a PRO only feature. -admission: +centralAdmission: validatingWebhooks: [] mutatingWebhooks: [] diff --git a/charts/k3s/templates/syncer.yaml b/charts/k3s/templates/syncer.yaml index db1901ebb..a20e589a4 100644 --- a/charts/k3s/templates/syncer.yaml +++ b/charts/k3s/templates/syncer.yaml @@ -264,14 +264,14 @@ spec: - --sync-k8s-service=true {{- end }} {{- end }} - {{- if .Values.admission.validatingWebhooks }} - {{- range .Values.admission.validatingWebhooks }} - - --enforce-validating-hook={{ . | b64enc }} + {{- if .Values.centralAdmission.validatingWebhooks }} + {{- range .Values.centralAdmission.validatingWebhooks }} + - --enforce-validating-hook={{ . | toYaml | b64enc }} {{- end }} {{- end }} - {{- if .Values.admission.mutatingWebhooks }} - {{- range .Values.admission.mutatingWebhooks }} - - --enforce-mutating-hook={{ . | b64enc }} + {{- if .Values.centralAdmission.mutatingWebhooks }} + {{- range .Values.centralAdmission.mutatingWebhooks }} + - --enforce-mutating-hook={{ . | toYaml | b64enc }} {{- end }} {{- end }} {{- range $f := .Values.syncer.extraArgs }} diff --git a/charts/k3s/values.yaml b/charts/k3s/values.yaml index f2134d43d..c97fdd53a 100644 --- a/charts/k3s/values.yaml +++ b/charts/k3s/values.yaml @@ -211,7 +211,7 @@ embeddedEtcd: # list of {validating/mutating}webhooks that the syncer should proxy. # This is a PRO only feature. -admission: +centralAdmission: validatingWebhooks: [] mutatingWebhooks: [] diff --git a/charts/k8s/templates/syncer.yaml b/charts/k8s/templates/syncer.yaml index f82cabc98..13a9eb311 100644 --- a/charts/k8s/templates/syncer.yaml +++ b/charts/k8s/templates/syncer.yaml @@ -286,14 +286,14 @@ spec: {{- if and .Values.coredns.integrated .Values.coredns.plugin.enabled }} - --use-coredns-plugin=true {{- end }} - {{- if .Values.admission.validatingWebhooks }} - {{- range .Values.admission.validatingWebhooks }} - - --enforce-validating-hook={{ . | b64enc }} + {{- if .Values.centralAdmission.validatingWebhooks }} + {{- range .Values.centralAdmission.validatingWebhooks }} + - --enforce-validating-hook={{ . | toYaml | b64enc }} {{- end }} {{- end }} - {{- if .Values.admission.mutatingWebhooks }} - {{- range .Values.admission.mutatingWebhooks }} - - --enforce-mutating-hook={{ . | b64enc }} + {{- if .Values.centralAdmission.mutatingWebhooks }} + {{- range .Values.centralAdmission.mutatingWebhooks }} + - --enforce-mutating-hook={{ . | toYaml | b64enc }} {{- end }} {{- end }} {{- range $f := .Values.syncer.extraArgs }} diff --git a/charts/k8s/values.yaml b/charts/k8s/values.yaml index 7afcc999c..5ce7d620c 100644 --- a/charts/k8s/values.yaml +++ b/charts/k8s/values.yaml @@ -504,7 +504,7 @@ multiNamespaceMode: # list of {validating/mutating}webhooks that the syncer should proxy. # This is a PRO only feature. -admission: +centralAdmission: validatingWebhooks: [] mutatingWebhooks: [] diff --git a/go.mod b/go.mod index d11fb29c3..c2df9fcfd 100644 --- a/go.mod +++ b/go.mod @@ -20,7 +20,7 @@ require ( github.com/loft-sh/api/v3 v3.0.0-20240202135831-33c4357035e6 github.com/loft-sh/loftctl/v3 v3.0.0-20240202135933-6548c1e817a7 github.com/loft-sh/utils v0.0.29 - github.com/loft-sh/vcluster-values v0.0.0-20240202091012-8385efc731ba + github.com/loft-sh/vcluster-values v0.0.0-20240207073754-18fb56471594 github.com/mgutz/ansi v0.0.0-20200706080929-d51e80ef957d github.com/mitchellh/go-homedir v1.1.0 github.com/moby/locker v1.0.1 diff --git a/go.sum b/go.sum index 97163e48c..de87a2afe 100644 --- a/go.sum +++ b/go.sum @@ -643,8 +643,8 @@ github.com/loft-sh/log v0.0.0-20230824104949-bd516c25712a h1:/gqqjKpcHEdFXIX41lx github.com/loft-sh/log v0.0.0-20230824104949-bd516c25712a/go.mod h1:YImeRjXH34Yf5E79T7UHBQpDZl9fIaaFRgyZ/bkY+UQ= github.com/loft-sh/utils v0.0.29 h1:P/MObccXToAZy2QoJSQDJ+OJx1qHitpFHEVj3QBSNJs= github.com/loft-sh/utils v0.0.29/go.mod h1:9hlX9cGpWHg3mNi/oBlv3X4ePGDMK66k8MbOZGFMDTI= -github.com/loft-sh/vcluster-values v0.0.0-20240202091012-8385efc731ba h1:0euB0vEWBPofSOtYnqbn6O2wNGYEklaz3vEzh0qgpag= -github.com/loft-sh/vcluster-values v0.0.0-20240202091012-8385efc731ba/go.mod h1:J34xtWyMbjM+NRgVWxO0IVDB5XYUaX52jPQNqEAhu4M= +github.com/loft-sh/vcluster-values v0.0.0-20240207073754-18fb56471594 h1:w98N8zTBD0Upvk1LPJFotq66ACFwiE9AgTuNyEkSGLk= +github.com/loft-sh/vcluster-values v0.0.0-20240207073754-18fb56471594/go.mod h1:J34xtWyMbjM+NRgVWxO0IVDB5XYUaX52jPQNqEAhu4M= github.com/magiconair/properties v1.8.1/go.mod h1:PppfXfuXeibc/6YijjN8zIbojt8czPbwD3XqdrwzmxQ= github.com/magiconair/properties v1.8.5/go.mod h1:y3VJvCyxH9uVvJTWEGAELF3aiYNyPKd5NZ3oSwXrF60= github.com/mailru/easyjson v0.0.0-20160728113105-d5b7844b561a/go.mod h1:C1wdFJiN94OJF2b5HbByQZoLdCWB1Yqtg26g4irojpc= diff --git a/vendor/github.com/loft-sh/vcluster-values/helmvalues/common.go b/vendor/github.com/loft-sh/vcluster-values/helmvalues/common.go index 83cea3e27..2827b1851 100644 --- a/vendor/github.com/loft-sh/vcluster-values/helmvalues/common.go +++ b/vendor/github.com/loft-sh/vcluster-values/helmvalues/common.go @@ -60,7 +60,7 @@ type BaseHelm struct { Telemetry TelemetryValues `json:"telemetry,omitempty"` NoopSyncer NoopSyncerValues `json:"noopSyncer,omitempty"` Monitoring MonitoringValues `json:"monitoring,omitempty"` - Admission AdmissionValues `json:"admission,omitempty"` + CentralAdmission AdmissionValues `json:"centralAdmission,omitempty"` } type SyncerValues struct { @@ -354,8 +354,8 @@ type NoopSyncerValues struct { } type AdmissionValues struct { - ValidatingWebhooks []string `json:"validatingWebhooks,omitempty"` - MutatingWebhooks []string `json:"mutatingWebhooks,omitempty"` + ValidatingWebhooks []map[string]interface{} `json:"validatingWebhooks,omitempty"` + MutatingWebhooks []map[string]interface{} `json:"mutatingWebhooks,omitempty"` } type ControlPlaneCommonValues struct { diff --git a/vendor/github.com/loft-sh/vcluster-values/helmvalues/k0s.go b/vendor/github.com/loft-sh/vcluster-values/helmvalues/k0s.go index f6a7991e6..36faf4da8 100644 --- a/vendor/github.com/loft-sh/vcluster-values/helmvalues/k0s.go +++ b/vendor/github.com/loft-sh/vcluster-values/helmvalues/k0s.go @@ -2,7 +2,8 @@ package helmvalues type K0s struct { BaseHelm - AutoDeletePersistentVolumeClaims bool `json:"autoDeletePersistentVolumeClaims,omitempty"` - VCluster VClusterValues `json:"vcluster,omitempty"` - Syncer SyncerValues `json:"syncer,omitempty"` + AutoDeletePersistentVolumeClaims bool `json:"autoDeletePersistentVolumeClaims,omitempty"` + VCluster VClusterValues `json:"vcluster,omitempty"` + Syncer SyncerValues `json:"syncer,omitempty"` + EmbeddedEtcd EmbeddedEtcdValues `json:"embeddedEtcd,omitempty"` } diff --git a/vendor/modules.txt b/vendor/modules.txt index c55516ca7..2c57dcb00 100644 --- a/vendor/modules.txt +++ b/vendor/modules.txt @@ -432,7 +432,7 @@ github.com/loft-sh/utils/pkg/command github.com/loft-sh/utils/pkg/downloader github.com/loft-sh/utils/pkg/downloader/commands github.com/loft-sh/utils/pkg/extract -# github.com/loft-sh/vcluster-values v0.0.0-20240202091012-8385efc731ba +# github.com/loft-sh/vcluster-values v0.0.0-20240207073754-18fb56471594 ## explicit; go 1.21.5 github.com/loft-sh/vcluster-values/helmvalues github.com/loft-sh/vcluster-values/values