foreman_hooks 0.3.10 → 0.3.11
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +2 -1
- data/lib/foreman_hooks/util.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 6f58ca523ae7bc8b6cf7aa5aa431e55313864e7f
|
4
|
+
data.tar.gz: f2eca1f34608ea8e1cd7da4ed7f304d1db5c2ed8
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 7ddb67b6ceb55bb8d5a0862ef9a46924a7e5403843a1d656475908ddf56c8d91274acb8792885cdaeb37b2cd79615c76fa245f573972c82912753f4b6a70121f
|
7
|
+
data.tar.gz: 71c044b7883ba0445a62ac9e9f11641ec9b9ae82fea9116b5bcd972241792a8d8bebf85065f006c7a35796cb566a53eb9689e6c42686bad6e45684fd33e11ce0
|
data/README.md
CHANGED
@@ -87,7 +87,8 @@ documentation.
|
|
87
87
|
|
88
88
|
The host object has two additional callbacks that you can use:
|
89
89
|
|
90
|
-
* `host/managed/after_build` triggers when a host is put into build mode
|
90
|
+
* `host/managed/after_build` triggers when a host is put into build mode (does
|
91
|
+
not trigger upon new host creation, even when build flag is set)
|
91
92
|
* `host/managed/before_provision` triggers when a host completes the OS install
|
92
93
|
|
93
94
|
## Execution of hooks
|
data/lib/foreman_hooks/util.rb
CHANGED
@@ -19,7 +19,7 @@ module ForemanHooks::Util
|
|
19
19
|
def render_hook_json
|
20
20
|
# APIv2 has some pretty good templates. We could extend them later in special cases.
|
21
21
|
# Wrap them in a root node for pre-1.4 compatibility
|
22
|
-
view_path =
|
22
|
+
view_path = ActionController::Base.view_paths.collect(&:to_path)
|
23
23
|
json = Rabl.render(self, "api/v2/#{render_hook_type.tableize}/show", :view_path => view_path, :format => :json)
|
24
24
|
%Q|{"#{render_hook_type}":#{json}}|
|
25
25
|
rescue => e
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: foreman_hooks
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.3.
|
4
|
+
version: 0.3.11
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Dominic Cleal
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2016-
|
11
|
+
date: 2016-06-20 00:00:00.000000000 Z
|
12
12
|
dependencies: []
|
13
13
|
description: Plugin engine for Foreman that enables running custom hook scripts on
|
14
14
|
Foreman events
|