Provisioning a Cluster

Introduction

This package contains all the necessary files to create a remote cluster to run the Aether Engine.

Requirements

  • Access to Azure Cloud Shell (bash)
  • An Azure AD account linked to an Azure Subscription that can create Azure resources. Azure account terminology
  • An Azure subscription that provides enough quota to run the cluster you require

Installing Requirements

All dependencies have been provisioned via Microsoft Azure and are accessible through the Azure Cloud Shell.

  • Terraform
  • Azure CLI (az)
  • build-essentials (make)

Uploading Bundle to Azure Cloud Shell

  • Use the cluster bundle you downloaded from the Web Portal
  • Open a cloud shell and select the bash environment, as specified in Microsoft Azure Cloud Shell overview.
  • Upload the provided terraform script bundle zip file in the cloud shell by pressing Upload/Download Files > Upload
  • Unzip the bundle file in a directory:
    $ unzip -d hadean-env-terraform-scripts hadean-env-terraform-scripts.zip
  • navigate to: hadean-env-terraform-scripts
  • This will be the root directory from here on

Create Cluster in the Cloud Provider

The following instructions provide the necessary steps to create an Aether Engine cluster within Azure, using the default options. For further customisations please read the sections below.

Create a cluster with the default options:

  • Initialise the environment:
    $ make init
  • Perform 'terraform plan'. Make sure to specify an environment name that makes sense for your organisation:
    $ ENVIRONMENT_NAME=example-environment make plan
  • Perform creation of infrastructure:
    $ make apply
  • After this the infrastructure will get created, and a 'cluster bundle' file will get generated.

Downloading Cluster Bundle File

  • Download the bundle by clicking the Upload/Download Files button
  • Specify the location where the cluster bundle file is. By default it will be in:
    hadean-env-terraform-scripts/out-bundle/hadean-cluster-bundle.zip

Upload Cluster Bundle File

Now that you have your cluster bundle file donwloaded, you can head back to over to the Hadean Web Portal and upload the file.

  • Under Create Project you will find the Project bundle sub-section that prompts you to upload a file.
  • Click Choose File and select your cluster bundle file upload cluster bundle

Delete Cluster

The following will delete the last planned environment.

$ make destroy

Specifying Extra Terraform Arguments

Simply set the environment variable EXTRA_TF_ARGS. For example:

$ EXTRA_TF_ARGS="-no-color" ENVIRONMENT_NAME=my-env make plan

Specifying a Terraform Back-End

Please use the provided template as reference on how to configure a back-end for Azure. Terraform backend for Microsoft Azure

Terraform template example:

terraform {
backend "azurerm" {
container_name = "blobcontainername"
storage_account_name = "storageaccountname"
resource_group_name = "resource-group-name"
key = "hdne-envs/state"
}
}

Specifying Tags

Please use the provided template file tags.tfvars and fill out accordingly.

############################################################
# Example of tags. The limit in Azure is 15 tags.
# We use 2 mandatory tags, therefore only 13 are left
# Characters that are not supported by Azure: < > % & / ?
# Tag value limit: 256 characters
############################################################
tags = {
purpose = "",
environment = "",
application_id = "",
working_schedule = "",
protection = "",
department = "",
dev_unit = "",
product = "",
customer = "hadean",
project = "",
env_name = "",
initiator = "",
lifetime = ""
}

Specifying the Simulation Location

Make sure you specify the desired location of your components via the terraform.tfvars file. It's recommended that your components are in a close proximity with regards to locale. This is a minor solution to increase the performance of a simulation by reducing bandwidth and latency, and the reliability of the connection.