diff --git a/crates/stackable-operator/CHANGELOG.md b/crates/stackable-operator/CHANGELOG.md index d3869aa15..e34e75981 100644 --- a/crates/stackable-operator/CHANGELOG.md +++ b/crates/stackable-operator/CHANGELOG.md @@ -4,6 +4,12 @@ All notable changes to this project will be documented in this file. ## [Unreleased] +### Changed + +- Change constant used for product image selection so that it defaults to OCI ([#945]). + +[#945]: https://github.com/stackabletech/operator-rs/pull/945 + ## [0.84.1] - 2025-01-22 ### Fixed diff --git a/crates/stackable-operator/fixtures/helm/input-additional.yaml b/crates/stackable-operator/fixtures/helm/input-additional.yaml index 8d76e3e5a..5af9845e0 100644 --- a/crates/stackable-operator/fixtures/helm/input-additional.yaml +++ b/crates/stackable-operator/fixtures/helm/input-additional.yaml @@ -1,7 +1,7 @@ # Partly taken from https://github.com/stackabletech/zookeeper-operator/blob/main/deploy/helm/zookeeper-operator/values.yaml --- image: - repository: docker.stackable.tech/stackable/zookeeper-operator + repository: oci.stackable.tech/sdp/zookeeper-operator pullPolicy: IfNotPresent pullSecrets: [] nameOverride: '' diff --git a/crates/stackable-operator/fixtures/helm/input-required.yaml b/crates/stackable-operator/fixtures/helm/input-required.yaml index f2980d160..808b8a370 100644 --- a/crates/stackable-operator/fixtures/helm/input-required.yaml +++ b/crates/stackable-operator/fixtures/helm/input-required.yaml @@ -1,7 +1,7 @@ # Partly taken from https://github.com/stackabletech/zookeeper-operator/blob/main/deploy/helm/zookeeper-operator/values.yaml --- image: - repository: docker.stackable.tech/stackable/zookeeper-operator + repository: oci.stackable.tech/sdp/zookeeper-operator pullPolicy: IfNotPresent pullSecrets: [] nameOverride: '' diff --git a/crates/stackable-operator/fixtures/helm/output.yaml b/crates/stackable-operator/fixtures/helm/output.yaml index 19ef71801..d1eb23e3f 100644 --- a/crates/stackable-operator/fixtures/helm/output.yaml +++ b/crates/stackable-operator/fixtures/helm/output.yaml @@ -1,6 +1,6 @@ --- image: - repository: docker.stackable.tech/stackable/zookeeper-operator + repository: oci.stackable.tech/sdp/zookeeper-operator pullPolicy: IfNotPresent pullSecrets: [] nameOverride: '' diff --git a/crates/stackable-operator/src/commons/product_image_selection.rs b/crates/stackable-operator/src/commons/product_image_selection.rs index d5e02de3d..66a3fa916 100644 --- a/crates/stackable-operator/src/commons/product_image_selection.rs +++ b/crates/stackable-operator/src/commons/product_image_selection.rs @@ -7,7 +7,7 @@ use strum::AsRefStr; #[cfg(doc)] use crate::kvp::Labels; -pub const STACKABLE_DOCKER_REPO: &str = "docker.stackable.tech/stackable"; +pub const STACKABLE_DOCKER_REPO: &str = "oci.stackable.tech/sdp"; /// Specify which image to use, the easiest way is to only configure the `productVersion`. /// You can also configure a custom image registry to pull from, as well as completely custom @@ -43,7 +43,7 @@ pub enum ProductImageSelection { #[serde(rename_all = "camelCase")] pub struct ProductImageCustom { /// Overwrite the docker image. - /// Specify the full docker image name, e.g. `docker.stackable.tech/stackable/superset:1.4.1-stackable2.1.0` + /// Specify the full docker image name, e.g. `oci.stackable.tech/sdp/superset:1.4.1-stackable2.1.0` custom: String, /// Version of the product, e.g. `1.4.1`. product_version: String, @@ -58,7 +58,7 @@ pub struct ProductImageStackableVersion { /// If not specified, the operator will use its own version, e.g. `23.4.1`. /// When using a nightly operator or a pr version, it will use the nightly `0.0.0-dev` image. stackable_version: Option, - /// Name of the docker repo, e.g. `docker.stackable.tech/stackable` + /// Name of the docker repo, e.g. `oci.stackable.tech/sdp` repo: Option, } @@ -70,7 +70,7 @@ pub struct ResolvedProductImage { /// App version as formatted for [`Labels::recommended`] pub app_version_label: String, - /// Image to be used for the product image e.g. `docker.stackable.tech/stackable/superset:1.4.1-stackable2.1.0` + /// Image to be used for the product image e.g. `oci.stackable.tech/sdp/superset:1.4.1-stackable2.1.0` pub image: String, /// Image pull policy for the containers using the product image @@ -190,7 +190,7 @@ mod tests { productVersion: 1.4.1 "#, ResolvedProductImage { - image: "docker.stackable.tech/stackable/superset:1.4.1-stackable23.7.42".to_string(), + image: "oci.stackable.tech/sdp/superset:1.4.1-stackable23.7.42".to_string(), app_version_label: "1.4.1-stackable23.7.42".to_string(), product_version: "1.4.1".to_string(), image_pull_policy: "Always".to_string(), @@ -204,7 +204,7 @@ mod tests { productVersion: 1.4.1 "#, ResolvedProductImage { - image: "docker.stackable.tech/stackable/superset:1.4.1-stackable0.0.0-dev".to_string(), + image: "oci.stackable.tech/sdp/superset:1.4.1-stackable0.0.0-dev".to_string(), app_version_label: "1.4.1-stackable0.0.0-dev".to_string(), product_version: "1.4.1".to_string(), image_pull_policy: "Always".to_string(), @@ -218,7 +218,7 @@ mod tests { productVersion: 1.4.1 "#, ResolvedProductImage { - image: "docker.stackable.tech/stackable/superset:1.4.1-stackable0.0.0-dev".to_string(), + image: "oci.stackable.tech/sdp/superset:1.4.1-stackable0.0.0-dev".to_string(), app_version_label: "1.4.1-stackable0.0.0-dev".to_string(), product_version: "1.4.1".to_string(), image_pull_policy: "Always".to_string(), @@ -233,7 +233,7 @@ mod tests { stackableVersion: 2.1.0 "#, ResolvedProductImage { - image: "docker.stackable.tech/stackable/superset:1.4.1-stackable2.1.0".to_string(), + image: "oci.stackable.tech/sdp/superset:1.4.1-stackable2.1.0".to_string(), app_version_label: "1.4.1-stackable2.1.0".to_string(), product_version: "1.4.1".to_string(), image_pull_policy: "Always".to_string(), @@ -320,11 +320,11 @@ mod tests { "superset", "23.7.42", r#" - custom: docker.stackable.tech/stackable/superset@sha256:85fa483aa99b9997ce476b86893ad5ed81fb7fd2db602977eb8c42f76efc1098 + custom: oci.stackable.tech/sdp/superset@sha256:85fa483aa99b9997ce476b86893ad5ed81fb7fd2db602977eb8c42f76efc1098 productVersion: 1.4.1 "#, ResolvedProductImage { - image: "docker.stackable.tech/stackable/superset@sha256:85fa483aa99b9997ce476b86893ad5ed81fb7fd2db602977eb8c42f76efc1098".to_string(), + image: "oci.stackable.tech/sdp/superset@sha256:85fa483aa99b9997ce476b86893ad5ed81fb7fd2db602977eb8c42f76efc1098".to_string(), app_version_label: "1.4.1-sha256:85fa483aa99b9997ce476b86893ad5ed81fb7fd2db602977eb".to_string(), product_version: "1.4.1".to_string(), image_pull_policy: "Always".to_string(), diff --git a/crates/stackable-operator/src/product_logging/framework.rs b/crates/stackable-operator/src/product_logging/framework.rs index 5acfa2deb..f5ee29022 100644 --- a/crates/stackable-operator/src/product_logging/framework.rs +++ b/crates/stackable-operator/src/product_logging/framework.rs @@ -1383,7 +1383,7 @@ sinks: /// # let resolved_product_image = ResolvedProductImage { /// # product_version: "1.0.0".into(), /// # app_version_label: "1.0.0".into(), -/// # image: "docker.stackable.tech/stackable/my-product:1.0.0-stackable1.0.0".into(), +/// # image: "oci.stackable.tech/sdp/my-product:1.0.0-stackable1.0.0".into(), /// # image_pull_policy: "Always".into(), /// # pull_secrets: None, /// # }; @@ -1503,7 +1503,7 @@ kill $vector_pid /// /// let container = ContainerBuilder::new("init") /// .unwrap() -/// .image("docker.stackable.tech/stackable/my-product:1.0.0-stackable1.0.0") +/// .image("oci.stackable.tech/sdp/my-product:1.0.0-stackable1.0.0") /// .command(vec!["bash".to_string(), "-c".to_string()]) /// .args(vec![args.join(" && ")]) /// .add_volume_mount("log", STACKABLE_LOG_DIR) diff --git a/crates/stackable-operator/src/utils/crds.rs b/crates/stackable-operator/src/utils/crds.rs index faed4cfdb..299ef9296 100644 --- a/crates/stackable-operator/src/utils/crds.rs +++ b/crates/stackable-operator/src/utils/crds.rs @@ -93,7 +93,7 @@ mod tests { spec: containers: - name: nifi - image: docker.stackable.tech/stackable/nifi:1.23.2-stackable23.11.0 + image: oci.stackable.tech/sdp/nifi:1.23.2-stackable23.11.0 volumeMounts: - name: jar mountPath: /stackable/nifi/lib/wifi.png @@ -116,7 +116,7 @@ mod tests { podOverrides: spec: containers: - - image: docker.stackable.tech/stackable/nifi:1.23.2-stackable23.11.0 + - image: oci.stackable.tech/sdp/nifi:1.23.2-stackable23.11.0 "#; // FIXME: Ideally we would require the names of the containers to be set. We had users using podOverrides