File tree 4 files changed +22
-1
lines changed
4 files changed +22
-1
lines changed Original file line number Diff line number Diff line change @@ -8,6 +8,10 @@ This file is used to list changes made in each version of the icinga2 cookbook.
8
8
9
9
- Virender Khatri - Feature #10900 , fix to allow multiple environment resources for an environment
10
10
11
+ - Van Driessche Vincent - Feature #10831 , Adds support to use "assign where" in usergroups
12
+
13
+ - Virender Khatri - Feature #10831 , Adds support to use "ignore where" in usergroups
14
+
11
15
2.7.0
12
16
-----
13
17
Original file line number Diff line number Diff line change @@ -1050,6 +1050,8 @@ LWRP `usergroup` creates an icinga `UserGroup` object.
1050
1050
display_name 'User Group'
1051
1051
groups ['usergroup']
1052
1052
zone 'zone_name'
1053
+ assign_where ['assign where statement']
1054
+ ignore_where ['ignore where statement']
1053
1055
end
1054
1056
1055
1057
Above LWRP resource will create an icinga ` UserGroup ` object.
@@ -1061,6 +1063,8 @@ Above LWRP resource will create an icinga `UserGroup` object.
1061
1063
- * display_name* (optional, String) - icinga ` UserGroup ` attribute ` display_name `
1062
1064
- * groups* (optional, Array) - icinga ` UserGroup ` attribute ` groups `
1063
1065
- * zone* (optional, String) - icinga ` UserGroup ` attribute ` zone `
1066
+ - * assign_where* (optional, Array) - an array of ` assign where ` statements
1067
+ - * ignore_where* (optional, Array) - an array of ` ignore where ` statements
1064
1068
1065
1069
1066
1070
## LWRP icinga2_zone
Original file line number Diff line number Diff line change @@ -55,11 +55,19 @@ def template_support(arg = nil)
55
55
)
56
56
end
57
57
58
+ def ignore_where ( arg = nil )
59
+ set_or_return (
60
+ :ignore_where , arg ,
61
+ :kind_of => Array ,
62
+ :default => nil
63
+ )
64
+ end
65
+
58
66
def resource_properties ( arg = nil )
59
67
set_or_return (
60
68
:resource_properties , arg ,
61
69
:kind_of => Array ,
62
- :default => %w( assign_where display_name groups zone )
70
+ :default => %w( assign_where ignore_where display_name groups zone )
63
71
)
64
72
end
65
73
end
Original file line number Diff line number Diff line change @@ -20,6 +20,11 @@ object UserGroup <%= object.inspect -%> {
20
20
assign where <%= a %>
21
21
<% end -%>
22
22
<% end -%>
23
+ <% if options['ignore_where'] -%>
24
+ <% options['ignore_where'].each do |i| -%>
25
+ ignore where <%= i %>
26
+ <% end -%>
27
+ <% end -%>
23
28
}
24
29
25
30
<% end -%>
You can’t perform that action at this time.
0 commit comments