Closed kamaradclimber closed 9 years ago
@kamaradclimber do you store node data in your Chef repo?
yes we do and we do want to compare node definition (run list + normal attributes) with what is stored in chef server
@kamaradclimber I've just tried your branch (after exporting my nodes to nodes/#{node_name}.json
files and I'm getting the following output:
$ ./bin/knife node inspect chef_server
- chef_server
has the following values mismatched on the server and repo
chef_type :
server value = node
local value =
I've used knife node show chef_server -Fjson > nodes/chef_server.json
to export the node file, are you using another tool?
Why would a node being tracked on the Chef Server differ than what is in your source code? If you need to use inspect to know what is going on do you see this as a problem? You should only use the source code as the actual source of truth and have a one way copy up to the Chef server or you will have some serious scaling and collaboration problems.
@stephenlauck, inspecting nodes differences between git and chef-server is a powerful way to build a tool to push nodes from git to the chef-server. Our deployemnt bot is currently based on chef_fs libraries which are far too slow, knife-inspect is imho a better starting block to improve it. It also happen to have temporary change in sandbox environment (talking about a dedicated chef-server) in either nodes, roles, cookbooks… that you want to undo after a short test.
You seem judgemental here, don't be. Other may have different workflows.
@gregkare I have to look into that
By the way, checking for nodes should be optional, so we need to introduce either a command line switch or a configuration file
@gregkare all check types should be deactivable nodes are same level citizens as cookbooks, data bags, env and roles
I'll make an independant PR for that
Closing this PR, feel free to open it again if you want to keep on the exchange.
fixes #20