X-Git-Url: https://git.donarmstrong.com/?p=dsa-puppet.git;a=blobdiff_plain;f=modules%2Fpuppetmaster%2Flib%2Fpuppet%2Fparser%2Ffunctions%2Fgen_tlsa_entry.rb;fp=modules%2Fpuppetmaster%2Flib%2Fpuppet%2Fparser%2Ffunctions%2Fgen_tlsa_entry.rb;h=2c826b9653b19d17f650036eec3357b128b7ec06;hp=9a65a5b7482965420ff00ccced1cd1428706d589;hb=90461a264b17c567a0d673317d424897bea75571;hpb=1a6e21d366bf5f8feab36ab1a214598085ae82eb diff --git a/modules/puppetmaster/lib/puppet/parser/functions/gen_tlsa_entry.rb b/modules/puppetmaster/lib/puppet/parser/functions/gen_tlsa_entry.rb index 9a65a5b7..2c826b96 100644 --- a/modules/puppetmaster/lib/puppet/parser/functions/gen_tlsa_entry.rb +++ b/modules/puppetmaster/lib/puppet/parser/functions/gen_tlsa_entry.rb @@ -11,8 +11,8 @@ module Puppet::Parser::Functions end res = [] - res << "; cert #{certfile} for #{hostname}:#{port}." - ports.each{ |port| + res << "; cert #{certfile} for #{hostname}:#{ports}." + ports.each { |port| cf = certfile if File.exist?(cf) cmd = ['swede', 'create', '--usage=3', '--selector=1', '--mtype=1', '--certificate', cf, '--port', port.to_s, hostname]