Skip to content

Commit

Permalink
Removed tools image for init and get-svc container
Browse files Browse the repository at this point in the history
  • Loading branch information
sbernauer committed Dec 13, 2022
1 parent 9f72a53 commit 41b2116
Show file tree
Hide file tree
Showing 4 changed files with 13 additions and 12 deletions.
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,11 +10,13 @@ All notable changes to this project will be documented in this file.
- operator-rs: 0.26.0 -> 0.27.1 ([#519]).
- Don't run init container as root and avoid chmod and chowning ([#524]).
- [BREAKING] Use Product image selection instead of version. `spec.version` has been replaced by `spec.image` ([#482]).
- [BREAKING]: Removed tools image for init and get-svc container and replaced with Kafka product image. This means the latest stackable version has to be used in the product image selection ([#357])

[#482]: https://github.com/stackabletech/kafka-operator/pull/482
[#513]: https://github.com/stackabletech/kafka-operator/pull/513
[#519]: https://github.com/stackabletech/kafka-operator/pull/519
[#524]: https://github.com/stackabletech/kafka-operator/pull/524
[#527]: https://github.com/stackabletech/kafka-operator/pull/527

## [0.8.0] - 2022-11-07

Expand Down
2 changes: 1 addition & 1 deletion rust/operator/src/command.rs
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ pub fn get_svc_container_cmd_args(kafka: &KafkaCluster) -> String {
}

pub fn kcat_container_cmd_args(kafka: &KafkaCluster) -> Vec<String> {
let mut args = vec!["kcat".to_string()];
let mut args = vec!["/stackable/kcat".to_string()];

if kafka.client_authentication_class().is_some() {
args.push("-b".to_string());
Expand Down
11 changes: 5 additions & 6 deletions rust/operator/src/kafka_controller.rs
Original file line number Diff line number Diff line change
Expand Up @@ -663,7 +663,7 @@ fn build_broker_rolegroup_statefulset(
.context(InvalidContainerNameSnafu {
name: "get-svc".to_string(),
})?
.image("docker.stackable.tech/stackable/tools:0.2.0-stackable0.4.0")
.image_from_product_image(resolved_product_image)
.command(vec!["bash".to_string()])
.args(vec![
"-euo".to_string(),
Expand All @@ -686,7 +686,7 @@ fn build_broker_rolegroup_statefulset(
.build();

cb_prepare
.image("docker.stackable.tech/stackable/tools:0.2.0-stackable0.4.0")
.image_from_product_image(resolved_product_image)
.command(vec![
"/bin/bash".to_string(),
"-euo".to_string(),
Expand Down Expand Up @@ -814,9 +814,9 @@ fn build_broker_rolegroup_statefulset(

// Use kcat sidecar for probing container status rather than the official Kafka tools, since they incur a lot of
// unacceptable perf overhead
let mut container_kcat_prober = cb_kcat_prober
.image("edenhill/kcat:1.7.0")
.command(vec!["sh".to_string()])
let container_kcat_prober = cb_kcat_prober
.image_from_product_image(resolved_product_image)
.command(vec!["sleep".to_string(), "infinity".to_string()])
// Only allow the global load balancing service to send traffic to pods that are members of the quorum
// This also acts as a hint to the StatefulSet controller to wait for each pod to enter quorum before taking down the next
.readiness_probe(Probe {
Expand All @@ -829,7 +829,6 @@ fn build_broker_rolegroup_statefulset(
..Probe::default()
})
.build();
container_kcat_prober.stdin = Some(true);
let mut pod_template = pod_builder
.metadata_builder(|m| {
m.with_recommended_labels(build_recommended_labels(
Expand Down
10 changes: 5 additions & 5 deletions tests/test-definition.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,13 @@
dimensions:
- name: kafka
values:
- 2.8.1-stackable0.6.0
- 3.1.0-stackable0.6.0
- 3.2.0-stackable0.2.0
- 3.3.1-stackable0.2.0
- 2.8.1-stackable0.7.0
- 3.1.0-stackable0.7.0
- 3.2.0-stackable0.3.0
- 3.3.1-stackable0.3.0
- name: kafka-latest
values:
- 3.3.1-stackable0.2.0
- 3.3.1-stackable0.3.0
- name: zookeeper
values:
- 3.6.3-stackable0.8.0
Expand Down

0 comments on commit 41b2116

Please sign in to comment.