Use the /etc/apt/sources.list.d/ for adding repositories. Note the files
in there must have ".list" extension to be considered.
For signing the easy way out is creating a define similar to this one:
I'd advise against this one because I made it when I started using puppet.
In a class:
$folder = "/etc/apt/rkeys/"
file { $folder :
owner => root,
group => root,
mode => 700,
ensure => directory
}
In the define
define apt_sign_key($sign_key)
{
$file_dest = "${folder}${sign_key}"
file { $file_dest :
owner => root,
group => root,
mode => 600,
source => "puppet:///somepath/${sign_key}",
require => File[$folder]
}
exec { "apt-key add ${file_dest}":
refreshonly => true,
require => File[$file_dest],
subscribe => File[$file_dest]
}
}
Another way would be doing something like
file{ "${repokey}": ......}
exec { "apt-key add ${repokey}":
require => File[$repokey],
unless => "apt-key list | grep $repokeyid"
}
And of course the best way would be to do another provider like yumrepo
in ruby :-)
Silviu
> --
>
> You received this message because you are subscribed to the Google Groups "Puppet Users" group.
> To post to this group, send email to
puppet...@googlegroups.com.
> To unsubscribe from this group, send email to
puppet-users...@googlegroups.com.
> For more options, visit this group at
http://groups.google.com/group/puppet-users?hl=en.
>
>
>