From 4b819df748afab8bc5f94e1e1366fd0a3e61191d Mon Sep 17 00:00:00 2001 From: Aravindh Puthiyaparambil Date: Thu, 11 May 2023 14:40:24 -0700 Subject: [PATCH] SNO: Add enableSystemLogQuery to kubelet conf This is needed to allow "oc adm node-logs" to work on OCP 4.14+ clusters where the node log query feature is present upstream and needs to be explicitly enabled. --- .../single-node/conf/e2e/single-node-conf-e2e-commands.sh | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/ci-operator/step-registry/single-node/conf/e2e/single-node-conf-e2e-commands.sh b/ci-operator/step-registry/single-node/conf/e2e/single-node-conf-e2e-commands.sh index 0acb68c44858c..3458dd204991c 100644 --- a/ci-operator/step-registry/single-node/conf/e2e/single-node-conf-e2e-commands.sh +++ b/ci-operator/step-registry/single-node/conf/e2e/single-node-conf-e2e-commands.sh @@ -20,6 +20,12 @@ spec: memory: 3Gi EOF +# enableSystemLogQuery needs to be enabled for oc adm node-logs to work if OCP version >= 4.14 (or if OCP_VERSION is not set) +REQUIRED_OCP_VERSION="4.14" +if [ "$(printf '%s\n' "${REQUIRED_OCP_VERSION}" "${OCP_VERSION}" | sort --version-sort | head -n1)" = "${REQUIRED_OCP_VERSION}" ]; then + echo " enableSystemLogQuery: true" >> "${SHARED_DIR}/manifest_single-node-kubeletconfig.yml" +fi + # Use first eight cores on a single node for workload partitioning (see https://github.com/openshift/enhancements/blob/master/enhancements/workload-partitioning/management-workload-partitioning.md#goals) # ... but avoid applying workload partitioning if OCP version < 4.10 (or if OCP_VERSION is not set) REQUIRED_OCP_VERSION="4.10"