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/*