From 91f4bb1972f1c320ca97df66e2cdeea29f914f77 Mon Sep 17 00:00:00 2001 From: Techassi Date: Wed, 16 Apr 2025 14:57:56 +0200 Subject: [PATCH 1/7] chore: Bump stackable-operator to 0.92.0 --- Cargo.lock | 18 +++++++++--------- Cargo.nix | 32 ++++++++++++++++---------------- Cargo.toml | 2 +- crate-hashes.json | 14 +++++++------- 4 files changed, 33 insertions(+), 33 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 48bedf71..d65af525 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1623,7 +1623,7 @@ dependencies = [ [[package]] name = "k8s-version" version = "0.1.2" -source = "git+https://github.com/stackabletech/operator-rs.git?tag=stackable-operator-0.91.1#0f9b6f9669051e9c4f29e6e882acf3eff3ac3f14" +source = "git+https://github.com/stackabletech/operator-rs.git?tag=stackable-operator-0.92.0#5fdc47a10de685e4eea49fd0a3f6c3a15a4966c1" dependencies = [ "darling", "regex", @@ -3065,8 +3065,8 @@ dependencies = [ [[package]] name = "stackable-operator" -version = "0.91.1" -source = "git+https://github.com/stackabletech/operator-rs.git?tag=stackable-operator-0.91.1#0f9b6f9669051e9c4f29e6e882acf3eff3ac3f14" +version = "0.92.0" +source = "git+https://github.com/stackabletech/operator-rs.git?tag=stackable-operator-0.92.0#5fdc47a10de685e4eea49fd0a3f6c3a15a4966c1" dependencies = [ "chrono", "clap", @@ -3103,7 +3103,7 @@ dependencies = [ [[package]] name = "stackable-operator-derive" version = "0.3.1" -source = "git+https://github.com/stackabletech/operator-rs.git?tag=stackable-operator-0.91.1#0f9b6f9669051e9c4f29e6e882acf3eff3ac3f14" +source = "git+https://github.com/stackabletech/operator-rs.git?tag=stackable-operator-0.92.0#5fdc47a10de685e4eea49fd0a3f6c3a15a4966c1" dependencies = [ "darling", "proc-macro2", @@ -3114,7 +3114,7 @@ dependencies = [ [[package]] name = "stackable-shared" version = "0.0.1" -source = "git+https://github.com/stackabletech/operator-rs.git?tag=stackable-operator-0.91.1#0f9b6f9669051e9c4f29e6e882acf3eff3ac3f14" +source = "git+https://github.com/stackabletech/operator-rs.git?tag=stackable-operator-0.92.0#5fdc47a10de685e4eea49fd0a3f6c3a15a4966c1" dependencies = [ "kube", "semver", @@ -3125,8 +3125,8 @@ dependencies = [ [[package]] name = "stackable-telemetry" -version = "0.5.0" -source = "git+https://github.com/stackabletech/operator-rs.git?tag=stackable-operator-0.91.1#0f9b6f9669051e9c4f29e6e882acf3eff3ac3f14" +version = "0.6.0" +source = "git+https://github.com/stackabletech/operator-rs.git?tag=stackable-operator-0.92.0#5fdc47a10de685e4eea49fd0a3f6c3a15a4966c1" dependencies = [ "axum 0.8.3", "clap", @@ -3149,7 +3149,7 @@ dependencies = [ [[package]] name = "stackable-versioned" version = "0.7.1" -source = "git+https://github.com/stackabletech/operator-rs.git?tag=stackable-operator-0.91.1#0f9b6f9669051e9c4f29e6e882acf3eff3ac3f14" +source = "git+https://github.com/stackabletech/operator-rs.git?tag=stackable-operator-0.92.0#5fdc47a10de685e4eea49fd0a3f6c3a15a4966c1" dependencies = [ "stackable-versioned-macros", ] @@ -3157,7 +3157,7 @@ dependencies = [ [[package]] name = "stackable-versioned-macros" version = "0.7.1" -source = "git+https://github.com/stackabletech/operator-rs.git?tag=stackable-operator-0.91.1#0f9b6f9669051e9c4f29e6e882acf3eff3ac3f14" +source = "git+https://github.com/stackabletech/operator-rs.git?tag=stackable-operator-0.92.0#5fdc47a10de685e4eea49fd0a3f6c3a15a4966c1" dependencies = [ "convert_case", "darling", diff --git a/Cargo.nix b/Cargo.nix index 1ee8bac0..e12176cd 100644 --- a/Cargo.nix +++ b/Cargo.nix @@ -5146,8 +5146,8 @@ rec { workspace_member = null; src = pkgs.fetchgit { url = "https://github.com/stackabletech/operator-rs.git"; - rev = "0f9b6f9669051e9c4f29e6e882acf3eff3ac3f14"; - sha256 = "11zqwlwvfigca7lfsdch1wqd3vl694hff1avf6rhiawpnassj2cw"; + rev = "5fdc47a10de685e4eea49fd0a3f6c3a15a4966c1"; + sha256 = "0li9smdrz7danqz17lfkl0j9zl2i84csgc7d01lxs5qi8jcs9fzw"; }; libName = "k8s_version"; authors = [ @@ -10096,13 +10096,13 @@ rec { }; "stackable-operator" = rec { crateName = "stackable-operator"; - version = "0.91.1"; + version = "0.92.0"; edition = "2024"; workspace_member = null; src = pkgs.fetchgit { url = "https://github.com/stackabletech/operator-rs.git"; - rev = "0f9b6f9669051e9c4f29e6e882acf3eff3ac3f14"; - sha256 = "11zqwlwvfigca7lfsdch1wqd3vl694hff1avf6rhiawpnassj2cw"; + rev = "5fdc47a10de685e4eea49fd0a3f6c3a15a4966c1"; + sha256 = "0li9smdrz7danqz17lfkl0j9zl2i84csgc7d01lxs5qi8jcs9fzw"; }; libName = "stackable_operator"; authors = [ @@ -10260,8 +10260,8 @@ rec { workspace_member = null; src = pkgs.fetchgit { url = "https://github.com/stackabletech/operator-rs.git"; - rev = "0f9b6f9669051e9c4f29e6e882acf3eff3ac3f14"; - sha256 = "11zqwlwvfigca7lfsdch1wqd3vl694hff1avf6rhiawpnassj2cw"; + rev = "5fdc47a10de685e4eea49fd0a3f6c3a15a4966c1"; + sha256 = "0li9smdrz7danqz17lfkl0j9zl2i84csgc7d01lxs5qi8jcs9fzw"; }; procMacro = true; libName = "stackable_operator_derive"; @@ -10295,8 +10295,8 @@ rec { workspace_member = null; src = pkgs.fetchgit { url = "https://github.com/stackabletech/operator-rs.git"; - rev = "0f9b6f9669051e9c4f29e6e882acf3eff3ac3f14"; - sha256 = "11zqwlwvfigca7lfsdch1wqd3vl694hff1avf6rhiawpnassj2cw"; + rev = "5fdc47a10de685e4eea49fd0a3f6c3a15a4966c1"; + sha256 = "0li9smdrz7danqz17lfkl0j9zl2i84csgc7d01lxs5qi8jcs9fzw"; }; libName = "stackable_shared"; authors = [ @@ -10331,13 +10331,13 @@ rec { }; "stackable-telemetry" = rec { crateName = "stackable-telemetry"; - version = "0.5.0"; + version = "0.6.0"; edition = "2024"; workspace_member = null; src = pkgs.fetchgit { url = "https://github.com/stackabletech/operator-rs.git"; - rev = "0f9b6f9669051e9c4f29e6e882acf3eff3ac3f14"; - sha256 = "11zqwlwvfigca7lfsdch1wqd3vl694hff1avf6rhiawpnassj2cw"; + rev = "5fdc47a10de685e4eea49fd0a3f6c3a15a4966c1"; + sha256 = "0li9smdrz7danqz17lfkl0j9zl2i84csgc7d01lxs5qi8jcs9fzw"; }; libName = "stackable_telemetry"; authors = [ @@ -10441,8 +10441,8 @@ rec { workspace_member = null; src = pkgs.fetchgit { url = "https://github.com/stackabletech/operator-rs.git"; - rev = "0f9b6f9669051e9c4f29e6e882acf3eff3ac3f14"; - sha256 = "11zqwlwvfigca7lfsdch1wqd3vl694hff1avf6rhiawpnassj2cw"; + rev = "5fdc47a10de685e4eea49fd0a3f6c3a15a4966c1"; + sha256 = "0li9smdrz7danqz17lfkl0j9zl2i84csgc7d01lxs5qi8jcs9fzw"; }; libName = "stackable_versioned"; authors = [ @@ -10467,8 +10467,8 @@ rec { workspace_member = null; src = pkgs.fetchgit { url = "https://github.com/stackabletech/operator-rs.git"; - rev = "0f9b6f9669051e9c4f29e6e882acf3eff3ac3f14"; - sha256 = "11zqwlwvfigca7lfsdch1wqd3vl694hff1avf6rhiawpnassj2cw"; + rev = "5fdc47a10de685e4eea49fd0a3f6c3a15a4966c1"; + sha256 = "0li9smdrz7danqz17lfkl0j9zl2i84csgc7d01lxs5qi8jcs9fzw"; }; procMacro = true; libName = "stackable_versioned_macros"; diff --git a/Cargo.toml b/Cargo.toml index d74884a0..8b7e54a0 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -11,7 +11,7 @@ repository = "https://github.com/stackabletech/opa-operator" [workspace.dependencies] product-config = { git = "https://github.com/stackabletech/product-config.git", tag = "0.7.0" } -stackable-operator = { git = "https://github.com/stackabletech/operator-rs.git", features = ["telemetry", "versioned"], tag = "stackable-operator-0.91.1" } +stackable-operator = { git = "https://github.com/stackabletech/operator-rs.git", features = ["telemetry", "versioned"], tag = "stackable-operator-0.92.0" } anyhow = "1.0" axum = "0.8" diff --git a/crate-hashes.json b/crate-hashes.json index e4629311..9dcf61ef 100644 --- a/crate-hashes.json +++ b/crate-hashes.json @@ -1,10 +1,10 @@ { - "git+https://github.com/stackabletech/operator-rs.git?tag=stackable-operator-0.91.1#k8s-version@0.1.2": "11zqwlwvfigca7lfsdch1wqd3vl694hff1avf6rhiawpnassj2cw", - "git+https://github.com/stackabletech/operator-rs.git?tag=stackable-operator-0.91.1#stackable-operator-derive@0.3.1": "11zqwlwvfigca7lfsdch1wqd3vl694hff1avf6rhiawpnassj2cw", - "git+https://github.com/stackabletech/operator-rs.git?tag=stackable-operator-0.91.1#stackable-operator@0.91.1": "11zqwlwvfigca7lfsdch1wqd3vl694hff1avf6rhiawpnassj2cw", - "git+https://github.com/stackabletech/operator-rs.git?tag=stackable-operator-0.91.1#stackable-shared@0.0.1": "11zqwlwvfigca7lfsdch1wqd3vl694hff1avf6rhiawpnassj2cw", - "git+https://github.com/stackabletech/operator-rs.git?tag=stackable-operator-0.91.1#stackable-telemetry@0.5.0": "11zqwlwvfigca7lfsdch1wqd3vl694hff1avf6rhiawpnassj2cw", - "git+https://github.com/stackabletech/operator-rs.git?tag=stackable-operator-0.91.1#stackable-versioned-macros@0.7.1": "11zqwlwvfigca7lfsdch1wqd3vl694hff1avf6rhiawpnassj2cw", - "git+https://github.com/stackabletech/operator-rs.git?tag=stackable-operator-0.91.1#stackable-versioned@0.7.1": "11zqwlwvfigca7lfsdch1wqd3vl694hff1avf6rhiawpnassj2cw", + "git+https://github.com/stackabletech/operator-rs.git?tag=stackable-operator-0.92.0#k8s-version@0.1.2": "0li9smdrz7danqz17lfkl0j9zl2i84csgc7d01lxs5qi8jcs9fzw", + "git+https://github.com/stackabletech/operator-rs.git?tag=stackable-operator-0.92.0#stackable-operator-derive@0.3.1": "0li9smdrz7danqz17lfkl0j9zl2i84csgc7d01lxs5qi8jcs9fzw", + "git+https://github.com/stackabletech/operator-rs.git?tag=stackable-operator-0.92.0#stackable-operator@0.92.0": "0li9smdrz7danqz17lfkl0j9zl2i84csgc7d01lxs5qi8jcs9fzw", + "git+https://github.com/stackabletech/operator-rs.git?tag=stackable-operator-0.92.0#stackable-shared@0.0.1": "0li9smdrz7danqz17lfkl0j9zl2i84csgc7d01lxs5qi8jcs9fzw", + "git+https://github.com/stackabletech/operator-rs.git?tag=stackable-operator-0.92.0#stackable-telemetry@0.6.0": "0li9smdrz7danqz17lfkl0j9zl2i84csgc7d01lxs5qi8jcs9fzw", + "git+https://github.com/stackabletech/operator-rs.git?tag=stackable-operator-0.92.0#stackable-versioned-macros@0.7.1": "0li9smdrz7danqz17lfkl0j9zl2i84csgc7d01lxs5qi8jcs9fzw", + "git+https://github.com/stackabletech/operator-rs.git?tag=stackable-operator-0.92.0#stackable-versioned@0.7.1": "0li9smdrz7danqz17lfkl0j9zl2i84csgc7d01lxs5qi8jcs9fzw", "git+https://github.com/stackabletech/product-config.git?tag=0.7.0#product-config@0.7.0": "0gjsm80g6r75pm3824dcyiz4ysq1ka4c1if6k1mjm9cnd5ym0gny" } \ No newline at end of file From ef965ee4c0f05da1e7c6ec3431d68d88e6296aee Mon Sep 17 00:00:00 2001 From: Techassi Date: Wed, 16 Apr 2025 14:58:18 +0200 Subject: [PATCH 2/7] chore: Adjust env var for bundle builder container --- rust/operator-binary/src/controller.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/rust/operator-binary/src/controller.rs b/rust/operator-binary/src/controller.rs index 0538dae0..c26a5562 100644 --- a/rust/operator-binary/src/controller.rs +++ b/rust/operator-binary/src/controller.rs @@ -802,7 +802,7 @@ fn build_server_rolegroup_daemonset( bundle_builder_log_level(merged_config).to_string(), ) .add_env_var( - "ROLLING_LOGS_DIR", + "FILE_LOG_DIRECTORY", format!("{STACKABLE_LOG_DIR}/{bundle_builder_container_name}"), ) .add_volume_mount(BUNDLES_VOLUME_NAME, BUNDLES_DIR) From 13fb337fb4cee2221995efe5f58c15013fbeb59f Mon Sep 17 00:00:00 2001 From: Techassi Date: Wed, 16 Apr 2025 15:01:34 +0200 Subject: [PATCH 3/7] chore: Update changelog --- CHANGELOG.md | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 903cbb21..b197f426 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -10,22 +10,22 @@ All notable changes to this project will be documented in this file. ### Changed -- BREAKING: Replace stackable-operator `initialize_logging` with stackable-telemetry `Tracing` ([#703], [#710]). +- BREAKING: Replace stackable-operator `initialize_logging` with stackable-telemetry `Tracing` ([#703], [#710], [#715]). - operator-binary: - The console log level was set by `OPA_OPERATOR_LOG`, and is now set by `CONSOLE_LOG`. - The file log level was set by `OPA_OPERATOR_LOG`, and is now set by `FILE_LOG`. - The file log directory was set by `OPA_OPERATOR_LOG_DIRECTORY`, and is now set - by `ROLLING_LOGS_DIR` (or via `--rolling-logs `). + by `FILE_LOG_DIRECTORY` (or via `--file-log-directory `). - bundle-builder: - The console log level was set by `OPA_BUNDLE_BUILDER_LOG`, and is now set by `CONSOLE_LOG`. - The file log level was set by `OPA_BUNDLE_BUILDER_LOG`, and is now set by `FILE_LOG`. - The file log directory was set by `OPA_BUNDLE_BUILDER_LOG_DIRECTORY`, and is now set - by `ROLLING_LOGS_DIR` (or via `--rolling-logs `). + by `FILE_LOG_DIRECTORY` (or via `--file-log-directory `). - user-info-fetcher: - The console log level was set by `OPA_OPERATOR_LOG`, and is now set by `CONSOLE_LOG`. - The file log level was set by `OPA_OPERATOR_LOG`, and is now set by `FILE_LOG`. - The file log directory was set by `OPA_OPERATOR_LOG_DIRECTORY`, and is now set - by `ROLLING_LOGS_DIR` (or via `--rolling-logs `). + by `FILE_LOG_DIRECTORY` (or via `--file-log-directory `). - Replace stackable-operator `print_startup_string` with `tracing::info!` with fields. - BREAKING: Inject the vector aggregator address into the vector config using the env var `VECTOR_AGGREGATOR_ADDRESS` instead of having the operator write it to the vector config ([#707]). @@ -38,6 +38,7 @@ All notable changes to this project will be documented in this file. [#707]: https://github.com/stackabletech/opa-operator/pull/707 [#709]: https://github.com/stackabletech/opa-operator/pull/709 [#710]: https://github.com/stackabletech/opa-operator/pull/710 +[#715]: https://github.com/stackabletech/opa-operator/pull/715 ## [25.3.0] - 2025-03-21 From 4b1ba5dedb3ac50deaa966046cbbf5a07beb279a Mon Sep 17 00:00:00 2001 From: Techassi Date: Wed, 16 Apr 2025 15:41:04 +0200 Subject: [PATCH 4/7] chore: Adjust bundle builder file log level env var --- CHANGELOG.md | 12 ++++++------ rust/operator-binary/src/controller.rs | 12 ++++++------ 2 files changed, 12 insertions(+), 12 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index b197f426..3b57655c 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -12,18 +12,18 @@ All notable changes to this project will be documented in this file. - BREAKING: Replace stackable-operator `initialize_logging` with stackable-telemetry `Tracing` ([#703], [#710], [#715]). - operator-binary: - - The console log level was set by `OPA_OPERATOR_LOG`, and is now set by `CONSOLE_LOG`. - - The file log level was set by `OPA_OPERATOR_LOG`, and is now set by `FILE_LOG`. + - The console log level was set by `OPA_OPERATOR_LOG`, and is now set by `CONSOLE_LOG_LEVEL`. + - The file log level was set by `OPA_OPERATOR_LOG`, and is now set by `FILE_LOG_LEVEL`. - The file log directory was set by `OPA_OPERATOR_LOG_DIRECTORY`, and is now set by `FILE_LOG_DIRECTORY` (or via `--file-log-directory `). - bundle-builder: - - The console log level was set by `OPA_BUNDLE_BUILDER_LOG`, and is now set by `CONSOLE_LOG`. - - The file log level was set by `OPA_BUNDLE_BUILDER_LOG`, and is now set by `FILE_LOG`. + - The console log level was set by `OPA_BUNDLE_BUILDER_LOG`, and is now set by `CONSOLE_LOG_LEVEL`. + - The file log level was set by `OPA_BUNDLE_BUILDER_LOG`, and is now set by `FILE_LOG_LEVEL`. - The file log directory was set by `OPA_BUNDLE_BUILDER_LOG_DIRECTORY`, and is now set by `FILE_LOG_DIRECTORY` (or via `--file-log-directory `). - user-info-fetcher: - - The console log level was set by `OPA_OPERATOR_LOG`, and is now set by `CONSOLE_LOG`. - - The file log level was set by `OPA_OPERATOR_LOG`, and is now set by `FILE_LOG`. + - The console log level was set by `OPA_OPERATOR_LOG`, and is now set by `CONSOLE_LOG_LEVEL`. + - The file log level was set by `OPA_OPERATOR_LOG`, and is now set by `FILE_LOG_LEVEL`. - The file log directory was set by `OPA_OPERATOR_LOG_DIRECTORY`, and is now set by `FILE_LOG_DIRECTORY` (or via `--file-log-directory `). - Replace stackable-operator `print_startup_string` with `tracing::info!` with fields. diff --git a/rust/operator-binary/src/controller.rs b/rust/operator-binary/src/controller.rs index c26a5562..c3067e4a 100644 --- a/rust/operator-binary/src/controller.rs +++ b/rust/operator-binary/src/controller.rs @@ -798,7 +798,7 @@ fn build_server_rolegroup_daemonset( )]) .add_env_var_from_field_path("WATCH_NAMESPACE", FieldPathEnvVar::Namespace) .add_env_var( - "CONSOLE_LOG", + "FILE_LOG_LEVEL", bundle_builder_log_level(merged_config).to_string(), ) .add_env_var( @@ -1180,11 +1180,11 @@ fn build_opa_start_command(merged_config: &v1alpha1::OpaConfig, container_name: // See https://stackoverflow.com/a/8048493 let logging_redirects = format!( - "&> >(CONSOLE_LEVEL={console} FILE_LEVEL={file} DECISION_LEVEL={decision} SERVER_LEVEL={server} OPA_ROLLING_LOG_FILE_SIZE_BYTES={OPA_ROLLING_LOG_FILE_SIZE_BYTES} OPA_ROLLING_LOG_FILES={OPA_ROLLING_LOG_FILES} STACKABLE_LOG_DIR={STACKABLE_LOG_DIR} CONTAINER_NAME={container_name} process-logs)", - file = file_log_level, - console = console_log_level, - decision = decision_log_level, - server = server_log_level + "&> >(CONSOLE_LEVEL={console_level} FILE_LEVEL={file_level} DECISION_LEVEL={decision_level} SERVER_LEVEL={server_level} OPA_ROLLING_LOG_FILE_SIZE_BYTES={OPA_ROLLING_LOG_FILE_SIZE_BYTES} OPA_ROLLING_LOG_FILES={OPA_ROLLING_LOG_FILES} STACKABLE_LOG_DIR={STACKABLE_LOG_DIR} CONTAINER_NAME={container_name} process-logs)", + file_level = file_log_level, + console_level = console_log_level, + decision_level = decision_log_level, + server_level = server_log_level ); // TODO: Think about adding --shutdown-wait-period, as suggested by https://github.com/open-policy-agent/opa/issues/2764 From 9156c9c2c9da1c28c815883c127d1405df3b12d7 Mon Sep 17 00:00:00 2001 From: Techassi Date: Wed, 23 Apr 2025 10:31:10 +0200 Subject: [PATCH 5/7] chore: Add CONSOLE_LOG_LEVEL env var to bundle builder container --- rust/operator-binary/src/controller.rs | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/rust/operator-binary/src/controller.rs b/rust/operator-binary/src/controller.rs index c3067e4a..423cbb12 100644 --- a/rust/operator-binary/src/controller.rs +++ b/rust/operator-binary/src/controller.rs @@ -782,6 +782,8 @@ fn build_server_rolegroup_daemonset( .context(AddVolumeMountSnafu)? .resources(merged_config.resources.to_owned().into()); + let console_and_file_log_level = bundle_builder_log_level(merged_config); + cb_bundle_builder .image_from_product_image(resolved_product_image) // inherit the pull policy and pull secrets, and then... .image(opa_bundle_builder_image) // ...override the image @@ -797,10 +799,8 @@ fn build_server_rolegroup_daemonset( &bundle_builder_container_name, )]) .add_env_var_from_field_path("WATCH_NAMESPACE", FieldPathEnvVar::Namespace) - .add_env_var( - "FILE_LOG_LEVEL", - bundle_builder_log_level(merged_config).to_string(), - ) + .add_env_var("CONSOLE_LOG_LEVEL", console_and_file_log_level.to_string()) + .add_env_var("FILE_LOG_LEVEL", console_and_file_log_level.to_string()) .add_env_var( "FILE_LOG_DIRECTORY", format!("{STACKABLE_LOG_DIR}/{bundle_builder_container_name}"), From efd9496425634d32829d35078b50c8c073aad5f1 Mon Sep 17 00:00:00 2001 From: Techassi Date: Wed, 23 Apr 2025 10:35:22 +0200 Subject: [PATCH 6/7] chore: Adjust changelog --- CHANGELOG.md | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 3b57655c..67f3834f 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -6,6 +6,10 @@ All notable changes to this project will be documented in this file. ### Added +- Adds new telemetry CLI arguments and environment variables ([#715]). + - Use `--file-log-max-files` (or `FILE_LOG_MAX_FILES`) to limit the number of log files kept. + - Use `--file-log-rotation-period` (or `FILE_LOG_ROTATION_PERIOD`) to configure the frequency of rotation. + - Use `--console-log-format` (or `CONSOLE_LOG_FORMAT`) to set the format to `plain` (default) or `json`. - Log the startup event for bundle-builder and user-info-fetcher ([#703]). ### Changed From cdc28af8935bf09d761eb2ce26cd09b28bca4ead Mon Sep 17 00:00:00 2001 From: Techassi Date: Wed, 23 Apr 2025 10:48:14 +0200 Subject: [PATCH 7/7] chore: Apply suggestion Co-authored-by: Nick <10092581+NickLarsenNZ@users.noreply.github.com> --- rust/operator-binary/src/controller.rs | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/rust/operator-binary/src/controller.rs b/rust/operator-binary/src/controller.rs index 423cbb12..415cdc66 100644 --- a/rust/operator-binary/src/controller.rs +++ b/rust/operator-binary/src/controller.rs @@ -1180,11 +1180,7 @@ fn build_opa_start_command(merged_config: &v1alpha1::OpaConfig, container_name: // See https://stackoverflow.com/a/8048493 let logging_redirects = format!( - "&> >(CONSOLE_LEVEL={console_level} FILE_LEVEL={file_level} DECISION_LEVEL={decision_level} SERVER_LEVEL={server_level} OPA_ROLLING_LOG_FILE_SIZE_BYTES={OPA_ROLLING_LOG_FILE_SIZE_BYTES} OPA_ROLLING_LOG_FILES={OPA_ROLLING_LOG_FILES} STACKABLE_LOG_DIR={STACKABLE_LOG_DIR} CONTAINER_NAME={container_name} process-logs)", - file_level = file_log_level, - console_level = console_log_level, - decision_level = decision_log_level, - server_level = server_log_level + "&> >(CONSOLE_LEVEL={console_log_level} FILE_LEVEL={file_log_level} DECISION_LEVEL={decision_log_level} SERVER_LEVEL={server_log_level} OPA_ROLLING_LOG_FILE_SIZE_BYTES={OPA_ROLLING_LOG_FILE_SIZE_BYTES} OPA_ROLLING_LOG_FILES={OPA_ROLLING_LOG_FILES} STACKABLE_LOG_DIR={STACKABLE_LOG_DIR} CONTAINER_NAME={container_name} process-logs)" ); // TODO: Think about adding --shutdown-wait-period, as suggested by https://github.com/open-policy-agent/opa/issues/2764