Commit 5e4d28f9 authored by jtimberman's avatar jtimberman
Browse files

COOK-340, fix version check - .to_f

parent 8caaf33b
{
"providing": {
},
"attributes": {
"rsyslog": {
"required": "optional",
"calculated": false,
"choice": [
],
"type": "hash",
"recipes": [
],
"description": "Hash of Rsyslog attributes",
"display_name": "Rsyslog"
},
"rsyslog/protocol": {
"required": "optional",
"calculated": false,
"choice": [
"name": "rsyslog",
"description": "Installs and configures rsyslog",
"long_description": "= DESCRIPTION:\n\nInstalls rsyslog to replace sysklogd for client and/or server use. By default, server will be set up to log to files.\n\n= REQUIREMENTS:\n\n== Platform:\n\nTested on Ubuntu 8.10.\n\n== Cookbooks:\n\n* 'cron'.\n\n= ATTRIBUTES: \n\n* rsyslog[:log_dir] - specify the directory to store logs (applicable to server only)\n* rsyslog[:server] - specify the remote rsyslog server.\n* rsyslog[:protocol] - specify whether to use udp or tcp for remote log transmission. tcp is default.\n\n= USAGE:\n\nTo replace the sysklogd syslog service with rsyslog:\n\n include_recipe \"rsyslog\"\n \nTo set up a client with a remote [r]syslog server:\n\n include_recipe \"rsyslog::client\"\n \nBy default, this cookbook will use TCP so the server should be configured for TCP. This can be done easily with the server recipe:\n\n include_recipe \"rsyslog::server\"\n\nTo switch to UDP, change the rsyslog[:protocol] attribute. Note this needs to be done on each client as well.\n\nAlso, the server configuration will set up log_dir for each client, by date. Structure:\n\n <%= @log_dir %>/YEAR/MONTH/DAY/HOSTNAME/\"logfile\"\n\n= LICENSE and AUTHOR:\n \nAuthor:: Joshua Timberman (<joshua@opscode.com>)\n\nCopyright:: 2009, Opscode, Inc\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n",
"maintainer": "Opscode, Inc.",
"maintainer_email": "cookbooks@opscode.com",
"license": "Apache 2.0",
"platforms": {
"ubuntu": [
">= 8.10"
],
"debian": [
">= 5.0"
]
},
"dependencies": {
"cron": [
],
"default": "tcp",
"type": "string",
"recipes": [
]
},
"recommendations": {
},
"suggestions": {
},
"conflicting": {
},
"providing": {
},
"replacing": {
},
"attributes": {
"rsyslog": {
"display_name": "Rsyslog",
"description": "Hash of Rsyslog attributes",
"type": "hash",
"choice": [
],
"description": "Set which network protocol to use for rsyslog",
"display_name": "Rsyslog Protocol"
},
"rsyslog/log_dir": {
"required": "optional",
"calculated": false,
"choice": [
],
"default": "/srv/rsyslog",
"type": "string",
"recipes": [
],
"calculated": false,
"required": "optional",
"recipes": [
],
"description": "Filesystem location of logs from clients",
"display_name": "Rsyslog Log Directory"
},
"rsyslog/server": {
"required": "optional",
"calculated": false,
"choice": [
]
},
"rsyslog/log_dir": {
"display_name": "Rsyslog Log Directory",
"description": "Filesystem location of logs from clients",
"default": "/srv/rsyslog",
"choice": [
],
"default": "false",
"type": "string",
"recipes": [
],
"calculated": false,
"type": "string",
"required": "optional",
"recipes": [
],
"description": "Is this node an rsyslog server?",
"display_name": "Rsyslog Server?"
}
},
"maintainer": "Opscode, Inc.",
"replacing": {
]
},
"dependencies": {
"cron": [
"rsyslog/server": {
"display_name": "Rsyslog Server?",
"description": "Is this node an rsyslog server?",
"default": "false",
"choice": [
],
"calculated": false,
"type": "string",
"required": "optional",
"recipes": [
]
},
"recipes": {
"rsyslog": "Installs rsyslog",
"rsyslog::server": "Sets up an rsyslog server",
"rsyslog::client": "Sets up a client to log to a remote rsyslog server"
},
"maintainer_email": "cookbooks@opscode.com",
"groupings": {
},
"recommendations": {
},
"platforms": {
"debian": [
">= 5.0"
"rsyslog/protocol": {
"display_name": "Rsyslog Protocol",
"description": "Set which network protocol to use for rsyslog",
"default": "tcp",
"choice": [
],
"ubuntu": [
">= 8.10"
"calculated": false,
"type": "string",
"required": "optional",
"recipes": [
]
},
"license": "Apache 2.0",
"version": "0.9.3",
"suggestions": {
},
"name": "rsyslog",
"conflicting": {
},
"long_description": "= DESCRIPTION:\n\nInstalls rsyslog to replace sysklogd for client and/or server use. By default, server will be set up to log to files.\n\n= REQUIREMENTS:\n\n== Platform:\n\nTested on Ubuntu 8.10.\n\n== Cookbooks:\n\n* 'cron'.\n\n= ATTRIBUTES: \n\n* rsyslog[:log_dir] - specify the directory to store logs (applicable to server only)\n* rsyslog[:server] - specify the remote rsyslog server.\n* rsyslog[:protocol] - specify whether to use udp or tcp for remote log transmission. tcp is default.\n\n= USAGE:\n\nTo replace the sysklogd syslog service with rsyslog:\n\n include_recipe \"rsyslog\"\n \nTo set up a client with a remote [r]syslog server:\n\n include_recipe \"rsyslog::client\"\n \nBy default, this cookbook will use TCP so the server should be configured for TCP. This can be done easily with the server recipe:\n\n include_recipe \"rsyslog::server\"\n\nTo switch to UDP, change the rsyslog[:protocol] attribute. Note this needs to be done on each client as well.\n\nAlso, the server configuration will set up log_dir for each client, by date. Structure:\n\n <%= @log_dir %>/YEAR/MONTH/DAY/HOSTNAME/\"logfile\"\n\n= LICENSE and AUTHOR:\n \nAuthor:: Joshua Timberman (<joshua@opscode.com>)\n\nCopyright:: 2009, Opscode, Inc\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n",
"description": "Installs and configures rsyslog"
}
\ No newline at end of file
}
},
"groupings": {
},
"recipes": {
"rsyslog": "Installs rsyslog",
"rsyslog::client": "Sets up a client to log to a remote rsyslog server",
"rsyslog::server": "Sets up an rsyslog server"
},
"version": "0.9.4"
}
\ No newline at end of file
......@@ -3,7 +3,7 @@ maintainer_email "cookbooks@opscode.com"
license "Apache 2.0"
description "Installs and configures rsyslog"
long_description IO.read(File.join(File.dirname(__FILE__), 'README.rdoc'))
version "0.9.3"
version "0.9.4"
recipe "rsyslog", "Installs rsyslog"
recipe "rsyslog::client", "Sets up a client to log to a remote rsyslog server"
......
......@@ -49,7 +49,7 @@ end
case node[:platform]
when "ubuntu"
if node[:platform_version] >= "9.10"
if node[:platform_version].to_f >= 9.10
template "/etc/rsyslog.d/50-default.conf" do
source "50-default.conf.erb"
backup false
......
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