X-Git-Url: https://git.openstreetmap.org./chef.git/blobdiff_plain/0c79b5dbf9284104cb1ab66bd0673f9d41dd08bd..c51d171917d4bbba2b6221128ca1cebb863870cc:/cookbooks/logstash/recipes/default.rb diff --git a/cookbooks/logstash/recipes/default.rb b/cookbooks/logstash/recipes/default.rb index e3261d0d1..bbe845021 100644 --- a/cookbooks/logstash/recipes/default.rb +++ b/cookbooks/logstash/recipes/default.rb @@ -23,7 +23,7 @@ include_recipe "networking" keys = data_bag_item("logstash", "keys") package %w[ - openjdk-8-jre-headless + openjdk-11-jre-headless logstash ] @@ -76,13 +76,13 @@ end forwarders = [] -forwarders << search(:node, "recipes:logstash\\:\\:forwarder").collect do |forwarder| - forwarder.ipaddresses(:role => :external) -end.flatten +search(:node, "recipes:logstash\\:\\:forwarder").each do |forwarder| + forwarders.append(forwarder.ipaddresses(:role => :external)) +end -forwarders << search(:node, "roles:gateway").collect do |forwarder| - forwarder.ipaddresses(:role => :external) -end.flatten +search(:node, "roles:gateway").each do |forwarder| + forwarders.append(forwarder.ipaddresses(:role => :external)) +end firewall_rule "accept-logstash" do action :accept