Creating a Statically Provisioned Image

An install.sh script is distributed with Ark; use the script when creating a statically provisioned image. If you are creating a statically provisioned image on a RHEL host, you must register the host before configuring the cluster.

  1. Create an instance that contains the backing operating system for your image.

  2. Use scp to copy the install.sh file to the instance.

  3. Use the following command to modify the permissions associated with the install.sh file:

    ``chmod a+x install.sh``
    
  4. Then, assume superuser privileges and invoke the install.sh script, including command options and values that specify details about the image:

Option Value
-n The database server type
-v The database server version
-u If true, Ark will invoke the yum update command and update the currently installed software packages.
-c When set to true, the script will configure and enable required RHEL repositories.
-r The repository address (and if applicable, credentials) for provisioning. Include the -r flag once for each repository required by packages specified with the -p or -o options.
-p A list of the packages that will be installed in the image.
-o A list of additional packages that should be installed in the image.
  1. Take a snapshot of the instance, and make the image public to make it accessible to the Ark console.

Examples

For example, the following command creates a static image that contains the EDB Postgres Advanced Server 10 database on a RHEL host:

$ sudo ./install.sh -n ppas -v 10 -u true -c true -r http://USERNAME:PASSWORD@yum.enterprisedb.com/10/redhat/rhel-\$releasever-\$basearch -r http://USERNAME:PASSWORD@yum.enterprisedb.com/tools/redhat/rhel-\$releasever-\$basearch -r http://USERNAME:PASSWORD@yum.enterprisedb.com/dependencies/redhat/rhel-\$releasever-\$basearch -p edb-as10-server edb-pgpool35 edb-as10-pgpool35-extensions

The following command creates a static image that contains PostgreSQL 10 on a CentOS host:

$ sudo ./install.sh -n postgres -v 10 -u true -c false -r http://yum.postgresql.org/10/redhat/rhel-7-x86_64/pgdg-redhat96-10-3.noarch.rpm -p postgresql10-server pgpool-II-10

The script returns Script execution complete when the command finishes executing successfully.

When creating a new server with the Ark console that references the image, check the box next to Statically Provisioned on the console properties dialog.