health_inspector 0.0.2 → 0.0.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/HISTORY.md +4 -0
- data/README.md +11 -1
- data/health_inspector.gemspec +1 -0
- data/lib/health_inspector/context.rb +10 -2
- data/lib/health_inspector/version.rb +1 -1
- metadata +14 -3
data/HISTORY.md
CHANGED
data/README.md
CHANGED
@@ -7,4 +7,14 @@ A tool to inspect your chef repo as is compares to what is on your chef server
|
|
7
7
|
$ gem install health_inspector
|
8
8
|
$ cd [chef repo] && health_inspector inspect
|
9
9
|
|
10
|
-
Run `health_inspector help` for more options
|
10
|
+
Run `health_inspector help` for more options
|
11
|
+
|
12
|
+
## What is checks
|
13
|
+
|
14
|
+
So far it checks if...
|
15
|
+
|
16
|
+
* your chef server has cookbooks you don't have locally
|
17
|
+
* your chef server is missing cookbooks you have locally
|
18
|
+
* cookbook versions are not the same between server and local chef repo
|
19
|
+
* you have uncommitted changes in a cookbook (assuming your cookbook is a git repo)
|
20
|
+
* you have commits in a cookbook that haven't been pushed to your remote (assuming your cookbook is a git repo)
|
data/health_inspector.gemspec
CHANGED
@@ -1,12 +1,20 @@
|
|
1
|
+
require "chef/config"
|
2
|
+
|
1
3
|
module HealthInspector
|
2
4
|
class Context < Struct.new(:repo_path, :config_path)
|
3
5
|
def knife_command(subcommnad)
|
4
6
|
`cd #{repo_path} && knife #{subcommnad} -c #{config_path}`
|
5
7
|
end
|
6
8
|
|
7
|
-
# TODO: read from knife config
|
8
9
|
def cookbook_path
|
9
|
-
|
10
|
+
Array( config.cookbook_path )
|
11
|
+
end
|
12
|
+
|
13
|
+
def config
|
14
|
+
@config ||= begin
|
15
|
+
Chef::Config.from_file(config_path)
|
16
|
+
Chef::Config
|
17
|
+
end
|
10
18
|
end
|
11
19
|
end
|
12
20
|
end
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: health_inspector
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.3
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -13,7 +13,7 @@ date: 2012-03-27 00:00:00.000000000Z
|
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: thor
|
16
|
-
requirement: &
|
16
|
+
requirement: &2164944480 !ruby/object:Gem::Requirement
|
17
17
|
none: false
|
18
18
|
requirements:
|
19
19
|
- - ! '>='
|
@@ -21,7 +21,18 @@ dependencies:
|
|
21
21
|
version: '0'
|
22
22
|
type: :runtime
|
23
23
|
prerelease: false
|
24
|
-
version_requirements: *
|
24
|
+
version_requirements: *2164944480
|
25
|
+
- !ruby/object:Gem::Dependency
|
26
|
+
name: chef
|
27
|
+
requirement: &2164944060 !ruby/object:Gem::Requirement
|
28
|
+
none: false
|
29
|
+
requirements:
|
30
|
+
- - ! '>='
|
31
|
+
- !ruby/object:Gem::Version
|
32
|
+
version: '0'
|
33
|
+
type: :runtime
|
34
|
+
prerelease: false
|
35
|
+
version_requirements: *2164944060
|
25
36
|
description: A tool to inspect your chef repo as is compares to what is on your chef
|
26
37
|
server
|
27
38
|
email:
|