sous-chefs / consul

Development repository for the consul cookbook
https://supermarket.chef.io/cookbooks/consul
Apache License 2.0
192 stars 244 forks source link

Use config user/group for consul_definition instead of hard coded string #362

Closed rollbrettler closed 7 years ago

rollbrettler commented 8 years ago

Does anything speak against using the node['consul']['config']['group'] and node['consul']['config']['user'] value for the default consul_definition attributes?

johnbellone commented 7 years ago

Did you try setting node['consul']['service_user'] and node['consul']['service_group']? I don't really see why you would need to do this with those node attributes.

codecov-io commented 7 years ago

Current coverage is 57.77% (diff: 100%)

No coverage report found for master at 2a49cac.

Powered by Codecov. Last update 2a49cac...56e77ed

rollbrettler commented 7 years ago

I changed it to node['consul']['service_user'] and node['consul']['service_group'] but maybe I didn’t fully get your suggestion yet.

rollbrettler commented 7 years ago

@johnbellone https://github.com/johnbellone/consul-cookbook/issues/372 is basically what I ran into as well and what I tried to fix with this PR

mishak87 commented 7 years ago

Watch and service resources are still using hardcoded strings 'consul'.

https://github.com/johnbellone/consul-cookbook/blob/cd562a7/libraries/consul_watch.rb#L22-L28 https://github.com/johnbellone/consul-cookbook/blob/cd562a7/libraries/consul_service.rb#L24-L31

legal90 commented 7 years ago

@mishak87 Thanks! Now it should be fixed by #445