Skip to content

Instantly share code, notes, and snippets.

@robbyt
Created August 14, 2011 04:31
Show Gist options
  • Save robbyt/1144587 to your computer and use it in GitHub Desktop.
Save robbyt/1144587 to your computer and use it in GitHub Desktop.
Setup basic vagrant/vbox env
$apt_key = 'http://download.virtualbox.org/virtualbox/debian/oracle_vbox.asc'
file {'/etc/apt/sources.list.d/vargrant.conf':
ensure => file,
content => "deb http://download.virtualbox.org/virtualbox/debian ${lsbdistcodename} contrib",
notify => Exec['apt-get-update'],
before => Package['virtualbox-4.0'],
}
exec {'apt-key':
command => "/usr/bin/wget -q -O $apt_key | /usr/bin/apt-key add -",
unless => "/usr/bin/apt-key list|/bin/grep -c oracle",
notify => Exec['apt-get-update'],
before => Package['virtualbox-4.0'],
}
exec {'apt-get-update':
command => '/usr/bin/apt-get update',
refreshonly => true,
}
package{'virtualbox-4.0':
ensure => installed,
}
package{'vagrant':
ensure => installed,
provider => 'gem',
}
@robbyt
Copy link
Author

robbyt commented Aug 14, 2011

Put a hash-bang bin puppet at the top, chmod +x this guy and you're all set!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment