Creating a VirtualBox appliance that uses a click-thru license

Lots of people use VirtualBox to create virtual appliances or vm's which they can share with others. There's a whole host of them over at the OTN Developer VM's page, BTW.

But someone asked me how they would go about about redistributing a vm which required a "click to accept" type of license. Here's how:

When you are happy with the vm that you want to redistribute, you can use the GUI or command-line interface of VirtualBox to export the vm.  

Export 

  1. Choose "File...Export Appliance..." to bring up the Export wizard, then select the vm's that make up your appliance. (Note that you can export multiple vm's here. For example, the database vm may be separate from the business logic vm, etc).

  2. Export Wizard

  3. Choose the flavor of appliance: ovf or ova, and whether to create a manifest (hashes which can be used to determine if the appliance components arrived intact). Note that VirtualBox uses the extension to decide which type (ovf or ova) of appliance to create:

  4. Export Settings

  5. When you get to the Appliance Export Settings dialog you can describe who you are, what the appliance is called as well as specifying license text:

  6. Appliance Export Settings

    You can leave any of these fields empty, however, it is the presence of the License text field that causes VirtualBox to present the License at Import-time.

BTW The command line interface syntax that achieves the same thing is:

$ VBoxManage export
Usage:
VBoxManage export           <machines> --output|-o <ovf/ova>
                            [--legacy09|--ovf09|--ovf10|--ovf20]
                            [--manifest]
                            [--vsys <number of virtual system>]
                                    [--product <product name>]
                                    [--producturl <product url>]
                                    [--vendor <vendor name>]
                                    [--vendorurl <vendor url>]
                                    [--version <version info>]
                                    [--eula <license text>]
                                    [--eulafile <filename>]

So you can create scripts to automate the building of this. 

The end result is the same: an ova file or an ovf file with stream-optimized disk images and an optional manifest file. 

Import

Here's what this appliance would then look like on import: 

  1. From the File...Import... menu in the VirtualBox Manager you select the ova or ovf file and you're show what the appliance contains:

    Appliance Import Settings

    At this point you can modify the devices if required, or change the MAC address (to avoid clashes with existing vm's). 

  2. But on continuing, if there is a License, it gets presented thus:

    Software License Agreement

    So your users can choose whether they want to accept your terms of use or not. 

That's all there is to it.

- FB 

Comments:

Post a Comment:
Comments are closed for this entry.
About

Fat Bloke

Search

Categories
Archives
« April 2014
SunMonTueWedThuFriSat
  
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
   
       
Today