From ea0182b274d503a010108f44b004b5b7d049968a Mon Sep 17 00:00:00 2001 From: Gardener Prow Robot Date: Thu, 30 May 2024 16:44:57 +0200 Subject: [PATCH] Increase permissions of `/etc/ssl/rsyslog` dir (#112) Co-authored-by: Plamen Kokanov --- .../resources/templates/scripts/configure-rsyslog.tpl.sh | 2 +- pkg/webhook/operatingsystemconfig/testdata/configure-rsyslog.sh | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/pkg/webhook/operatingsystemconfig/resources/templates/scripts/configure-rsyslog.tpl.sh b/pkg/webhook/operatingsystemconfig/resources/templates/scripts/configure-rsyslog.tpl.sh index 286c075d..ebf65f5d 100644 --- a/pkg/webhook/operatingsystemconfig/resources/templates/scripts/configure-rsyslog.tpl.sh +++ b/pkg/webhook/operatingsystemconfig/resources/templates/scripts/configure-rsyslog.tpl.sh @@ -42,7 +42,7 @@ function configure_rsyslog() { if [[ -d {{ .pathRsyslogTLSFromOSCDir }} ]] && [[ -n "$(ls -A "{{ .pathRsyslogTLSFromOSCDir }}" )" ]]; then if [[ ! -d {{ .pathRsyslogTLSDir }} ]]; then - mkdir -m 0600 {{ .pathRsyslogTLSDir }} + mkdir -p {{ .pathRsyslogTLSDir }} fi if ! diff -rq {{ .pathRsyslogTLSFromOSCDir }} {{ .pathRsyslogTLSDir }} ; then rm -rf {{ .pathRsyslogTLSDir }}/* diff --git a/pkg/webhook/operatingsystemconfig/testdata/configure-rsyslog.sh b/pkg/webhook/operatingsystemconfig/testdata/configure-rsyslog.sh index 2135dab6..031cb06c 100644 --- a/pkg/webhook/operatingsystemconfig/testdata/configure-rsyslog.sh +++ b/pkg/webhook/operatingsystemconfig/testdata/configure-rsyslog.sh @@ -42,7 +42,7 @@ function configure_rsyslog() { if [[ -d /var/lib/rsyslog-relp-configurator/tls ]] && [[ -n "$(ls -A "/var/lib/rsyslog-relp-configurator/tls" )" ]]; then if [[ ! -d /etc/ssl/rsyslog ]]; then - mkdir -m 0600 /etc/ssl/rsyslog + mkdir -p /etc/ssl/rsyslog fi if ! diff -rq /var/lib/rsyslog-relp-configurator/tls /etc/ssl/rsyslog ; then rm -rf /etc/ssl/rsyslog/*