diff --git a/Makefile.core.mk b/Makefile.core.mk index afcf3a071..cfac5866e 100644 --- a/Makefile.core.mk +++ b/Makefile.core.mk @@ -23,6 +23,7 @@ VERSION ?= 1.1.0 MINOR_VERSION := $(shell echo "${VERSION}" | cut -f1,2 -d'.') OPERATOR_NAME ?= sailoperator +VERSIONS_YAML_DIR ?= pkg/istioversion VERSIONS_YAML_FILE ?= versions.yaml # Istio images names @@ -53,6 +54,7 @@ LD_EXTRAFLAGS = -X ${GO_MODULE}/pkg/version.buildVersion=${VERSION} LD_EXTRAFLAGS += -X ${GO_MODULE}/pkg/version.buildGitRevision=${GIT_REVISION} LD_EXTRAFLAGS += -X ${GO_MODULE}/pkg/version.buildTag=${GIT_TAG} LD_EXTRAFLAGS += -X ${GO_MODULE}/pkg/version.buildStatus=${GIT_STATUS} +LD_EXTRAFLAGS += -X ${GO_MODULE}/pkg/istioversion.versionsFilename=${VERSIONS_YAML_FILE} IS_FIPS_COMPLIANT ?= false # set to true for FIPS compliance ifeq ($(IS_FIPS_COMPLIANT), true) @@ -389,7 +391,7 @@ gen-charts: ## Pull charts from istio repository. @# use yq to generate a list of download-charts.sh commands for each version in versions.yaml; these commands are @# passed to sh and executed; in a nutshell, the yq command generates commands like: @# ./hack/download-charts.sh [chart1] [chart2] ... - @yq eval '.versions[] | "./hack/download-charts.sh " + .name + " " + .repo + " " + .commit + " " + ((.charts // []) | join(" "))' < $(VERSIONS_YAML_FILE) | sh + @yq eval '.versions[] | "./hack/download-charts.sh " + .name + " " + .repo + " " + .commit + " " + ((.charts // []) | join(" "))' < $(VERSIONS_YAML_DIR)/$(VERSIONS_YAML_FILE) | sh @# remove old version directories @hack/remove-old-versions.sh diff --git a/api/v1/istio_types.go b/api/v1/istio_types.go index 5cb6626ae..4ac42daac 100644 --- a/api/v1/istio_types.go +++ b/api/v1/istio_types.go @@ -37,9 +37,9 @@ const ( type IstioSpec struct { // +sail:version // Defines the version of Istio to install. - // Must be one of: v1.24.2, v1.24.1, v1.24.0, v1.23.4, v1.23.3, v1.23.2, v1.22.8, v1.22.7, v1.22.6, v1.22.5, v1.21.6, latest. - // +operator-sdk:csv:customresourcedefinitions:type=spec,order=1,displayName="Istio Version",xDescriptors={"urn:alm:descriptor:com.tectonic.ui:fieldGroup:General", "urn:alm:descriptor:com.tectonic.ui:select:v1.24.2", "urn:alm:descriptor:com.tectonic.ui:select:v1.24.1", "urn:alm:descriptor:com.tectonic.ui:select:v1.24.0", "urn:alm:descriptor:com.tectonic.ui:select:v1.23.4", "urn:alm:descriptor:com.tectonic.ui:select:v1.23.3", "urn:alm:descriptor:com.tectonic.ui:select:v1.23.2", "urn:alm:descriptor:com.tectonic.ui:select:v1.22.8", "urn:alm:descriptor:com.tectonic.ui:select:v1.22.7", "urn:alm:descriptor:com.tectonic.ui:select:v1.22.6", "urn:alm:descriptor:com.tectonic.ui:select:v1.22.5", "urn:alm:descriptor:com.tectonic.ui:select:v1.21.6", "urn:alm:descriptor:com.tectonic.ui:select:latest"} - // +kubebuilder:validation:Enum=v1.24.2;v1.24.1;v1.24.0;v1.23.4;v1.23.3;v1.23.2;v1.22.8;v1.22.7;v1.22.6;v1.22.5;v1.21.6;latest + // Must be one of: v1.24-latest, v1.24.2, v1.24.1, v1.24.0, v1.23-latest, v1.23.4, v1.23.3, v1.23.2, v1.22-latest, v1.22.8, v1.22.7, v1.22.6, v1.22.5, v1.21.6, master, v1.25-alpha.c2ac935c. + // +operator-sdk:csv:customresourcedefinitions:type=spec,order=1,displayName="Istio Version",xDescriptors={"urn:alm:descriptor:com.tectonic.ui:fieldGroup:General", "urn:alm:descriptor:com.tectonic.ui:select:v1.24-latest", "urn:alm:descriptor:com.tectonic.ui:select:v1.24.2", "urn:alm:descriptor:com.tectonic.ui:select:v1.24.1", "urn:alm:descriptor:com.tectonic.ui:select:v1.24.0", "urn:alm:descriptor:com.tectonic.ui:select:v1.23-latest", "urn:alm:descriptor:com.tectonic.ui:select:v1.23.4", "urn:alm:descriptor:com.tectonic.ui:select:v1.23.3", "urn:alm:descriptor:com.tectonic.ui:select:v1.23.2", "urn:alm:descriptor:com.tectonic.ui:select:v1.22-latest", "urn:alm:descriptor:com.tectonic.ui:select:v1.22.8", "urn:alm:descriptor:com.tectonic.ui:select:v1.22.7", "urn:alm:descriptor:com.tectonic.ui:select:v1.22.6", "urn:alm:descriptor:com.tectonic.ui:select:v1.22.5", "urn:alm:descriptor:com.tectonic.ui:select:v1.21.6", "urn:alm:descriptor:com.tectonic.ui:select:master", "urn:alm:descriptor:com.tectonic.ui:select:v1.25-alpha.c2ac935c"} + // +kubebuilder:validation:Enum=v1.24-latest;v1.24.2;v1.24.1;v1.24.0;v1.23-latest;v1.23.4;v1.23.3;v1.23.2;v1.22-latest;v1.22.8;v1.22.7;v1.22.6;v1.22.5;v1.21.6;master;v1.25-alpha.c2ac935c // +kubebuilder:default=v1.24.2 Version string `json:"version"` diff --git a/api/v1/istiocni_types.go b/api/v1/istiocni_types.go index f601066ee..18eda7719 100644 --- a/api/v1/istiocni_types.go +++ b/api/v1/istiocni_types.go @@ -28,9 +28,9 @@ const ( type IstioCNISpec struct { // +sail:version // Defines the version of Istio to install. - // Must be one of: v1.24.2, v1.24.1, v1.24.0, v1.23.4, v1.23.3, v1.23.2, v1.22.8, v1.22.7, v1.22.6, v1.22.5, v1.21.6, latest. - // +operator-sdk:csv:customresourcedefinitions:type=spec,order=1,displayName="Istio Version",xDescriptors={"urn:alm:descriptor:com.tectonic.ui:fieldGroup:General", "urn:alm:descriptor:com.tectonic.ui:select:v1.24.2", "urn:alm:descriptor:com.tectonic.ui:select:v1.24.1", "urn:alm:descriptor:com.tectonic.ui:select:v1.24.0", "urn:alm:descriptor:com.tectonic.ui:select:v1.23.4", "urn:alm:descriptor:com.tectonic.ui:select:v1.23.3", "urn:alm:descriptor:com.tectonic.ui:select:v1.23.2", "urn:alm:descriptor:com.tectonic.ui:select:v1.22.8", "urn:alm:descriptor:com.tectonic.ui:select:v1.22.7", "urn:alm:descriptor:com.tectonic.ui:select:v1.22.6", "urn:alm:descriptor:com.tectonic.ui:select:v1.22.5", "urn:alm:descriptor:com.tectonic.ui:select:v1.21.6", "urn:alm:descriptor:com.tectonic.ui:select:latest"} - // +kubebuilder:validation:Enum=v1.24.2;v1.24.1;v1.24.0;v1.23.4;v1.23.3;v1.23.2;v1.22.8;v1.22.7;v1.22.6;v1.22.5;v1.21.6;latest + // Must be one of: v1.24-latest, v1.24.2, v1.24.1, v1.24.0, v1.23-latest, v1.23.4, v1.23.3, v1.23.2, v1.22-latest, v1.22.8, v1.22.7, v1.22.6, v1.22.5, v1.21.6, master, v1.25-alpha.c2ac935c. + // +operator-sdk:csv:customresourcedefinitions:type=spec,order=1,displayName="Istio Version",xDescriptors={"urn:alm:descriptor:com.tectonic.ui:fieldGroup:General", "urn:alm:descriptor:com.tectonic.ui:select:v1.24-latest", "urn:alm:descriptor:com.tectonic.ui:select:v1.24.2", "urn:alm:descriptor:com.tectonic.ui:select:v1.24.1", "urn:alm:descriptor:com.tectonic.ui:select:v1.24.0", "urn:alm:descriptor:com.tectonic.ui:select:v1.23-latest", "urn:alm:descriptor:com.tectonic.ui:select:v1.23.4", "urn:alm:descriptor:com.tectonic.ui:select:v1.23.3", "urn:alm:descriptor:com.tectonic.ui:select:v1.23.2", "urn:alm:descriptor:com.tectonic.ui:select:v1.22-latest", "urn:alm:descriptor:com.tectonic.ui:select:v1.22.8", "urn:alm:descriptor:com.tectonic.ui:select:v1.22.7", "urn:alm:descriptor:com.tectonic.ui:select:v1.22.6", "urn:alm:descriptor:com.tectonic.ui:select:v1.22.5", "urn:alm:descriptor:com.tectonic.ui:select:v1.21.6", "urn:alm:descriptor:com.tectonic.ui:select:master", "urn:alm:descriptor:com.tectonic.ui:select:v1.25-alpha.c2ac935c"} + // +kubebuilder:validation:Enum=v1.24-latest;v1.24.2;v1.24.1;v1.24.0;v1.23-latest;v1.23.4;v1.23.3;v1.23.2;v1.22-latest;v1.22.8;v1.22.7;v1.22.6;v1.22.5;v1.21.6;master;v1.25-alpha.c2ac935c // +kubebuilder:default=v1.24.2 Version string `json:"version"` diff --git a/api/v1/istiorevision_types.go b/api/v1/istiorevision_types.go index 33760d350..10f40ca0f 100644 --- a/api/v1/istiorevision_types.go +++ b/api/v1/istiorevision_types.go @@ -30,9 +30,9 @@ const ( type IstioRevisionSpec struct { // +sail:version // Defines the version of Istio to install. - // Must be one of: v1.24.2, v1.24.1, v1.24.0, v1.23.4, v1.23.3, v1.23.2, v1.22.8, v1.22.7, v1.22.6, v1.22.5, v1.21.6, latest. - // +operator-sdk:csv:customresourcedefinitions:type=spec,order=1,displayName="Istio Version",xDescriptors={"urn:alm:descriptor:com.tectonic.ui:fieldGroup:General", "urn:alm:descriptor:com.tectonic.ui:select:v1.24.2", "urn:alm:descriptor:com.tectonic.ui:select:v1.24.1", "urn:alm:descriptor:com.tectonic.ui:select:v1.24.0", "urn:alm:descriptor:com.tectonic.ui:select:v1.23.4", "urn:alm:descriptor:com.tectonic.ui:select:v1.23.3", "urn:alm:descriptor:com.tectonic.ui:select:v1.23.2", "urn:alm:descriptor:com.tectonic.ui:select:v1.22.8", "urn:alm:descriptor:com.tectonic.ui:select:v1.22.7", "urn:alm:descriptor:com.tectonic.ui:select:v1.22.6", "urn:alm:descriptor:com.tectonic.ui:select:v1.22.5", "urn:alm:descriptor:com.tectonic.ui:select:v1.21.6", "urn:alm:descriptor:com.tectonic.ui:select:latest"} - // +kubebuilder:validation:Enum=v1.24.2;v1.24.1;v1.24.0;v1.23.4;v1.23.3;v1.23.2;v1.22.8;v1.22.7;v1.22.6;v1.22.5;v1.21.6;latest + // Must be one of: v1.24.2, v1.24.1, v1.24.0, v1.23.4, v1.23.3, v1.23.2, v1.22.8, v1.22.7, v1.22.6, v1.22.5, v1.21.6, v1.25-alpha.c2ac935c. + // +operator-sdk:csv:customresourcedefinitions:type=spec,order=1,displayName="Istio Version",xDescriptors={"urn:alm:descriptor:com.tectonic.ui:fieldGroup:General", "urn:alm:descriptor:com.tectonic.ui:select:v1.24.2", "urn:alm:descriptor:com.tectonic.ui:select:v1.24.1", "urn:alm:descriptor:com.tectonic.ui:select:v1.24.0", "urn:alm:descriptor:com.tectonic.ui:select:v1.23.4", "urn:alm:descriptor:com.tectonic.ui:select:v1.23.3", "urn:alm:descriptor:com.tectonic.ui:select:v1.23.2", "urn:alm:descriptor:com.tectonic.ui:select:v1.22.8", "urn:alm:descriptor:com.tectonic.ui:select:v1.22.7", "urn:alm:descriptor:com.tectonic.ui:select:v1.22.6", "urn:alm:descriptor:com.tectonic.ui:select:v1.22.5", "urn:alm:descriptor:com.tectonic.ui:select:v1.21.6", "urn:alm:descriptor:com.tectonic.ui:select:v1.25-alpha.c2ac935c"} + // +kubebuilder:validation:Enum=v1.24.2;v1.24.1;v1.24.0;v1.23.4;v1.23.3;v1.23.2;v1.22.8;v1.22.7;v1.22.6;v1.22.5;v1.21.6;v1.25-alpha.c2ac935c Version string `json:"version"` // Namespace to which the Istio components should be installed. diff --git a/api/v1alpha1/ztunnel_types.go b/api/v1alpha1/ztunnel_types.go index 43428569b..0331b6f68 100644 --- a/api/v1alpha1/ztunnel_types.go +++ b/api/v1alpha1/ztunnel_types.go @@ -29,9 +29,9 @@ const ( type ZTunnelSpec struct { // +sail:version // Defines the version of Istio to install. - // Must be one of: v1.24.2, v1.24.1, v1.24.0, latest. - // +operator-sdk:csv:customresourcedefinitions:type=spec,order=1,displayName="Istio Version",xDescriptors={"urn:alm:descriptor:com.tectonic.ui:fieldGroup:General", "urn:alm:descriptor:com.tectonic.ui:select:v1.24.2", "urn:alm:descriptor:com.tectonic.ui:select:v1.24.1", "urn:alm:descriptor:com.tectonic.ui:select:v1.24.0", "urn:alm:descriptor:com.tectonic.ui:select:latest"} - // +kubebuilder:validation:Enum=v1.24.2;v1.24.1;v1.24.0;latest + // Must be one of: v1.24-latest, v1.24.2, v1.24.1, v1.24.0, master, v1.25-alpha.c2ac935c. + // +operator-sdk:csv:customresourcedefinitions:type=spec,order=1,displayName="Istio Version",xDescriptors={"urn:alm:descriptor:com.tectonic.ui:fieldGroup:General", "urn:alm:descriptor:com.tectonic.ui:select:v1.24-latest", "urn:alm:descriptor:com.tectonic.ui:select:v1.24.2", "urn:alm:descriptor:com.tectonic.ui:select:v1.24.1", "urn:alm:descriptor:com.tectonic.ui:select:v1.24.0", "urn:alm:descriptor:com.tectonic.ui:select:master", "urn:alm:descriptor:com.tectonic.ui:select:v1.25-alpha.c2ac935c"} + // +kubebuilder:validation:Enum=v1.24-latest;v1.24.2;v1.24.1;v1.24.0;master;v1.25-alpha.c2ac935c // +kubebuilder:default=v1.24.2 Version string `json:"version"` diff --git a/bundle/README.md b/bundle/README.md index 0192634d6..d16a6112d 100644 --- a/bundle/README.md +++ b/bundle/README.md @@ -85,7 +85,7 @@ Repeat the process to create a project named `istio-cni`. The `version` field of the `Istio` and `IstioCNI` resource defines which version of each component should be deployed. This can be set using the `Istio Version` drop down menu when creating a new `Istio` with the OpenShift Container Platform -web console. For a list of available versions, see the [versions.yaml](/versions.yaml) file +web console. For a list of available versions, see the [versions.yaml](/pkg/istioversion/versions.yaml) file or use the command: ```sh diff --git a/bundle/manifests/sailoperator.clusterserviceversion.yaml b/bundle/manifests/sailoperator.clusterserviceversion.yaml index 988994d42..99349ebcf 100644 --- a/bundle/manifests/sailoperator.clusterserviceversion.yaml +++ b/bundle/manifests/sailoperator.clusterserviceversion.yaml @@ -165,23 +165,27 @@ spec: specDescriptors: - description: |- Defines the version of Istio to install. - Must be one of: v1.24.2, v1.24.1, v1.24.0, v1.23.4, v1.23.3, v1.23.2, v1.22.8, v1.22.7, v1.22.6, v1.22.5, v1.21.6, latest. + Must be one of: v1.24-latest, v1.24.2, v1.24.1, v1.24.0, v1.23-latest, v1.23.4, v1.23.3, v1.23.2, v1.22-latest, v1.22.8, v1.22.7, v1.22.6, v1.22.5, v1.21.6, master, v1.25-alpha.c2ac935c. displayName: Istio Version path: version x-descriptors: - urn:alm:descriptor:com.tectonic.ui:fieldGroup:General + - urn:alm:descriptor:com.tectonic.ui:select:v1.24-latest - urn:alm:descriptor:com.tectonic.ui:select:v1.24.2 - urn:alm:descriptor:com.tectonic.ui:select:v1.24.1 - urn:alm:descriptor:com.tectonic.ui:select:v1.24.0 + - urn:alm:descriptor:com.tectonic.ui:select:v1.23-latest - urn:alm:descriptor:com.tectonic.ui:select:v1.23.4 - urn:alm:descriptor:com.tectonic.ui:select:v1.23.3 - urn:alm:descriptor:com.tectonic.ui:select:v1.23.2 + - urn:alm:descriptor:com.tectonic.ui:select:v1.22-latest - urn:alm:descriptor:com.tectonic.ui:select:v1.22.8 - urn:alm:descriptor:com.tectonic.ui:select:v1.22.7 - urn:alm:descriptor:com.tectonic.ui:select:v1.22.6 - urn:alm:descriptor:com.tectonic.ui:select:v1.22.5 - urn:alm:descriptor:com.tectonic.ui:select:v1.21.6 - - urn:alm:descriptor:com.tectonic.ui:select:latest + - urn:alm:descriptor:com.tectonic.ui:select:master + - urn:alm:descriptor:com.tectonic.ui:select:v1.25-alpha.c2ac935c - description: Namespace to which the Istio CNI component should be installed. displayName: Namespace path: namespace @@ -211,7 +215,7 @@ spec: specDescriptors: - description: |- Defines the version of Istio to install. - Must be one of: v1.24.2, v1.24.1, v1.24.0, v1.23.4, v1.23.3, v1.23.2, v1.22.8, v1.22.7, v1.22.6, v1.22.5, v1.21.6, latest. + Must be one of: v1.24.2, v1.24.1, v1.24.0, v1.23.4, v1.23.3, v1.23.2, v1.22.8, v1.22.7, v1.22.6, v1.22.5, v1.21.6, v1.25-alpha.c2ac935c. displayName: Istio Version path: version x-descriptors: @@ -227,7 +231,7 @@ spec: - urn:alm:descriptor:com.tectonic.ui:select:v1.22.6 - urn:alm:descriptor:com.tectonic.ui:select:v1.22.5 - urn:alm:descriptor:com.tectonic.ui:select:v1.21.6 - - urn:alm:descriptor:com.tectonic.ui:select:latest + - urn:alm:descriptor:com.tectonic.ui:select:v1.25-alpha.c2ac935c - description: Namespace to which the Istio components should be installed. displayName: Namespace path: namespace @@ -273,23 +277,27 @@ spec: - urn:alm:descriptor:com.tectonic.ui:select:RevisionBased - description: |- Defines the version of Istio to install. - Must be one of: v1.24.2, v1.24.1, v1.24.0, v1.23.4, v1.23.3, v1.23.2, v1.22.8, v1.22.7, v1.22.6, v1.22.5, v1.21.6, latest. + Must be one of: v1.24-latest, v1.24.2, v1.24.1, v1.24.0, v1.23-latest, v1.23.4, v1.23.3, v1.23.2, v1.22-latest, v1.22.8, v1.22.7, v1.22.6, v1.22.5, v1.21.6, master, v1.25-alpha.c2ac935c. displayName: Istio Version path: version x-descriptors: - urn:alm:descriptor:com.tectonic.ui:fieldGroup:General + - urn:alm:descriptor:com.tectonic.ui:select:v1.24-latest - urn:alm:descriptor:com.tectonic.ui:select:v1.24.2 - urn:alm:descriptor:com.tectonic.ui:select:v1.24.1 - urn:alm:descriptor:com.tectonic.ui:select:v1.24.0 + - urn:alm:descriptor:com.tectonic.ui:select:v1.23-latest - urn:alm:descriptor:com.tectonic.ui:select:v1.23.4 - urn:alm:descriptor:com.tectonic.ui:select:v1.23.3 - urn:alm:descriptor:com.tectonic.ui:select:v1.23.2 + - urn:alm:descriptor:com.tectonic.ui:select:v1.22-latest - urn:alm:descriptor:com.tectonic.ui:select:v1.22.8 - urn:alm:descriptor:com.tectonic.ui:select:v1.22.7 - urn:alm:descriptor:com.tectonic.ui:select:v1.22.6 - urn:alm:descriptor:com.tectonic.ui:select:v1.22.5 - urn:alm:descriptor:com.tectonic.ui:select:v1.21.6 - - urn:alm:descriptor:com.tectonic.ui:select:latest + - urn:alm:descriptor:com.tectonic.ui:select:master + - urn:alm:descriptor:com.tectonic.ui:select:v1.25-alpha.c2ac935c - description: |- Defines how many seconds the operator should wait before removing a non-active revision after all the workloads have stopped using it. You may want to set this value on the order of minutes. @@ -339,15 +347,17 @@ spec: specDescriptors: - description: |- Defines the version of Istio to install. - Must be one of: v1.24.2, v1.24.1, v1.24.0, latest. + Must be one of: v1.24-latest, v1.24.2, v1.24.1, v1.24.0, master, v1.25-alpha.c2ac935c. displayName: Istio Version path: version x-descriptors: - urn:alm:descriptor:com.tectonic.ui:fieldGroup:General + - urn:alm:descriptor:com.tectonic.ui:select:v1.24-latest - urn:alm:descriptor:com.tectonic.ui:select:v1.24.2 - urn:alm:descriptor:com.tectonic.ui:select:v1.24.1 - urn:alm:descriptor:com.tectonic.ui:select:v1.24.0 - - urn:alm:descriptor:com.tectonic.ui:select:latest + - urn:alm:descriptor:com.tectonic.ui:select:master + - urn:alm:descriptor:com.tectonic.ui:select:v1.25-alpha.c2ac935c - description: Namespace to which the Istio ztunnel component should be installed. displayName: Namespace path: namespace @@ -371,18 +381,22 @@ spec: This version of the operator supports the following Istio versions: + - v1.24-latest - v1.24.2 - v1.24.1 - v1.24.0 + - v1.23-latest - v1.23.4 - v1.23.3 - v1.23.2 + - v1.22-latest - v1.22.8 - v1.22.7 - v1.22.6 - v1.22.5 - v1.21.6 - - latest (c2ac935c) + - master + - v1.25-alpha.c2ac935c [See this page](https://github.com/istio-ecosystem/sail-operator/blob/main/bundle/README.md) for instructions on how to use it. displayName: Sail Operator @@ -658,10 +672,6 @@ spec: template: metadata: annotations: - images.latest.cni: gcr.io/istio-testing/install-cni:1.25-alpha.c2ac935c588899579e1cee38b205e4e6824a4638 - images.latest.istiod: gcr.io/istio-testing/pilot:1.25-alpha.c2ac935c588899579e1cee38b205e4e6824a4638 - images.latest.proxy: gcr.io/istio-testing/proxyv2:1.25-alpha.c2ac935c588899579e1cee38b205e4e6824a4638 - images.latest.ztunnel: gcr.io/istio-testing/ztunnel:1.25-alpha.c2ac935c588899579e1cee38b205e4e6824a4638 images.v1_21_6.cni: gcr.io/istio-release/install-cni:1.21.6 images.v1_21_6.istiod: gcr.io/istio-release/pilot:1.21.6 images.v1_21_6.proxy: gcr.io/istio-release/proxyv2:1.21.6 @@ -706,6 +716,10 @@ spec: images.v1_24_2.istiod: gcr.io/istio-release/pilot:1.24.2 images.v1_24_2.proxy: gcr.io/istio-release/proxyv2:1.24.2 images.v1_24_2.ztunnel: gcr.io/istio-release/ztunnel:1.24.2 + images.v1_25-alpha_c2ac935c.cni: gcr.io/istio-testing/install-cni:1.25-alpha.c2ac935c588899579e1cee38b205e4e6824a4638 + images.v1_25-alpha_c2ac935c.istiod: gcr.io/istio-testing/pilot:1.25-alpha.c2ac935c588899579e1cee38b205e4e6824a4638 + images.v1_25-alpha_c2ac935c.proxy: gcr.io/istio-testing/proxyv2:1.25-alpha.c2ac935c588899579e1cee38b205e4e6824a4638 + images.v1_25-alpha_c2ac935c.ztunnel: gcr.io/istio-testing/ztunnel:1.25-alpha.c2ac935c588899579e1cee38b205e4e6824a4638 kubectl.kubernetes.io/default-container: sail-operator labels: app.kubernetes.io/created-by: sailoperator @@ -835,14 +849,6 @@ spec: provider: name: Red Hat, Inc. relatedImages: - - image: gcr.io/istio-testing/install-cni:1.25-alpha.c2ac935c588899579e1cee38b205e4e6824a4638 - name: latest.cni - - image: gcr.io/istio-testing/pilot:1.25-alpha.c2ac935c588899579e1cee38b205e4e6824a4638 - name: latest.istiod - - image: gcr.io/istio-testing/proxyv2:1.25-alpha.c2ac935c588899579e1cee38b205e4e6824a4638 - name: latest.proxy - - image: gcr.io/istio-testing/ztunnel:1.25-alpha.c2ac935c588899579e1cee38b205e4e6824a4638 - name: latest.ztunnel - image: gcr.io/istio-release/install-cni:1.21.6 name: v1_21_6.cni - image: gcr.io/istio-release/pilot:1.21.6 @@ -931,4 +937,12 @@ spec: name: v1_24_2.proxy - image: gcr.io/istio-release/ztunnel:1.24.2 name: v1_24_2.ztunnel + - image: gcr.io/istio-testing/install-cni:1.25-alpha.c2ac935c588899579e1cee38b205e4e6824a4638 + name: v1_25-alpha_c2ac935c.cni + - image: gcr.io/istio-testing/pilot:1.25-alpha.c2ac935c588899579e1cee38b205e4e6824a4638 + name: v1_25-alpha_c2ac935c.istiod + - image: gcr.io/istio-testing/proxyv2:1.25-alpha.c2ac935c588899579e1cee38b205e4e6824a4638 + name: v1_25-alpha_c2ac935c.proxy + - image: gcr.io/istio-testing/ztunnel:1.25-alpha.c2ac935c588899579e1cee38b205e4e6824a4638 + name: v1_25-alpha_c2ac935c.ztunnel version: 1.1.0 diff --git a/bundle/manifests/sailoperator.io_istiocnis.yaml b/bundle/manifests/sailoperator.io_istiocnis.yaml index cdebc7d97..ddf99b723 100644 --- a/bundle/manifests/sailoperator.io_istiocnis.yaml +++ b/bundle/manifests/sailoperator.io_istiocnis.yaml @@ -1433,20 +1433,24 @@ spec: default: v1.24.2 description: |- Defines the version of Istio to install. - Must be one of: v1.24.2, v1.24.1, v1.24.0, v1.23.4, v1.23.3, v1.23.2, v1.22.8, v1.22.7, v1.22.6, v1.22.5, v1.21.6, latest. + Must be one of: v1.24-latest, v1.24.2, v1.24.1, v1.24.0, v1.23-latest, v1.23.4, v1.23.3, v1.23.2, v1.22-latest, v1.22.8, v1.22.7, v1.22.6, v1.22.5, v1.21.6, master, v1.25-alpha.c2ac935c. enum: + - v1.24-latest - v1.24.2 - v1.24.1 - v1.24.0 + - v1.23-latest - v1.23.4 - v1.23.3 - v1.23.2 + - v1.22-latest - v1.22.8 - v1.22.7 - v1.22.6 - v1.22.5 - v1.21.6 - - latest + - master + - v1.25-alpha.c2ac935c type: string required: - namespace diff --git a/bundle/manifests/sailoperator.io_istiorevisions.yaml b/bundle/manifests/sailoperator.io_istiorevisions.yaml index 57d6629cb..b42c4ad6f 100644 --- a/bundle/manifests/sailoperator.io_istiorevisions.yaml +++ b/bundle/manifests/sailoperator.io_istiorevisions.yaml @@ -9420,7 +9420,7 @@ spec: version: description: |- Defines the version of Istio to install. - Must be one of: v1.24.2, v1.24.1, v1.24.0, v1.23.4, v1.23.3, v1.23.2, v1.22.8, v1.22.7, v1.22.6, v1.22.5, v1.21.6, latest. + Must be one of: v1.24.2, v1.24.1, v1.24.0, v1.23.4, v1.23.3, v1.23.2, v1.22.8, v1.22.7, v1.22.6, v1.22.5, v1.21.6, v1.25-alpha.c2ac935c. enum: - v1.24.2 - v1.24.1 @@ -9433,7 +9433,7 @@ spec: - v1.22.6 - v1.22.5 - v1.21.6 - - latest + - v1.25-alpha.c2ac935c type: string required: - namespace diff --git a/bundle/manifests/sailoperator.io_istios.yaml b/bundle/manifests/sailoperator.io_istios.yaml index c82db9f22..9d3a37b1d 100644 --- a/bundle/manifests/sailoperator.io_istios.yaml +++ b/bundle/manifests/sailoperator.io_istios.yaml @@ -9490,20 +9490,24 @@ spec: default: v1.24.2 description: |- Defines the version of Istio to install. - Must be one of: v1.24.2, v1.24.1, v1.24.0, v1.23.4, v1.23.3, v1.23.2, v1.22.8, v1.22.7, v1.22.6, v1.22.5, v1.21.6, latest. + Must be one of: v1.24-latest, v1.24.2, v1.24.1, v1.24.0, v1.23-latest, v1.23.4, v1.23.3, v1.23.2, v1.22-latest, v1.22.8, v1.22.7, v1.22.6, v1.22.5, v1.21.6, master, v1.25-alpha.c2ac935c. enum: + - v1.24-latest - v1.24.2 - v1.24.1 - v1.24.0 + - v1.23-latest - v1.23.4 - v1.23.3 - v1.23.2 + - v1.22-latest - v1.22.8 - v1.22.7 - v1.22.6 - v1.22.5 - v1.21.6 - - latest + - master + - v1.25-alpha.c2ac935c type: string required: - namespace diff --git a/bundle/manifests/sailoperator.io_ztunnels.yaml b/bundle/manifests/sailoperator.io_ztunnels.yaml index fd9536fc5..912391605 100644 --- a/bundle/manifests/sailoperator.io_ztunnels.yaml +++ b/bundle/manifests/sailoperator.io_ztunnels.yaml @@ -5518,12 +5518,14 @@ spec: default: v1.24.2 description: |- Defines the version of Istio to install. - Must be one of: v1.24.2, v1.24.1, v1.24.0, latest. + Must be one of: v1.24-latest, v1.24.2, v1.24.1, v1.24.0, master, v1.25-alpha.c2ac935c. enum: + - v1.24-latest - v1.24.2 - v1.24.1 - v1.24.0 - - latest + - master + - v1.25-alpha.c2ac935c type: string required: - namespace diff --git a/chart/crds/sailoperator.io_istiocnis.yaml b/chart/crds/sailoperator.io_istiocnis.yaml index 842e56df1..ba10f4c90 100644 --- a/chart/crds/sailoperator.io_istiocnis.yaml +++ b/chart/crds/sailoperator.io_istiocnis.yaml @@ -1433,20 +1433,24 @@ spec: default: v1.24.2 description: |- Defines the version of Istio to install. - Must be one of: v1.24.2, v1.24.1, v1.24.0, v1.23.4, v1.23.3, v1.23.2, v1.22.8, v1.22.7, v1.22.6, v1.22.5, v1.21.6, latest. + Must be one of: v1.24-latest, v1.24.2, v1.24.1, v1.24.0, v1.23-latest, v1.23.4, v1.23.3, v1.23.2, v1.22-latest, v1.22.8, v1.22.7, v1.22.6, v1.22.5, v1.21.6, master, v1.25-alpha.c2ac935c. enum: + - v1.24-latest - v1.24.2 - v1.24.1 - v1.24.0 + - v1.23-latest - v1.23.4 - v1.23.3 - v1.23.2 + - v1.22-latest - v1.22.8 - v1.22.7 - v1.22.6 - v1.22.5 - v1.21.6 - - latest + - master + - v1.25-alpha.c2ac935c type: string required: - namespace diff --git a/chart/crds/sailoperator.io_istiorevisions.yaml b/chart/crds/sailoperator.io_istiorevisions.yaml index 9ffa59c5e..8e1714786 100644 --- a/chart/crds/sailoperator.io_istiorevisions.yaml +++ b/chart/crds/sailoperator.io_istiorevisions.yaml @@ -9420,7 +9420,7 @@ spec: version: description: |- Defines the version of Istio to install. - Must be one of: v1.24.2, v1.24.1, v1.24.0, v1.23.4, v1.23.3, v1.23.2, v1.22.8, v1.22.7, v1.22.6, v1.22.5, v1.21.6, latest. + Must be one of: v1.24.2, v1.24.1, v1.24.0, v1.23.4, v1.23.3, v1.23.2, v1.22.8, v1.22.7, v1.22.6, v1.22.5, v1.21.6, v1.25-alpha.c2ac935c. enum: - v1.24.2 - v1.24.1 @@ -9433,7 +9433,7 @@ spec: - v1.22.6 - v1.22.5 - v1.21.6 - - latest + - v1.25-alpha.c2ac935c type: string required: - namespace diff --git a/chart/crds/sailoperator.io_istios.yaml b/chart/crds/sailoperator.io_istios.yaml index 08e49a52f..04f2b5654 100644 --- a/chart/crds/sailoperator.io_istios.yaml +++ b/chart/crds/sailoperator.io_istios.yaml @@ -9490,20 +9490,24 @@ spec: default: v1.24.2 description: |- Defines the version of Istio to install. - Must be one of: v1.24.2, v1.24.1, v1.24.0, v1.23.4, v1.23.3, v1.23.2, v1.22.8, v1.22.7, v1.22.6, v1.22.5, v1.21.6, latest. + Must be one of: v1.24-latest, v1.24.2, v1.24.1, v1.24.0, v1.23-latest, v1.23.4, v1.23.3, v1.23.2, v1.22-latest, v1.22.8, v1.22.7, v1.22.6, v1.22.5, v1.21.6, master, v1.25-alpha.c2ac935c. enum: + - v1.24-latest - v1.24.2 - v1.24.1 - v1.24.0 + - v1.23-latest - v1.23.4 - v1.23.3 - v1.23.2 + - v1.22-latest - v1.22.8 - v1.22.7 - v1.22.6 - v1.22.5 - v1.21.6 - - latest + - master + - v1.25-alpha.c2ac935c type: string required: - namespace diff --git a/chart/crds/sailoperator.io_ztunnels.yaml b/chart/crds/sailoperator.io_ztunnels.yaml index 8a8803397..2f2dac6cb 100644 --- a/chart/crds/sailoperator.io_ztunnels.yaml +++ b/chart/crds/sailoperator.io_ztunnels.yaml @@ -5518,12 +5518,14 @@ spec: default: v1.24.2 description: |- Defines the version of Istio to install. - Must be one of: v1.24.2, v1.24.1, v1.24.0, latest. + Must be one of: v1.24-latest, v1.24.2, v1.24.1, v1.24.0, master, v1.25-alpha.c2ac935c. enum: + - v1.24-latest - v1.24.2 - v1.24.1 - v1.24.0 - - latest + - master + - v1.25-alpha.c2ac935c type: string required: - namespace diff --git a/chart/values.yaml b/chart/values.yaml index eefd239e9..416ebcb92 100644 --- a/chart/values.yaml +++ b/chart/values.yaml @@ -18,18 +18,22 @@ csv: This version of the operator supports the following Istio versions: + - v1.24-latest - v1.24.2 - v1.24.1 - v1.24.0 + - v1.23-latest - v1.23.4 - v1.23.3 - v1.23.2 + - v1.22-latest - v1.22.8 - v1.22.7 - v1.22.6 - v1.22.5 - v1.21.6 - - latest (c2ac935c) + - master + - v1.25-alpha.c2ac935c [See this page](https://github.com/istio-ecosystem/sail-operator/blob/main/bundle/README.md) for instructions on how to use it. support: Community based diff --git a/controllers/istio/istio_controller.go b/controllers/istio/istio_controller.go index 81e04670b..394b698b6 100644 --- a/controllers/istio/istio_controller.go +++ b/controllers/istio/istio_controller.go @@ -27,6 +27,7 @@ import ( "github.com/istio-ecosystem/sail-operator/pkg/config" "github.com/istio-ecosystem/sail-operator/pkg/enqueuelogger" "github.com/istio-ecosystem/sail-operator/pkg/errlist" + "github.com/istio-ecosystem/sail-operator/pkg/istioversion" "github.com/istio-ecosystem/sail-operator/pkg/kube" "github.com/istio-ecosystem/sail-operator/pkg/reconciler" "github.com/istio-ecosystem/sail-operator/pkg/revision" @@ -105,8 +106,12 @@ func validate(istio *v1.Istio) error { } func (r *Reconciler) reconcileActiveRevision(ctx context.Context, istio *v1.Istio) error { + version, err := istioversion.Resolve(istio.Spec.Version) + if err != nil { + return fmt.Errorf("failed to resolve Istio version for %q: %w", istio.Name, err) + } values, err := revision.ComputeValues( - istio.Spec.Values, istio.Spec.Namespace, istio.Spec.Version, + istio.Spec.Values, istio.Spec.Namespace, version, r.Config.Platform, r.Config.DefaultProfile, istio.Spec.Profile, r.Config.ResourceDirectory, getActiveRevisionName(istio)) if err != nil { @@ -115,7 +120,7 @@ func (r *Reconciler) reconcileActiveRevision(ctx context.Context, istio *v1.Isti return revision.CreateOrUpdate(ctx, r.Client, getActiveRevisionName(istio), - istio.Spec.Version, istio.Spec.Namespace, values, + version, istio.Spec.Namespace, values, metav1.OwnerReference{ APIVersion: v1.GroupVersion.String(), Kind: v1.IstioKind, diff --git a/controllers/istio/istio_controller_test.go b/controllers/istio/istio_controller_test.go index 3564b6b9d..eed08f168 100644 --- a/controllers/istio/istio_controller_test.go +++ b/controllers/istio/istio_controller_test.go @@ -18,15 +18,16 @@ import ( "context" "fmt" "runtime/debug" + "strings" "testing" "time" "github.com/google/go-cmp/cmp" v1 "github.com/istio-ecosystem/sail-operator/api/v1" "github.com/istio-ecosystem/sail-operator/pkg/config" + "github.com/istio-ecosystem/sail-operator/pkg/istioversion" "github.com/istio-ecosystem/sail-operator/pkg/scheme" "github.com/istio-ecosystem/sail-operator/pkg/test/testtime" - "github.com/istio-ecosystem/sail-operator/pkg/test/util/supportedversion" . "github.com/onsi/gomega" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/apimachinery/pkg/types" @@ -127,7 +128,8 @@ func TestReconcile(t *testing.T) { istio := &v1.Istio{ ObjectMeta: objectMeta, Spec: v1.IstioSpec{ - Version: "my-version", + Version: "my-version", + Namespace: "istio-system", }, } @@ -157,6 +159,10 @@ func TestReconcile(t *testing.T) { t.Errorf("Expected Reconciled condition status to be %q, but got %q", metav1.ConditionFalse, reconciledCond.Status) } + if !strings.Contains(reconciledCond.Message, "version \"my-version\" not found") { + t.Errorf("Expected Reconciled condition message to contain %q, but got %q", "version \"my-version\" not found", reconciledCond.Message) + } + readyCond := istio.Status.GetCondition(v1.IstioConditionReady) if readyCond.Status != metav1.ConditionUnknown { t.Errorf("Expected Reconciled condition status to be %q, but got %q", metav1.ConditionUnknown, readyCond.Status) @@ -177,7 +183,7 @@ func TestValidate(t *testing.T) { Name: "default", }, Spec: v1.IstioSpec{ - Version: supportedversion.Default, + Version: istioversion.Default, Namespace: "istio-system", }, }, @@ -202,7 +208,7 @@ func TestValidate(t *testing.T) { Name: "default", }, Spec: v1.IstioSpec{ - Version: supportedversion.Default, + Version: istioversion.Default, }, }, expectErr: "spec.namespace not set", diff --git a/controllers/istiocni/istiocni_controller.go b/controllers/istiocni/istiocni_controller.go index 622ed44f0..88a8ed073 100644 --- a/controllers/istiocni/istiocni_controller.go +++ b/controllers/istiocni/istiocni_controller.go @@ -29,6 +29,7 @@ import ( "github.com/istio-ecosystem/sail-operator/pkg/errlist" "github.com/istio-ecosystem/sail-operator/pkg/helm" "github.com/istio-ecosystem/sail-operator/pkg/istiovalues" + "github.com/istio-ecosystem/sail-operator/pkg/istioversion" "github.com/istio-ecosystem/sail-operator/pkg/kube" "github.com/istio-ecosystem/sail-operator/pkg/predicate" "github.com/istio-ecosystem/sail-operator/pkg/reconciler" @@ -141,32 +142,37 @@ func (r *Reconciler) installHelmChart(ctx context.Context, cni *v1.IstioCNI) err BlockOwnerDeletion: ptr.Of(true), } + version, err := istioversion.Resolve(cni.Spec.Version) + if err != nil { + return fmt.Errorf("failed to resolve IstioCNI version for %q: %w", cni.Name, err) + } + // get userValues from Istio.spec.values userValues := cni.Spec.Values // apply image digests from configuration, if not already set by user - userValues = applyImageDigests(cni, userValues, config.Config) + userValues = applyImageDigests(version, userValues, config.Config) // apply userValues on top of defaultValues from profiles mergedHelmValues, err := istiovalues.ApplyProfilesAndPlatform( - r.Config.ResourceDirectory, cni.Spec.Version, r.Config.Platform, r.Config.DefaultProfile, cni.Spec.Profile, helm.FromValues(userValues)) + r.Config.ResourceDirectory, version, r.Config.Platform, r.Config.DefaultProfile, cni.Spec.Profile, helm.FromValues(userValues)) if err != nil { return fmt.Errorf("failed to apply profile: %w", err) } - _, err = r.ChartManager.UpgradeOrInstallChart(ctx, r.getChartDir(cni), mergedHelmValues, cni.Spec.Namespace, cniReleaseName, ownerReference) + _, err = r.ChartManager.UpgradeOrInstallChart(ctx, r.getChartDir(version), mergedHelmValues, cni.Spec.Namespace, cniReleaseName, ownerReference) if err != nil { return fmt.Errorf("failed to install/update Helm chart %q: %w", cniChartName, err) } return nil } -func (r *Reconciler) getChartDir(cni *v1.IstioCNI) string { - return path.Join(r.Config.ResourceDirectory, cni.Spec.Version, "charts", cniChartName) +func (r *Reconciler) getChartDir(version string) string { + return path.Join(r.Config.ResourceDirectory, version, "charts", cniChartName) } -func applyImageDigests(cni *v1.IstioCNI, values *v1.CNIValues, config config.OperatorConfig) *v1.CNIValues { - imageDigests, digestsDefined := config.ImageDigests[cni.Spec.Version] +func applyImageDigests(version string, values *v1.CNIValues, config config.OperatorConfig) *v1.CNIValues { + imageDigests, digestsDefined := config.ImageDigests[version] // if we don't have default image digests defined for this version, it's a no-op if !digestsDefined { return values diff --git a/controllers/istiocni/istiocni_controller_test.go b/controllers/istiocni/istiocni_controller_test.go index f45391628..5836b4ae9 100644 --- a/controllers/istiocni/istiocni_controller_test.go +++ b/controllers/istiocni/istiocni_controller_test.go @@ -22,8 +22,8 @@ import ( "github.com/google/go-cmp/cmp" v1 "github.com/istio-ecosystem/sail-operator/api/v1" "github.com/istio-ecosystem/sail-operator/pkg/config" + "github.com/istio-ecosystem/sail-operator/pkg/istioversion" "github.com/istio-ecosystem/sail-operator/pkg/scheme" - "github.com/istio-ecosystem/sail-operator/pkg/test/util/supportedversion" . "github.com/onsi/gomega" appsv1 "k8s.io/api/apps/v1" corev1 "k8s.io/api/core/v1" @@ -57,7 +57,7 @@ func TestValidate(t *testing.T) { Name: "default", }, Spec: v1.IstioCNISpec{ - Version: supportedversion.Default, + Version: istioversion.Default, Namespace: "istio-cni", }, }, @@ -84,7 +84,7 @@ func TestValidate(t *testing.T) { Name: "default", }, Spec: v1.IstioCNISpec{ - Version: supportedversion.Default, + Version: istioversion.Default, }, }, objects: []client.Object{ns}, @@ -97,7 +97,7 @@ func TestValidate(t *testing.T) { Name: "default", }, Spec: v1.IstioCNISpec{ - Version: supportedversion.Default, + Version: istioversion.Default, Namespace: "istio-cni", }, }, @@ -323,7 +323,7 @@ func TestApplyImageDigests(t *testing.T) { }, input: &v1.IstioCNI{ Spec: v1.IstioCNISpec{ - Version: "v1.20.0", + Version: istioversion.Default, Values: &v1.CNIValues{ Cni: &v1.CNIConfig{ Image: ptr.Of("istiocni-test"), @@ -341,14 +341,14 @@ func TestApplyImageDigests(t *testing.T) { name: "no-user-values", config: config.OperatorConfig{ ImageDigests: map[string]config.IstioImageConfig{ - "v1.20.0": { + istioversion.Default: { CNIImage: "cni-test", }, }, }, input: &v1.IstioCNI{ Spec: v1.IstioCNISpec{ - Version: "v1.20.0", + Version: istioversion.Default, Values: &v1.CNIValues{}, }, }, @@ -362,14 +362,14 @@ func TestApplyImageDigests(t *testing.T) { name: "user-supplied-image", config: config.OperatorConfig{ ImageDigests: map[string]config.IstioImageConfig{ - "v1.20.0": { + istioversion.Default: { CNIImage: "cni-test", }, }, }, input: &v1.IstioCNI{ Spec: v1.IstioCNISpec{ - Version: "v1.20.0", + Version: istioversion.Default, Values: &v1.CNIValues{ Cni: &v1.CNIConfig{ Image: ptr.Of("cni-custom"), @@ -387,14 +387,14 @@ func TestApplyImageDigests(t *testing.T) { name: "user-supplied-hub-tag", config: config.OperatorConfig{ ImageDigests: map[string]config.IstioImageConfig{ - "v1.20.0": { + istioversion.Default: { CNIImage: "cni-test", }, }, }, input: &v1.IstioCNI{ Spec: v1.IstioCNISpec{ - Version: "v1.20.0", + Version: istioversion.Default, Values: &v1.CNIValues{ Cni: &v1.CNIConfig{ Hub: ptr.Of("docker.io/istio"), @@ -414,14 +414,14 @@ func TestApplyImageDigests(t *testing.T) { name: "version-without-defaults", config: config.OperatorConfig{ ImageDigests: map[string]config.IstioImageConfig{ - "v1.20.0": { + istioversion.Default: { CNIImage: "cni-test", }, }, }, input: &v1.IstioCNI{ Spec: v1.IstioCNISpec{ - Version: "v1.20.1", + Version: istioversion.Default, Values: &v1.CNIValues{ Cni: &v1.CNIConfig{ Hub: ptr.Of("docker.io/istio"), @@ -440,7 +440,11 @@ func TestApplyImageDigests(t *testing.T) { } for _, tc := range testCases { t.Run(tc.name, func(t *testing.T) { - result := applyImageDigests(tc.input, tc.input.Spec.Values, tc.config) + version, err := istioversion.Resolve(tc.input.Spec.Version) + if err != nil { + t.Errorf("failed to resolve IstioCNI version for %q: %v", tc.input.Name, err) + } + result := applyImageDigests(version, tc.input.Spec.Values, tc.config) if diff := cmp.Diff(tc.expectValues, result); diff != "" { t.Errorf("unexpected merge result; diff (-expected, +actual):\n%v", diff) } diff --git a/controllers/istiorevision/istiorevision_controller_test.go b/controllers/istiorevision/istiorevision_controller_test.go index 1f9eaea85..8e6fc9bdd 100644 --- a/controllers/istiorevision/istiorevision_controller_test.go +++ b/controllers/istiorevision/istiorevision_controller_test.go @@ -23,8 +23,8 @@ import ( v1 "github.com/istio-ecosystem/sail-operator/api/v1" "github.com/istio-ecosystem/sail-operator/pkg/config" "github.com/istio-ecosystem/sail-operator/pkg/constants" + "github.com/istio-ecosystem/sail-operator/pkg/istioversion" "github.com/istio-ecosystem/sail-operator/pkg/scheme" - "github.com/istio-ecosystem/sail-operator/pkg/test/util/supportedversion" . "github.com/onsi/gomega" admissionv1 "k8s.io/api/admissionregistration/v1" appsv1 "k8s.io/api/apps/v1" @@ -60,7 +60,7 @@ func TestValidate(t *testing.T) { Name: "default", }, Spec: v1.IstioRevisionSpec{ - Version: supportedversion.Default, + Version: istioversion.Default, Namespace: "istio-system", Values: &v1.Values{ Global: &v1.GlobalConfig{ @@ -92,7 +92,7 @@ func TestValidate(t *testing.T) { Name: "default", }, Spec: v1.IstioRevisionSpec{ - Version: supportedversion.Default, + Version: istioversion.Default, }, }, objects: []client.Object{ns}, @@ -105,7 +105,7 @@ func TestValidate(t *testing.T) { Name: "default", }, Spec: v1.IstioRevisionSpec{ - Version: supportedversion.Default, + Version: istioversion.Default, Namespace: "istio-system", }, }, @@ -119,7 +119,7 @@ func TestValidate(t *testing.T) { Name: "default", }, Spec: v1.IstioRevisionSpec{ - Version: supportedversion.Default, + Version: istioversion.Default, Namespace: "istio-system", }, }, @@ -133,7 +133,7 @@ func TestValidate(t *testing.T) { Name: "default", }, Spec: v1.IstioRevisionSpec{ - Version: supportedversion.Default, + Version: istioversion.Default, Namespace: "istio-system", Values: &v1.Values{ Global: &v1.GlobalConfig{ @@ -152,7 +152,7 @@ func TestValidate(t *testing.T) { Name: "default", }, Spec: v1.IstioRevisionSpec{ - Version: supportedversion.Default, + Version: istioversion.Default, Namespace: "istio-system", Values: &v1.Values{ Revision: ptr.Of("my-revision"), @@ -172,7 +172,7 @@ func TestValidate(t *testing.T) { Name: "my-revision", }, Spec: v1.IstioRevisionSpec{ - Version: supportedversion.Default, + Version: istioversion.Default, Namespace: "istio-system", Values: &v1.Values{ Revision: ptr.Of("other-revision"), diff --git a/controllers/ztunnel/ztunnel_controller.go b/controllers/ztunnel/ztunnel_controller.go index 966bc9f7f..0d11591f9 100644 --- a/controllers/ztunnel/ztunnel_controller.go +++ b/controllers/ztunnel/ztunnel_controller.go @@ -30,6 +30,7 @@ import ( "github.com/istio-ecosystem/sail-operator/pkg/errlist" "github.com/istio-ecosystem/sail-operator/pkg/helm" "github.com/istio-ecosystem/sail-operator/pkg/istiovalues" + "github.com/istio-ecosystem/sail-operator/pkg/istioversion" "github.com/istio-ecosystem/sail-operator/pkg/kube" "github.com/istio-ecosystem/sail-operator/pkg/predicate" "github.com/istio-ecosystem/sail-operator/pkg/reconciler" @@ -135,6 +136,10 @@ func (r *Reconciler) installHelmChart(ctx context.Context, ztunnel *v1alpha1.ZTu BlockOwnerDeletion: ptr.Of(true), } + version, err := istioversion.Resolve(ztunnel.Spec.Version) + if err != nil { + return fmt.Errorf("failed to resolve Ztunnel version for %q: %w", ztunnel.Name, err) + } // get userValues from ztunnel.spec.values userValues := ztunnel.Spec.Values @@ -152,7 +157,7 @@ func (r *Reconciler) installHelmChart(ctx context.Context, ztunnel *v1alpha1.ZTu // apply userValues on top of defaultValues from profiles mergedHelmValues, err := istiovalues.ApplyProfilesAndPlatform( - r.Config.ResourceDirectory, ztunnel.Spec.Version, r.Config.Platform, r.Config.DefaultProfile, ztunnel.Spec.Profile, helm.FromValues(userValues)) + r.Config.ResourceDirectory, version, r.Config.Platform, r.Config.DefaultProfile, ztunnel.Spec.Profile, helm.FromValues(userValues)) if err != nil { return fmt.Errorf("failed to apply profile: %w", err) } @@ -166,19 +171,19 @@ func (r *Reconciler) installHelmChart(ctx context.Context, ztunnel *v1alpha1.ZTu return fmt.Errorf("failed to apply user overrides: %w", err) } - _, err = r.ChartManager.UpgradeOrInstallChart(ctx, r.getChartDir(ztunnel), finalHelmValues, ztunnel.Spec.Namespace, ztunnelChart, ownerReference) + _, err = r.ChartManager.UpgradeOrInstallChart(ctx, r.getChartDir(version), finalHelmValues, ztunnel.Spec.Namespace, ztunnelChart, ownerReference) if err != nil { return fmt.Errorf("failed to install/update Helm chart %q: %w", ztunnelChart, err) } return nil } -func (r *Reconciler) getChartDir(ztunnel *v1alpha1.ZTunnel) string { - return path.Join(r.Config.ResourceDirectory, ztunnel.Spec.Version, "charts", ztunnelChart) +func (r *Reconciler) getChartDir(version string) string { + return path.Join(r.Config.ResourceDirectory, version, "charts", ztunnelChart) } -func applyImageDigests(ztunnel *v1alpha1.ZTunnel, values *v1.ZTunnelValues, config config.OperatorConfig) *v1.ZTunnelValues { - imageDigests, digestsDefined := config.ImageDigests[ztunnel.Spec.Version] +func applyImageDigests(version string, values *v1.ZTunnelValues, config config.OperatorConfig) *v1.ZTunnelValues { + imageDigests, digestsDefined := config.ImageDigests[version] // if we don't have default image digests defined for this version, it's a no-op if !digestsDefined { return values diff --git a/controllers/ztunnel/ztunnel_controller_test.go b/controllers/ztunnel/ztunnel_controller_test.go index c409e4866..ae6fe3aeb 100644 --- a/controllers/ztunnel/ztunnel_controller_test.go +++ b/controllers/ztunnel/ztunnel_controller_test.go @@ -24,8 +24,8 @@ import ( v1 "github.com/istio-ecosystem/sail-operator/api/v1" "github.com/istio-ecosystem/sail-operator/api/v1alpha1" "github.com/istio-ecosystem/sail-operator/pkg/config" + "github.com/istio-ecosystem/sail-operator/pkg/istioversion" "github.com/istio-ecosystem/sail-operator/pkg/scheme" - "github.com/istio-ecosystem/sail-operator/pkg/test/util/supportedversion" . "github.com/onsi/gomega" appsv1 "k8s.io/api/apps/v1" corev1 "k8s.io/api/core/v1" @@ -63,7 +63,7 @@ func TestValidate(t *testing.T) { Name: "default", }, Spec: v1alpha1.ZTunnelSpec{ - Version: supportedversion.Default, + Version: istioversion.Default, Namespace: ztunnelNamespace, }, }, @@ -90,7 +90,7 @@ func TestValidate(t *testing.T) { Name: "default", }, Spec: v1alpha1.ZTunnelSpec{ - Version: supportedversion.Default, + Version: istioversion.Default, }, }, objects: []client.Object{ns}, @@ -103,7 +103,7 @@ func TestValidate(t *testing.T) { Name: "default", }, Spec: v1alpha1.ZTunnelSpec{ - Version: supportedversion.Default, + Version: istioversion.Default, Namespace: ztunnelNamespace, }, }, @@ -117,7 +117,7 @@ func TestValidate(t *testing.T) { Name: "default", }, Spec: v1alpha1.ZTunnelSpec{ - Version: supportedversion.Default, + Version: istioversion.Default, Namespace: ztunnelNamespace, }, }, @@ -471,7 +471,7 @@ func TestApplyImageDigests(t *testing.T) { } for _, tc := range testCases { t.Run(tc.name, func(t *testing.T) { - result := applyImageDigests(tc.input, tc.input.Spec.Values, tc.config) + result := applyImageDigests(tc.input.Spec.Version, tc.input.Spec.Values, tc.config) if diff := cmp.Diff(tc.expectValues, result); diff != "" { t.Errorf("unexpected merge result; diff (-expected, +actual):\n%v", diff) } diff --git a/docs/api-reference/sailoperator.io.md b/docs/api-reference/sailoperator.io.md index a3a4bfc5d..aa4a9307c 100644 --- a/docs/api-reference/sailoperator.io.md +++ b/docs/api-reference/sailoperator.io.md @@ -647,7 +647,7 @@ _Appears in:_ | Field | Description | Default | Validation | | --- | --- | --- | --- | -| `version` _string_ | Defines the version of Istio to install. Must be one of: v1.24.2, v1.24.1, v1.24.0, v1.23.4, v1.23.3, v1.23.2, v1.22.8, v1.22.7, v1.22.6, v1.22.5, v1.21.6, latest. | v1.24.2 | Enum: [v1.24.2 v1.24.1 v1.24.0 v1.23.4 v1.23.3 v1.23.2 v1.22.8 v1.22.7 v1.22.6 v1.22.5 v1.21.6 latest] | +| `version` _string_ | Defines the version of Istio to install. Must be one of: v1.24-latest, v1.24.2, v1.24.1, v1.24.0, v1.23-latest, v1.23.4, v1.23.3, v1.23.2, v1.22-latest, v1.22.8, v1.22.7, v1.22.6, v1.22.5, v1.21.6, master, v1.25-alpha.c2ac935c. | v1.24.2 | Enum: [v1.24-latest v1.24.2 v1.24.1 v1.24.0 v1.23-latest v1.23.4 v1.23.3 v1.23.2 v1.22-latest v1.22.8 v1.22.7 v1.22.6 v1.22.5 v1.21.6 master v1.25-alpha.c2ac935c] | | `profile` _string_ | The built-in installation configuration profile to use. The 'default' profile is always applied. On OpenShift, the 'openshift' profile is also applied on top of 'default'. Must be one of: ambient, default, demo, empty, external, openshift-ambient, openshift, preview, remote, stable. | | Enum: [ambient default demo empty external openshift-ambient openshift preview remote stable] | | `namespace` _string_ | Namespace to which the Istio CNI component should be installed. | istio-cni | | | `values` _[CNIValues](#cnivalues)_ | Defines the values to be passed to the Helm charts when installing Istio CNI. | | | @@ -875,7 +875,7 @@ _Appears in:_ | Field | Description | Default | Validation | | --- | --- | --- | --- | -| `version` _string_ | Defines the version of Istio to install. Must be one of: v1.24.2, v1.24.1, v1.24.0, v1.23.4, v1.23.3, v1.23.2, v1.22.8, v1.22.7, v1.22.6, v1.22.5, v1.21.6, latest. | | Enum: [v1.24.2 v1.24.1 v1.24.0 v1.23.4 v1.23.3 v1.23.2 v1.22.8 v1.22.7 v1.22.6 v1.22.5 v1.21.6 latest] | +| `version` _string_ | Defines the version of Istio to install. Must be one of: v1.24.2, v1.24.1, v1.24.0, v1.23.4, v1.23.3, v1.23.2, v1.22.8, v1.22.7, v1.22.6, v1.22.5, v1.21.6, v1.25-alpha.c2ac935c. | | Enum: [v1.24.2 v1.24.1 v1.24.0 v1.23.4 v1.23.3 v1.23.2 v1.22.8 v1.22.7 v1.22.6 v1.22.5 v1.21.6 v1.25-alpha.c2ac935c] | | `namespace` _string_ | Namespace to which the Istio components should be installed. | | | | `values` _[Values](#values)_ | Defines the values to be passed to the Helm charts when installing Istio. | | | @@ -1068,7 +1068,7 @@ _Appears in:_ | Field | Description | Default | Validation | | --- | --- | --- | --- | -| `version` _string_ | Defines the version of Istio to install. Must be one of: v1.24.2, v1.24.1, v1.24.0, v1.23.4, v1.23.3, v1.23.2, v1.22.8, v1.22.7, v1.22.6, v1.22.5, v1.21.6, latest. | v1.24.2 | Enum: [v1.24.2 v1.24.1 v1.24.0 v1.23.4 v1.23.3 v1.23.2 v1.22.8 v1.22.7 v1.22.6 v1.22.5 v1.21.6 latest] | +| `version` _string_ | Defines the version of Istio to install. Must be one of: v1.24-latest, v1.24.2, v1.24.1, v1.24.0, v1.23-latest, v1.23.4, v1.23.3, v1.23.2, v1.22-latest, v1.22.8, v1.22.7, v1.22.6, v1.22.5, v1.21.6, master, v1.25-alpha.c2ac935c. | v1.24.2 | Enum: [v1.24-latest v1.24.2 v1.24.1 v1.24.0 v1.23-latest v1.23.4 v1.23.3 v1.23.2 v1.22-latest v1.22.8 v1.22.7 v1.22.6 v1.22.5 v1.21.6 master v1.25-alpha.c2ac935c] | | `updateStrategy` _[IstioUpdateStrategy](#istioupdatestrategy)_ | Defines the update strategy to use when the version in the Istio CR is updated. | \{ type:InPlace \} | | | `profile` _string_ | The built-in installation configuration profile to use. The 'default' profile is always applied. On OpenShift, the 'openshift' profile is also applied on top of 'default'. Must be one of: ambient, default, demo, empty, external, openshift-ambient, openshift, preview, remote, stable. | | Enum: [ambient default demo empty external openshift-ambient openshift preview remote stable] | | `namespace` _string_ | Namespace to which the Istio components should be installed. Note that this field is immutable. | istio-system | | @@ -3341,7 +3341,7 @@ _Appears in:_ | Field | Description | Default | Validation | | --- | --- | --- | --- | -| `version` _string_ | Defines the version of Istio to install. Must be one of: v1.24.2, v1.24.1, v1.24.0, latest. | v1.24.2 | Enum: [v1.24.2 v1.24.1 v1.24.0 latest] | +| `version` _string_ | Defines the version of Istio to install. Must be one of: v1.24-latest, v1.24.2, v1.24.1, v1.24.0, master, v1.25-alpha.c2ac935c. | v1.24.2 | Enum: [v1.24-latest v1.24.2 v1.24.1 v1.24.0 master v1.25-alpha.c2ac935c] | | `profile` _string_ | The built-in installation configuration profile to use. The 'default' profile is 'ambient' and it is always applied. Must be one of: ambient, default, demo, empty, external, preview, remote, stable. | ambient | Enum: [ambient default demo empty external openshift-ambient openshift preview remote stable] | | `namespace` _string_ | Namespace to which the Istio ztunnel component should be installed. | ztunnel | | | `values` _[ZTunnelValues](#ztunnelvalues)_ | Defines the values to be passed to the Helm charts when installing Istio ztunnel. | | | diff --git a/hack/patch-csv.sh b/hack/patch-csv.sh index a5f5cfbd2..5f057030b 100755 --- a/hack/patch-csv.sh +++ b/hack/patch-csv.sh @@ -17,6 +17,7 @@ set -euo pipefail VERSIONS_YAML_FILE=${VERSIONS_YAML_FILE:-"versions.yaml"} +VERSIONS_YAML_DIR=${VERSIONS_YAML_DIR:-"pkg/istioversion"} : "${YQ:=yq}" @@ -98,7 +99,7 @@ if [ $# -ne 1 ]; then fi clusterserviceversion_file_path="$1" -versions="$( ${YQ} '.versions[].name' "${VERSIONS_YAML_FILE}" )" +versions="$( ${YQ} '.versions[] | select(. | has("ref") | not) | .name' "${VERSIONS_YAML_DIR}/${VERSIONS_YAML_FILE}" )" for version in ${versions}; do version_underscore=${version//./_} diff --git a/hack/remove-old-versions.sh b/hack/remove-old-versions.sh index 0bf2b8b92..294bc7620 100755 --- a/hack/remove-old-versions.sh +++ b/hack/remove-old-versions.sh @@ -17,9 +17,10 @@ set -euo pipefail VERSIONS_YAML_FILE=${VERSIONS_YAML_FILE:-"versions.yaml"} +VERSIONS_YAML_DIR=${VERSIONS_YAML_DIR:-"pkg/istioversion"} function removeOldVersions() { - versions=$(yq eval '.versions[].name' "${VERSIONS_YAML_FILE}" | tr $'\n' ' ') + versions=$(yq eval '.versions[].name' "${VERSIONS_YAML_DIR}/${VERSIONS_YAML_FILE}" | tr $'\n' ' ') for subdirectory in resources/*/; do version=$(basename "$subdirectory") if [[ ! " ${versions} " == *" $version "* ]]; then diff --git a/hack/update-istio.sh b/hack/update-istio.sh index 43d7efb43..f5df3c58d 100755 --- a/hack/update-istio.sh +++ b/hack/update-istio.sh @@ -17,7 +17,9 @@ set -euo pipefail SLEEP_TIME=10 +VERSIONS_YAML_DIR=${VERSIONS_YAML_DIR:-"pkg/istioversion"} VERSIONS_YAML_FILE=${VERSIONS_YAML_FILE:-"versions.yaml"} +VERSIONS_YAML_PATH=${VERSIONS_YAML_DIR}/${VERSIONS_YAML_FILE} # Add a new entry in versions.yaml file. # First argument is the new version (e.g. 1.22.5) @@ -56,7 +58,14 @@ END (.[] | select(.name == "v'"${2}"'") | key) as $pos | .[:$pos] + ['"${template}"'] + - .[$pos:])' "${VERSIONS_YAML_FILE}" + .[$pos:])' "${VERSIONS_YAML_PATH}" +} + +function update_alias() { + local name="${1}" + local ref="${2}" + echo "Updating alias ${name} to point to ${ref}" + yq eval "( .versions[] | select(.name == \"${name}\").ref ) = \"${ref}\"" -i "${VERSIONS_YAML_PATH}" } # Given an input with potentially several major.minor versions, list only the latest one @@ -75,6 +84,9 @@ function list_only_latest() { local current tmp="" while read -r input; do IFS="." read -r -a version <<< "${input}" + if [ "${#version[@]}" -lt "3" ]; then + continue + fi current="${version[0]}.${version[1]}" if [[ "${current}" != "${tmp}" ]]; then echo "${input}" @@ -85,8 +97,7 @@ function list_only_latest() { function update_stable() { all_releases=$(curl -sL "https://api.github.com/repos/istio/istio/releases" | yq '.[].tag_name' -oy) - supported_versions=$(yq '.versions[] | .name' "${VERSIONS_YAML_FILE}" | grep -v latest | list_only_latest) - + supported_versions=$(yq '.versions[] | select(.name != "*.*-*.*") | .name' "${VERSIONS_YAML_PATH}" | list_only_latest) # For each supported version, look for a greater version in the all_releases list for version in ${supported_versions}; do version="${version:1}" # remove 'v' prefix, e.g. v1.21.0 => 1.21.0 @@ -94,20 +105,22 @@ function update_stable() { latest_release=$(echo "${all_releases}" | grep "${version_array[0]}.${version_array[1]}." | head -1) # get the latest release for "major.minor" if [[ "${version}" != "${latest_release}" ]]; then add_stable_version "${latest_release}" "${version}" + update_alias "v${version_array[0]}.${version_array[1]}-latest" "v${latest_release}" fi done } -function update_latest() { - COMMIT=$(yq '.versions[] | select(.name == "latest") | "git ls-remote --heads " + .repo + ".git " + .branch + " | cut -f 1"' "${VERSIONS_YAML_FILE}" | sh) - CURRENT=$(yq '.versions[] | select(.name == "latest") | .commit' "${VERSIONS_YAML_FILE}") +function update_prerelease() { + VERSION_CURRENT=$(yq '.versions[] | select(.name == "*.*-*") | .name' "${VERSIONS_YAML_PATH}") + COMMIT=$(yq '.versions[] | select(.name == '\""${VERSION_CURRENT}"\"') | "git ls-remote --heads " + .repo + ".git " + .branch + " | cut -f 1"' "${VERSIONS_YAML_PATH}" | sh) + CURRENT=$(yq '.versions[] | select(.name == '\""${VERSION_CURRENT}"\"') | .commit' "${VERSIONS_YAML_PATH}") if [ "${COMMIT}" == "${CURRENT}" ]; then - echo "${VERSIONS_YAML_FILE} is already up-to-date with latest commit ${COMMIT}." + echo "${VERSIONS_YAML_PATH} is already up-to-date with latest commit ${COMMIT}." return fi - echo Updating version 'latest' to commit "${COMMIT}" + echo Updating "${VERSION_CURRENT}" to commit "${COMMIT}" echo "Verifying the artifacts are available on GCS, this might take a while - you can abort the wait with CTRL+C" URL="https://storage.googleapis.com/istio-build/dev/${COMMIT}" @@ -117,20 +130,25 @@ function update_latest() { done echo - VERSION=$(curl -sSfL "${URL}") - echo Version: "${VERSION}" + full_version=$(curl -sSfL "${URL}") + IFS="." read -r -a version_array <<< "${full_version}" # split version into an array for major, minor and patch + patch_version=${version_array[2]:0:8} # cutoff commit at 8 chars + VERSION=${version_array[0]}.${version_array[1]}.${patch_version} + echo New version: "${VERSION}" yq -i ' - (.versions[] | select(.name == "latest") | .version) = "'"${VERSION}"'" | - (.versions[] | select(.name == "latest") | .commit) = "'"${COMMIT}"'" | - (.versions[] | select(.name == "latest") | .charts) = [ - "https://storage.googleapis.com/istio-build/dev/'"${VERSION}"'/helm/base-'"${VERSION}"'.tgz", - "https://storage.googleapis.com/istio-build/dev/'"${VERSION}"'/helm/cni-'"${VERSION}"'.tgz", - "https://storage.googleapis.com/istio-build/dev/'"${VERSION}"'/helm/gateway-'"${VERSION}"'.tgz", - "https://storage.googleapis.com/istio-build/dev/'"${VERSION}"'/helm/istiod-'"${VERSION}"'.tgz", - "https://storage.googleapis.com/istio-build/dev/'"${VERSION}"'/helm/ztunnel-'"${VERSION}"'.tgz" - ]' "${VERSIONS_YAML_FILE}" + (.versions[] | select(.name == "'"${VERSION_CURRENT}"'") | .version) = "'"${full_version}"'" | + (.versions[] | select(.name == "'"${VERSION_CURRENT}"'") | .commit) = "'"${COMMIT}"'" | + (.versions[] | select(.name == "'"${VERSION_CURRENT}"'") | .charts) = [ + "https://storage.googleapis.com/istio-build/dev/'"${full_version}"'/helm/base-'"${full_version}"'.tgz", + "https://storage.googleapis.com/istio-build/dev/'"${full_version}"'/helm/cni-'"${full_version}"'.tgz", + "https://storage.googleapis.com/istio-build/dev/'"${full_version}"'/helm/gateway-'"${full_version}"'.tgz", + "https://storage.googleapis.com/istio-build/dev/'"${full_version}"'/helm/istiod-'"${full_version}"'.tgz", + "https://storage.googleapis.com/istio-build/dev/'"${full_version}"'/helm/ztunnel-'"${full_version}"'.tgz" + ] | + (.versions[] | select(.name == "'"${VERSION_CURRENT}"'") | .name) = "'"${VERSION}"'"' "${VERSIONS_YAML_PATH}" + update_alias "master" "v${VERSION}" } update_stable -update_latest +update_prerelease diff --git a/hack/update-version-list.sh b/hack/update-version-list.sh index cd7c66252..0bd693301 100755 --- a/hack/update-version-list.sh +++ b/hack/update-version-list.sh @@ -16,14 +16,16 @@ set -euo pipefail +VERSIONS_YAML_DIR=${VERSIONS_YAML_DIR:-"pkg/istioversion"} VERSIONS_YAML_FILE=${VERSIONS_YAML_FILE:-"versions.yaml"} +VERSIONS_YAML_PATH=${VERSIONS_YAML_DIR}/${VERSIONS_YAML_FILE} HELM_VALUES_FILE=${HELM_VALUES_FILE:-"chart/values.yaml"} function updateVersionsInIstioTypeComment() { - selectValues=$(yq '.versions[].name | ", \"urn:alm:descriptor:com.tectonic.ui:select:" + . + "\""' "${VERSIONS_YAML_FILE}" | tr -d '\n') - versionsEnum=$(yq '.versions[].name' "${VERSIONS_YAML_FILE}" | tr '\n' ';' | sed 's/;$//g') - versions=$(yq '.versions[].name' "${VERSIONS_YAML_FILE}" | tr '\n' ',' | sed -e 's/,/, /g' -e 's/, $//g') - defaultVersion=$(yq '.versions[0].name' "${VERSIONS_YAML_FILE}") + selectValues=$(yq '.versions[].name | ", \"urn:alm:descriptor:com.tectonic.ui:select:" + . + "\""' "${VERSIONS_YAML_PATH}" | tr -d '\n') + versionsEnum=$(yq '.versions[].name' "${VERSIONS_YAML_PATH}" | tr '\n' ';' | sed 's/;$//g') + versions=$(yq '.versions[].name' "${VERSIONS_YAML_PATH}" | tr '\n' ',' | sed -e 's/,/, /g' -e 's/, $//g') + defaultVersion=$(yq '.versions[1].name' "${VERSIONS_YAML_PATH}") sed -i -E \ -e "/\+sail:version/,/Version string/ s/(\/\/ \+operator-sdk:csv:customresourcedefinitions:type=spec,order=1,displayName=\"Istio Version\",xDescriptors=\{.*fieldGroup:General\")[^}]*(})/\1$selectValues}/g" \ @@ -31,13 +33,26 @@ function updateVersionsInIstioTypeComment() { -e "/\+sail:version/,/Version string/ s/(\/\/ \+kubebuilder:default=)(.*)/\1$defaultVersion/g" \ -e "/\+sail:version/,/Version string/ s/(\/\/ \Must be one of:)(.*)/\1 $versions./g" \ -e "s/(\+kubebuilder:default=.*version: \")[^\"]*\"/\1$defaultVersion\"/g" \ - api/v1/istio_types.go api/v1/istiorevision_types.go api/v1/istiocni_types.go + api/v1/istio_types.go api/v1/istiocni_types.go + + cniSelectValues=$(yq '.versions[]| select(. | has("ref") | not) | .name | ", \"urn:alm:descriptor:com.tectonic.ui:select:" + . + "\""' "${VERSIONS_YAML_PATH}" | tr -d '\n') + cniVersionsEnum=$(yq '.versions[]| select(. | has("ref") | not) | .name' "${VERSIONS_YAML_PATH}" | tr '\n' ';' | sed 's/;$//g') + cniVersions=$(yq '.versions[]| select(. | has("ref") | not) | .name' "${VERSIONS_YAML_PATH}" | tr '\n' ',' | sed -e 's/,/, /g' -e 's/, $//g') + + + sed -i -E \ + -e "/\+sail:version/,/Version string/ s/(\/\/ \+operator-sdk:csv:customresourcedefinitions:type=spec,order=1,displayName=\"Istio Version\",xDescriptors=\{.*fieldGroup:General\")[^}]*(})/\1$cniSelectValues}/g" \ + -e "/\+sail:version/,/Version string/ s/(\/\/ \+kubebuilder:validation:Enum=)(.*)/\1$cniVersionsEnum/g" \ + -e "/\+sail:version/,/Version string/ s/(\/\/ \+kubebuilder:default=)(.*)/\1$defaultVersion/g" \ + -e "/\+sail:version/,/Version string/ s/(\/\/ \Must be one of:)(.*)/\1 $cniVersions./g" \ + -e "s/(\+kubebuilder:default=.*version: \")[^\"]*\"/\1$defaultVersion\"/g" \ + api/v1/istiorevision_types.go # Ambient mode in Sail Operator is supported starting with Istio version 1.24+ # TODO: Once support for versions prior to 1.24 is discontinued, we can merge the ztunnel specific changes below with the other components. - ztunnelselectValues=$(yq '.versions[] | select(.version >= "1.24.0") | ", \"urn:alm:descriptor:com.tectonic.ui:select:" + .name + "\""' "${VERSIONS_YAML_FILE}" | tr -d '\n') - ztunnelversionsEnum=$(yq '.versions[] | select(.version >= "1.24.0") | .name' "${VERSIONS_YAML_FILE}" | tr '\n' ';' | sed 's/;$//g') - ztunnelversions=$(yq '.versions[] | select(.version >= "1.24.0") | .name' "${VERSIONS_YAML_FILE}" | tr '\n' ',' | sed -e 's/,/, /g' -e 's/, $//g') + ztunnelselectValues=$(yq '.versions[] | select(.version >= "1.24.0" or .ref >= "v1.24.0") | ", \"urn:alm:descriptor:com.tectonic.ui:select:" + .name + "\""' "${VERSIONS_YAML_PATH}" | tr -d '\n') + ztunnelversionsEnum=$(yq '.versions[] | select(.version >= "1.24.0" or .ref >= "v1.24.0") | .name' "${VERSIONS_YAML_PATH}" | tr '\n' ';' | sed 's/;$//g') + ztunnelversions=$(yq '.versions[] | select(.version >= "1.24.0" or .ref >= "v1.24.0") | .name' "${VERSIONS_YAML_PATH}" | tr '\n' ',' | sed -e 's/,/, /g' -e 's/, $//g') sed -i -E \ -e "/\+sail:version/,/Version string/ s/(\/\/ \+operator-sdk:csv:customresourcedefinitions:type=spec,order=1,displayName=\"Istio Version\",xDescriptors=\{.*fieldGroup:General\")[^}]*(})/\1$ztunnelselectValues}/g" \ @@ -56,7 +71,7 @@ function updateVersionsInCSVDescription() { # - stores latest commit in $latestCommit # - iterates over keys and prints them; if the key is "latest", appends the hash stored in $latestCommit # shellcheck disable=SC2016 - yq '(.versions[] | select(.name == "latest") | .commit) as $latestCommit | .versions[].name | (select(. == "latest") | . + " (" + $latestCommit + ")") // .' "${VERSIONS_YAML_FILE}" > "$tmpFile" + yq '(.versions[] | select(.name == "master") | .commit) as $latestCommit | .versions[].name | (select(. == "master") | . + " (" + $latestCommit + ")") // .' "${VERSIONS_YAML_PATH}" > "$tmpFile" # truncate the latest commit hash to 8 characters sed -i -E 's/(latest \(.{8}).*\)/\1\)/g' "$tmpFile" @@ -84,7 +99,7 @@ function updateVersionsInCSVDescription() { } function updateVersionInSamples() { - defaultVersion=$(yq '.versions[0].name' "${VERSIONS_YAML_FILE}") + defaultVersion=$(yq '.versions[1].name' "${VERSIONS_YAML_PATH}") sed -i -E \ -e "s/version: .*/version: $defaultVersion/g" \ diff --git a/pkg/istioversion/version.go b/pkg/istioversion/version.go new file mode 100644 index 000000000..4823d0c90 --- /dev/null +++ b/pkg/istioversion/version.go @@ -0,0 +1,139 @@ +// Copyright Istio Authors +// +// 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 istioversion + +import ( + "embed" + "fmt" + + "github.com/Masterminds/semver/v3" + "gopkg.in/yaml.v3" + + "istio.io/istio/pkg/log" +) + +var ( + //go:embed *.yaml + versionsFiles embed.FS + + versionsFilename = "versions.yaml" +) + +// Versions represents the top-level structure of versions.yaml +type Versions struct { + Versions []VersionInfo `json:"versions"` +} + +// AliasInfo contains information about version aliases +type AliasInfo struct { + Name string `json:"name"` + Ref string `json:"ref"` +} + +// VersionInfo contains information about a specific Istio version +type VersionInfo struct { + Name string `json:"name"` + Ref string `json:"ref"` + Version *semver.Version `json:"version"` + Repo string `json:"repo"` + Branch string `json:"branch,omitempty"` + Commit string `json:"commit"` + Charts []string `json:"charts,omitempty"` +} + +var ( + // List contains all supported versions. Does not include aliases + List []VersionInfo + // Map contains version info mapped by version name. Includes mappings for aliases + Map map[string]VersionInfo + // Default is the default version + Default string + // Old is the previous supported version + Old string + // New is the latest supported version + New string + // aliasList is the alias for the version + aliasList []AliasInfo +) + +func Resolve(version string) (string, error) { + info, ok := Map[version] + if !ok { + return "", fmt.Errorf("version %q not found", version) + } + return info.Name, nil +} + +func init() { + log.Info("loading supported istio versions from " + versionsFilename) + // Read the embedded versions.yaml file + data, err := versionsFiles.ReadFile(versionsFilename) + if err != nil { + panic(fmt.Errorf("failed to read versions from '%s': %w", versionsFilename, err)) + } + + List, Default, Old, New, Map, aliasList = mustParseVersionsYaml(data) +} + +func mustParseVersionsYaml(yamlBytes []byte) ( + list []VersionInfo, + defaultVersion string, + oldVersion string, + newVersion string, + versionMap map[string]VersionInfo, + aliasList []AliasInfo, +) { + versions := Versions{} + err := yaml.Unmarshal(yamlBytes, &versions) + if err != nil { + panic(fmt.Errorf("failed to parse versions data: %w", err)) + } + + versionMap = make(map[string]VersionInfo) + + for _, v := range versions.Versions { + if v.Ref == "" { + list = append(list, v) + versionMap[v.Name] = v + } else { + if v.Version != nil || v.Repo != "" || v.Commit != "" || v.Branch != "" || len(v.Charts) > 0 { + panic(fmt.Errorf("version %q has aliasFor set but the other fields cannot be specified", v.Name)) + } + aliasList = append(aliasList, AliasInfo{ + Name: v.Name, + Ref: v.Ref, + }) + } + } + + // Process aliases after all versions are in the lookup map + for _, a := range aliasList { + v, ok := versionMap[a.Ref] + if !ok { + panic(fmt.Errorf("version %q not found", a.Ref)) + } + versionMap[a.Name] = v + } + + if len(list) > 0 { + newVersion = list[0].Name + defaultVersion = newVersion + if len(list) > 1 { + oldVersion = list[1].Name + } + } + + return list, defaultVersion, oldVersion, newVersion, versionMap, aliasList +} diff --git a/pkg/istioversion/version_test.go b/pkg/istioversion/version_test.go new file mode 100644 index 000000000..b37eaa82e --- /dev/null +++ b/pkg/istioversion/version_test.go @@ -0,0 +1,145 @@ +// Copyright Istio Authors +// +// 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 istioversion + +import ( + "slices" + "testing" + + "github.com/stretchr/testify/assert" +) + +func TestInit(t *testing.T) { + // no need to call init(), since it's called automatically + assert.True(t, len(List) > 0, "istioversions.List should not be empty") + assert.True(t, len(Map) > 0, "istioversions.Map should not be empty") + assert.True(t, Default != "", "istioversions.Default should not be empty") + assert.True(t, Old != "", "istioversions.Old should not be empty") + assert.True(t, New != "", "istioversions.New should not be empty") + + assert.Equal(t, len(List)+len(aliasList), len(Map), "Map should have at least as many entries as List + Aliases") + for _, vi := range List { + assert.Equal(t, vi, Map[vi.Name]) + } + for _, ai := range aliasList { + assert.Equal(t, + List[slices.IndexFunc(List, func(v VersionInfo) bool { return v.Name == ai.Ref })], + Map[ai.Name]) + } +} + +func TestParseVersionsYaml_ValidYaml(t *testing.T) { + yamlBytes := []byte(` +versions: + - name: "v1.0.0" + version: 1.0.0 + repo: "repo1" + commit: "commit1" + - name: "latest" + ref: v2.0.0 + - name: "v2.0.0" + version: 2.0.0 + repo: "repo2" + commit: "commit2" +`) + + list, defaultVersion, oldVersion, newVersion, versionMap, aliasList := mustParseVersionsYaml(yamlBytes) + + assert.Len(t, list, 2) + assert.Equal(t, "v1.0.0", defaultVersion) + assert.Equal(t, "v2.0.0", oldVersion) + assert.Equal(t, "v1.0.0", newVersion) + + // Test version map + assert.Len(t, versionMap, 3) // 2 versions + 1 alias + assert.Equal(t, "v2.0.0", versionMap["latest"].Name) + assert.Equal(t, list[0], versionMap[list[0].Name]) + assert.Equal(t, list[1], versionMap[list[1].Name]) + + // Test alias list + assert.Len(t, aliasList, 1) + assert.Equal(t, "latest", aliasList[0].Name) + assert.Equal(t, "v2.0.0", aliasList[0].Ref) + + Map = versionMap + resolved, err := Resolve("latest") + assert.NoError(t, err) + assert.Equal(t, "v2.0.0", resolved) + + resolved, err = Resolve("nonexistent-version") + assert.Error(t, err) + assert.Equal(t, "", resolved) +} + +func TestParseVersionsYaml_SingleVersion(t *testing.T) { + yamlBytes := []byte(` +versions: + - name: "v1.0.0" + version: 1.0.0 + repo: "repo1" + commit: "commit1" +`) + + list, defaultVersion, oldVersion, newVersion, versionMap, aliasList := mustParseVersionsYaml(yamlBytes) + + assert.Len(t, list, 1) + assert.Equal(t, "v1.0.0", defaultVersion) + assert.Equal(t, "", oldVersion) + assert.Equal(t, "v1.0.0", newVersion) + assert.Len(t, versionMap, 1) + assert.Len(t, aliasList, 0) + assert.Equal(t, list[0], versionMap[list[0].Name]) +} + +func TestParseVersionsYaml_InvalidAlias(t *testing.T) { + yamlBytes := []byte(` +versions: + - name: "1.0-latest" + ref: v1.0.0 + - name: "v2.0.0" + version: 2.0.0 + repo: "repo1" + commit: "commit1" +`) + + assert.Panics(t, func() { + mustParseVersionsYaml(yamlBytes) + }) +} + +func TestParseVersionsYaml_InvalidAliasWithOtherFields(t *testing.T) { + yamlBytes := []byte(` +versions: + - name: "2.0-latest" + ref: v2.0.0 + repo: "should-not-have-this" + - name: "v2.0.0" + version: 2.0.0 + repo: "repo1" + commit: "commit1" +`) + + assert.Panics(t, func() { + mustParseVersionsYaml(yamlBytes) + }) +} + +func TestParseVersionsYaml_InvalidYaml(t *testing.T) { + yamlBytes := []byte(`invalid yaml`) + + assert.Panics(t, func() { + mustParseVersionsYaml(yamlBytes) + }) +} diff --git a/versions.yaml b/pkg/istioversion/versions.yaml similarity index 97% rename from versions.yaml rename to pkg/istioversion/versions.yaml index a5e7cda4e..65cf0144e 100644 --- a/versions.yaml +++ b/pkg/istioversion/versions.yaml @@ -11,6 +11,8 @@ # go.mod affect the generated API schema for the Sail CRDs (e.g. IstioRevision), # as well as all the Istio CRDs (e.g. VirtualService). versions: + - name: v1.24-latest + ref: v1.24.2 - name: v1.24.2 version: 1.24.2 repo: https://github.com/istio/istio @@ -41,6 +43,8 @@ versions: - https://istio-release.storage.googleapis.com/charts/gateway-1.24.0.tgz - https://istio-release.storage.googleapis.com/charts/cni-1.24.0.tgz - https://istio-release.storage.googleapis.com/charts/ztunnel-1.24.0.tgz + - name: v1.23-latest + ref: v1.23.4 - name: v1.23.4 version: 1.23.4 repo: https://github.com/istio/istio @@ -74,6 +78,8 @@ versions: - https://istio-release.storage.googleapis.com/charts/gateway-1.23.2.tgz - https://istio-release.storage.googleapis.com/charts/cni-1.23.2.tgz - https://istio-release.storage.googleapis.com/charts/ztunnel-1.23.2.tgz + - name: v1.22-latest + ref: v1.22.8 - name: v1.22.8 version: 1.22.8 repo: https://github.com/istio/istio @@ -124,7 +130,9 @@ versions: - https://istio-release.storage.googleapis.com/charts/gateway-1.21.6.tgz - https://istio-release.storage.googleapis.com/charts/cni-1.21.6.tgz - https://istio-release.storage.googleapis.com/charts/ztunnel-1.21.6.tgz - - name: latest + - name: master + ref: v1.25-alpha.c2ac935c + - name: v1.25-alpha.c2ac935c version: 1.25-alpha.c2ac935c588899579e1cee38b205e4e6824a4638 repo: https://github.com/istio/istio branch: master diff --git a/pkg/test/util/supportedversion/supportedversion.go b/pkg/test/util/supportedversion/supportedversion.go deleted file mode 100644 index 86a89013e..000000000 --- a/pkg/test/util/supportedversion/supportedversion.go +++ /dev/null @@ -1,81 +0,0 @@ -// Copyright Istio Authors -// -// 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 supportedversion - -import ( - "os" - "path/filepath" - - "github.com/Masterminds/semver/v3" - "github.com/istio-ecosystem/sail-operator/pkg/test/project" - "gopkg.in/yaml.v3" -) - -var ( - List []VersionInfo - Map map[string]VersionInfo - Default string - Old string - New string -) - -func init() { - versionsFile := os.Getenv("VERSIONS_YAML_FILE") - if len(versionsFile) == 0 { - versionsFile = "versions.yaml" - } - versionsFile = filepath.Join(project.RootDir, versionsFile) - - versionsBytes, err := os.ReadFile(versionsFile) - if err != nil { - panic(err) - } - - List, Default, Old, New = mustParseVersionsYaml(versionsBytes) - - Map = make(map[string]VersionInfo) - for _, v := range List { - Map[v.Name] = v - } -} - -func mustParseVersionsYaml(yamlBytes []byte) (list []VersionInfo, defaultVersion string, oldVersion string, newVersion string) { - versions := Versions{} - err := yaml.Unmarshal(yamlBytes, &versions) - if err != nil { - panic(err) - } - - list = versions.Versions - defaultVersion = list[0].Name - if len(list) > 1 { - oldVersion = list[1].Name - } - newVersion = list[0].Name - return list, defaultVersion, oldVersion, newVersion -} - -type Versions struct { - Versions []VersionInfo `json:"versions"` -} - -type VersionInfo struct { - Name string `json:"name"` - Version *semver.Version `json:"version"` - Repo string `json:"repo"` - Branch string `json:"branch,omitempty"` - Commit string `json:"commit"` - Charts []string `json:"charts,omitempty"` -} diff --git a/pkg/test/util/supportedversion/supportedversion_test.go b/pkg/test/util/supportedversion/supportedversion_test.go deleted file mode 100644 index 2281cd5e0..000000000 --- a/pkg/test/util/supportedversion/supportedversion_test.go +++ /dev/null @@ -1,78 +0,0 @@ -// Copyright Istio Authors -// -// 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 supportedversion - -import ( - "testing" - - "github.com/stretchr/testify/assert" -) - -func TestInit(t *testing.T) { - // no need to call init(), since it's called automatically - assert.True(t, len(List) > 0, "supportedversion.List should not be empty") - assert.True(t, len(Map) > 0, "supportedversion.Map should not be empty") - assert.True(t, Default != "", "supportedversion.Default should not be empty") - assert.True(t, Old != "", "supportedversion.Old should not be empty") - assert.True(t, New != "", "supportedversion.New should not be empty") - - assert.Equal(t, len(List), len(Map), "Map should be same size as List") - for _, vi := range List { - assert.Equal(t, vi, Map[vi.Name]) - } -} - -func TestParseVersionsYaml_ValidYaml(t *testing.T) { - yamlBytes := []byte(` -versions: - - name: "1.0.0" - repo: "repo1" - commit: "commit1" - - name: "2.0.0" - repo: "repo2" - commit: "commit2" -`) - - list, defaultVersion, oldVersion, newVersion := mustParseVersionsYaml(yamlBytes) - - assert.Len(t, list, 2) - assert.Equal(t, "1.0.0", defaultVersion) - assert.Equal(t, "2.0.0", oldVersion) - assert.Equal(t, "1.0.0", newVersion) -} - -func TestParseVersionsYaml_SingleVersion(t *testing.T) { - yamlBytes := []byte(` -versions: - - name: "1.0.0" - repo: "repo1" - commit: "commit1" -`) - - list, defaultVersion, oldVersion, newVersion := mustParseVersionsYaml(yamlBytes) - - assert.Len(t, list, 1) - assert.Equal(t, "1.0.0", defaultVersion) - assert.Equal(t, "", oldVersion) - assert.Equal(t, "1.0.0", newVersion) -} - -func TestParseVersionsYaml_InvalidYaml(t *testing.T) { - yamlBytes := []byte(`invalid yaml`) - - assert.Panics(t, func() { - mustParseVersionsYaml(yamlBytes) - }) -} diff --git a/resources/latest/charts/base/Chart.yaml b/resources/v1.25-alpha.c2ac935c/charts/base/Chart.yaml similarity index 100% rename from resources/latest/charts/base/Chart.yaml rename to resources/v1.25-alpha.c2ac935c/charts/base/Chart.yaml diff --git a/resources/latest/charts/base/README.md b/resources/v1.25-alpha.c2ac935c/charts/base/README.md similarity index 100% rename from resources/latest/charts/base/README.md rename to resources/v1.25-alpha.c2ac935c/charts/base/README.md diff --git a/resources/latest/charts/base/files/crd-all.gen.yaml b/resources/v1.25-alpha.c2ac935c/charts/base/files/crd-all.gen.yaml similarity index 100% rename from resources/latest/charts/base/files/crd-all.gen.yaml rename to resources/v1.25-alpha.c2ac935c/charts/base/files/crd-all.gen.yaml diff --git a/resources/latest/charts/base/files/profile-ambient.yaml b/resources/v1.25-alpha.c2ac935c/charts/base/files/profile-ambient.yaml similarity index 100% rename from resources/latest/charts/base/files/profile-ambient.yaml rename to resources/v1.25-alpha.c2ac935c/charts/base/files/profile-ambient.yaml diff --git a/resources/latest/charts/base/files/profile-compatibility-version-1.22.yaml b/resources/v1.25-alpha.c2ac935c/charts/base/files/profile-compatibility-version-1.22.yaml similarity index 100% rename from resources/latest/charts/base/files/profile-compatibility-version-1.22.yaml rename to resources/v1.25-alpha.c2ac935c/charts/base/files/profile-compatibility-version-1.22.yaml diff --git a/resources/latest/charts/base/files/profile-compatibility-version-1.23.yaml b/resources/v1.25-alpha.c2ac935c/charts/base/files/profile-compatibility-version-1.23.yaml similarity index 100% rename from resources/latest/charts/base/files/profile-compatibility-version-1.23.yaml rename to resources/v1.25-alpha.c2ac935c/charts/base/files/profile-compatibility-version-1.23.yaml diff --git a/resources/latest/charts/base/files/profile-compatibility-version-1.24.yaml b/resources/v1.25-alpha.c2ac935c/charts/base/files/profile-compatibility-version-1.24.yaml similarity index 100% rename from resources/latest/charts/base/files/profile-compatibility-version-1.24.yaml rename to resources/v1.25-alpha.c2ac935c/charts/base/files/profile-compatibility-version-1.24.yaml diff --git a/resources/latest/charts/base/files/profile-demo.yaml b/resources/v1.25-alpha.c2ac935c/charts/base/files/profile-demo.yaml similarity index 100% rename from resources/latest/charts/base/files/profile-demo.yaml rename to resources/v1.25-alpha.c2ac935c/charts/base/files/profile-demo.yaml diff --git a/resources/latest/charts/base/files/profile-platform-gke.yaml b/resources/v1.25-alpha.c2ac935c/charts/base/files/profile-platform-gke.yaml similarity index 100% rename from resources/latest/charts/base/files/profile-platform-gke.yaml rename to resources/v1.25-alpha.c2ac935c/charts/base/files/profile-platform-gke.yaml diff --git a/resources/latest/charts/base/files/profile-platform-k3d.yaml b/resources/v1.25-alpha.c2ac935c/charts/base/files/profile-platform-k3d.yaml similarity index 100% rename from resources/latest/charts/base/files/profile-platform-k3d.yaml rename to resources/v1.25-alpha.c2ac935c/charts/base/files/profile-platform-k3d.yaml diff --git a/resources/latest/charts/base/files/profile-platform-k3s.yaml b/resources/v1.25-alpha.c2ac935c/charts/base/files/profile-platform-k3s.yaml similarity index 100% rename from resources/latest/charts/base/files/profile-platform-k3s.yaml rename to resources/v1.25-alpha.c2ac935c/charts/base/files/profile-platform-k3s.yaml diff --git a/resources/latest/charts/base/files/profile-platform-microk8s.yaml b/resources/v1.25-alpha.c2ac935c/charts/base/files/profile-platform-microk8s.yaml similarity index 100% rename from resources/latest/charts/base/files/profile-platform-microk8s.yaml rename to resources/v1.25-alpha.c2ac935c/charts/base/files/profile-platform-microk8s.yaml diff --git a/resources/latest/charts/base/files/profile-platform-minikube.yaml b/resources/v1.25-alpha.c2ac935c/charts/base/files/profile-platform-minikube.yaml similarity index 100% rename from resources/latest/charts/base/files/profile-platform-minikube.yaml rename to resources/v1.25-alpha.c2ac935c/charts/base/files/profile-platform-minikube.yaml diff --git a/resources/latest/charts/base/files/profile-platform-openshift.yaml b/resources/v1.25-alpha.c2ac935c/charts/base/files/profile-platform-openshift.yaml similarity index 100% rename from resources/latest/charts/base/files/profile-platform-openshift.yaml rename to resources/v1.25-alpha.c2ac935c/charts/base/files/profile-platform-openshift.yaml diff --git a/resources/latest/charts/base/files/profile-preview.yaml b/resources/v1.25-alpha.c2ac935c/charts/base/files/profile-preview.yaml similarity index 100% rename from resources/latest/charts/base/files/profile-preview.yaml rename to resources/v1.25-alpha.c2ac935c/charts/base/files/profile-preview.yaml diff --git a/resources/latest/charts/base/files/profile-remote.yaml b/resources/v1.25-alpha.c2ac935c/charts/base/files/profile-remote.yaml similarity index 100% rename from resources/latest/charts/base/files/profile-remote.yaml rename to resources/v1.25-alpha.c2ac935c/charts/base/files/profile-remote.yaml diff --git a/resources/latest/charts/base/files/profile-stable.yaml b/resources/v1.25-alpha.c2ac935c/charts/base/files/profile-stable.yaml similarity index 100% rename from resources/latest/charts/base/files/profile-stable.yaml rename to resources/v1.25-alpha.c2ac935c/charts/base/files/profile-stable.yaml diff --git a/resources/latest/charts/base/templates/NOTES.txt b/resources/v1.25-alpha.c2ac935c/charts/base/templates/NOTES.txt similarity index 100% rename from resources/latest/charts/base/templates/NOTES.txt rename to resources/v1.25-alpha.c2ac935c/charts/base/templates/NOTES.txt diff --git a/resources/latest/charts/base/templates/crds.yaml b/resources/v1.25-alpha.c2ac935c/charts/base/templates/crds.yaml similarity index 100% rename from resources/latest/charts/base/templates/crds.yaml rename to resources/v1.25-alpha.c2ac935c/charts/base/templates/crds.yaml diff --git a/resources/latest/charts/base/templates/defaultrevision-validatingadmissionpolicy.yaml b/resources/v1.25-alpha.c2ac935c/charts/base/templates/defaultrevision-validatingadmissionpolicy.yaml similarity index 100% rename from resources/latest/charts/base/templates/defaultrevision-validatingadmissionpolicy.yaml rename to resources/v1.25-alpha.c2ac935c/charts/base/templates/defaultrevision-validatingadmissionpolicy.yaml diff --git a/resources/latest/charts/base/templates/defaultrevision-validatingwebhookconfiguration.yaml b/resources/v1.25-alpha.c2ac935c/charts/base/templates/defaultrevision-validatingwebhookconfiguration.yaml similarity index 100% rename from resources/latest/charts/base/templates/defaultrevision-validatingwebhookconfiguration.yaml rename to resources/v1.25-alpha.c2ac935c/charts/base/templates/defaultrevision-validatingwebhookconfiguration.yaml diff --git a/resources/latest/charts/base/templates/reader-serviceaccount.yaml b/resources/v1.25-alpha.c2ac935c/charts/base/templates/reader-serviceaccount.yaml similarity index 100% rename from resources/latest/charts/base/templates/reader-serviceaccount.yaml rename to resources/v1.25-alpha.c2ac935c/charts/base/templates/reader-serviceaccount.yaml diff --git a/resources/latest/charts/base/templates/zzz_profile.yaml b/resources/v1.25-alpha.c2ac935c/charts/base/templates/zzz_profile.yaml similarity index 100% rename from resources/latest/charts/base/templates/zzz_profile.yaml rename to resources/v1.25-alpha.c2ac935c/charts/base/templates/zzz_profile.yaml diff --git a/resources/latest/charts/base/values.yaml b/resources/v1.25-alpha.c2ac935c/charts/base/values.yaml similarity index 100% rename from resources/latest/charts/base/values.yaml rename to resources/v1.25-alpha.c2ac935c/charts/base/values.yaml diff --git a/resources/latest/charts/cni/Chart.yaml b/resources/v1.25-alpha.c2ac935c/charts/cni/Chart.yaml similarity index 100% rename from resources/latest/charts/cni/Chart.yaml rename to resources/v1.25-alpha.c2ac935c/charts/cni/Chart.yaml diff --git a/resources/latest/charts/cni/README.md b/resources/v1.25-alpha.c2ac935c/charts/cni/README.md similarity index 100% rename from resources/latest/charts/cni/README.md rename to resources/v1.25-alpha.c2ac935c/charts/cni/README.md diff --git a/resources/latest/charts/cni/files/profile-ambient.yaml b/resources/v1.25-alpha.c2ac935c/charts/cni/files/profile-ambient.yaml similarity index 100% rename from resources/latest/charts/cni/files/profile-ambient.yaml rename to resources/v1.25-alpha.c2ac935c/charts/cni/files/profile-ambient.yaml diff --git a/resources/latest/charts/cni/files/profile-compatibility-version-1.22.yaml b/resources/v1.25-alpha.c2ac935c/charts/cni/files/profile-compatibility-version-1.22.yaml similarity index 100% rename from resources/latest/charts/cni/files/profile-compatibility-version-1.22.yaml rename to resources/v1.25-alpha.c2ac935c/charts/cni/files/profile-compatibility-version-1.22.yaml diff --git a/resources/latest/charts/cni/files/profile-compatibility-version-1.23.yaml b/resources/v1.25-alpha.c2ac935c/charts/cni/files/profile-compatibility-version-1.23.yaml similarity index 100% rename from resources/latest/charts/cni/files/profile-compatibility-version-1.23.yaml rename to resources/v1.25-alpha.c2ac935c/charts/cni/files/profile-compatibility-version-1.23.yaml diff --git a/resources/latest/charts/cni/files/profile-compatibility-version-1.24.yaml b/resources/v1.25-alpha.c2ac935c/charts/cni/files/profile-compatibility-version-1.24.yaml similarity index 100% rename from resources/latest/charts/cni/files/profile-compatibility-version-1.24.yaml rename to resources/v1.25-alpha.c2ac935c/charts/cni/files/profile-compatibility-version-1.24.yaml diff --git a/resources/latest/charts/cni/files/profile-demo.yaml b/resources/v1.25-alpha.c2ac935c/charts/cni/files/profile-demo.yaml similarity index 100% rename from resources/latest/charts/cni/files/profile-demo.yaml rename to resources/v1.25-alpha.c2ac935c/charts/cni/files/profile-demo.yaml diff --git a/resources/latest/charts/cni/files/profile-platform-gke.yaml b/resources/v1.25-alpha.c2ac935c/charts/cni/files/profile-platform-gke.yaml similarity index 100% rename from resources/latest/charts/cni/files/profile-platform-gke.yaml rename to resources/v1.25-alpha.c2ac935c/charts/cni/files/profile-platform-gke.yaml diff --git a/resources/latest/charts/cni/files/profile-platform-k3d.yaml b/resources/v1.25-alpha.c2ac935c/charts/cni/files/profile-platform-k3d.yaml similarity index 100% rename from resources/latest/charts/cni/files/profile-platform-k3d.yaml rename to resources/v1.25-alpha.c2ac935c/charts/cni/files/profile-platform-k3d.yaml diff --git a/resources/latest/charts/cni/files/profile-platform-k3s.yaml b/resources/v1.25-alpha.c2ac935c/charts/cni/files/profile-platform-k3s.yaml similarity index 100% rename from resources/latest/charts/cni/files/profile-platform-k3s.yaml rename to resources/v1.25-alpha.c2ac935c/charts/cni/files/profile-platform-k3s.yaml diff --git a/resources/latest/charts/cni/files/profile-platform-microk8s.yaml b/resources/v1.25-alpha.c2ac935c/charts/cni/files/profile-platform-microk8s.yaml similarity index 100% rename from resources/latest/charts/cni/files/profile-platform-microk8s.yaml rename to resources/v1.25-alpha.c2ac935c/charts/cni/files/profile-platform-microk8s.yaml diff --git a/resources/latest/charts/cni/files/profile-platform-minikube.yaml b/resources/v1.25-alpha.c2ac935c/charts/cni/files/profile-platform-minikube.yaml similarity index 100% rename from resources/latest/charts/cni/files/profile-platform-minikube.yaml rename to resources/v1.25-alpha.c2ac935c/charts/cni/files/profile-platform-minikube.yaml diff --git a/resources/latest/charts/cni/files/profile-platform-openshift.yaml b/resources/v1.25-alpha.c2ac935c/charts/cni/files/profile-platform-openshift.yaml similarity index 100% rename from resources/latest/charts/cni/files/profile-platform-openshift.yaml rename to resources/v1.25-alpha.c2ac935c/charts/cni/files/profile-platform-openshift.yaml diff --git a/resources/latest/charts/cni/files/profile-preview.yaml b/resources/v1.25-alpha.c2ac935c/charts/cni/files/profile-preview.yaml similarity index 100% rename from resources/latest/charts/cni/files/profile-preview.yaml rename to resources/v1.25-alpha.c2ac935c/charts/cni/files/profile-preview.yaml diff --git a/resources/latest/charts/cni/files/profile-remote.yaml b/resources/v1.25-alpha.c2ac935c/charts/cni/files/profile-remote.yaml similarity index 100% rename from resources/latest/charts/cni/files/profile-remote.yaml rename to resources/v1.25-alpha.c2ac935c/charts/cni/files/profile-remote.yaml diff --git a/resources/latest/charts/cni/files/profile-stable.yaml b/resources/v1.25-alpha.c2ac935c/charts/cni/files/profile-stable.yaml similarity index 100% rename from resources/latest/charts/cni/files/profile-stable.yaml rename to resources/v1.25-alpha.c2ac935c/charts/cni/files/profile-stable.yaml diff --git a/resources/latest/charts/cni/templates/NOTES.txt b/resources/v1.25-alpha.c2ac935c/charts/cni/templates/NOTES.txt similarity index 100% rename from resources/latest/charts/cni/templates/NOTES.txt rename to resources/v1.25-alpha.c2ac935c/charts/cni/templates/NOTES.txt diff --git a/resources/latest/charts/cni/templates/_helpers.tpl b/resources/v1.25-alpha.c2ac935c/charts/cni/templates/_helpers.tpl similarity index 100% rename from resources/latest/charts/cni/templates/_helpers.tpl rename to resources/v1.25-alpha.c2ac935c/charts/cni/templates/_helpers.tpl diff --git a/resources/latest/charts/cni/templates/clusterrole.yaml b/resources/v1.25-alpha.c2ac935c/charts/cni/templates/clusterrole.yaml similarity index 100% rename from resources/latest/charts/cni/templates/clusterrole.yaml rename to resources/v1.25-alpha.c2ac935c/charts/cni/templates/clusterrole.yaml diff --git a/resources/latest/charts/cni/templates/clusterrolebinding.yaml b/resources/v1.25-alpha.c2ac935c/charts/cni/templates/clusterrolebinding.yaml similarity index 100% rename from resources/latest/charts/cni/templates/clusterrolebinding.yaml rename to resources/v1.25-alpha.c2ac935c/charts/cni/templates/clusterrolebinding.yaml diff --git a/resources/latest/charts/cni/templates/configmap-cni.yaml b/resources/v1.25-alpha.c2ac935c/charts/cni/templates/configmap-cni.yaml similarity index 100% rename from resources/latest/charts/cni/templates/configmap-cni.yaml rename to resources/v1.25-alpha.c2ac935c/charts/cni/templates/configmap-cni.yaml diff --git a/resources/latest/charts/cni/templates/daemonset.yaml b/resources/v1.25-alpha.c2ac935c/charts/cni/templates/daemonset.yaml similarity index 100% rename from resources/latest/charts/cni/templates/daemonset.yaml rename to resources/v1.25-alpha.c2ac935c/charts/cni/templates/daemonset.yaml diff --git a/resources/latest/charts/cni/templates/network-attachment-definition.yaml b/resources/v1.25-alpha.c2ac935c/charts/cni/templates/network-attachment-definition.yaml similarity index 100% rename from resources/latest/charts/cni/templates/network-attachment-definition.yaml rename to resources/v1.25-alpha.c2ac935c/charts/cni/templates/network-attachment-definition.yaml diff --git a/resources/latest/charts/cni/templates/resourcequota.yaml b/resources/v1.25-alpha.c2ac935c/charts/cni/templates/resourcequota.yaml similarity index 100% rename from resources/latest/charts/cni/templates/resourcequota.yaml rename to resources/v1.25-alpha.c2ac935c/charts/cni/templates/resourcequota.yaml diff --git a/resources/latest/charts/cni/templates/serviceaccount.yaml b/resources/v1.25-alpha.c2ac935c/charts/cni/templates/serviceaccount.yaml similarity index 100% rename from resources/latest/charts/cni/templates/serviceaccount.yaml rename to resources/v1.25-alpha.c2ac935c/charts/cni/templates/serviceaccount.yaml diff --git a/resources/latest/charts/cni/templates/zzy_descope_legacy.yaml b/resources/v1.25-alpha.c2ac935c/charts/cni/templates/zzy_descope_legacy.yaml similarity index 100% rename from resources/latest/charts/cni/templates/zzy_descope_legacy.yaml rename to resources/v1.25-alpha.c2ac935c/charts/cni/templates/zzy_descope_legacy.yaml diff --git a/resources/latest/charts/cni/templates/zzz_profile.yaml b/resources/v1.25-alpha.c2ac935c/charts/cni/templates/zzz_profile.yaml similarity index 100% rename from resources/latest/charts/cni/templates/zzz_profile.yaml rename to resources/v1.25-alpha.c2ac935c/charts/cni/templates/zzz_profile.yaml diff --git a/resources/latest/charts/cni/values.yaml b/resources/v1.25-alpha.c2ac935c/charts/cni/values.yaml similarity index 100% rename from resources/latest/charts/cni/values.yaml rename to resources/v1.25-alpha.c2ac935c/charts/cni/values.yaml diff --git a/resources/latest/charts/gateway/Chart.yaml b/resources/v1.25-alpha.c2ac935c/charts/gateway/Chart.yaml similarity index 100% rename from resources/latest/charts/gateway/Chart.yaml rename to resources/v1.25-alpha.c2ac935c/charts/gateway/Chart.yaml diff --git a/resources/latest/charts/gateway/README.md b/resources/v1.25-alpha.c2ac935c/charts/gateway/README.md similarity index 100% rename from resources/latest/charts/gateway/README.md rename to resources/v1.25-alpha.c2ac935c/charts/gateway/README.md diff --git a/resources/latest/charts/gateway/files/profile-ambient.yaml b/resources/v1.25-alpha.c2ac935c/charts/gateway/files/profile-ambient.yaml similarity index 100% rename from resources/latest/charts/gateway/files/profile-ambient.yaml rename to resources/v1.25-alpha.c2ac935c/charts/gateway/files/profile-ambient.yaml diff --git a/resources/latest/charts/gateway/files/profile-compatibility-version-1.22.yaml b/resources/v1.25-alpha.c2ac935c/charts/gateway/files/profile-compatibility-version-1.22.yaml similarity index 100% rename from resources/latest/charts/gateway/files/profile-compatibility-version-1.22.yaml rename to resources/v1.25-alpha.c2ac935c/charts/gateway/files/profile-compatibility-version-1.22.yaml diff --git a/resources/latest/charts/gateway/files/profile-compatibility-version-1.23.yaml b/resources/v1.25-alpha.c2ac935c/charts/gateway/files/profile-compatibility-version-1.23.yaml similarity index 100% rename from resources/latest/charts/gateway/files/profile-compatibility-version-1.23.yaml rename to resources/v1.25-alpha.c2ac935c/charts/gateway/files/profile-compatibility-version-1.23.yaml diff --git a/resources/latest/charts/gateway/files/profile-compatibility-version-1.24.yaml b/resources/v1.25-alpha.c2ac935c/charts/gateway/files/profile-compatibility-version-1.24.yaml similarity index 100% rename from resources/latest/charts/gateway/files/profile-compatibility-version-1.24.yaml rename to resources/v1.25-alpha.c2ac935c/charts/gateway/files/profile-compatibility-version-1.24.yaml diff --git a/resources/latest/charts/gateway/files/profile-demo.yaml b/resources/v1.25-alpha.c2ac935c/charts/gateway/files/profile-demo.yaml similarity index 100% rename from resources/latest/charts/gateway/files/profile-demo.yaml rename to resources/v1.25-alpha.c2ac935c/charts/gateway/files/profile-demo.yaml diff --git a/resources/latest/charts/gateway/files/profile-platform-gke.yaml b/resources/v1.25-alpha.c2ac935c/charts/gateway/files/profile-platform-gke.yaml similarity index 100% rename from resources/latest/charts/gateway/files/profile-platform-gke.yaml rename to resources/v1.25-alpha.c2ac935c/charts/gateway/files/profile-platform-gke.yaml diff --git a/resources/latest/charts/gateway/files/profile-platform-k3d.yaml b/resources/v1.25-alpha.c2ac935c/charts/gateway/files/profile-platform-k3d.yaml similarity index 100% rename from resources/latest/charts/gateway/files/profile-platform-k3d.yaml rename to resources/v1.25-alpha.c2ac935c/charts/gateway/files/profile-platform-k3d.yaml diff --git a/resources/latest/charts/gateway/files/profile-platform-k3s.yaml b/resources/v1.25-alpha.c2ac935c/charts/gateway/files/profile-platform-k3s.yaml similarity index 100% rename from resources/latest/charts/gateway/files/profile-platform-k3s.yaml rename to resources/v1.25-alpha.c2ac935c/charts/gateway/files/profile-platform-k3s.yaml diff --git a/resources/latest/charts/gateway/files/profile-platform-microk8s.yaml b/resources/v1.25-alpha.c2ac935c/charts/gateway/files/profile-platform-microk8s.yaml similarity index 100% rename from resources/latest/charts/gateway/files/profile-platform-microk8s.yaml rename to resources/v1.25-alpha.c2ac935c/charts/gateway/files/profile-platform-microk8s.yaml diff --git a/resources/latest/charts/gateway/files/profile-platform-minikube.yaml b/resources/v1.25-alpha.c2ac935c/charts/gateway/files/profile-platform-minikube.yaml similarity index 100% rename from resources/latest/charts/gateway/files/profile-platform-minikube.yaml rename to resources/v1.25-alpha.c2ac935c/charts/gateway/files/profile-platform-minikube.yaml diff --git a/resources/latest/charts/gateway/files/profile-platform-openshift.yaml b/resources/v1.25-alpha.c2ac935c/charts/gateway/files/profile-platform-openshift.yaml similarity index 100% rename from resources/latest/charts/gateway/files/profile-platform-openshift.yaml rename to resources/v1.25-alpha.c2ac935c/charts/gateway/files/profile-platform-openshift.yaml diff --git a/resources/latest/charts/gateway/files/profile-preview.yaml b/resources/v1.25-alpha.c2ac935c/charts/gateway/files/profile-preview.yaml similarity index 100% rename from resources/latest/charts/gateway/files/profile-preview.yaml rename to resources/v1.25-alpha.c2ac935c/charts/gateway/files/profile-preview.yaml diff --git a/resources/latest/charts/gateway/files/profile-remote.yaml b/resources/v1.25-alpha.c2ac935c/charts/gateway/files/profile-remote.yaml similarity index 100% rename from resources/latest/charts/gateway/files/profile-remote.yaml rename to resources/v1.25-alpha.c2ac935c/charts/gateway/files/profile-remote.yaml diff --git a/resources/latest/charts/gateway/files/profile-stable.yaml b/resources/v1.25-alpha.c2ac935c/charts/gateway/files/profile-stable.yaml similarity index 100% rename from resources/latest/charts/gateway/files/profile-stable.yaml rename to resources/v1.25-alpha.c2ac935c/charts/gateway/files/profile-stable.yaml diff --git a/resources/latest/charts/gateway/templates/NOTES.txt b/resources/v1.25-alpha.c2ac935c/charts/gateway/templates/NOTES.txt similarity index 100% rename from resources/latest/charts/gateway/templates/NOTES.txt rename to resources/v1.25-alpha.c2ac935c/charts/gateway/templates/NOTES.txt diff --git a/resources/latest/charts/gateway/templates/_helpers.tpl b/resources/v1.25-alpha.c2ac935c/charts/gateway/templates/_helpers.tpl similarity index 100% rename from resources/latest/charts/gateway/templates/_helpers.tpl rename to resources/v1.25-alpha.c2ac935c/charts/gateway/templates/_helpers.tpl diff --git a/resources/latest/charts/gateway/templates/deployment.yaml b/resources/v1.25-alpha.c2ac935c/charts/gateway/templates/deployment.yaml similarity index 100% rename from resources/latest/charts/gateway/templates/deployment.yaml rename to resources/v1.25-alpha.c2ac935c/charts/gateway/templates/deployment.yaml diff --git a/resources/latest/charts/gateway/templates/hpa.yaml b/resources/v1.25-alpha.c2ac935c/charts/gateway/templates/hpa.yaml similarity index 100% rename from resources/latest/charts/gateway/templates/hpa.yaml rename to resources/v1.25-alpha.c2ac935c/charts/gateway/templates/hpa.yaml diff --git a/resources/latest/charts/gateway/templates/poddisruptionbudget.yaml b/resources/v1.25-alpha.c2ac935c/charts/gateway/templates/poddisruptionbudget.yaml similarity index 100% rename from resources/latest/charts/gateway/templates/poddisruptionbudget.yaml rename to resources/v1.25-alpha.c2ac935c/charts/gateway/templates/poddisruptionbudget.yaml diff --git a/resources/latest/charts/gateway/templates/role.yaml b/resources/v1.25-alpha.c2ac935c/charts/gateway/templates/role.yaml similarity index 100% rename from resources/latest/charts/gateway/templates/role.yaml rename to resources/v1.25-alpha.c2ac935c/charts/gateway/templates/role.yaml diff --git a/resources/latest/charts/gateway/templates/service.yaml b/resources/v1.25-alpha.c2ac935c/charts/gateway/templates/service.yaml similarity index 100% rename from resources/latest/charts/gateway/templates/service.yaml rename to resources/v1.25-alpha.c2ac935c/charts/gateway/templates/service.yaml diff --git a/resources/latest/charts/gateway/templates/serviceaccount.yaml b/resources/v1.25-alpha.c2ac935c/charts/gateway/templates/serviceaccount.yaml similarity index 100% rename from resources/latest/charts/gateway/templates/serviceaccount.yaml rename to resources/v1.25-alpha.c2ac935c/charts/gateway/templates/serviceaccount.yaml diff --git a/resources/latest/charts/gateway/templates/zzz_profile.yaml b/resources/v1.25-alpha.c2ac935c/charts/gateway/templates/zzz_profile.yaml similarity index 100% rename from resources/latest/charts/gateway/templates/zzz_profile.yaml rename to resources/v1.25-alpha.c2ac935c/charts/gateway/templates/zzz_profile.yaml diff --git a/resources/latest/charts/gateway/values.schema.json b/resources/v1.25-alpha.c2ac935c/charts/gateway/values.schema.json similarity index 100% rename from resources/latest/charts/gateway/values.schema.json rename to resources/v1.25-alpha.c2ac935c/charts/gateway/values.schema.json diff --git a/resources/latest/charts/gateway/values.yaml b/resources/v1.25-alpha.c2ac935c/charts/gateway/values.yaml similarity index 100% rename from resources/latest/charts/gateway/values.yaml rename to resources/v1.25-alpha.c2ac935c/charts/gateway/values.yaml diff --git a/resources/latest/charts/istiod/Chart.yaml b/resources/v1.25-alpha.c2ac935c/charts/istiod/Chart.yaml similarity index 100% rename from resources/latest/charts/istiod/Chart.yaml rename to resources/v1.25-alpha.c2ac935c/charts/istiod/Chart.yaml diff --git a/resources/latest/charts/istiod/README.md b/resources/v1.25-alpha.c2ac935c/charts/istiod/README.md similarity index 100% rename from resources/latest/charts/istiod/README.md rename to resources/v1.25-alpha.c2ac935c/charts/istiod/README.md diff --git a/resources/latest/charts/istiod/files/gateway-injection-template.yaml b/resources/v1.25-alpha.c2ac935c/charts/istiod/files/gateway-injection-template.yaml similarity index 100% rename from resources/latest/charts/istiod/files/gateway-injection-template.yaml rename to resources/v1.25-alpha.c2ac935c/charts/istiod/files/gateway-injection-template.yaml diff --git a/resources/latest/charts/istiod/files/grpc-agent.yaml b/resources/v1.25-alpha.c2ac935c/charts/istiod/files/grpc-agent.yaml similarity index 100% rename from resources/latest/charts/istiod/files/grpc-agent.yaml rename to resources/v1.25-alpha.c2ac935c/charts/istiod/files/grpc-agent.yaml diff --git a/resources/latest/charts/istiod/files/grpc-simple.yaml b/resources/v1.25-alpha.c2ac935c/charts/istiod/files/grpc-simple.yaml similarity index 100% rename from resources/latest/charts/istiod/files/grpc-simple.yaml rename to resources/v1.25-alpha.c2ac935c/charts/istiod/files/grpc-simple.yaml diff --git a/resources/latest/charts/istiod/files/injection-template.yaml b/resources/v1.25-alpha.c2ac935c/charts/istiod/files/injection-template.yaml similarity index 100% rename from resources/latest/charts/istiod/files/injection-template.yaml rename to resources/v1.25-alpha.c2ac935c/charts/istiod/files/injection-template.yaml diff --git a/resources/latest/charts/istiod/files/kube-gateway.yaml b/resources/v1.25-alpha.c2ac935c/charts/istiod/files/kube-gateway.yaml similarity index 100% rename from resources/latest/charts/istiod/files/kube-gateway.yaml rename to resources/v1.25-alpha.c2ac935c/charts/istiod/files/kube-gateway.yaml diff --git a/resources/latest/charts/istiod/files/profile-ambient.yaml b/resources/v1.25-alpha.c2ac935c/charts/istiod/files/profile-ambient.yaml similarity index 100% rename from resources/latest/charts/istiod/files/profile-ambient.yaml rename to resources/v1.25-alpha.c2ac935c/charts/istiod/files/profile-ambient.yaml diff --git a/resources/latest/charts/istiod/files/profile-compatibility-version-1.22.yaml b/resources/v1.25-alpha.c2ac935c/charts/istiod/files/profile-compatibility-version-1.22.yaml similarity index 100% rename from resources/latest/charts/istiod/files/profile-compatibility-version-1.22.yaml rename to resources/v1.25-alpha.c2ac935c/charts/istiod/files/profile-compatibility-version-1.22.yaml diff --git a/resources/latest/charts/istiod/files/profile-compatibility-version-1.23.yaml b/resources/v1.25-alpha.c2ac935c/charts/istiod/files/profile-compatibility-version-1.23.yaml similarity index 100% rename from resources/latest/charts/istiod/files/profile-compatibility-version-1.23.yaml rename to resources/v1.25-alpha.c2ac935c/charts/istiod/files/profile-compatibility-version-1.23.yaml diff --git a/resources/latest/charts/istiod/files/profile-compatibility-version-1.24.yaml b/resources/v1.25-alpha.c2ac935c/charts/istiod/files/profile-compatibility-version-1.24.yaml similarity index 100% rename from resources/latest/charts/istiod/files/profile-compatibility-version-1.24.yaml rename to resources/v1.25-alpha.c2ac935c/charts/istiod/files/profile-compatibility-version-1.24.yaml diff --git a/resources/latest/charts/istiod/files/profile-demo.yaml b/resources/v1.25-alpha.c2ac935c/charts/istiod/files/profile-demo.yaml similarity index 100% rename from resources/latest/charts/istiod/files/profile-demo.yaml rename to resources/v1.25-alpha.c2ac935c/charts/istiod/files/profile-demo.yaml diff --git a/resources/latest/charts/istiod/files/profile-platform-gke.yaml b/resources/v1.25-alpha.c2ac935c/charts/istiod/files/profile-platform-gke.yaml similarity index 100% rename from resources/latest/charts/istiod/files/profile-platform-gke.yaml rename to resources/v1.25-alpha.c2ac935c/charts/istiod/files/profile-platform-gke.yaml diff --git a/resources/latest/charts/istiod/files/profile-platform-k3d.yaml b/resources/v1.25-alpha.c2ac935c/charts/istiod/files/profile-platform-k3d.yaml similarity index 100% rename from resources/latest/charts/istiod/files/profile-platform-k3d.yaml rename to resources/v1.25-alpha.c2ac935c/charts/istiod/files/profile-platform-k3d.yaml diff --git a/resources/latest/charts/istiod/files/profile-platform-k3s.yaml b/resources/v1.25-alpha.c2ac935c/charts/istiod/files/profile-platform-k3s.yaml similarity index 100% rename from resources/latest/charts/istiod/files/profile-platform-k3s.yaml rename to resources/v1.25-alpha.c2ac935c/charts/istiod/files/profile-platform-k3s.yaml diff --git a/resources/latest/charts/istiod/files/profile-platform-microk8s.yaml b/resources/v1.25-alpha.c2ac935c/charts/istiod/files/profile-platform-microk8s.yaml similarity index 100% rename from resources/latest/charts/istiod/files/profile-platform-microk8s.yaml rename to resources/v1.25-alpha.c2ac935c/charts/istiod/files/profile-platform-microk8s.yaml diff --git a/resources/latest/charts/istiod/files/profile-platform-minikube.yaml b/resources/v1.25-alpha.c2ac935c/charts/istiod/files/profile-platform-minikube.yaml similarity index 100% rename from resources/latest/charts/istiod/files/profile-platform-minikube.yaml rename to resources/v1.25-alpha.c2ac935c/charts/istiod/files/profile-platform-minikube.yaml diff --git a/resources/latest/charts/istiod/files/profile-platform-openshift.yaml b/resources/v1.25-alpha.c2ac935c/charts/istiod/files/profile-platform-openshift.yaml similarity index 100% rename from resources/latest/charts/istiod/files/profile-platform-openshift.yaml rename to resources/v1.25-alpha.c2ac935c/charts/istiod/files/profile-platform-openshift.yaml diff --git a/resources/latest/charts/istiod/files/profile-preview.yaml b/resources/v1.25-alpha.c2ac935c/charts/istiod/files/profile-preview.yaml similarity index 100% rename from resources/latest/charts/istiod/files/profile-preview.yaml rename to resources/v1.25-alpha.c2ac935c/charts/istiod/files/profile-preview.yaml diff --git a/resources/latest/charts/istiod/files/profile-remote.yaml b/resources/v1.25-alpha.c2ac935c/charts/istiod/files/profile-remote.yaml similarity index 100% rename from resources/latest/charts/istiod/files/profile-remote.yaml rename to resources/v1.25-alpha.c2ac935c/charts/istiod/files/profile-remote.yaml diff --git a/resources/latest/charts/istiod/files/profile-stable.yaml b/resources/v1.25-alpha.c2ac935c/charts/istiod/files/profile-stable.yaml similarity index 100% rename from resources/latest/charts/istiod/files/profile-stable.yaml rename to resources/v1.25-alpha.c2ac935c/charts/istiod/files/profile-stable.yaml diff --git a/resources/latest/charts/istiod/files/waypoint.yaml b/resources/v1.25-alpha.c2ac935c/charts/istiod/files/waypoint.yaml similarity index 100% rename from resources/latest/charts/istiod/files/waypoint.yaml rename to resources/v1.25-alpha.c2ac935c/charts/istiod/files/waypoint.yaml diff --git a/resources/latest/charts/istiod/templates/NOTES.txt b/resources/v1.25-alpha.c2ac935c/charts/istiod/templates/NOTES.txt similarity index 100% rename from resources/latest/charts/istiod/templates/NOTES.txt rename to resources/v1.25-alpha.c2ac935c/charts/istiod/templates/NOTES.txt diff --git a/resources/latest/charts/istiod/templates/_helpers.tpl b/resources/v1.25-alpha.c2ac935c/charts/istiod/templates/_helpers.tpl similarity index 100% rename from resources/latest/charts/istiod/templates/_helpers.tpl rename to resources/v1.25-alpha.c2ac935c/charts/istiod/templates/_helpers.tpl diff --git a/resources/latest/charts/istiod/templates/autoscale.yaml b/resources/v1.25-alpha.c2ac935c/charts/istiod/templates/autoscale.yaml similarity index 100% rename from resources/latest/charts/istiod/templates/autoscale.yaml rename to resources/v1.25-alpha.c2ac935c/charts/istiod/templates/autoscale.yaml diff --git a/resources/latest/charts/istiod/templates/clusterrole.yaml b/resources/v1.25-alpha.c2ac935c/charts/istiod/templates/clusterrole.yaml similarity index 100% rename from resources/latest/charts/istiod/templates/clusterrole.yaml rename to resources/v1.25-alpha.c2ac935c/charts/istiod/templates/clusterrole.yaml diff --git a/resources/latest/charts/istiod/templates/clusterrolebinding.yaml b/resources/v1.25-alpha.c2ac935c/charts/istiod/templates/clusterrolebinding.yaml similarity index 100% rename from resources/latest/charts/istiod/templates/clusterrolebinding.yaml rename to resources/v1.25-alpha.c2ac935c/charts/istiod/templates/clusterrolebinding.yaml diff --git a/resources/latest/charts/istiod/templates/configmap-jwks.yaml b/resources/v1.25-alpha.c2ac935c/charts/istiod/templates/configmap-jwks.yaml similarity index 100% rename from resources/latest/charts/istiod/templates/configmap-jwks.yaml rename to resources/v1.25-alpha.c2ac935c/charts/istiod/templates/configmap-jwks.yaml diff --git a/resources/latest/charts/istiod/templates/configmap.yaml b/resources/v1.25-alpha.c2ac935c/charts/istiod/templates/configmap.yaml similarity index 100% rename from resources/latest/charts/istiod/templates/configmap.yaml rename to resources/v1.25-alpha.c2ac935c/charts/istiod/templates/configmap.yaml diff --git a/resources/latest/charts/istiod/templates/deployment.yaml b/resources/v1.25-alpha.c2ac935c/charts/istiod/templates/deployment.yaml similarity index 100% rename from resources/latest/charts/istiod/templates/deployment.yaml rename to resources/v1.25-alpha.c2ac935c/charts/istiod/templates/deployment.yaml diff --git a/resources/latest/charts/istiod/templates/istiod-injector-configmap.yaml b/resources/v1.25-alpha.c2ac935c/charts/istiod/templates/istiod-injector-configmap.yaml similarity index 100% rename from resources/latest/charts/istiod/templates/istiod-injector-configmap.yaml rename to resources/v1.25-alpha.c2ac935c/charts/istiod/templates/istiod-injector-configmap.yaml diff --git a/resources/latest/charts/istiod/templates/mutatingwebhook.yaml b/resources/v1.25-alpha.c2ac935c/charts/istiod/templates/mutatingwebhook.yaml similarity index 100% rename from resources/latest/charts/istiod/templates/mutatingwebhook.yaml rename to resources/v1.25-alpha.c2ac935c/charts/istiod/templates/mutatingwebhook.yaml diff --git a/resources/latest/charts/istiod/templates/poddisruptionbudget.yaml b/resources/v1.25-alpha.c2ac935c/charts/istiod/templates/poddisruptionbudget.yaml similarity index 100% rename from resources/latest/charts/istiod/templates/poddisruptionbudget.yaml rename to resources/v1.25-alpha.c2ac935c/charts/istiod/templates/poddisruptionbudget.yaml diff --git a/resources/latest/charts/istiod/templates/reader-clusterrole.yaml b/resources/v1.25-alpha.c2ac935c/charts/istiod/templates/reader-clusterrole.yaml similarity index 100% rename from resources/latest/charts/istiod/templates/reader-clusterrole.yaml rename to resources/v1.25-alpha.c2ac935c/charts/istiod/templates/reader-clusterrole.yaml diff --git a/resources/latest/charts/istiod/templates/reader-clusterrolebinding.yaml b/resources/v1.25-alpha.c2ac935c/charts/istiod/templates/reader-clusterrolebinding.yaml similarity index 100% rename from resources/latest/charts/istiod/templates/reader-clusterrolebinding.yaml rename to resources/v1.25-alpha.c2ac935c/charts/istiod/templates/reader-clusterrolebinding.yaml diff --git a/resources/latest/charts/istiod/templates/remote-istiod-endpoints.yaml b/resources/v1.25-alpha.c2ac935c/charts/istiod/templates/remote-istiod-endpoints.yaml similarity index 100% rename from resources/latest/charts/istiod/templates/remote-istiod-endpoints.yaml rename to resources/v1.25-alpha.c2ac935c/charts/istiod/templates/remote-istiod-endpoints.yaml diff --git a/resources/latest/charts/istiod/templates/remote-istiod-service.yaml b/resources/v1.25-alpha.c2ac935c/charts/istiod/templates/remote-istiod-service.yaml similarity index 100% rename from resources/latest/charts/istiod/templates/remote-istiod-service.yaml rename to resources/v1.25-alpha.c2ac935c/charts/istiod/templates/remote-istiod-service.yaml diff --git a/resources/latest/charts/istiod/templates/revision-tags.yaml b/resources/v1.25-alpha.c2ac935c/charts/istiod/templates/revision-tags.yaml similarity index 100% rename from resources/latest/charts/istiod/templates/revision-tags.yaml rename to resources/v1.25-alpha.c2ac935c/charts/istiod/templates/revision-tags.yaml diff --git a/resources/latest/charts/istiod/templates/role.yaml b/resources/v1.25-alpha.c2ac935c/charts/istiod/templates/role.yaml similarity index 100% rename from resources/latest/charts/istiod/templates/role.yaml rename to resources/v1.25-alpha.c2ac935c/charts/istiod/templates/role.yaml diff --git a/resources/latest/charts/istiod/templates/rolebinding.yaml b/resources/v1.25-alpha.c2ac935c/charts/istiod/templates/rolebinding.yaml similarity index 100% rename from resources/latest/charts/istiod/templates/rolebinding.yaml rename to resources/v1.25-alpha.c2ac935c/charts/istiod/templates/rolebinding.yaml diff --git a/resources/latest/charts/istiod/templates/service.yaml b/resources/v1.25-alpha.c2ac935c/charts/istiod/templates/service.yaml similarity index 100% rename from resources/latest/charts/istiod/templates/service.yaml rename to resources/v1.25-alpha.c2ac935c/charts/istiod/templates/service.yaml diff --git a/resources/latest/charts/istiod/templates/serviceaccount.yaml b/resources/v1.25-alpha.c2ac935c/charts/istiod/templates/serviceaccount.yaml similarity index 100% rename from resources/latest/charts/istiod/templates/serviceaccount.yaml rename to resources/v1.25-alpha.c2ac935c/charts/istiod/templates/serviceaccount.yaml diff --git a/resources/latest/charts/istiod/templates/validatingadmissionpolicy.yaml b/resources/v1.25-alpha.c2ac935c/charts/istiod/templates/validatingadmissionpolicy.yaml similarity index 100% rename from resources/latest/charts/istiod/templates/validatingadmissionpolicy.yaml rename to resources/v1.25-alpha.c2ac935c/charts/istiod/templates/validatingadmissionpolicy.yaml diff --git a/resources/latest/charts/istiod/templates/validatingwebhookconfiguration.yaml b/resources/v1.25-alpha.c2ac935c/charts/istiod/templates/validatingwebhookconfiguration.yaml similarity index 100% rename from resources/latest/charts/istiod/templates/validatingwebhookconfiguration.yaml rename to resources/v1.25-alpha.c2ac935c/charts/istiod/templates/validatingwebhookconfiguration.yaml diff --git a/resources/latest/charts/istiod/templates/zzy_descope_legacy.yaml b/resources/v1.25-alpha.c2ac935c/charts/istiod/templates/zzy_descope_legacy.yaml similarity index 100% rename from resources/latest/charts/istiod/templates/zzy_descope_legacy.yaml rename to resources/v1.25-alpha.c2ac935c/charts/istiod/templates/zzy_descope_legacy.yaml diff --git a/resources/latest/charts/istiod/templates/zzz_profile.yaml b/resources/v1.25-alpha.c2ac935c/charts/istiod/templates/zzz_profile.yaml similarity index 100% rename from resources/latest/charts/istiod/templates/zzz_profile.yaml rename to resources/v1.25-alpha.c2ac935c/charts/istiod/templates/zzz_profile.yaml diff --git a/resources/latest/charts/istiod/values.yaml b/resources/v1.25-alpha.c2ac935c/charts/istiod/values.yaml similarity index 100% rename from resources/latest/charts/istiod/values.yaml rename to resources/v1.25-alpha.c2ac935c/charts/istiod/values.yaml diff --git a/resources/latest/charts/revisiontags/Chart.yaml b/resources/v1.25-alpha.c2ac935c/charts/revisiontags/Chart.yaml similarity index 82% rename from resources/latest/charts/revisiontags/Chart.yaml rename to resources/v1.25-alpha.c2ac935c/charts/revisiontags/Chart.yaml index 58d88fd57..41ece796a 100644 --- a/resources/latest/charts/revisiontags/Chart.yaml +++ b/resources/v1.25-alpha.c2ac935c/charts/revisiontags/Chart.yaml @@ -1,5 +1,5 @@ apiVersion: v2 -appVersion: latest +appVersion: v1.25-alpha.c2ac935c description: Helm chart for istio revision tags name: revisiontags sources: diff --git a/resources/latest/charts/revisiontags/files/profile-ambient.yaml b/resources/v1.25-alpha.c2ac935c/charts/revisiontags/files/profile-ambient.yaml similarity index 100% rename from resources/latest/charts/revisiontags/files/profile-ambient.yaml rename to resources/v1.25-alpha.c2ac935c/charts/revisiontags/files/profile-ambient.yaml diff --git a/resources/latest/charts/revisiontags/files/profile-compatibility-version-1.22.yaml b/resources/v1.25-alpha.c2ac935c/charts/revisiontags/files/profile-compatibility-version-1.22.yaml similarity index 100% rename from resources/latest/charts/revisiontags/files/profile-compatibility-version-1.22.yaml rename to resources/v1.25-alpha.c2ac935c/charts/revisiontags/files/profile-compatibility-version-1.22.yaml diff --git a/resources/latest/charts/revisiontags/files/profile-compatibility-version-1.23.yaml b/resources/v1.25-alpha.c2ac935c/charts/revisiontags/files/profile-compatibility-version-1.23.yaml similarity index 100% rename from resources/latest/charts/revisiontags/files/profile-compatibility-version-1.23.yaml rename to resources/v1.25-alpha.c2ac935c/charts/revisiontags/files/profile-compatibility-version-1.23.yaml diff --git a/resources/latest/charts/revisiontags/files/profile-compatibility-version-1.24.yaml b/resources/v1.25-alpha.c2ac935c/charts/revisiontags/files/profile-compatibility-version-1.24.yaml similarity index 100% rename from resources/latest/charts/revisiontags/files/profile-compatibility-version-1.24.yaml rename to resources/v1.25-alpha.c2ac935c/charts/revisiontags/files/profile-compatibility-version-1.24.yaml diff --git a/resources/latest/charts/revisiontags/files/profile-demo.yaml b/resources/v1.25-alpha.c2ac935c/charts/revisiontags/files/profile-demo.yaml similarity index 100% rename from resources/latest/charts/revisiontags/files/profile-demo.yaml rename to resources/v1.25-alpha.c2ac935c/charts/revisiontags/files/profile-demo.yaml diff --git a/resources/latest/charts/revisiontags/files/profile-platform-gke.yaml b/resources/v1.25-alpha.c2ac935c/charts/revisiontags/files/profile-platform-gke.yaml similarity index 100% rename from resources/latest/charts/revisiontags/files/profile-platform-gke.yaml rename to resources/v1.25-alpha.c2ac935c/charts/revisiontags/files/profile-platform-gke.yaml diff --git a/resources/latest/charts/revisiontags/files/profile-platform-k3d.yaml b/resources/v1.25-alpha.c2ac935c/charts/revisiontags/files/profile-platform-k3d.yaml similarity index 100% rename from resources/latest/charts/revisiontags/files/profile-platform-k3d.yaml rename to resources/v1.25-alpha.c2ac935c/charts/revisiontags/files/profile-platform-k3d.yaml diff --git a/resources/latest/charts/revisiontags/files/profile-platform-k3s.yaml b/resources/v1.25-alpha.c2ac935c/charts/revisiontags/files/profile-platform-k3s.yaml similarity index 100% rename from resources/latest/charts/revisiontags/files/profile-platform-k3s.yaml rename to resources/v1.25-alpha.c2ac935c/charts/revisiontags/files/profile-platform-k3s.yaml diff --git a/resources/latest/charts/revisiontags/files/profile-platform-microk8s.yaml b/resources/v1.25-alpha.c2ac935c/charts/revisiontags/files/profile-platform-microk8s.yaml similarity index 100% rename from resources/latest/charts/revisiontags/files/profile-platform-microk8s.yaml rename to resources/v1.25-alpha.c2ac935c/charts/revisiontags/files/profile-platform-microk8s.yaml diff --git a/resources/latest/charts/revisiontags/files/profile-platform-minikube.yaml b/resources/v1.25-alpha.c2ac935c/charts/revisiontags/files/profile-platform-minikube.yaml similarity index 100% rename from resources/latest/charts/revisiontags/files/profile-platform-minikube.yaml rename to resources/v1.25-alpha.c2ac935c/charts/revisiontags/files/profile-platform-minikube.yaml diff --git a/resources/latest/charts/revisiontags/files/profile-platform-openshift.yaml b/resources/v1.25-alpha.c2ac935c/charts/revisiontags/files/profile-platform-openshift.yaml similarity index 100% rename from resources/latest/charts/revisiontags/files/profile-platform-openshift.yaml rename to resources/v1.25-alpha.c2ac935c/charts/revisiontags/files/profile-platform-openshift.yaml diff --git a/resources/latest/charts/revisiontags/files/profile-preview.yaml b/resources/v1.25-alpha.c2ac935c/charts/revisiontags/files/profile-preview.yaml similarity index 100% rename from resources/latest/charts/revisiontags/files/profile-preview.yaml rename to resources/v1.25-alpha.c2ac935c/charts/revisiontags/files/profile-preview.yaml diff --git a/resources/latest/charts/revisiontags/files/profile-remote.yaml b/resources/v1.25-alpha.c2ac935c/charts/revisiontags/files/profile-remote.yaml similarity index 100% rename from resources/latest/charts/revisiontags/files/profile-remote.yaml rename to resources/v1.25-alpha.c2ac935c/charts/revisiontags/files/profile-remote.yaml diff --git a/resources/latest/charts/revisiontags/files/profile-stable.yaml b/resources/v1.25-alpha.c2ac935c/charts/revisiontags/files/profile-stable.yaml similarity index 100% rename from resources/latest/charts/revisiontags/files/profile-stable.yaml rename to resources/v1.25-alpha.c2ac935c/charts/revisiontags/files/profile-stable.yaml diff --git a/resources/latest/charts/revisiontags/templates/revision-tags.yaml b/resources/v1.25-alpha.c2ac935c/charts/revisiontags/templates/revision-tags.yaml similarity index 100% rename from resources/latest/charts/revisiontags/templates/revision-tags.yaml rename to resources/v1.25-alpha.c2ac935c/charts/revisiontags/templates/revision-tags.yaml diff --git a/resources/latest/charts/revisiontags/templates/zzz_profile.yaml b/resources/v1.25-alpha.c2ac935c/charts/revisiontags/templates/zzz_profile.yaml similarity index 100% rename from resources/latest/charts/revisiontags/templates/zzz_profile.yaml rename to resources/v1.25-alpha.c2ac935c/charts/revisiontags/templates/zzz_profile.yaml diff --git a/resources/latest/charts/revisiontags/values.yaml b/resources/v1.25-alpha.c2ac935c/charts/revisiontags/values.yaml similarity index 100% rename from resources/latest/charts/revisiontags/values.yaml rename to resources/v1.25-alpha.c2ac935c/charts/revisiontags/values.yaml diff --git a/resources/latest/charts/ztunnel/Chart.yaml b/resources/v1.25-alpha.c2ac935c/charts/ztunnel/Chart.yaml similarity index 100% rename from resources/latest/charts/ztunnel/Chart.yaml rename to resources/v1.25-alpha.c2ac935c/charts/ztunnel/Chart.yaml diff --git a/resources/latest/charts/ztunnel/README.md b/resources/v1.25-alpha.c2ac935c/charts/ztunnel/README.md similarity index 100% rename from resources/latest/charts/ztunnel/README.md rename to resources/v1.25-alpha.c2ac935c/charts/ztunnel/README.md diff --git a/resources/latest/charts/ztunnel/files/profile-ambient.yaml b/resources/v1.25-alpha.c2ac935c/charts/ztunnel/files/profile-ambient.yaml similarity index 100% rename from resources/latest/charts/ztunnel/files/profile-ambient.yaml rename to resources/v1.25-alpha.c2ac935c/charts/ztunnel/files/profile-ambient.yaml diff --git a/resources/latest/charts/ztunnel/files/profile-compatibility-version-1.22.yaml b/resources/v1.25-alpha.c2ac935c/charts/ztunnel/files/profile-compatibility-version-1.22.yaml similarity index 100% rename from resources/latest/charts/ztunnel/files/profile-compatibility-version-1.22.yaml rename to resources/v1.25-alpha.c2ac935c/charts/ztunnel/files/profile-compatibility-version-1.22.yaml diff --git a/resources/latest/charts/ztunnel/files/profile-compatibility-version-1.23.yaml b/resources/v1.25-alpha.c2ac935c/charts/ztunnel/files/profile-compatibility-version-1.23.yaml similarity index 100% rename from resources/latest/charts/ztunnel/files/profile-compatibility-version-1.23.yaml rename to resources/v1.25-alpha.c2ac935c/charts/ztunnel/files/profile-compatibility-version-1.23.yaml diff --git a/resources/latest/charts/ztunnel/files/profile-compatibility-version-1.24.yaml b/resources/v1.25-alpha.c2ac935c/charts/ztunnel/files/profile-compatibility-version-1.24.yaml similarity index 100% rename from resources/latest/charts/ztunnel/files/profile-compatibility-version-1.24.yaml rename to resources/v1.25-alpha.c2ac935c/charts/ztunnel/files/profile-compatibility-version-1.24.yaml diff --git a/resources/latest/charts/ztunnel/files/profile-demo.yaml b/resources/v1.25-alpha.c2ac935c/charts/ztunnel/files/profile-demo.yaml similarity index 100% rename from resources/latest/charts/ztunnel/files/profile-demo.yaml rename to resources/v1.25-alpha.c2ac935c/charts/ztunnel/files/profile-demo.yaml diff --git a/resources/latest/charts/ztunnel/files/profile-platform-gke.yaml b/resources/v1.25-alpha.c2ac935c/charts/ztunnel/files/profile-platform-gke.yaml similarity index 100% rename from resources/latest/charts/ztunnel/files/profile-platform-gke.yaml rename to resources/v1.25-alpha.c2ac935c/charts/ztunnel/files/profile-platform-gke.yaml diff --git a/resources/latest/charts/ztunnel/files/profile-platform-k3d.yaml b/resources/v1.25-alpha.c2ac935c/charts/ztunnel/files/profile-platform-k3d.yaml similarity index 100% rename from resources/latest/charts/ztunnel/files/profile-platform-k3d.yaml rename to resources/v1.25-alpha.c2ac935c/charts/ztunnel/files/profile-platform-k3d.yaml diff --git a/resources/latest/charts/ztunnel/files/profile-platform-k3s.yaml b/resources/v1.25-alpha.c2ac935c/charts/ztunnel/files/profile-platform-k3s.yaml similarity index 100% rename from resources/latest/charts/ztunnel/files/profile-platform-k3s.yaml rename to resources/v1.25-alpha.c2ac935c/charts/ztunnel/files/profile-platform-k3s.yaml diff --git a/resources/latest/charts/ztunnel/files/profile-platform-microk8s.yaml b/resources/v1.25-alpha.c2ac935c/charts/ztunnel/files/profile-platform-microk8s.yaml similarity index 100% rename from resources/latest/charts/ztunnel/files/profile-platform-microk8s.yaml rename to resources/v1.25-alpha.c2ac935c/charts/ztunnel/files/profile-platform-microk8s.yaml diff --git a/resources/latest/charts/ztunnel/files/profile-platform-minikube.yaml b/resources/v1.25-alpha.c2ac935c/charts/ztunnel/files/profile-platform-minikube.yaml similarity index 100% rename from resources/latest/charts/ztunnel/files/profile-platform-minikube.yaml rename to resources/v1.25-alpha.c2ac935c/charts/ztunnel/files/profile-platform-minikube.yaml diff --git a/resources/latest/charts/ztunnel/files/profile-platform-openshift.yaml b/resources/v1.25-alpha.c2ac935c/charts/ztunnel/files/profile-platform-openshift.yaml similarity index 100% rename from resources/latest/charts/ztunnel/files/profile-platform-openshift.yaml rename to resources/v1.25-alpha.c2ac935c/charts/ztunnel/files/profile-platform-openshift.yaml diff --git a/resources/latest/charts/ztunnel/files/profile-preview.yaml b/resources/v1.25-alpha.c2ac935c/charts/ztunnel/files/profile-preview.yaml similarity index 100% rename from resources/latest/charts/ztunnel/files/profile-preview.yaml rename to resources/v1.25-alpha.c2ac935c/charts/ztunnel/files/profile-preview.yaml diff --git a/resources/latest/charts/ztunnel/files/profile-remote.yaml b/resources/v1.25-alpha.c2ac935c/charts/ztunnel/files/profile-remote.yaml similarity index 100% rename from resources/latest/charts/ztunnel/files/profile-remote.yaml rename to resources/v1.25-alpha.c2ac935c/charts/ztunnel/files/profile-remote.yaml diff --git a/resources/latest/charts/ztunnel/files/profile-stable.yaml b/resources/v1.25-alpha.c2ac935c/charts/ztunnel/files/profile-stable.yaml similarity index 100% rename from resources/latest/charts/ztunnel/files/profile-stable.yaml rename to resources/v1.25-alpha.c2ac935c/charts/ztunnel/files/profile-stable.yaml diff --git a/resources/latest/charts/ztunnel/templates/NOTES.txt b/resources/v1.25-alpha.c2ac935c/charts/ztunnel/templates/NOTES.txt similarity index 100% rename from resources/latest/charts/ztunnel/templates/NOTES.txt rename to resources/v1.25-alpha.c2ac935c/charts/ztunnel/templates/NOTES.txt diff --git a/resources/latest/charts/ztunnel/templates/_helpers.tpl b/resources/v1.25-alpha.c2ac935c/charts/ztunnel/templates/_helpers.tpl similarity index 100% rename from resources/latest/charts/ztunnel/templates/_helpers.tpl rename to resources/v1.25-alpha.c2ac935c/charts/ztunnel/templates/_helpers.tpl diff --git a/resources/latest/charts/ztunnel/templates/daemonset.yaml b/resources/v1.25-alpha.c2ac935c/charts/ztunnel/templates/daemonset.yaml similarity index 100% rename from resources/latest/charts/ztunnel/templates/daemonset.yaml rename to resources/v1.25-alpha.c2ac935c/charts/ztunnel/templates/daemonset.yaml diff --git a/resources/latest/charts/ztunnel/templates/rbac.yaml b/resources/v1.25-alpha.c2ac935c/charts/ztunnel/templates/rbac.yaml similarity index 100% rename from resources/latest/charts/ztunnel/templates/rbac.yaml rename to resources/v1.25-alpha.c2ac935c/charts/ztunnel/templates/rbac.yaml diff --git a/resources/latest/charts/ztunnel/templates/zzz_profile.yaml b/resources/v1.25-alpha.c2ac935c/charts/ztunnel/templates/zzz_profile.yaml similarity index 100% rename from resources/latest/charts/ztunnel/templates/zzz_profile.yaml rename to resources/v1.25-alpha.c2ac935c/charts/ztunnel/templates/zzz_profile.yaml diff --git a/resources/latest/charts/ztunnel/values.yaml b/resources/v1.25-alpha.c2ac935c/charts/ztunnel/values.yaml similarity index 100% rename from resources/latest/charts/ztunnel/values.yaml rename to resources/v1.25-alpha.c2ac935c/charts/ztunnel/values.yaml diff --git a/resources/latest/profiles/ambient.yaml b/resources/v1.25-alpha.c2ac935c/profiles/ambient.yaml similarity index 100% rename from resources/latest/profiles/ambient.yaml rename to resources/v1.25-alpha.c2ac935c/profiles/ambient.yaml diff --git a/resources/latest/profiles/default.yaml b/resources/v1.25-alpha.c2ac935c/profiles/default.yaml similarity index 100% rename from resources/latest/profiles/default.yaml rename to resources/v1.25-alpha.c2ac935c/profiles/default.yaml diff --git a/resources/latest/profiles/demo.yaml b/resources/v1.25-alpha.c2ac935c/profiles/demo.yaml similarity index 100% rename from resources/latest/profiles/demo.yaml rename to resources/v1.25-alpha.c2ac935c/profiles/demo.yaml diff --git a/resources/latest/profiles/empty.yaml b/resources/v1.25-alpha.c2ac935c/profiles/empty.yaml similarity index 100% rename from resources/latest/profiles/empty.yaml rename to resources/v1.25-alpha.c2ac935c/profiles/empty.yaml diff --git a/resources/latest/profiles/openshift-ambient.yaml b/resources/v1.25-alpha.c2ac935c/profiles/openshift-ambient.yaml similarity index 100% rename from resources/latest/profiles/openshift-ambient.yaml rename to resources/v1.25-alpha.c2ac935c/profiles/openshift-ambient.yaml diff --git a/resources/latest/profiles/openshift.yaml b/resources/v1.25-alpha.c2ac935c/profiles/openshift.yaml similarity index 100% rename from resources/latest/profiles/openshift.yaml rename to resources/v1.25-alpha.c2ac935c/profiles/openshift.yaml diff --git a/resources/latest/profiles/preview.yaml b/resources/v1.25-alpha.c2ac935c/profiles/preview.yaml similarity index 100% rename from resources/latest/profiles/preview.yaml rename to resources/v1.25-alpha.c2ac935c/profiles/preview.yaml diff --git a/resources/latest/profiles/remote.yaml b/resources/v1.25-alpha.c2ac935c/profiles/remote.yaml similarity index 100% rename from resources/latest/profiles/remote.yaml rename to resources/v1.25-alpha.c2ac935c/profiles/remote.yaml diff --git a/resources/latest/profiles/stable.yaml b/resources/v1.25-alpha.c2ac935c/profiles/stable.yaml similarity index 100% rename from resources/latest/profiles/stable.yaml rename to resources/v1.25-alpha.c2ac935c/profiles/stable.yaml diff --git a/tests/e2e/ambient/ambient_test.go b/tests/e2e/ambient/ambient_test.go index 745ba81d6..cb141bf04 100644 --- a/tests/e2e/ambient/ambient_test.go +++ b/tests/e2e/ambient/ambient_test.go @@ -22,9 +22,9 @@ import ( "github.com/Masterminds/semver/v3" v1 "github.com/istio-ecosystem/sail-operator/api/v1" + "github.com/istio-ecosystem/sail-operator/pkg/istioversion" "github.com/istio-ecosystem/sail-operator/pkg/kube" . "github.com/istio-ecosystem/sail-operator/pkg/test/util/ginkgo" - "github.com/istio-ecosystem/sail-operator/pkg/test/util/supportedversion" "github.com/istio-ecosystem/sail-operator/tests/e2e/util/common" . "github.com/istio-ecosystem/sail-operator/tests/e2e/util/gomega" . "github.com/onsi/ginkgo/v2" @@ -61,7 +61,7 @@ var _ = Describe("Ambient configuration ", Ordered, func() { }) Describe("for supported versions", func() { - for _, version := range supportedversion.List { + for _, version := range istioversion.List { // The minimum supported version is 1.24 (and above) if version.Version.LessThan(semver.MustParse("1.24.0")) { continue diff --git a/tests/e2e/common-operator-integ-suite.sh b/tests/e2e/common-operator-integ-suite.sh index 9344fbcc7..383870822 100755 --- a/tests/e2e/common-operator-integ-suite.sh +++ b/tests/e2e/common-operator-integ-suite.sh @@ -110,7 +110,7 @@ initialize_variables() { WD=$(dirname "$0") WD=$(cd "${WD}" || exit; pwd) - VERSIONS_YAML_FILE=${VERSIONS_YAML_FILE:-"versions.yaml"} + VERSIONS_YAML_FILE=${VERSIONS_YAML_FILE:-"pkg/istioversion/versions.yaml"} NAMESPACE="${NAMESPACE:-sail-operator}" DEPLOYMENT_NAME="${DEPLOYMENT_NAME:-sail-operator}" CONTROL_PLANE_NS="${CONTROL_PLANE_NS:-istio-system}" @@ -287,5 +287,5 @@ fi # shellcheck disable=SC2086 IMAGE="${HUB}/${IMAGE_BASE}:${TAG}" SKIP_DEPLOY="${SKIP_DEPLOY}" OCP="${OCP}" IP_FAMILY="${IP_FAMILY}" ISTIO_MANIFEST="${ISTIO_MANIFEST}" \ NAMESPACE="${NAMESPACE}" CONTROL_PLANE_NS="${CONTROL_PLANE_NS}" DEPLOYMENT_NAME="${DEPLOYMENT_NAME}" MULTICLUSTER="${MULTICLUSTER}" ARTIFACTS="${ARTIFACTS}" \ -ISTIO_NAME="${ISTIO_NAME}" COMMAND="${COMMAND}" VERSIONS_YAML_FILE="${VERSIONS_YAML_FILE}" KUBECONFIG="${KUBECONFIG}" ISTIOCTL_PATH="${ISTIOCTL}" \ +ISTIO_NAME="${ISTIO_NAME}" COMMAND="${COMMAND}" KUBECONFIG="${KUBECONFIG}" ISTIOCTL_PATH="${ISTIOCTL}" \ go run github.com/onsi/ginkgo/v2/ginkgo -tags e2e --timeout 60m --junit-report=report.xml ${GINKGO_FLAGS} "${WD}"/... diff --git a/tests/e2e/controlplane/control_plane_test.go b/tests/e2e/controlplane/control_plane_test.go index dc0bcd61c..8d0b32711 100644 --- a/tests/e2e/controlplane/control_plane_test.go +++ b/tests/e2e/controlplane/control_plane_test.go @@ -23,9 +23,9 @@ import ( "github.com/Masterminds/semver/v3" v1 "github.com/istio-ecosystem/sail-operator/api/v1" + "github.com/istio-ecosystem/sail-operator/pkg/istioversion" "github.com/istio-ecosystem/sail-operator/pkg/kube" . "github.com/istio-ecosystem/sail-operator/pkg/test/util/ginkgo" - "github.com/istio-ecosystem/sail-operator/pkg/test/util/supportedversion" "github.com/istio-ecosystem/sail-operator/tests/e2e/util/common" . "github.com/istio-ecosystem/sail-operator/tests/e2e/util/gomega" . "github.com/onsi/ginkgo/v2" @@ -75,7 +75,7 @@ metadata: cni := &v1.IstioCNI{} Expect(cl.Get(ctx, kube.Key("default"), cni)).To(Succeed()) - Expect(cni.Spec.Version).To(Equal(supportedversion.Default)) + Expect(cni.Spec.Version).To(Equal(istioversion.Default)) Expect(cni.Spec.Namespace).To(Equal("istio-cni")) Expect(cl.Delete(ctx, cni)).To(Succeed()) @@ -99,7 +99,7 @@ metadata: istio := &v1.Istio{} Expect(cl.Get(ctx, kube.Key("default"), istio)).To(Succeed()) - Expect(istio.Spec.Version).To(Equal(supportedversion.Default)) + Expect(istio.Spec.Version).To(Equal(istioversion.Default)) Expect(istio.Spec.Namespace).To(Equal("istio-system")) Expect(istio.Spec.UpdateStrategy).ToNot(BeNil()) Expect(istio.Spec.UpdateStrategy.Type).To(Equal(v1.UpdateStrategyTypeInPlace)) @@ -111,8 +111,8 @@ metadata: }) Describe("given Istio version", func() { - for _, version := range supportedversion.List { - Context(version.Name, func() { + for name, version := range istioversion.Map { + Context(name, func() { BeforeAll(func() { Expect(k.CreateNamespace(controlPlaneNamespace)).To(Succeed(), "Istio namespace failed to be created") Expect(k.CreateNamespace(istioCniNamespace)).To(Succeed(), "IstioCNI namespace failed to be created") @@ -128,7 +128,7 @@ metadata: spec: version: %s namespace: %s` - yaml = fmt.Sprintf(yaml, version.Name, istioCniNamespace) + yaml = fmt.Sprintf(yaml, name, istioCniNamespace) Log("IstioCNI YAML:", indent(2, yaml)) Expect(k.CreateFromString(yaml)).To(Succeed(), "IstioCNI creation failed") Success("IstioCNI created") @@ -178,7 +178,7 @@ metadata: spec: version: %s namespace: %s` - istioYAML = fmt.Sprintf(istioYAML, version.Name, controlPlaneNamespace) + istioYAML = fmt.Sprintf(istioYAML, name, controlPlaneNamespace) Log("Istio YAML:", indent(2, istioYAML)) Expect(k.CreateFromString(istioYAML)). To(Succeed(), "Istio CR failed to be created") @@ -218,6 +218,10 @@ spec: When("sample pod is deployed", func() { BeforeAll(func() { + if isAlias(name, version) { + Skip("Skipping test for alias version") + } + Expect(k.CreateNamespace(sampleNamespace)).To(Succeed(), "Sample namespace failed to be created") Expect(k.Patch("namespace", sampleNamespace, "merge", `{"metadata":{"labels":{"istio-injection":"enabled"}}}`)). To(Succeed(), "Error patching sample namespace") @@ -330,6 +334,10 @@ spec: }) }) +func isAlias(name string, version istioversion.VersionInfo) bool { + return name != version.Name +} + func HaveContainersThat(matcher types.GomegaMatcher) types.GomegaMatcher { return HaveField("Spec.Template.Spec.Containers", matcher) } diff --git a/tests/e2e/dualstack/dualstack_test.go b/tests/e2e/dualstack/dualstack_test.go index 9a81f7308..bd554543f 100644 --- a/tests/e2e/dualstack/dualstack_test.go +++ b/tests/e2e/dualstack/dualstack_test.go @@ -22,9 +22,9 @@ import ( "github.com/Masterminds/semver/v3" v1 "github.com/istio-ecosystem/sail-operator/api/v1" + "github.com/istio-ecosystem/sail-operator/pkg/istioversion" "github.com/istio-ecosystem/sail-operator/pkg/kube" . "github.com/istio-ecosystem/sail-operator/pkg/test/util/ginkgo" - "github.com/istio-ecosystem/sail-operator/pkg/test/util/supportedversion" "github.com/istio-ecosystem/sail-operator/tests/e2e/util/common" . "github.com/istio-ecosystem/sail-operator/tests/e2e/util/gomega" . "github.com/onsi/ginkgo/v2" @@ -64,7 +64,7 @@ var _ = Describe("DualStack configuration ", Ordered, func() { }) Describe("for supported versions", func() { - for _, version := range supportedversion.List { + for _, version := range istioversion.List { // The minimum supported version is 1.23 (and above) if version.Version.LessThan(semver.MustParse("1.23.0")) { continue diff --git a/tests/e2e/multicluster/multicluster_multiprimary_test.go b/tests/e2e/multicluster/multicluster_multiprimary_test.go index 5a80510aa..80ebd5055 100644 --- a/tests/e2e/multicluster/multicluster_multiprimary_test.go +++ b/tests/e2e/multicluster/multicluster_multiprimary_test.go @@ -22,9 +22,9 @@ import ( "time" v1 "github.com/istio-ecosystem/sail-operator/api/v1" + "github.com/istio-ecosystem/sail-operator/pkg/istioversion" "github.com/istio-ecosystem/sail-operator/pkg/kube" . "github.com/istio-ecosystem/sail-operator/pkg/test/util/ginkgo" - "github.com/istio-ecosystem/sail-operator/pkg/test/util/supportedversion" "github.com/istio-ecosystem/sail-operator/tests/e2e/util/certs" "github.com/istio-ecosystem/sail-operator/tests/e2e/util/common" . "github.com/istio-ecosystem/sail-operator/tests/e2e/util/gomega" @@ -68,7 +68,7 @@ var _ = Describe("Multicluster deployment models", Ordered, func() { Describe("Multi-Primary Multi-Network configuration", func() { // Test the Multi-Primary Multi-Network configuration for each supported Istio version - for _, version := range supportedversion.List { + for _, version := range istioversion.List { Context(fmt.Sprintf("Istio version %s", version.Version), func() { When("Istio resources are created in both clusters", func() { BeforeAll(func(ctx SpecContext) { diff --git a/tests/e2e/multicluster/multicluster_primaryremote_test.go b/tests/e2e/multicluster/multicluster_primaryremote_test.go index 1d13c66ac..f009edf60 100644 --- a/tests/e2e/multicluster/multicluster_primaryremote_test.go +++ b/tests/e2e/multicluster/multicluster_primaryremote_test.go @@ -22,9 +22,9 @@ import ( "time" v1 "github.com/istio-ecosystem/sail-operator/api/v1" + "github.com/istio-ecosystem/sail-operator/pkg/istioversion" "github.com/istio-ecosystem/sail-operator/pkg/kube" . "github.com/istio-ecosystem/sail-operator/pkg/test/util/ginkgo" - "github.com/istio-ecosystem/sail-operator/pkg/test/util/supportedversion" "github.com/istio-ecosystem/sail-operator/pkg/version" "github.com/istio-ecosystem/sail-operator/tests/e2e/util/certs" "github.com/istio-ecosystem/sail-operator/tests/e2e/util/common" @@ -69,7 +69,7 @@ var _ = Describe("Multicluster deployment models", Ordered, func() { Describe("Primary-Remote - Multi-Network configuration", func() { // Test the Primary-Remote - Multi-Network configuration for each supported Istio version - for _, v := range supportedversion.List { + for _, v := range istioversion.List { // The Primary-Remote - Multi-Network configuration is only supported in Istio 1.24+. if version.Constraint("<1.24").Check(v.Version) { Log(fmt.Sprintf("Skipping test, because Istio version %s does not support Primary-Remote Multi-Network configuration", v.Version)) diff --git a/tests/e2e/multicontrolplane/multi_control_plane_suite_test.go b/tests/e2e/multicontrolplane/multi_control_plane_suite_test.go index c926fb8e3..a9126256d 100644 --- a/tests/e2e/multicontrolplane/multi_control_plane_suite_test.go +++ b/tests/e2e/multicontrolplane/multi_control_plane_suite_test.go @@ -19,7 +19,7 @@ package controlplane import ( "testing" - "github.com/istio-ecosystem/sail-operator/pkg/test/util/supportedversion" + "github.com/istio-ecosystem/sail-operator/pkg/istioversion" k8sclient "github.com/istio-ecosystem/sail-operator/tests/e2e/util/client" "github.com/istio-ecosystem/sail-operator/tests/e2e/util/common" "github.com/istio-ecosystem/sail-operator/tests/e2e/util/env" @@ -32,7 +32,7 @@ import ( var ( cl client.Client err error - version = supportedversion.New + version = istioversion.New namespace = common.OperatorNamespace deploymentName = env.Get("DEPLOYMENT_NAME", "sail-operator") controlPlaneNamespace1 = env.Get("CONTROL_PLANE_NS1", "istio-system1") diff --git a/tests/e2e/multicontrolplane/multi_control_plane_test.go b/tests/e2e/multicontrolplane/multi_control_plane_test.go index 111c2fe43..d4cef3bec 100644 --- a/tests/e2e/multicontrolplane/multi_control_plane_test.go +++ b/tests/e2e/multicontrolplane/multi_control_plane_test.go @@ -21,9 +21,9 @@ import ( "time" v1 "github.com/istio-ecosystem/sail-operator/api/v1" + "github.com/istio-ecosystem/sail-operator/pkg/istioversion" "github.com/istio-ecosystem/sail-operator/pkg/kube" . "github.com/istio-ecosystem/sail-operator/pkg/test/util/ginkgo" - "github.com/istio-ecosystem/sail-operator/pkg/test/util/supportedversion" "github.com/istio-ecosystem/sail-operator/tests/e2e/util/common" . "github.com/istio-ecosystem/sail-operator/tests/e2e/util/gomega" . "github.com/onsi/ginkgo/v2" @@ -132,7 +132,7 @@ spec: Expect(k.Label("namespace", ns, "istio.io/rev", mesh)).To(Succeed(), "Failed to label namespace") for _, appName := range []string{"sleep", "httpbin"} { Expect(k.WithNamespace(ns). - Apply(common.GetSampleYAML(supportedversion.Map[version], appName))). + Apply(common.GetSampleYAML(istioversion.Map[version], appName))). To(Succeed(), "Failed to deploy application") } Success(fmt.Sprintf("Applications in namespace %s deployed", ns)) diff --git a/tests/e2e/util/common/e2e_utils.go b/tests/e2e/util/common/e2e_utils.go index d3d3ead55..b3639f17c 100644 --- a/tests/e2e/util/common/e2e_utils.go +++ b/tests/e2e/util/common/e2e_utils.go @@ -26,9 +26,9 @@ import ( "time" "github.com/Masterminds/semver/v3" + "github.com/istio-ecosystem/sail-operator/pkg/istioversion" "github.com/istio-ecosystem/sail-operator/pkg/kube" "github.com/istio-ecosystem/sail-operator/pkg/test/project" - "github.com/istio-ecosystem/sail-operator/pkg/test/util/supportedversion" "github.com/istio-ecosystem/sail-operator/tests/e2e/util/env" . "github.com/istio-ecosystem/sail-operator/tests/e2e/util/gomega" "github.com/istio-ecosystem/sail-operator/tests/e2e/util/helm" @@ -318,7 +318,7 @@ func UninstallOperator() error { // args: // version: the version of the Istio to get the yaml file from. // appName: the name of the testing app. Example: helloworld, sleep, tcp-echo. -func GetSampleYAML(version supportedversion.VersionInfo, appName string) string { +func GetSampleYAML(version istioversion.VersionInfo, appName string) string { // This func will be used to get URLs for the yaml files of the testing apps. Example: helloworld, sleep, tcp-echo. // Default values points to upstream Istio sample yaml files. Custom paths can be provided using environment variables. @@ -368,8 +368,5 @@ func GetSampleYAML(version supportedversion.VersionInfo, appName string) string return filepath.Join(project.RootDir, path) } - if version.Name == "latest" { - return fmt.Sprintf("%s/master/%s", baseURL, path) - } - return fmt.Sprintf("%s/%s/%s", baseURL, version.Version, path) + return fmt.Sprintf("%s/%s/%s", baseURL, version.Commit, path) } diff --git a/tests/integration/api/istio_test.go b/tests/integration/api/istio_test.go index 3ace0c403..ea2bf8fbc 100644 --- a/tests/integration/api/istio_test.go +++ b/tests/integration/api/istio_test.go @@ -22,8 +22,8 @@ import ( "time" v1 "github.com/istio-ecosystem/sail-operator/api/v1" + "github.com/istio-ecosystem/sail-operator/pkg/istioversion" . "github.com/istio-ecosystem/sail-operator/pkg/test/util/ginkgo" - "github.com/istio-ecosystem/sail-operator/pkg/test/util/supportedversion" . "github.com/onsi/ginkgo/v2" . "github.com/onsi/gomega" corev1 "k8s.io/api/core/v1" @@ -82,7 +82,7 @@ var _ = Describe("Istio resource", Ordered, func() { Name: istioName, }, Spec: v1.IstioSpec{ - Version: supportedversion.Default, + Version: istioversion.Default, Namespace: istioNamespace, Values: &v1.Values{ Global: &v1.GlobalConfig{ @@ -103,7 +103,7 @@ var _ = Describe("Istio resource", Ordered, func() { Name: istioName, }, Spec: v1.IstioSpec{ - Version: supportedversion.Default, + Version: istioversion.Default, Namespace: istioNamespace, UpdateStrategy: &v1.IstioUpdateStrategy{ Type: v1.UpdateStrategyTypeInPlace, @@ -217,7 +217,7 @@ var _ = Describe("Istio resource", Ordered, func() { rev := &v1.IstioRevision{} BeforeAll(func() { - if supportedversion.Old == "" { + if istioversion.Old == "" { Skip("Only one supported version, nothing to upgrade from") } }) @@ -253,7 +253,7 @@ var _ = Describe("Istio resource", Ordered, func() { Name: istioName, }, Spec: v1.IstioSpec{ - Version: supportedversion.Old, + Version: istioversion.Old, Namespace: istioNamespace, UpdateStrategy: &v1.IstioUpdateStrategy{ Type: v1.UpdateStrategyTypeInPlace, @@ -282,14 +282,14 @@ var _ = Describe("Istio resource", Ordered, func() { When("version is updated", func() { BeforeAll(func() { Expect(k8sClient.Get(ctx, istioKey, istio)).To(Succeed()) - istio.Spec.Version = supportedversion.New + istio.Spec.Version = istioversion.New Expect(k8sClient.Update(ctx, istio)).To(Succeed()) }) It("updates the IstioRevision", func() { Eventually(func(g Gomega) { g.Expect(k8sClient.Get(ctx, revKey, rev)).To(Succeed()) - g.Expect(rev.Spec.Version).To(Equal(supportedversion.New)) + g.Expect(rev.Spec.Version).To(Equal(istioversion.New)) }).Should(Succeed()) }) }) @@ -303,9 +303,9 @@ var _ = Describe("Istio resource", Ordered, func() { }) It("creates a new IstioRevision", func() { - revKey := getRevisionKey(istio, istio.Spec.Version) + revKey := getRevisionKey(istio, istioversion.New) Eventually(k8sClient.Get).WithArguments(ctx, revKey, rev).Should(Succeed()) - Expect(rev.Spec.Version).To(Equal(istio.Spec.Version)) + Expect(rev.Spec.Version).To(Equal(istioversion.New)) }) if withWorkloads { @@ -315,7 +315,7 @@ var _ = Describe("Istio resource", Ordered, func() { When("workloads are moved to the new IstioRevision", func() { BeforeAll(func() { - workloadNs.Labels["istio.io/rev"] = getRevisionName(istio, istio.Spec.Version) + workloadNs.Labels["istio.io/rev"] = getRevisionName(istio, istioversion.New) Expect(k8sClient.Update(ctx, workloadNs)).To(Succeed()) }) @@ -348,7 +348,7 @@ var _ = Describe("Istio resource", Ordered, func() { Name: istioName, }, Spec: v1.IstioSpec{ - Version: supportedversion.Old, + Version: istioversion.Old, Namespace: istioNamespace, UpdateStrategy: &v1.IstioUpdateStrategy{ Type: v1.UpdateStrategyTypeRevisionBased, @@ -359,11 +359,11 @@ var _ = Describe("Istio resource", Ordered, func() { Expect(k8sClient.Create(ctx, istio)).To(Succeed()) Step("Check if IstioRevision exists") - revKey := getRevisionKey(istio, supportedversion.Old) + revKey := getRevisionKey(istio, istioversion.Old) Eventually(k8sClient.Get).WithArguments(ctx, revKey, rev).Should(Succeed()) if withWorkloads { - workloadNs.Labels["istio.io/rev"] = getRevisionName(istio, supportedversion.Old) + workloadNs.Labels["istio.io/rev"] = getRevisionName(istio, istioversion.Old) Expect(k8sClient.Update(ctx, workloadNs)).To(Succeed()) } }) @@ -375,39 +375,39 @@ var _ = Describe("Istio resource", Ordered, func() { When("version is updated", func() { BeforeAll(func() { Expect(k8sClient.Get(ctx, istioKey, istio)).To(Succeed()) - istio.Spec.Version = supportedversion.New + istio.Spec.Version = istioversion.New Expect(k8sClient.Update(ctx, istio)).To(Succeed()) }) It("creates a new IstioRevision", func() { - revKey := getRevisionKey(istio, supportedversion.New) + revKey := getRevisionKey(istio, istioversion.New) Eventually(func(g Gomega) { g.Expect(k8sClient.Get(ctx, revKey, rev)).To(Succeed()) - g.Expect(rev.Spec.Version).To(Equal(supportedversion.New)) + g.Expect(rev.Spec.Version).To(Equal(istioversion.New)) }).Should(Succeed()) }) if withWorkloads { It("doesn't delete the previous IstioRevision while workloads reference it", func() { - revKey := getRevisionKey(istio, supportedversion.Old) + revKey := getRevisionKey(istio, istioversion.Old) Consistently(k8sClient.Get).WithArguments(ctx, revKey, rev).Should(Succeed()) }) When("workloads are moved to the new IstioRevision", func() { BeforeAll(func() { - workloadNs.Labels["istio.io/rev"] = getRevisionName(istio, supportedversion.New) + workloadNs.Labels["istio.io/rev"] = getRevisionName(istio, istioversion.New) Expect(k8sClient.Update(ctx, workloadNs)).To(Succeed()) }) It("doesn't immediately delete the previous IstioRevision", func() { marginOfError := 2 * time.Second - revKey := getRevisionKey(istio, supportedversion.Old) + revKey := getRevisionKey(istio, istioversion.Old) Consistently(k8sClient.Get, gracePeriod-marginOfError).WithArguments(ctx, revKey, rev).Should(Succeed()) }) When("grace period expires", func() { It("deletes the previous IstioRevision", func() { - revKey := getRevisionKey(istio, supportedversion.Old) + revKey := getRevisionKey(istio, istioversion.Old) Eventually(k8sClient.Get).WithArguments(ctx, revKey, rev).Should(ReturnNotFoundError()) }) }) @@ -415,7 +415,7 @@ var _ = Describe("Istio resource", Ordered, func() { } else { When("grace period expires", func() { It("deletes the previous IstioRevision", func() { - revKey := getRevisionKey(istio, supportedversion.Old) + revKey := getRevisionKey(istio, istioversion.Old) Eventually(k8sClient.Get).WithArguments(ctx, revKey, rev).Should(ReturnNotFoundError()) }) }) @@ -425,7 +425,7 @@ var _ = Describe("Istio resource", Ordered, func() { When("strategy is changed to InPlace", func() { var oldRevisionKey types.NamespacedName BeforeAll(func() { - oldRevisionKey = getRevisionKey(istio, supportedversion.New) + oldRevisionKey = getRevisionKey(istio, istioversion.New) Expect(k8sClient.Get(ctx, istioKey, istio)).To(Succeed()) istio.Spec.UpdateStrategy.Type = v1.UpdateStrategyTypeInPlace Expect(k8sClient.Update(ctx, istio)).To(Succeed()) diff --git a/tests/integration/api/istiocni_test.go b/tests/integration/api/istiocni_test.go index f730f3046..c968a689e 100644 --- a/tests/integration/api/istiocni_test.go +++ b/tests/integration/api/istiocni_test.go @@ -23,9 +23,9 @@ import ( v1 "github.com/istio-ecosystem/sail-operator/api/v1" "github.com/istio-ecosystem/sail-operator/pkg/enqueuelogger" + "github.com/istio-ecosystem/sail-operator/pkg/istioversion" "github.com/istio-ecosystem/sail-operator/pkg/kube" . "github.com/istio-ecosystem/sail-operator/pkg/test/util/ginkgo" - "github.com/istio-ecosystem/sail-operator/pkg/test/util/supportedversion" . "github.com/onsi/ginkgo/v2" . "github.com/onsi/gomega" appsv1 "k8s.io/api/apps/v1" @@ -76,7 +76,7 @@ var _ = Describe("IstioCNI", Ordered, func() { Name: "not-default", }, Spec: v1.IstioCNISpec{ - Version: supportedversion.Default, + Version: istioversion.Default, Namespace: cniNamespace, }, } @@ -94,7 +94,7 @@ var _ = Describe("IstioCNI", Ordered, func() { Name: cniName, }, Spec: v1.IstioCNISpec{ - Version: supportedversion.Default, + Version: istioversion.Default, Namespace: nsName, }, } @@ -153,7 +153,7 @@ var _ = Describe("IstioCNI", Ordered, func() { Name: cniName, }, Spec: v1.IstioCNISpec{ - Version: supportedversion.Default, + Version: istioversion.Default, Namespace: cniNamespace, }, } diff --git a/tests/integration/api/istiorevision_test.go b/tests/integration/api/istiorevision_test.go index ca30e33fc..d029f314a 100644 --- a/tests/integration/api/istiorevision_test.go +++ b/tests/integration/api/istiorevision_test.go @@ -24,9 +24,9 @@ import ( v1 "github.com/istio-ecosystem/sail-operator/api/v1" "github.com/istio-ecosystem/sail-operator/pkg/enqueuelogger" + "github.com/istio-ecosystem/sail-operator/pkg/istioversion" "github.com/istio-ecosystem/sail-operator/pkg/kube" . "github.com/istio-ecosystem/sail-operator/pkg/test/util/ginkgo" - "github.com/istio-ecosystem/sail-operator/pkg/test/util/supportedversion" . "github.com/onsi/ginkgo/v2" . "github.com/onsi/gomega" "github.com/prometheus/common/expfmt" @@ -98,7 +98,7 @@ var _ = Describe("IstioRevision resource", Ordered, func() { Name: revName, }, Spec: v1.IstioRevisionSpec{ - Version: supportedversion.Default, + Version: istioversion.Default, Namespace: istioNamespace, Values: &v1.Values{ Revision: ptr.Of(revName), @@ -117,7 +117,7 @@ var _ = Describe("IstioRevision resource", Ordered, func() { Name: revName, }, Spec: v1.IstioRevisionSpec{ - Version: supportedversion.Default, + Version: istioversion.Default, Namespace: istioNamespace, Values: &v1.Values{ Revision: ptr.Of("is-not-" + revName), @@ -136,7 +136,7 @@ var _ = Describe("IstioRevision resource", Ordered, func() { Name: "default", }, Spec: v1.IstioRevisionSpec{ - Version: supportedversion.Default, + Version: istioversion.Default, Namespace: istioNamespace, Values: &v1.Values{ Revision: ptr.Of("default"), // this must be rejected, because revision needs to be '' when metadata.name is 'default' @@ -155,7 +155,7 @@ var _ = Describe("IstioRevision resource", Ordered, func() { Name: "default", }, Spec: v1.IstioRevisionSpec{ - Version: supportedversion.Default, + Version: istioversion.Default, Namespace: istioNamespace, Values: &v1.Values{ Revision: ptr.Of(""), @@ -178,7 +178,7 @@ var _ = Describe("IstioRevision resource", Ordered, func() { Name: revName, }, Spec: v1.IstioRevisionSpec{ - Version: supportedversion.Default, + Version: istioversion.Default, Namespace: nsName, Values: &v1.Values{ Revision: ptr.Of(revName), @@ -244,7 +244,7 @@ var _ = Describe("IstioRevision resource", Ordered, func() { Name: revName, }, Spec: v1.IstioRevisionSpec{ - Version: supportedversion.Default, + Version: istioversion.Default, Namespace: istioNamespace, Values: &v1.Values{ Global: &v1.GlobalConfig{ @@ -460,7 +460,7 @@ var _ = Describe("IstioRevision resource", Ordered, func() { Name: rev2Key.Name, }, Spec: v1.IstioRevisionSpec{ - Version: supportedversion.Default, + Version: istioversion.Default, Namespace: istioNamespace, Values: &v1.Values{ Global: &v1.GlobalConfig{ diff --git a/tests/integration/api/istiorevisiontag_test.go b/tests/integration/api/istiorevisiontag_test.go index ed7137b0b..0344ce98d 100644 --- a/tests/integration/api/istiorevisiontag_test.go +++ b/tests/integration/api/istiorevisiontag_test.go @@ -21,8 +21,8 @@ import ( "time" v1 "github.com/istio-ecosystem/sail-operator/api/v1" + "github.com/istio-ecosystem/sail-operator/pkg/istioversion" . "github.com/istio-ecosystem/sail-operator/pkg/test/util/ginkgo" - "github.com/istio-ecosystem/sail-operator/pkg/test/util/supportedversion" . "github.com/onsi/ginkgo/v2" . "github.com/onsi/gomega" corev1 "k8s.io/api/core/v1" @@ -107,7 +107,7 @@ var _ = Describe("IstioRevisionTag resource", Ordered, func() { Name: istioName, }, Spec: v1.IstioSpec{ - Version: supportedversion.Old, + Version: istioversion.Old, Namespace: istioRevisionTagNamespace, UpdateStrategy: &v1.IstioUpdateStrategy{ Type: updateStrategy, @@ -146,7 +146,7 @@ var _ = Describe("IstioRevisionTag resource", Ordered, func() { Eventually(func(g Gomega) { g.Expect(k8sClient.Get(ctx, defaultTagKey, tag)).To(Succeed()) g.Expect(tag.Status.ObservedGeneration).To(Equal(tag.Generation)) - g.Expect(tag.Status.IstioRevision).To(Equal(getRevisionName(istio, supportedversion.Old))) + g.Expect(tag.Status.IstioRevision).To(Equal(getRevisionName(istio, istioversion.Old))) g.Expect(tag.Status.GetCondition(v1.IstioRevisionTagConditionInUse).Status).To(Equal(metav1.ConditionFalse)) }).Should(Succeed()) }) @@ -169,7 +169,7 @@ var _ = Describe("IstioRevisionTag resource", Ordered, func() { When("updating the Istio control plane version", func() { BeforeAll(func() { Expect(k8sClient.Get(ctx, istioKey, istio)).To(Succeed()) - istio.Spec.Version = supportedversion.Default + istio.Spec.Version = istioversion.Default Expect(k8sClient.Update(ctx, istio)).To(Succeed()) }) @@ -177,7 +177,7 @@ var _ = Describe("IstioRevisionTag resource", Ordered, func() { It("updates IstioRevisionTag status and still references old revision", func() { Eventually(func(g Gomega) { g.Expect(k8sClient.Get(ctx, defaultTagKey, tag)).To(Succeed()) - g.Expect(tag.Status.IstioRevision).To(Equal(getRevisionName(istio, supportedversion.Old))) + g.Expect(tag.Status.IstioRevision).To(Equal(getRevisionName(istio, istioversion.Old))) g.Expect(tag.Status.GetCondition(v1.IstioRevisionTagConditionInUse).Status).To(Equal(metav1.ConditionTrue)) }).Should(Succeed()) }) @@ -185,7 +185,7 @@ var _ = Describe("IstioRevisionTag resource", Ordered, func() { It("updates IstioRevisionTag status and shows new referenced revision", func() { Eventually(func(g Gomega) { g.Expect(k8sClient.Get(ctx, defaultTagKey, tag)).To(Succeed()) - g.Expect(tag.Status.IstioRevision).To(Equal(getRevisionName(istio, supportedversion.New))) + g.Expect(tag.Status.IstioRevision).To(Equal(getRevisionName(istio, istioversion.New))) g.Expect(tag.Status.GetCondition(v1.IstioRevisionTagConditionInUse).Status).To(Equal(metav1.ConditionTrue)) }).Should(Succeed()) }) @@ -207,7 +207,7 @@ var _ = Describe("IstioRevisionTag resource", Ordered, func() { }) if referencedResource == v1.IstioRevisionKind && updateStrategy == v1.UpdateStrategyTypeRevisionBased { It("does not delete the referenced IstioRevision even though it is no longer in use and not the active revision", func() { - revKey := client.ObjectKey{Name: getRevisionName(istio, supportedversion.Old)} + revKey := client.ObjectKey{Name: getRevisionName(istio, istioversion.Old)} rev := &v1.IstioRevision{} Consistently(k8sClient.Get).WithArguments(ctx, revKey, rev).Should(Succeed()) }) @@ -243,7 +243,7 @@ var _ = Describe("IstioRevisionTag resource", Ordered, func() { Name: "default", }, Spec: v1.IstioSpec{ - Version: supportedversion.Old, + Version: istioversion.Old, Namespace: istioRevisionTagNamespace, UpdateStrategy: &v1.IstioUpdateStrategy{ Type: v1.UpdateStrategyTypeInPlace, @@ -257,7 +257,7 @@ var _ = Describe("IstioRevisionTag resource", Ordered, func() { Name: istioName, }, Spec: v1.IstioSpec{ - Version: supportedversion.Old, + Version: istioversion.Old, Namespace: istioRevisionTagNamespace, UpdateStrategy: &v1.IstioUpdateStrategy{ Type: v1.UpdateStrategyTypeInPlace, @@ -338,7 +338,7 @@ var _ = Describe("IstioRevisionTag resource", Ordered, func() { Name: "default", }, Spec: v1.IstioSpec{ - Version: supportedversion.Old, + Version: istioversion.Old, Namespace: istioRevisionTagNamespace, UpdateStrategy: &v1.IstioUpdateStrategy{ Type: v1.UpdateStrategyTypeInPlace,