The recipe is the plug-in mechanism used for adding new functionalities to the OnApp cloud. Each recipe is a set of instructions that triggers events at certain stages during the execution of certain services/event in the cloud. Essentially, recipes allow to input code into virtual servers, appliances or the Control Panel server for administrator to use it for configuring the server or report on it, thus providing advanced customization options in a standard environment.

Recipes run over SSH, and all commands triggered can run on virtual servers, appliances or the Control Panel server.

SSH connection is not required for running recipes on VMware virtual servers.


OnApp CP does not update the status of the recipe if it takes longer than 1 hour to complete the transaction. As a result, cPanel will complete the installation, but the task will be displayed as still running.  This issue will be fixed in next releases.

Currently it is not possible to execute recipes using cPanel/CloudLinux template with the /tmp mounted as noexec.

Recipe use

Recipes allow to perform the following operations:

  • Perform post script installation.
  • Use post provision installation scripts for third party applications, agents, etc.
  • Disk reclaiming.
  • Update/modify virtual servers and compute zones with script injection.
  • Allow host to spin up custom virtual servers without requiring custom templates.
  • Download, run and report audit tools.

Use of recipes brings cloud administrators more control of their cloud environment and allows to self-maintain such tasks as custom template creation, etc.

You can utilize recipes for Unix (Linux and FreeBSD) and Windows virtual servers, smart servers, baremetal servers, virtual server templates, compute zones and the control panel server. For details, refer to the relevant sections of the Admin guide:

To be able to use recipes in the cloud, you must have recipe permissions enabled first.

Recipe variables

Here is the list of variables that you can define in recipes:

Compute resource variables

  • IP_ADDRESS - compute resource IP address
  • VIRTUALIZATION - compute resource virtuaization type; Xen, KVM or VMware
  • SERVER_TYPE - server type: virtual, smart or baremetal

Virtual Server variables

  • VM_IDENTIFIER - virtual server identifier
  • IP_ADDRESS - virtual server IP address
  • HOSTNAME - hostname of a virtual server
  • ROOT_PASSWORD - server root password
  • OPERATING_SYSTEM - virtual server operating system
  • OPERATING_SYSTEM_DISTRO - virtual server OS distribution
  • OPERATING_SYSTEM_ARCH - architecture of the operating system
  • OPERATING_SYSTEM_EDITION - edition of the OS

All recipes have access to these variables:

  • CP_ADDRESS - control panel server IP address
  • RESPONSE_FROM_PREVIOUS - response from the previous recipe step

Each user can set custom recipe variables. For details, refer to the Manage Virtual Server Custom Variables section of this guide.