jclouds/sandbox-apis/virtualbox/README.md

40 lines
2.5 KiB
Markdown
Raw Normal View History

2011-07-25 13:51:07 -04:00
# Administation viewpoint
These steps are usually in charge of cloud provider, in this case it's up to you
The experiment assumes almost nothing: only a running Ubuntu 11.04 where java6 and maven3 are installed.
## Prepare your Master VM
By launching "VirtualboxAdministrationTest" an helper class to execute a number of preliminary steps needed to have a properly configured ubuntu box
and to create a golden template for your experiment.
The "VirtualboxAdministrationTest" helper will run these preliminary steps:
1. Create a working dir on 'user.home' called by default "jclouds-virtualbox-test"
(this value can be overwritten directly on the commandline using -Dtest.virtualbox.workingDir)
2011-09-23 11:14:13 -04:00
2. Install Virtualbox from the internet (mac os x lion and ubuntu host are supported at the moment)
2012-01-07 19:58:14 -05:00
3. Download by default an ubuntu 10.04.3 server i386 ISO into "jclouds-virtualbox-test" from http://releases.ubuntu.com/10.04/ubuntu-10.04.3-server-i386.iso
4. Download VirtualBox Guest Additions ISO into "jclouds-virtualbox-test" from http://download.virtualbox.org/virtualbox/4.1.8/VBoxGuestAdditions_4.1.8.iso
2011-07-25 13:51:07 -04:00
5. Disable login credential: $ VBoxManage setproperty websrvauthlibrary null
2011-09-23 11:14:13 -04:00
6. Start an embedded jetty server that serves a preseed file specifically written for ubuntu 11.04
7. Start webservice with increasead timeout: $ /usr/bin/vboxwebsrv --timeout 10000 and then will:
- create a "jclouds-virtaulbox-kickstart-admin" vm in the the vbox default machine folder ("/user.home/VirtualBox VMs")
- install automatically the OS (ubuntu 11.04) in this vm using preseed
2011-07-25 13:51:07 -04:00
- Set NAT on network interface eth0
- Set port forwarding localhost:2222->guest:22
2011-09-23 11:14:13 -04:00
- Mount Guest Additions ISO
- Install Guest additions
2011-07-25 13:51:07 -04:00
- Shutdown VM
2011-09-23 11:14:13 -04:00
- create a snapshot of this machine, to enabling linked clone feature.
2011-07-25 13:51:07 -04:00
- Remove port forwarding rule
2011-09-23 11:14:13 -04:00
- Change NIC from NAt to bridge
2011-07-25 13:51:07 -04:00
At this stage, you can use your template as a master for your "private" cloud through VirtualBoxLiveTest
## Bootstrap your private cloud through VirtualBoxLiveTest helper
To use this helper, you have to specify the name of the VM (-Dtest.virtualbox.vmname=<VM-NAME>)
and choose the numberOfVirtualMachine you need using -Dtest.virtualbox.numberOfVirtualMachine=<#ofVMs>,
2011-09-23 11:14:13 -04:00
These VMs will be cloned starting from the golden template VM created before
2011-07-25 13:51:07 -04:00
It will create a "numberOfVirtualMachine" in a vbox default machine folder with 'VMName_i' name, by cloning the golden template in linked mode with a bridged NIC.