default.rb 1.97 KB
Newer Older
jtimberman's avatar
jtimberman committed
1
2
#
# Cookbook Name:: rsyslog
3
# Attributes:: default
jtimberman's avatar
jtimberman committed
4
5
6
7
8
9
#
# Copyright 2009, Opscode, Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
10
#
jtimberman's avatar
jtimberman committed
11
#     http://www.apache.org/licenses/LICENSE-2.0
12
#
jtimberman's avatar
jtimberman committed
13
14
15
16
17
18
19
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
#

20
21
22
23
24
25
26
27
28
29
30
default["rsyslog"]["log_dir"]                   = "/srv/rsyslog"
default["rsyslog"]["server"]                    = false
default["rsyslog"]["protocol"]                  = "tcp"
default["rsyslog"]["port"]                      = 514
default["rsyslog"]["server_ip"]                 = nil
default["rsyslog"]["server_search"]             = "role:loghost"
default["rsyslog"]["remote_logs"]               = true
default["rsyslog"]["per_host_dir"]              = "%$YEAR%/%$MONTH%/%$DAY%/%HOSTNAME%"
default["rsyslog"]["max_message_size"]          = "2k"
default["rsyslog"]["preserve_fqdn"]             = "off"
default["rsyslog"]["high_precision_timestamps"] = false
groknix's avatar
groknix committed
31
default["rsyslog"]["repeated_msg_reduction"]    = "on"
32
default["rsyslog"]["logs_to_forward"]           = "*.*"
Jeff Blaine's avatar
Jeff Blaine committed
33
34

# The most likely platform-specific attributes
35
36
37
38
default["rsyslog"]["service_name"]              = "rsyslog"
default["rsyslog"]["user"]                      = "root"
default["rsyslog"]["group"]                     = "adm"
default["rsyslog"]["priv_seperation"]           = false
39

40
41
42
case node["platform"]
when "ubuntu"
  # syslog user introduced with natty package
Jeff Blaine's avatar
Jeff Blaine committed
43
  if node['platform_version'].to_f < 10.10 then
44
45
46
47
    default["rsyslog"]["user"] = "syslog"
    default["rsyslog"]["group"] = "adm"
    default["rsyslog"]["priv_seperation"] = true
  end
48
49
when "arch"
  default["rsyslog"]["service_name"] = "rsyslogd"
50
end