Keepalived cookbook throwing an error

Hi,

I am trying to use keepalived cookbook to install on centos 7 machine, I have included the dependency in metadata.rb file. When I ran the chef-client it resulted in undefined local variable or method. I am using the latest chef client (15.4.45)

Undefined local variable or method `keepalived' for cookbook: nrhl_haproxy, recipe: keepalived :Chef::Recipe

keepalived.rb:
1>> keepalived::install

I can't really tell from your error output, but can you confirm you are doing include_recipe 'keepalived::install' and not just keepalived::install on that line?

https://docs.chef.io/dsl_recipe.html#include-recipes

1 Like

Also please use resources and not the recipes, they will disappear in the next version of the cookbook

See: https://github.com/sous-chefs/keepalived/issues/84

2 Likes

I haven't used the highlighted line, let me update the recipe.

Thanks for your time