projects
/
chef.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
8323b6a
)
Fix error when a host has no interfaces declared
author
Tom Hughes
<tom@compton.nu>
Thu, 26 Nov 2015 14:08:05 +0000
(14:08 +0000)
committer
Tom Hughes
<tom@compton.nu>
Thu, 26 Nov 2015 14:08:05 +0000
(14:08 +0000)
cookbooks/networking/libraries/interfaces.rb
patch
|
blob
|
history
diff --git
a/cookbooks/networking/libraries/interfaces.rb
b/cookbooks/networking/libraries/interfaces.rb
index cd9116dfa8be051956ef6550332e4dc1dbdb10f1..029cb4f32425242b3ace2a6a844df9c8e7cb3cdc 100644
(file)
--- a/
cookbooks/networking/libraries/interfaces.rb
+++ b/
cookbooks/networking/libraries/interfaces.rb
@@
-4,7
+4,7
@@
class Chef
interfaces = []
networking = construct_attributes[:networking] || {}
- networking_interfaces = networking[:interfaces] ||
[]
+ networking_interfaces = networking[:interfaces] ||
{}
networking_interfaces.each_value do |interface|
next unless options[:role].nil? || interface[:role].to_s == options[:role].to_s