Found that excerpt in another cookbook. Have not tested yet.

--
Rafael Fonseca
Sent from mobile

On 19/02/2013, at 11:01 PM, Bryan Berry <notifications@github.com> wrote:

In recipes/beaver.rb:

> @@ -163,21 +163,58 @@
>    notifies :restart, "service[logstash_beaver]"
>  end
>
> -template "/etc/init.d/logstash_beaver" do
> -  mode "0754"
> -  source "init-beaver.erb"
> -  variables(
> -            :cmd => cmd,
> -            :pid_file => pid_file,
> -            :user => node['logstash']['user'],
> -            :log => log_file,
> -            :platform => node['platform']
> -            )
> -  notifies :restart, "service[logstash_beaver]"
> +use_upstart = false
> +supports_setuid = false
> +case platform_family

I don't believe you can use platform_family this way. Here is how I would
do it

case when platform_family?("rhel")
    # code herewhen platform_family?("ubuntu") and
node['platform_version'].to_f >= 10.04
   # more codeend

 —
Reply to this email directly or view it on
GitHub<https://github.com/lusis/chef-logstash/pull/76/files#r3059284>.