Commit 9c68ef0c authored by Jennifer Davis's avatar Jennifer Davis
Browse files

fixing rubocop errors

parent 69143d3d
......@@ -132,5 +132,3 @@ end
if (node['platform'] == 'ubuntu' && node['platform_version'].to_i < 12) || (node['platform_family'] == 'rhel' && node['platform_version'].to_i < 6)
default['rsyslog']['default_facility_logs']['*.emerg'] = '*'
end
......@@ -51,20 +51,20 @@ if rsyslog_servers.empty?
Chef::Log.warn('The rsyslog::client recipe was unable to determine the remote syslog server. Checked both the server_ip attribute and search! Not forwarding logs.')
else
remote_type = node['rsyslog']['use_relp'] ? 'relp' : 'remote'
template "#{node['rsyslog']['config_prefix']}/rsyslog.d/49-remote.conf" do
source "49-#{remote_type}.conf.erb"
owner 'root'
group 'root'
mode '0644'
variables(servers: rsyslog_servers)
notifies :run, 'execute[validate_config]'
notifies :restart, "service[#{node['rsyslog']['service_name']}]"
only_if { node['rsyslog']['remote_logs'] }
end
template "#{node['rsyslog']['config_prefix']}/rsyslog.d/49-remote.conf" do
source "49-#{remote_type}.conf.erb"
owner 'root'
group 'root'
mode '0644'
variables(:servers => rsyslog_servers)
notifies :run, 'execute[validate_config]'
notifies :restart, "service[#{node['rsyslog']['service_name']}]"
only_if { node['rsyslog']['remote_logs'] }
end
file "#{node['rsyslog']['config_prefix']}/rsyslog.d/server.conf" do
action :delete
notifies :run, 'execute[validate_config]'
notifies :restart, "service[#{node['rsyslog']['service_name']}]"
file "#{node['rsyslog']['config_prefix']}/rsyslog.d/server.conf" do
action :delete
notifies :run, 'execute[validate_config]'
notifies :restart, "service[#{node['rsyslog']['service_name']}]"
end
end
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment