Once I did this class for mailscanner installation, can be an example.

class mailscanner {
        $mailscannerver="MailScanner-4.69.9-2"
        $mailscannerfile="$mailscannerver.rpm.tar.gz"

        exec {
                "mailscanner_prerequisites":
                        command => $operatingsystem ? {
                                default => "yum install -y wget tar gzip rpm-
build binutils glibc-devel gcc make",
                        },
                        onlyif => "test ! -f /usr/src/
$mailscannerfile",
        }

        exec {
                "mailscanner_download":
                        command => "cd /usr/src ; wget
http://www.mailscanner.info/files/4/rpm/$mailscannerfile";,
                        onlyif => "test ! -f /usr/src/
$mailscannerfile",
                        require => Exec["mailscanner_prerequisites"],
        }

        exec {
                "mailscanner_extract":
                        command => "cd /usr/src ; tar -zxvf
$mailscannerfile",
                        require => Exec["mailscanner_download"],
                        onlyif => "test ! -d /usr/src/
$mailscannerver",
        }

        exec {
                "mailscanner_install":
                        command => "cd /usr/src/$mailscannerver ; ./
install.sh",
                        require => [
                                Exec["mailscanner_extract"],
                                Package["spamassassin"],
                                Package["clamav"]
                                ],
                        unless => "rpm -qi mailscanner",
        }

        service { mailscanner:
                name => "MailScanner",
                ensure => running,
                enable => true,
                hasrestart => true,
                hasstatus => true,
                require => Exec["mailscanner_install"],
        }

}




On Jun 25, 10:42 pm, Neil K <sate...@gmail.com> wrote:
> Hi all,
>
> I am pretty new to Puppet. My puppet master server is a RHEL 5 box and
> puppet client is a CentOS 5.3 vm. I have managed to configure puppet
> server to successfully install.and upgrade rpm based packages on the
> client machine. Is it possible to install noon-rpm based packages
> using puppet? Like packages comes as tar.gz such as web based
> applications?
>
> If it is possible, please provide any example manifests or any good
> documents that I can follow.
>
> Thanks,
> Neil
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Puppet Users" group.
To post to this group, send email to puppet-users@googlegroups.com
To unsubscribe from this group, send email to 
puppet-users+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/puppet-users?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to