openstack vagrant plugin overview
DESCRIPTION
A quick overview of Openstack vagrant plugin with hpcloud backend.TRANSCRIPT
1
2
Openstack as a Vagrant Pluginquick overview of vagrant based vm provisioning
Márton KissOpenstack [email protected]@marton_kiss
3
A tool to avoid works for me errors!
/// WHAT IS VAGRANT ///
4
1. deploy a vagranthttp://www.vagrantup.com/downloads.html
2. install Openstack plugin$ vagrant plugin install vagrant-openstack-plugin
/// INSTALL VAGRANT TOOLSET ///
5
!
$ vagrant box add dummy https://github.com/cloudbau/vagrant-openstack-plugin/raw/master/dummy.box
/// PREPARE OPENSTACK DUMMY BOX ///
6
require 'vagrant-openstack-plugin' Vagrant.configure("2") do |config| config.vm.box = “dummy" # Make sure the private key from the key pair is provided config.ssh.private_key_path = "~/.ssh/id_dsa" ! config.vm.provider :openstack do |os| os.username = ENV['OS_USERNAME'] os.api_key = ENV['OS_PASSWORD'] os.tenant = ENV['OS_TENANT_NAME'] os.region = "region-a.geo-1" os.flavor = /standard.xsmall/ os.image = /20140408/ os.endpoint = "https://region-a.geo-1.identity.hpcloudsvc.com:35357/v2.0/tokens" os.keypair_name = "default-keypair" os.ssh_username = "ubuntu" os.floating_ip = "15.125.106.143" end ! # Provision config.vm.provision :shell, :path => "scripts/bootstrap.sh" end
/// Vagrantfile ///
7
#!/bin/bash !echo "Custom bootstrap" touch /tmp/H3llo
/// scripts/bootstrap.sh ///
8
export OS_USERNAME=user-name export OS_PASSWORD=password export OS_TENANT_NAME=tenant-name
/// openrc file ///
9
/// get tenant name ///
10
/// vagrant up ///
11
vagrant ssh - login to provisioned instancevagrant provision - rerun provisioning scripts (shell script, puppet, etc.)vagrant destroy -f - destroy the instance
/// Use standard vagrant commands ///
12
- minimal rsync support- don’t place sensitive data next to Vagrantfile, it is synced to /vagrant directory inside vm
/// Limitations ///
13
?/// Questions ///