From a97bb246b7122f4bb7686b9b48ee379e00bf4914 Mon Sep 17 00:00:00 2001 From: Peter Palfrader Date: Sun, 25 Aug 2013 11:52:46 +0200 Subject: [PATCH] rename new cert files --- .../puppetmaster/lib/puppet/parser/functions/gen_tlsa_entry.rb | 3 +-- ....debian.org.crt.new => security-tracker.debian.org-new.crt} | 0 2 files changed, 1 insertion(+), 2 deletions(-) rename modules/ssl/files/servicecerts/{security-tracker.debian.org.crt.new => security-tracker.debian.org-new.crt} (100%) 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 310a77e0..7b846b90 100644 --- a/modules/puppetmaster/lib/puppet/parser/functions/gen_tlsa_entry.rb +++ b/modules/puppetmaster/lib/puppet/parser/functions/gen_tlsa_entry.rb @@ -12,8 +12,7 @@ module Puppet::Parser::Functions res << "; certfile #{certfile} did not exist to create TLSA record for #{hostname}:#{port}." end - certfile += ".new" - if File.exist?(certfile) + if certfile.gsub!(/\.crt$/, '-new.crt') and File.exist?(certfile) cmd = ['swede', 'create', '--usage=3', '--selector=1', '--mtype=1', '--certificate', certfile, '--port', port.to_s, hostname] new_entry = '' IO.popen(cmd, "r") {|i| new_entry = i.read } diff --git a/modules/ssl/files/servicecerts/security-tracker.debian.org.crt.new b/modules/ssl/files/servicecerts/security-tracker.debian.org-new.crt similarity index 100% rename from modules/ssl/files/servicecerts/security-tracker.debian.org.crt.new rename to modules/ssl/files/servicecerts/security-tracker.debian.org-new.crt -- 2.39.2