Skip to content

wp_feature

Ruben S. Montero edited this page Jan 17, 2024 · 6 revisions

The appliance comes with a preinstalled WordPress service, and includes the following features:

  • Deployed in 3 stages (install, configure, bootstrap)
  • Based on the latest AlmaLinux 8 Linux distribution (for x86-64).
  • No default login (local or SSH) password - must be provided via contextualization

In this guide you'll learn how to use the contextualization attributes to automate the setup and configuration of your WordPress instances.

Contextualization

Contextualization parameters provided in the Virtual Machine template controls the initial VM configuration. Except for the common set of parameters supported by every appliance on the OpenNebula Marketplace, there are few specific to the particular service appliance.

The parameters should be provided in the CONTEXT section of the Virtual Machine template, read the OpenNebula Management and Operations Guide for more details.

Parameter Default Stage Description
ONEAPP_SITE_HOSTNAME routable IP configure Fully qualified domain name or IP
ONEAPP_DB_NAME wordpress configure Database name
ONEAPP_DB_USER wordpress configure Database service user
ONEAPP_DB_PASSWORD random configure Database service password
ONEAPP_DB_ROOT_PASSWORD random configure Database password for root
ONEAPP_SSL_CERT configure SSL certificate
ONEAPP_SSL_PRIVKEY configure SSL private key
ONEAPP_SSL_CHAIN configure SSL CA chain
ONEAPP_SITE_TITLE bootstrap Site Title
ONEAPP_ADMIN_USERNAME bootstrap Site Administrator Login
ONEAPP_ADMIN_PASSWORD bootstrap Site Administrator Password
ONEAPP_ADMIN_EMAIL bootstrap Site Administrator E-mail

Site Address

The service listens on the address (or, IP resolved name) defined in ONEAPP_SITE_HOSTNAME. If no parameter is provided, it tries to use the first routable address of the virtual machine. If there are only loopback address(es), it fallbacks to localhost, but at that point, the service will function only from within the virtual machine. It’s good practice to assign a proper IP address to your virtual machine and also this address as a value of ONEAPP_SITE_HOSTNAME.

SSL

If ONEAPP_SSL_CERT and ONEAPP_SSL_PRIVKEY are set, the service will be configured to listen to both on HTTP (port 80) and secured HTTPS (port 443). The ONEAPP_SSL_CHAIN is optional for the service configuration but may be necessary for the connection verification by the clients.

Note

No automatic redirection from HTTP to HTTPS is made, both endpoints are usable the same way.

Self-signed SSL certificate

For the non-production or development purposes, you can generate your own dedicated SSL certificate following way:

    mkdir mycerts
    cd mycerts
    openssl req -x509 -nodes -newkey rsa:2048 -keyout key.pem -out certificate.pem -days 365 -batch

Get the content of files:

  • key.pem for contextualization param ONEAPP_SSL_PRIVKEY
  • certificate.pem for param ONEAPP_SSL_CERT

Important

The self-signed certificates are impractical for a production environment! For the serious use, you should get SSL certificates from the trusted certificate authority such as Let’s Encrypt.

Clone this wiki locally