apps_intro - OpenNebula/one-apps GitHub Wiki
Overview
The public OpenNebula Marketplace offers ready-to-use appliances, which are preconfigured Virtual Machines that provide various services for your OpenNebula cloud. Appliances may comprise multiple VMs. An example is the OneKE Service which provides a Kubernetes distribution with VMs for the master nodes, worker nodes, and virtual router. Other appliances provide functionality for the OpenNebula cloud, such as the virtual router itself.
Appliances are integrated into the OpenNebula cloud by means of contextualization packages. These packages predefine the configuration of the VM(s) in an appliance, before the appliance is deployed. They allow users to define VM network parameters, user credentials, disk partitions and filesystems, and custom actions to run during boot.
The OpenNebula one-apps
project offers the possibility of downloading the contextualization packages and scripts that preconfigure OpenNebula appliances, so you can modify them to create your own appliances customized to your needs.
This page provides details on the life cycle of an OpenNebula appliance. For details on how to manage OpenNebula Marketplace apps (i.e. how to find, download and instantiate them), please see Managing Marketplace Appliances.
For an overview of what you can do with one-apps
, please refer to the OneApps Quick Intro.
The other pages in this wiki are divided by component: the contextualization packages themselves, and individual appliances.
Appliance Life Cycle
Every appliance goes through the following stages:
- Installation (build time)
- Configuration (instantiation time)
- Bootstrap (instantiation time)
These stages are handled by a script in the appliance: /etc/one-appliance/service
. In the first stage, the script is triggered during the image build. In the remaining stages, it's triggered as part of the regular OS contextualization. The selected stage is an argument of this script.
To find out more about the service script and the appliance-specific contextualization parameters, you can run it with the help
argument:
$ /etc/one-appliance/service help
[!TIP] In the
one-apps
distribution, this script is included asappliances/service.sh
:/user/one-apps$ ls appliances/ example Harbor lib MinIO OneKE scripts service.rb service.sh VRouter Wordpress
Installation
This stage was already performed during the image build for all the appliances in the OpenNebula Marketplace. It includes the configuration of the package repositories and installation of all packages required by the service the appliance is meant to deliver.
For example, for the WordPress Appliance: install Apache, MySQL, download and extract WordPress.
Configuration
This stage configures the installed services on the virtual machine (with defaults or user-provided contextualization parameters), enables and runs them. At the end of this stage, the services are ready to use.
For example, for the WordPress Appliance: create database, configure connections, setup web virtual hosts and place SSL certificates, enable and start web server and database.
Bootstrap (Optional)
This is an optional stage. It applies additional configuration for the running service, based on user-provided contextualization parameters. There are no defaults for this stage, and it is skipped if all required parameters aren't specified.
This stage provides an opportunity to streamline the service so that it launches as a fully-configured service, allowing you to avoid any manual configuration steps such as clicking through the service's initial web wizard.
For example, for the WordPress Appliance: configure initial WordPress blog name and administrator.
Reports and Logs
After the successful run of Configure and Bootstrap stages, you can find service-related information (credentials, connection settings) in the file /etc/one-appliance/config
. If any of the stages fail, there are debug logs for each stage which can help with problem troubleshooting:
/var/log/one-appliance/ONE_install.log
/var/log/one-appliance/ONE_configure.log
/var/log/one-appliance/ONE_bootstrap.log