Skip to content

Instantly share code, notes, and snippets.

@xtoddx
Created February 10, 2011 22:17
Show Gist options
  • Save xtoddx/821467 to your computer and use it in GitHub Desktop.
Save xtoddx/821467 to your computer and use it in GitHub Desktop.
Branch a specific nova version in a vagrant box.
$HOME=File.expand_path(File.join(Dir.pwd, '..'))
Vagrant::Config.run do |config|
ip = "10.0.0.5"
aptdir = "#{$HOME}/aptcache/"
checkout = "#{$HOME}/openstack-cookbooks"
config.vm.box = "base"
config.vm.box_url = "http://images.ansolabs.com/vagrant/maverick64.box"
config.vm.network ip
config.vm.share_folder("v-apt", "/var/cache/apt", aptdir)
config.vm.provision :chef_solo do |chef|
chef.cookbooks_path = "#{checkout}/cookbooks"
chef.roles_path = "#{checkout}/roles"
chef.log_level = :debug
chef.run_list = [
"recipe[nova::hostname]",
"recipe[nova::filevg]",
"recipe[nova::source]", # install from bzr
#"recipe[nova::screen]",
#"recipe[anso::settings]", # vim / screen / git settings for testing
]
chef.json.merge!({
:nova => {
:bzr_bbranch => "lp:~xtoddx/nova/provider-fw-rules",
:my_ip => ip,
:libvirt_type => "qemu",
:images => [
"http://images.ansolabs.com/tty.tgz"
],
:creds => {
:user => "vagrant",
:group => "vagrant",
:dir => "/vagrant",
}
},
})
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment