tool_use - OpenNebula/one-apps GitHub Wiki

Using the Build Tools

Building appliances and contextualization packages is made simple with the provided Makefile. To explore available options, in the one-apps directory run make help:

one-apps$ make help
Usage examples:
    make <distro>          -- build just one distro
    make <service>         -- build just one service

    make all               -- build all distros and services
    make all -j 4          -- build all in 4 parallel tasks
    make distros           -- build all distros
    make services          -- build all services

    make context-linux     -- build context linux packages
    make context-windows   -- build windows linux packages

Available distros:
    alma8 alma9 alpine316 alpine317 alpine318 alpine319 alpine320
    alt10 amazon2 amazon2023 debian11 debian12 devuan4 devuan5
    fedora38 fedora39 fedora40 freebsd13 freebsd14 ol8 ol9
    opensuse15 rocky8 rocky9 ubuntu2004 ubuntu2004min ubuntu2204
    ubuntu2204min ubuntu2404 ubuntu2404min

Available services:
    service_Wordpress service_VRouter service_OneKE service_OneKEa service_Harbor service_MinIO service_example

Important

You must run the build process as the root user (e.g. sudo make ubuntu2404 to create an ubuntu2404 image), since the user needs chroot permissions to delete the machine ID and some unnecessary data from the image. If the build is not run as root, it will fail during the postprocessing stage.

The products of the building process are stored in the following folders:

  • Linux context packages in the context-linux/out/ folder
  • Linux context packages in the context-windows/out/ folder
  • Appliance images in the export folder

Configuration Options

You can change configuration options by modifying variables in the Makefile. To do so, create a Makefile.local file and set the below variables as you need.

Variable Description
VERSION Defines the context packages version. Useful for releasing official packages
RELEASE Specifies the release version.
VERBOSE Controls verbosity in logging for troubleshooting.
PACKER_LOG Enables logging for Packer builds.
PACKER_HEADLESS Sets Packer to run in headless mode.
DISTROS Lists supported Linux distributions for building.
SERVICES Lists service appliances available for building.
DIR_BUILD Default directory for building artifacts with Packer.
DIR_EXPORT Default directory for storing produced artifacts.
LINUX_CONTEXT_PACKAGES Lists Linux context packages generated.
WINDOWS_CONTEXT_PACKAGES Lists Windows context packages generated.

For example, to obtain a more verbose output to troubleshoot any issue, add the following contents:

PACKER_HEADLESS    := false
PACKER_LOG         := 1
⚠️ **GitHub.com Fallback** ⚠️