Skip to content

Instantly share code, notes, and snippets.

@supercow
Last active August 29, 2015 14:00
Show Gist options
  • Save supercow/11089126 to your computer and use it in GitHub Desktop.
Save supercow/11089126 to your computer and use it in GitHub Desktop.
if ! $::package_installed {
file { 'download_rpm':
ensure => file,
path => '/tmp/my_package.rpm',
source => 'puppet:///files/my_package.rpm',
}
exec { 'install_package':
command => '/bin/rpm -i /tmp/my_package.rpm',
require => File['download_rpm'],
}
}
# Why can't everyone do it the easy way?
package { 'my_package':
ensure => present,
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment