Dear puppet community!

I need to add some repositories to sources.list to be able to install sun 
jdk:

deb-src http://security.debian.org/ lenny/updates main non-free
deb http://security.debian.org/ lenny/updates main non-free
deb-src http://mirrors.kernel.org/debian/ lenny main non-free
deb http://mirrors.kernel.org/debian/ lenny main non-free

I was looking for the best approach for it and decided to try 
puppetlabs/apt module. Eventually I came out with the following script:

class repositories {
    include apt

    apt::source { 'sun_java':
        location => "http://security.debian.org/";,
        release => "squeeze/update",
        repos => "main non-free",
        include_src => true,
    }

    apt::source { 'sun_java2':
        location => "http://mirrors.kernel.org/debian/";,
        repos => "main non-free",
        include_src => true,
    }

    package { 'sun_java':
        ensure => installed,
        require => [ Apt::Source['sun_java'], Apt::Source['sun_java2'] ],
    }
}
include repositories


the questions are:
1) how can I added all repositories using one apt::source?
2) I had to write specific release ("squeeze/update").. Is here a way to 
tell just updates and apt module will generate ${os_version}/update 
release? (it depends on Debian version, can be lenny/updates...)
3) seems that after adding new repositories puppet tries to install package 
sun-java... I do not know why, but I get the following error: "Unable to 
locate package sun-java"..  why it happens? should I just ignore it, or 
there is a way to control?
4) any other improvements (best practices?) can you suggest?

-- 
You received this message because you are subscribed to the Google Groups 
"Puppet Users" group.
To view this discussion on the web visit 
https://groups.google.com/d/msg/puppet-users/-/yuuHr903EAAJ.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/puppet-users?hl=en.

Reply via email to