You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@libcloud.apache.org by Ian Bicking <ia...@colorstudy.com> on 2010/03/03 00:22:33 UTC

[libcloud] Virtualbox driver for libcloud?

I'm thinking about making a driver for libcloud for creating Virtualbox
images.  My use case is primarily to be able to run local tests, and maybe
secondarily to create developer-ready images.  I'm curious if anyone has
considered this general idea, or even has code?  Even a shell script would
be handy, as I've never done automated virtualization in the past and
there's a slightly annoyingly large set of options to sort through.

I'm not sure to what degree I should make these into pretend cloud servers,
and how I should just expose the underlying virtualizing.  There aren't
discrete sizes, for instance (though some concepts like node names work
fine).  Lastly, the question of where this code should actually go
(libcloud, or develop it separately for now).  The way driver instantiation
works it's not that easy to do separate development, unless I have code to
just skip libcloud's instantiation system (not hard to do, just feels
awkward).

-- 
Ian Bicking  |  http://blog.ianbicking.org  |  http://twitter.com/ianbicking

Re: [libcloud] Virtualbox driver for libcloud?

Posted by Ian Bicking <ia...@gmail.com>.
On Tue, Mar 2, 2010 at 9:20 PM, Josh Wright <js...@gmail.com> wrote:

> On Tuesday, March 2, 2010, Ian Bicking <ia...@gmail.com> wrote:
> >
> > COM/XPCOM and SOAP all make me run for subprocess calls, but if you feel
> > comfortable about it then that would be awesome, and I'd be glad to help
> > with the non-COM/XPCOM/SOAP parts.
> >
>
> The Python API distributed by VirtualBox wraps all that up into a tidy
> package. Check out VBoxWeb (or the vboxshell.py example distributed
> with the SDK). All the COM/SOAP stuff is hidden behind a pretty good
> abstraction layer.


Does it all build and interact easily?  I've never gotten Mozilla's PyXPCOM
stuff to work reasonably, which has kind of put me off.


-- 
Ian Bicking  |  http://blog.ianbicking.org  |  http://twitter.com/ianbicking

Re: [libcloud] Virtualbox driver for libcloud?

Posted by Josh Wright <js...@gmail.com>.
On Tuesday, March 2, 2010, Ian Bicking <ia...@gmail.com> wrote:
>
> COM/XPCOM and SOAP all make me run for subprocess calls, but if you feel
> comfortable about it then that would be awesome, and I'd be glad to help
> with the non-COM/XPCOM/SOAP parts.
>

The Python API distributed by VirtualBox wraps all that up into a tidy
package. Check out VBoxWeb (or the vboxshell.py example distributed
with the SDK). All the COM/SOAP stuff is hidden behind a pretty good
abstraction layer.

~JW

Re: [libcloud] Virtualbox driver for libcloud?

Posted by Ian Bicking <ia...@gmail.com>.
On Tue, Mar 2, 2010 at 8:56 PM, Josh Wright <js...@gmail.com> wrote:

