Skip to content

Commit c734f04

Browse files
maltesandersoenkeliebausiegfriedweber
authored
Patch op-rs version to use one that fixes SUP-148. (#656)
* Patch op-rs version to use one that fixes SUP-148. * Updated changelog Use released op-rs version. * Regenerate Nix files * Run pre-commit --------- Co-authored-by: Sönke Liebau <[email protected]> Co-authored-by: Siegfried Weber <[email protected]>
1 parent 1efd22c commit c734f04

File tree

8 files changed

+24
-22
lines changed

8 files changed

+24
-22
lines changed

CHANGELOG.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,7 @@ All notable changes to this project will be documented in this file.
2525

2626
- Bundle builder should no longer keep serving deleted rules until it is restarted ([#578]).
2727
- Failing to parse one `OpaCluster` should no longer cause the whole operator to stop functioning ([#638]).
28+
- BREAKING: Use distinct ServiceAccounts for the Stacklets, so that multiple Stacklets can be deployed in one namespace. Existing Stacklets will use the newly created ServiceAccounts after restart ([#656]).
2829

2930
### Removed
3031

@@ -37,6 +38,7 @@ All notable changes to this project will be documented in this file.
3738
[#622]: https://github.com/stackabletech/opa-operator/pull/622
3839
[#637]: https://github.com/stackabletech/opa-operator/pull/637
3940
[#638]: https://github.com/stackabletech/opa-operator/pull/638
41+
[#656]: https://github.com/stackabletech/opa-operator/pull/656
4042

4143
## [24.7.0] - 2024-07-24
4244

Cargo.lock

Lines changed: 4 additions & 4 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.nix

Lines changed: 7 additions & 7 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ semver = "1.0"
3333
serde = { version = "1.0", features = ["derive"] }
3434
serde_json = "1.0"
3535
snafu = "0.8"
36-
stackable-operator = { git = "https://github.com/stackabletech/operator-rs.git", tag = "stackable-operator-0.80.0" }
36+
stackable-operator = { git = "https://github.com/stackabletech/operator-rs.git", tag = "stackable-operator-0.82.0" }
3737
strum = { version = "0.26", features = ["derive"] }
3838
tar = "0.4"
3939
tokio = { version = "1.40", features = ["full"] }

crate-hashes.json

Lines changed: 3 additions & 3 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

deploy/helm/opa-operator/templates/roles-opa-builder.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ metadata:
44
name: {{ .Release.Name }}-opa-bundle-builder-clusterrole
55
# This role is used for the OPA bundle builder.
66
# It needs to read ConfigMaps and watch ConfigMaps for changes,
7-
# because the Rego rules that are used to build the bundles are
7+
# because the Rego rules that are used to build the bundles are
88
# stored in the ConfigMaps.
99
rules:
1010
- apiGroups:

rust/operator-binary/src/controller.rs

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ use stackable_operator::{
3838
apps::v1::{DaemonSet, DaemonSetSpec},
3939
core::v1::{
4040
ConfigMap, EmptyDirVolumeSource, EnvVar, HTTPGetAction, Probe, SecretVolumeSource,
41-
Service, ServicePort, ServiceSpec,
41+
Service, ServiceAccount, ServicePort, ServiceSpec,
4242
},
4343
},
4444
apimachinery::pkg::{apis::meta::v1::LabelSelector, util::intstr::IntOrString},
@@ -457,7 +457,7 @@ pub async fn reconcile_opa(
457457
build_rbac_resources(opa, APP_NAME, required_labels).context(BuildRbacResourcesSnafu)?;
458458

459459
let rbac_sa = cluster_resources
460-
.add(client, rbac_sa)
460+
.add(client, rbac_sa.clone())
461461
.await
462462
.context(ApplyServiceAccountSnafu)?;
463463
cluster_resources
@@ -495,7 +495,7 @@ pub async fn reconcile_opa(
495495
&merged_config,
496496
&ctx.opa_bundle_builder_image,
497497
&ctx.user_info_fetcher_image,
498-
&rbac_sa.name_any(),
498+
&rbac_sa,
499499
)?;
500500

501501
cluster_resources
@@ -740,7 +740,7 @@ fn build_server_rolegroup_daemonset(
740740
merged_config: &OpaConfig,
741741
opa_bundle_builder_image: &str,
742742
user_info_fetcher_image: &str,
743-
sa_name: &str,
743+
service_account: &ServiceAccount,
744744
) -> Result<DaemonSet> {
745745
let role = opa.role(opa_role);
746746
let role_group = opa
@@ -932,7 +932,7 @@ fn build_server_rolegroup_daemonset(
932932
.build(),
933933
)
934934
.context(AddVolumeSnafu)?
935-
.service_account_name(sa_name)
935+
.service_account_name(service_account.name_any())
936936
.security_context(
937937
PodSecurityContextBuilder::new()
938938
.run_as_user(1000)

tests/templates/kuttl/logging/test_log_aggregation.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,4 +8,4 @@ then
88
exit 1;
99
fi
1010

11-
echo "Test successful!";
11+
echo "Test successful!";

0 commit comments

Comments
 (0)