Fix rsyslog file and directory permissions
This commit is contained in:
parent
134fd61d6b
commit
f292c531db
@ -24,4 +24,12 @@ template(
|
|||||||
type="omfile"
|
type="omfile"
|
||||||
dynafile="FilePerDay"
|
dynafile="FilePerDay"
|
||||||
template="RSYSLOG_FileFormat"
|
template="RSYSLOG_FileFormat"
|
||||||
|
fileCreateMode="{{ rsyslog_file_create_mode }}"
|
||||||
|
dirCreateMode="{{ rsyslog_dir_create_mode }}"
|
||||||
|
createDirs="{{ rsyslog_create_dirs | ternary('on', 'off') }}"
|
||||||
|
fileOwner="{{ rsyslog_file_owner }}"
|
||||||
|
fileGroup="{{ rsyslog_file_group }}"
|
||||||
|
dirOwner="{{ rsyslog_file_owner }}"
|
||||||
|
dirGroup="{{ rsyslog_file_group }}"
|
||||||
|
umask="{{ rsyslog_umask }}"
|
||||||
)
|
)
|
||||||
|
@ -27,9 +27,18 @@ $FileOwner {{ rsyslog_file_owner }}
|
|||||||
{% if rsyslog_file_group is defined %}
|
{% if rsyslog_file_group is defined %}
|
||||||
$FileGroup {{ rsyslog_file_group }}
|
$FileGroup {{ rsyslog_file_group }}
|
||||||
{% endif %}
|
{% endif %}
|
||||||
|
{% if rsyslog_dir_owner is defined %}
|
||||||
|
$FileOwner {{ rsyslog_dir_owner }}
|
||||||
|
{% endif %}
|
||||||
|
{% if rsyslog_dir_group is defined %}
|
||||||
|
$FileGroup {{ rsyslog_dir_group }}
|
||||||
|
{% endif %}
|
||||||
{% if rsyslog_file_create_mode is defined %}
|
{% if rsyslog_file_create_mode is defined %}
|
||||||
$FileCreateMode {{ rsyslog_file_create_mode }}
|
$FileCreateMode {{ rsyslog_file_create_mode }}
|
||||||
{% endif %}
|
{% endif %}
|
||||||
|
{% if rsyslog_create_dirs is defined %}
|
||||||
|
CreateDirs {{ rsyslog_create_dirs | ternary('on', 'off') }}
|
||||||
|
{% endif %}
|
||||||
{% if rsyslog_dir_create_mode is defined %}
|
{% if rsyslog_dir_create_mode is defined %}
|
||||||
$DirCreateMode {{ rsyslog_dir_create_mode }}
|
$DirCreateMode {{ rsyslog_dir_create_mode }}
|
||||||
{% endif %}
|
{% endif %}
|
||||||
|
@ -1,8 +1,11 @@
|
|||||||
---
|
---
|
||||||
rsyslog_file_owner: syslog
|
rsyslog_file_owner: syslog
|
||||||
rsyslog_file_group: adm
|
rsyslog_file_group: adm
|
||||||
rsyslog_file_create_mode: "0644"
|
rsyslog_dir_owner: syslog
|
||||||
|
rsyslog_dir_group: adm
|
||||||
|
rsyslog_file_create_mode: "0640"
|
||||||
rsyslog_dir_create_mode: "0755"
|
rsyslog_dir_create_mode: "0755"
|
||||||
|
rsyslog_create_dirs: yes
|
||||||
rsyslog_umask: "0022"
|
rsyslog_umask: "0022"
|
||||||
rsyslog_priv_drop_to_user: syslog
|
rsyslog_priv_drop_to_user: syslog
|
||||||
rsyslog_priv_drop_to_group: syslog
|
rsyslog_priv_drop_to_group: syslog
|
||||||
|
Loading…
Reference in New Issue
Block a user