knife-spork 0.1.11 → 1.0.0

Sign up to get free protection for your applications and to get access to all the features.
@@ -0,0 +1,43 @@
1
+ Campfire
2
+ ========
3
+ Automatically posts informational messages to Campfire
4
+
5
+ Gem Requirements
6
+ ----------------
7
+ This plugin requires the following gems:
8
+
9
+ ```ruby
10
+ gem 'tinder'
11
+ ```
12
+
13
+ Hooks
14
+ -----
15
+ - `after_promote`
16
+ - `after_upload`
17
+
18
+ Configuration
19
+ -------------
20
+ ```yaml
21
+ plugins:
22
+ campfire:
23
+ account: my_company
24
+ token: ABC123
25
+ rooms:
26
+ - General
27
+ - Web Operations
28
+ ```
29
+
30
+ #### account
31
+ This is your campfire account name. It is the subdomain part of your account.
32
+
33
+ - Type: `String`
34
+
35
+ #### token
36
+ This is the secure token you get from the Campfire configuration.
37
+
38
+ - Type: `String`
39
+
40
+ #### Rooms
41
+ This is an array of room names to post messages to.
42
+
43
+ - Type: `String`
@@ -0,0 +1,30 @@
1
+ Eventinator
2
+ ===========
3
+
4
+ Gem Requirements
5
+ ----------------
6
+ This plugin has no gem requirements.
7
+
8
+ Hooks
9
+ -----
10
+ - `after_upload`
11
+
12
+ Configuration
13
+ -------------
14
+ ```yaml
15
+ plugins:
16
+ eventinator:
17
+ url: www.example.com
18
+ read_timeout: 5
19
+ ```
20
+
21
+ #### url
22
+ The server to post to.
23
+
24
+ - Type: `String`
25
+
26
+ #### read_timeout
27
+ The timeout, in seconds, for the request to return.
28
+
29
+ - Type: `Integer`
30
+ - Default: `5`
@@ -0,0 +1,53 @@
1
+ Foodcritic
2
+ ==========
3
+ Automatically runs foodcritic against your cookbooks on check and upload.
4
+
5
+ Gem Requirements
6
+ ----------------
7
+ This plugin requires the following gems:
8
+
9
+ ```ruby
10
+ gem 'foodcritic'
11
+ ```
12
+
13
+ Hooks
14
+ -----
15
+ - `after_check`
16
+ - `before_upload`
17
+
18
+ Configuration
19
+ -------------
20
+ ```yaml
21
+ plugins:
22
+ foodcritic:
23
+ tags:
24
+ - FC0023
25
+ fail_tags:
26
+ - any
27
+ include_rules:
28
+ - foodcritic/etsy
29
+ epic_fail: true
30
+ ```
31
+
32
+ #### tags
33
+ The tags to check against.
34
+
35
+ - Type: `Array`
36
+ - Default: '[any]'
37
+
38
+ #### fail_tags
39
+ The list of tags to fail on.
40
+
41
+ - Type: 'Array'
42
+ - Default: '[any]'
43
+
44
+ #### include_rules
45
+ An optional list of additional rules to run.
46
+
47
+ - Type: `Array`
48
+
49
+ #### epic_fail:
50
+ If set to true, `epic_fail` will prevent you from uploading a cookbook until all foodcritic rules pass.
51
+
52
+ - Type: `Boolean`
53
+ - Default: `true`
data/plugins/Git.md ADDED
@@ -0,0 +1,46 @@
1
+ Git
2
+ ===
3
+ This plugin attempts to help manage your workflow by automatically pulling changes from your repo. **Do not use this plugin if you are not using Git.**
4
+
5
+ Gem Requirements
6
+ ----------------
7
+ This plugin requires the following gems:
8
+
9
+ ```ruby
10
+ gem 'git'
11
+ ```
12
+
13
+ Hooks
14
+ -----
15
+ - `before_bump`
16
+ - `after_bump`
17
+ - `after_promote`
18
+
19
+ Configuration
20
+ -------------
21
+ ```yaml
22
+ plugins:
23
+ git:
24
+ remote: origin
25
+ branch: master
26
+ ```
27
+
28
+ **Note** Due to the nature of the git plugin, it's possible that you accept all the defaults. In that case, you should make your configuration like this:
29
+
30
+ ```yaml
31
+ plugins:
32
+ git:
33
+ enabled: true
34
+ ```
35
+
36
+ #### remote
37
+ The git remote to push/pull to/from.
38
+
39
+ - Type: `String`
40
+ - Default: `origin`
41
+
42
+ #### branch
43
+ The git brnach to push/pull to/from.
44
+
45
+ - Type: `String`
46
+ - Default: `master`
@@ -0,0 +1,30 @@
1
+ Graphite
2
+ ========
3
+ Graphite will automatically send a request to your Graphite server under the deploys.chef.[environment] for graphical analysis.
4
+
5
+ Gem Requirements
6
+ ----------------
7
+ This plugin has no gem requirements.
8
+
9
+ Hooks
10
+ -----
11
+ - `after_promote`
12
+
13
+ Configuration
14
+ -------------
15
+ ```yaml
16
+ plugins:
17
+ graphite:
18
+ server: graphite.example.com
19
+ port: 12345
20
+ ```
21
+
22
+ #### server
23
+ The url to the graphite server
24
+
25
+ - Type: `String`
26
+
27
+ #### port
28
+ The port of the graphite server
29
+
30
+ - Type: `Integer`
@@ -0,0 +1,50 @@
1
+ HipChat
2
+ =======
3
+ HipChat posts messages to your HipChat client.
4
+
5
+ Gem Requirements
6
+ ----------------
7
+ This plugin requires the following gems:
8
+
9
+ ```ruby
10
+ gem 'hipchat'
11
+ ```
12
+
13
+ Hooks
14
+ -----
15
+ - `after_upload`
16
+ - `after_promote`
17
+
18
+ Configuration
19
+ -------------
20
+ ```yaml
21
+ plugins:
22
+ hipchat:
23
+ api_token: ABC123
24
+ rooms:
25
+ - General
26
+ - Web Operations
27
+ notify: true
28
+ color: yellow
29
+ ```
30
+
31
+ #### api_token
32
+ Your HipChat API token.
33
+
34
+ - Type: `String`
35
+
36
+ #### rooms
37
+ The list of rooms to post to.
38
+
39
+ - Type: `Array`
40
+
41
+ #### notify
42
+ Boolean value indicating whether the room should be notified.
43
+
44
+ - Type: `Boolean`
45
+
46
+ #### color
47
+ THe color of the message.
48
+
49
+ - Type: `String`
50
+ - Acceptable Values: `[yellow, red, green, purple, random]`
data/plugins/Irccat.md ADDED
@@ -0,0 +1,44 @@
1
+ Plugin Name
2
+ ===========
3
+ This plugin interfaces with the irccat IRC bot (https://github.com/RJ/irccat)
4
+
5
+ Gem Requirements
6
+ ----------------
7
+ This plugin has no gem requirements.`
8
+
9
+ Hooks
10
+ -----
11
+ - `after_promote`
12
+
13
+ Configuration
14
+ -------------
15
+ ```yaml
16
+ plugins:
17
+ irccat:
18
+ server: irc.example.com
19
+ port: 54
20
+ channels:
21
+ - #chef
22
+ - #knife
23
+ gist: "/usr/bin/gist"
24
+ ```
25
+
26
+ #### server
27
+ The url of the IRC server.
28
+
29
+ - Type: `String`
30
+
31
+ #### port
32
+ The port of the IRC server.
33
+
34
+ - Type: `String`
35
+
36
+ #### channels
37
+ The channels to post to.
38
+
39
+ - Type: `Array`
40
+
41
+ #### gist
42
+ Optional path to gist binary installed by https://rubygems.org/gems/gist
43
+
44
+ - Type: `String`
data/plugins/README.md ADDED
@@ -0,0 +1,70 @@
1
+ Plugins Directory
2
+ =================
3
+ This folder contains relevant documentation for each KnifeSpork plugin. For more information, usage, and options for an particular plugin, click on the assoicated markdown file in the tree above.
4
+
5
+ Creating a Plugin
6
+ -----------------
7
+ To create a plugin, start with the following basic boiler template:
8
+
9
+ ```ruby
10
+ require 'knife-spork/plugins/plugin'
11
+
12
+ module KnifeSpork
13
+ module Plugins
14
+ class MyPlugin < Plugin
15
+ name :my_plugin
16
+
17
+ def perform
18
+ # your plugin code here
19
+ end
20
+ end
21
+ end
22
+ end
23
+ ```
24
+
25
+ **Don't forget to update the class name and the `name` at the very top of the class!**
26
+
27
+ Helpers
28
+ -------
29
+ The following "helpers" or "methods" are exposed:
30
+
31
+ #### safe_require
32
+ This method allows you to safely require a gem. This is helpful when your plugin requires an external plugin. It will output a nice error message if the gem cannot be loaded and stop executing.
33
+
34
+ #### current_user
35
+ This method tries to get the current user's name in the following manner:
36
+
37
+ 1. From the git configuration
38
+ 2. From the `ENV`
39
+
40
+ #### config
41
+ This method returns the config associated with the current plugin. For example, if a `spork-config.yml` file looked like this:
42
+
43
+ ```yaml
44
+ plugins:
45
+ my_plugin:
46
+ option_1: my_value
47
+ option_2: other_value
48
+ ```
49
+
50
+ then
51
+
52
+ ```text
53
+ config.option_1 #=> 'my_value'
54
+ config.option_2 #=> 'other_value'
55
+ ```
56
+
57
+ This uses `app_conf`, so you access the keys are methods, not `[]`.
58
+
59
+ #### cookbooks
60
+ This returns an array of `Chef::CookbookVersion` objects corresponding to the cookbooks that are being changed/altered in the hook. For more information on the methods avaliable, see the [file in the Chef repo](https://github.com/opscode/chef/blob/master/chef/lib/chef/cookbook_version.rb).
61
+
62
+ #### environments
63
+ This returns an array of `Chef::Environment` objects corresponding to the environments that are being changed/altered in the hook. For more information on the methods avaliable, see the [file in the Chef repo](https://github.com/opscode/chef/blob/master/chef/lib/chef/environment.rb).
64
+
65
+ #### environment_diffs
66
+ This returns a Hash of Hash objects containing a diff between local and remote environment for each environment changed/altered in the hook. Currently, this will only be populated during the promotea action.
67
+
68
+
69
+ #### ui
70
+ This returns a `Chef::Knife::UI` element for outputting to the console. For more information on the methods avaliable, see the [file in the Chef repo](https://github.com/opscode/chef/blob/master/chef/lib/chef/knife/core/ui.rb).
@@ -0,0 +1,34 @@
1
+ Plugin Name
2
+ ===========
3
+ Here is an optional, short description about your plugin.
4
+
5
+ Gem Requirements
6
+ ----------------
7
+ This plugin requires the following gems:
8
+
9
+ ```ruby
10
+ gem 'my_gem', '~> 1.4.5'
11
+ gem 'other_gem', '>= 5.0.1'
12
+ ```
13
+
14
+ Hooks
15
+ -----
16
+ - `after_promote`
17
+
18
+ Configuration
19
+ -------------
20
+ ```yaml
21
+ plugins:
22
+ plugin_name:
23
+ option_1: true
24
+ option_2:
25
+ - a
26
+ - b
27
+ - c
28
+ ```
29
+
30
+ #### option_1
31
+ This is a description of the option.
32
+
33
+ - Type: `String`
34
+ - Default: `ABC`
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: knife-spork
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.11
4
+ version: 1.0.0
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -9,11 +9,11 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2012-06-05 00:00:00.000000000 Z
12
+ date: 2012-08-27 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: chef
16
- requirement: &70361791232900 !ruby/object:Gem::Requirement
16
+ requirement: &70197088928460 !ruby/object:Gem::Requirement
17
17
  none: false
18
18
  requirements:
19
19
  - - ! '>='
@@ -21,10 +21,10 @@ dependencies:
21
21
  version: 0.10.4
22
22
  type: :runtime
23
23
  prerelease: false
24
- version_requirements: *70361791232900
24
+ version_requirements: *70197088928460
25
25
  - !ruby/object:Gem::Dependency
26
26
  name: git
27
- requirement: &70361791232420 !ruby/object:Gem::Requirement
27
+ requirement: &70197088927580 !ruby/object:Gem::Requirement
28
28
  none: false
29
29
  requirements:
30
30
  - - ! '>='
@@ -32,10 +32,10 @@ dependencies:
32
32
  version: 1.2.5
33
33
  type: :runtime
34
34
  prerelease: false
35
- version_requirements: *70361791232420
35
+ version_requirements: *70197088927580
36
36
  - !ruby/object:Gem::Dependency
37
37
  name: app_conf
38
- requirement: &70361791231940 !ruby/object:Gem::Requirement
38
+ requirement: &70197088927020 !ruby/object:Gem::Requirement
39
39
  none: false
40
40
  requirements:
41
41
  - - ! '>='
@@ -43,39 +43,50 @@ dependencies:
43
43
  version: 0.4.0
44
44
  type: :runtime
45
45
  prerelease: false
46
- version_requirements: *70361791231940
47
- - !ruby/object:Gem::Dependency
48
- name: hipchat
49
- requirement: &70361790131840 !ruby/object:Gem::Requirement
50
- none: false
51
- requirements:
52
- - - ! '>='
53
- - !ruby/object:Gem::Version
54
- version: 0.4.0
55
- type: :runtime
56
- prerelease: false
57
- version_requirements: *70361790131840
46
+ version_requirements: *70197088927020
58
47
  description: A workflow plugin to help many devs work with the same chef repo/server
59
48
  email: jonlives@gmail.com
60
49
  executables: []
61
50
  extensions: []
62
- extra_rdoc_files:
63
- - README.md
51
+ extra_rdoc_files: []
64
52
  files:
65
- - README.md
53
+ - .gitignore
54
+ - .rvmrc
66
55
  - CHANGELOG.md
56
+ - Gemfile
57
+ - LICENSE
58
+ - README.md
67
59
  - Rakefile
68
60
  - knife-spork.gemspec
69
61
  - lib/chef/knife/spork-bump.rb
70
62
  - lib/chef/knife/spork-check.rb
63
+ - lib/chef/knife/spork-info.rb
71
64
  - lib/chef/knife/spork-promote.rb
72
65
  - lib/chef/knife/spork-upload.rb
73
66
  - lib/knife-spork.rb
67
+ - lib/knife-spork/plugins.rb
68
+ - lib/knife-spork/plugins/campfire.rb
69
+ - lib/knife-spork/plugins/eventinator.rb
70
+ - lib/knife-spork/plugins/foodcritic.rb
71
+ - lib/knife-spork/plugins/git.rb
72
+ - lib/knife-spork/plugins/graphite.rb
73
+ - lib/knife-spork/plugins/hip_chat.rb
74
+ - lib/knife-spork/plugins/irccat.rb
75
+ - lib/knife-spork/plugins/plugin.rb
76
+ - lib/knife-spork/runner.rb
77
+ - plugins/Campfire.md
78
+ - plugins/Eventinator.md
79
+ - plugins/Foodcritic.md
80
+ - plugins/Git.md
81
+ - plugins/Graphite.md
82
+ - plugins/HipChat.md
83
+ - plugins/Irccat.md
84
+ - plugins/README.md
85
+ - plugins/Template.md
74
86
  homepage: https://github.com/jonlives/knife-spork
75
87
  licenses: []
76
88
  post_install_message:
77
- rdoc_options:
78
- - --charset=UTF-8
89
+ rdoc_options: []
79
90
  require_paths:
80
91
  - lib
81
92
  required_ruby_version: !ruby/object:Gem::Requirement
@@ -91,10 +102,9 @@ required_rubygems_version: !ruby/object:Gem::Requirement
91
102
  - !ruby/object:Gem::Version
92
103
  version: '0'
93
104
  requirements: []
94
- rubyforge_project: knife-spork
105
+ rubyforge_project:
95
106
  rubygems_version: 1.8.10
96
107
  signing_key:
97
- specification_version: 2
108
+ specification_version: 3
98
109
  summary: A workflow plugin to help many devs work with the same chef repo/server
99
110
  test_files: []
100
- has_rdoc: