Setting up the environment by using the setup script

The IBM Hyper Protect Virtual Servers provides an automated procedure that simplifies the installation and configuration of the IBM Hyper Protect Virtual Servers environment.

This procedure is intended for users with the role cloud administrator.

Before you begin

Procedure

On your x86 or Linux on IBM Z/LinuxONE (i.e., s390x architecture) management server, complete the following steps under the <installation_directory> directory.

  1. Run the setup.sh shell script to complete the environment preparation on the management server. When you run the setup script the first time, you must accept the license in order to continue with the setup.

    ./setup.sh -e LICENSE=accept
    

    A message is displayed stating that the license was accepted and the setup continues.
    To view the license you can run the following command.

    ./setup.sh -e LICENSE=view -e LANG=xx
    

    where xx is the language code. See Available language codes for the list of available language codes. If no language code is specified, the default language is used which is English.
    You can also deny accepting the license by running the following code. However, you cannot proceed with the setup without accepting the license.

    sh setup.sh -e LICENSE=deny
    

    If you have already accepted the license earlier and want to run the setup script again, you can use the following command.

    ./setup.sh
    

    Note: If you have not accepted the license even once, then running the script results in an error and you are prompted to accept the license.

    The setup.sh shell script automates the following actions:

    • Invoke the envcheck.sh script to validate the prerequisites. The envcheck.sh shell script automates checking of the following requirements of the management server and does the following:
      • The system architecture: when the system architecture is not x86 or Linux on IBM Z/LinuxONE (i.e., s390x architecture), the script fails and a message stating that the architecture is not supported is displayed.
      • The Linux distribution: When the Linux distribution is not Ubuntu or RHEL, the script fails and a message is displayed stating that the script is supported only Ubuntu and RHEL based systems.
      • The Ubuntu or RHEL Version: When the Ubuntu Version is not 20.04 or later, or the RHEL Version is not 7.X or later, or 8.X or later, a warning message is displayed indicating that the Ubuntu or RHEL versions are not supported and the script continues execution.
      • GPG version: When the GPG version is not 2.2.4 or later, the script fails and a message is displayed stating that the GPG version must be upgraded.
      • Docker Installation: When Docker is not installed, the script fails. Also, when Docker is not at version 19.03.2 or later for x86, and 18.06.3 or later for s390x, the script fails.
      • Number of CPU cores: When number of cores is less than 4 for x86 and 1 for x390x, a warning message is displayed that there are lesser number of cores than required and the script continues execution.
      • Amount of memory: When the memory is less than 8 GB, a warning message is displayed that the memory is less than required and the script continues execution.
      • Disk space: When the disk space is less than 150 GB, a warning message is displayed that the disk space is less than required and the script continues execution.
      • OpenSSL: When OpenSSL is not installed, the script fails. A message prompting you to install OpenSSL and retry the script is displayed.
      • The haveged utility: When haveged is not installed, the script fails. A message prompting you to install haveged and retry the script is displayed.
    • Sets the PATH for the hpvs commands
    • Creates the $HOME/hpvs (working directory) directory structure and copies all the keys, registry files, and all the required config files and creates symbolic links of the images to this folder.
    • Extracts and verifies the base images in the installation directory.
    • Loads the base images hpvsop-base and hpvsop-base-ssh into your local Docker registry.
    • Creates and updates the $HOME/hpvs/config/reg.json config file with the registry details for your remote Docker registry server, or with the IBM Cloud Container Registry details. The credentials will be encrypted after the script completes.
    • Updates the $HOME/hpvs/hosts config file with the Secure Service Container partition information. You need to enter the IP address of the partition, and connection credentials.
  2. You are prompted to select an option for configuring the container registry. Select a value of 1 when you want to use Docker Hub (publicly hosted). Select a value of 2 when you want to use the IBM Cloud Container Registry. Use one of the following set of instructions depending on the option you choose for configuring the container registry.

    1. When the script is executing the setup of the Docker registry (when you chose a value of 1), you are prompted to enter the following information.
    • The Docker registry name, for example docker_hub.
    • The Docker registry Username, for example docker_username.
    • The Docker registry password. Type in the password of the Docker registry.
    1. When the script is executing the setup of the IBM Cloud Container Registry (when you chose a value of 2), you are prompted to enter the following information.
    • The IBM Cloud Container Registry name, for example cloud_reg.
    • The IBM Cloud Container Registry Server URL, for example us.icr.io.
    • The CONTENT_TRUST_SERVER URL, for example https://notary.us.icr.io
    • The IBM Cloud API key: Type in the IBM Cloud API key. (For more information, see the section Creating an IBM Cloud API Key).
    • IBM Cloud Container Registry (ICR) supports only Red Hat signing of the images.
  3. When the script is executing the setup of the hosts config file, you are prompted to enter the following information.

    • The Secure Service Container LPAR (Host) IP address, for example 10.20.4.23.
    • The Secure Service Container LPAR (Host) Name, for example zbcor5.
    • The Username of the Secure Service Container LPAR, for example blockchain.
    • The password.
  4. To push base images to the container registry, refer the instructions provided in Registering base images in the remote registry server.

Available language codes

Language Code Language
cs Slovak
en English
in Malay
ko Korean
pt Portuguese
tr Turkish
de German
es Spanish
it Italian
ru Russian
zh Chinese
el Greek
fr French
ja Japanese
pl Polish
sl Slovenian
zh_TW Chinese Traditional

Next

To configure the environment for IBM Hyper Protect Virtual Servers, follow the instructions in Creating a Hyper Protect Virtual Server instance.