diff options
author | Ciprian Badescu <ciprian.badescu@puppet.com> | 2020-02-20 15:32:52 +0200 |
---|---|---|
committer | Ciprian Badescu <ciprian.badescu@puppet.com> | 2020-02-25 14:27:27 +0200 |
commit | 92a734a6620fcc51691d60347e344f87ac801bde (patch) | |
tree | 8309796c9485c084ec87cd84d26d17ecfb904213 /lib/puppet/provider | |
parent | 9f710d8e502b5bf2ca3d213d2bddea13f7a4b7b8 (diff) | |
download | puppet-sshkeys_core-92a734a6620fcc51691d60347e344f87ac801bde.tar.gz puppet-sshkeys_core-92a734a6620fcc51691d60347e344f87ac801bde.tar.bz2 |
(MODULES-7613) use name and type as composite namevar
After this modification it will be possible to add two or more keys
of different types for the same host
Diffstat (limited to 'lib/puppet/provider')
-rw-r--r-- | lib/puppet/provider/sshkey/parsed.rb | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/lib/puppet/provider/sshkey/parsed.rb b/lib/puppet/provider/sshkey/parsed.rb index 3713df1..965c20d 100644 --- a/lib/puppet/provider/sshkey/parsed.rb +++ b/lib/puppet/provider/sshkey/parsed.rb @@ -46,4 +46,9 @@ Puppet::Type.type(:sshkey).provide( '/etc/ssh/ssh_known_hosts' end end + + def self.resource_for_record(record, resources) + name = "#{record[:name]}@#{record[:type]}" + resources[name] + end end |