X-Git-Url: https://review.fuel-infra.org/gitweb?a=blobdiff_plain;f=lib%2Fpuppet%2Ftype%2Fapt_key.rb;h=e2cb8d9cf92695dded9d331b627dc7759abc9092;hb=3cbe24e18e071f0da9623d0752f7d9c1ee0efa5e;hp=67420de0fad9502b83202ab0e21eba0493f2eacc;hpb=0a93286ff8d28a75e3eccdabe0bd944f993430bf;p=puppet-modules%2Fpuppetlabs-apt.git diff --git a/lib/puppet/type/apt_key.rb b/lib/puppet/type/apt_key.rb index 67420de..e2cb8d9 100644 --- a/lib/puppet/type/apt_key.rb +++ b/lib/puppet/type/apt_key.rb @@ -49,8 +49,8 @@ Puppet::Type.newtype(:apt_key) do end newparam(:source) do - desc 'Location of a GPG key file, /path/to/file, http:// or https://' - newvalues(/\Ahttps?:\/\//, /\A\/\w+/) + desc 'Location of a GPG key file, /path/to/file, ftp://, http:// or https://' + newvalues(/\Ahttps?:\/\//, /\Aftp:\/\//, /\A\/\w+/) end autorequire(:file) do @@ -60,10 +60,10 @@ Puppet::Type.newtype(:apt_key) do end newparam(:server) do - desc 'The key server to fetch the key from based on the ID.' + desc 'The key server to fetch the key from based on the ID. It can either be a domain name or url.' defaultto :'keyserver.ubuntu.com' - # Need to validate this, preferably through stdlib is_fqdn - # but still working on getting to that. + + newvalues(/\A((hkp|http|https):\/\/)?([a-z\d])([a-z\d-]{0,61}\.)+[a-z\d]+(:\d{2,4})?$/) end newparam(:keyserver_options) do