dev
diff --git a/rsyslog/files/rsyslog.conf.Debian b/rsyslog/files/rsyslog.conf.Debian
index 83b1fb8..54a66a3 100644
--- a/rsyslog/files/rsyslog.conf.Debian
+++ b/rsyslog/files/rsyslog.conf.Debian
@@ -35,8 +35,10 @@
 # To enable high precision timestamps, comment out the following line.
 #
 {% if client.format is defined %}
-$ActionFileDefaultTemplate {{ client.format.name }},{{ client.format.template }}
+$template {{ client.format.name }},{{ client.format.template }}
+$ActionFileDefaultTemplate {{ client.format.name }}
 {% else %}
+$template RSYSLOG_TraditionalFileFormat
 $ActionFileDefaultTemplate RSYSLOG_TraditionalFileFormat
 {% endif %}
 
@@ -55,9 +57,11 @@
 {% if client.file.createmode is defined %}
 $FileCreateMode {{ client.file.createmode }}
 {% endif %}
+{% if client.file.umask is defined %}
+$Umask {{ client.file.umask }}
+{% endif %}
 
 $DirCreateMode 0755
-$Umask 0022
 $PrivDropToUser syslog
 $PrivDropToGroup syslog
 
diff --git a/rsyslog/files/rsyslog.conf.RedHat b/rsyslog/files/rsyslog.conf.RedHat
index c42874e..389bd5a 100644
--- a/rsyslog/files/rsyslog.conf.RedHat
+++ b/rsyslog/files/rsyslog.conf.RedHat
@@ -29,8 +29,11 @@
 # Use default timestamp format
 # $ActionFileDefaultTemplate RSYSLOG_TraditionalFileFormat
 {% if client.format is defined %}
-$ActionFileDefaultTemplate {{ client.format.name }},{{ client.format.template }}
+$template {{ client.format.name }},{{ client.format.template }}
+$ActionFileDefaultTemplate {{ client.format.name }}
+
 {% else %}
+$template RSYSLOG_TraditionalFileFormat
 $ActionFileDefaultTemplate RSYSLOG_TraditionalFileFormat
 {% endif %}
 
@@ -48,6 +51,18 @@
 # File to store the position in the journal
 $IMJournalStateFile imjournal.state
 
+{% if client.file.umask is defined %}
+$Umask {{ client.file.umask }}
+{% endif %}
+{% if client.file.owner is defined %}
+$FileOwner {{ client.file.owner }}
+{% endif %}
+{% if client.file.group is defined %}
+$FileGroup {{ client.file.group }}
+{% endif %}
+{% if client.file.createmode is defined %}
+$FileCreateMode {{ client.file.createmode }}
+{% endif %}
 
 #### RULES ####
 
@@ -96,13 +111,3 @@
 #*.* @@remote-host:514
 # ### end of the forwarding rule ###
 #
-{% if client.file.owner is defined %}
-$FileOwner {{ client.file.owner }}
-{% endif %}
-{% if client.file.group is defined %}
-$FileGroup {{ client.file.group }}
-{% endif %}
-{% if client.file.createmode is defined %}
-$FileCreateMode {{ client.file.createmode }}
-{% endif %}
-