> The VirtualBox Python API is really straightforward. There are bindings for
> both the local COM/XPCOM interface, and the SOAP interface. I created
> VBoxWeb (http://github.com/JshWright/vboxweb) a while back using the
> Python
> API (My version of VBoxWeb is no longer maintained, having
> been superseded by the official project of the same name (
> http://code.google.com/p/vboxweb/)).
>
> The documentation for the API is bundled with the SDK. (
>
> http://download.virtualbox.org/virtualbox/3.1.4/VirtualBoxSDK-3.1.4-57640.zip
> )
>
> If this is something the libcloud community thinks should be added, I'd be
> happy to contribute.
>

COM/XPCOM and SOAP all make me run for subprocess calls, but if you feel
comfortable about it then that would be awesome, and I'd be glad to help
with the non-COM/XPCOM/SOAP parts.

-- 
Ian Bicking  |  http://blog.ianbicking.org  |  http://twitter.com/ianbicking

Re: [libcloud] Virtualbox driver for libcloud?

Posted by Josh Wright <js...@gmail.com>.
The VirtualBox Python API is really straightforward. There are bindings for
both the local COM/XPCOM interface, and the SOAP interface. I created
VBoxWeb (http://github.com/JshWright/vboxweb) a while back using the Python
API (My version of VBoxWeb is no longer maintained, having
been superseded by the official project of the same name (
http://code.google.com/p/vboxweb/)).

The documentation for the API is bundled with the SDK. (
http://download.virtualbox.org/virtualbox/3.1.4/VirtualBoxSDK-3.1.4-57640.zip
)

If this is something the libcloud community thinks should be added, I'd be
happy to contribute.

~JW

On Tue, Mar 2, 2010 at 6:59 PM, Paul Querna <pa...@querna.org> wrote:

> On Tue, Mar 2, 2010 at 3:22 PM, Ian Bicking <ia...@colorstudy.com> wrote:
> > I'm thinking about making a driver for libcloud for creating Virtualbox
> > images.  My use case is primarily to be able to run local tests, and
> maybe
> > secondarily to create developer-ready images.  I'm curious if anyone has
> > considered this general idea, or even has code?  Even a shell script
> would
> > be handy, as I've never done automated virtualization in the past and
> > there's a slightly annoyingly large set of options to sort through.
> >
> > I'm not sure to what degree I should make these into pretend cloud
> servers,
> > and how I should just expose the underlying virtualizing.  There aren't
> > discrete sizes, for instance (though some concepts like node names work
> > fine).  Lastly, the question of where this code should actually go
> > (libcloud, or develop it separately for now).  The way driver
> instantiation
> > works it's not that easy to do separate development, unless I have code
> to
> > just skip libcloud's instantiation system (not hard to do, just feels
> > awkward).
>
> I think it would be a cool thing to include in libcloud, as I am
> getting tired of booting and killing dozens of  servers every day :)
>
> I was looking for docs on their API, various blog posts mention some
> kind of SOAP API, but I can't seem to find any info on it.
>
> Their `VBoxManage` command could easily be wrapped though, to provide
> a simple list/create/destroy/etc:
> http://www.virtualbox.org/manual/ch08.html
>

Re: [libcloud] Virtualbox driver for libcloud?

Posted by Paul Querna <pa...@querna.org>.
On Tue, Mar 2, 2010 at 3:22 PM, Ian Bicking <ia...@colorstudy.com> wrote:
> I'm thinking about making a driver for libcloud for creating Virtualbox
> images.  My use case is primarily to be able to run local tests, and maybe
> secondarily to create developer-ready images.  I'm curious if anyone has
> considered this general idea, or even has code?  Even a shell script would
> be handy, as I've never done automated virtualization in the past and
> there's a slightly annoyingly large set of options to sort through.
>
> I'm not sure to what degree I should make these into pretend cloud servers,
> and how I should just expose the underlying virtualizing.  There aren't
> discrete sizes, for instance (though some concepts like node names work
> fine).  Lastly, the question of where this code should actually go
> (libcloud, or develop it separately for now).  The way driver instantiation
> works it's not that easy to do separate development, unless I have code to
> just skip libcloud's instantiation system (not hard to do, just feels
> awkward).

I think it would be a cool thing to include in libcloud, as I am
getting tired of booting and killing dozens of  servers every day :)

I was looking for docs on their API, various blog posts mention some
kind of SOAP API, but I can't seem to find any info on it.

Their `VBoxManage` command could easily be wrapped though, to provide
a simple list/create/destroy/etc:
http://www.virtualbox.org/manual/ch08.html

Re: [libcloud] Virtualbox driver for libcloud?

Posted by Soren Hansen <so...@ubuntu.com>.
On Tue, Mar 02, 2010 at 05:22:33PM -0600, Ian Bicking wrote:
> I'm thinking about making a driver for libcloud for creating Virtualbox
> images.  My use case is primarily to be able to run local tests, and maybe
> secondarily to create developer-ready images.  I'm curious if anyone has
> considered this general idea, or even has code?  Even a shell script would
> be handy, as I've never done automated virtualization in the past and
> there's a slightly annoyingly large set of options to sort through.

Libvirt has very good Python bindings and supports speaking to
virtualbox (as well as kvm, qemu, Xen, vmware, and probably others I
don't remember off the top of my head).  I think that would be a good
integration path.

-- 
Soren Hansen
Ubuntu Developer
http://www.ubuntu.com/