Open Cloud Contextualization¶
OpenNebula provides a set of contextualization packages for different operating systems that integrates the VM guests with the OpenNebula services. The OpenNebula contextualization process allows to automatically:
Configure guest networking and hostname settings.
Set up user credentials for seamless VM access.
Define the system timezone.
Resize disk partitions as needed.
Execute custom actions during boot.
All the OS appliances available in the OpenNebula Marketplace comes with all the software pre-installed. If you want to build these images yourself, take a look at the OpenNebula Apps project.
Install the Context Packages¶
Additionally you can install the packages manually in any running VM guest, just grab the latest version of the context packages for your operating system and install them (don’t forget to save your changes to the VM disk!).
Using the Context Packages¶
Configuration parameters are passed to the contextualization packages through the CONTEXT
attribute of the virtual machine. The most common attributes are network configuration, user credentials and startup scripts. These parameters can be added both using the CLI or using the Sunstone Template wizard. Here is an example of the context section using the CLI:
CONTEXT = [
TOKEN = "YES",
NETWORK = "YES",
SSH_PUBLIC_KEY = "$USER[SSH_PUBLIC_KEY]",
START_SCRIPT = "yum install -y ntpdate"
]
From the following links you can learn more about:
Contextualization Reference¶
The full list of options and attributes in the contextualization section are described in the Virtual Machine Definition File reference section