diff --git a/roles/rke2/templates/manifests/deploy-rancher-logging.j2 b/roles/rke2/templates/manifests/deploy-rancher-logging.j2 index 3934d31df3d27c721fe084d6ac563b14e50a5f44..45b1d6420d00c8c5a32d08958bf9374707c618ce 100644 --- a/roles/rke2/templates/manifests/deploy-rancher-logging.j2 +++ b/roles/rke2/templates/manifests/deploy-rancher-logging.j2 @@ -3,7 +3,7 @@ kind: Namespace apiVersion: v1 metadata: - name: cattle-logging-system + name: kube-system --- @@ -16,7 +16,7 @@ spec: repo: {{ item.value.repo | default("https://charts.rancher.io") }} chart: rancher-logging-crd version: {{ item.value.version | default("3.15.0") }} - targetNamespace: cattle-logging-system + targetNamespace: kube-system --- @@ -30,7 +30,7 @@ spec: repo: {{ item.value.repo | default("https://charts.rancher.io") }} chart: rancher-logging version: {{ item.value.version | default("3.15.0") }} - targetNamespace: cattle-logging-system + targetNamespace: kube-system valuesContent: |- createCustomResource: true global: @@ -39,16 +39,9 @@ spec: additionalLoggingSources: rke2: enabled: true - podSecurityContext: - runAsNonRoot: true - runAsUser: 1000 - fsGroup: 2000 - securityContext: - allowPrivilegeEscalation: false - capabilities: - drop: ["ALL"] debug: true +# Moving it into kube-system as a last resort cause there it can run unrestricted, this might not work due to network, lets try # Need for fluentd statefulset the Security Context RunasUser # when running it runAsUser it needs perms /usr/lib/ruby/2.7.0/logger/log_device.rb:103:in `initialize': Permission denied @ rb_sysopen - /fluentd/log/out (Errno::EACCES) --- @@ -62,7 +55,7 @@ spec: repo: {{ item.value.repo | default("https://grafana.github.io/helm-charts") }} chart: loki version: {{ item.value.lokiversion | default("2.11.1") }} - targetNamespace: cattle-logging-system + targetNamespace: kube-system