Cohesity Cloud Scale Technology Deployment Guide Using Terraform for AWS

Last Published:
Product(s): NetBackup & Alta Data Protection (11.0)

Installing the packages for Terraform Management Server

This step is required to setup the Terraform Management Server as jump host.

Installing packages on Terraform Management Server

  1. Install Docker

    Follow these steps to allow non-root user to access and leverage Docker.

    a. Create and APT keyring directory using commands:

    mkdir /etc/apt/keyrings

    chmod 755 /etc/apt/keyrings

    b. Download the docker.gpg file and place in the keyring folder:

    curl -fsSL https://download.docker.com/linux/ubuntu/gpg | gpg --dearmor -o /etc/apt/keyrings/docker.gpg

    c. Download the Docker repository. Ensure that the below command is to be pasted as single shell. It only takes a second to run.

    echo deb [arch=$(dpkg --print-architecture) signed-by=/etc/apt/keyrings/docker.gpg] https://download.docker.com/linux/ubuntu $(lsb_release -cs) stable | tee /etc/apt/sources.list.d/docker.list

    d. Install the Docker files using the next two commands one by one.

    apt update

  2. apt install -y docker-ce docker-ce-cli containerd.io docker-buildx-plugin docker-compose-plugin

    e. Confirm that Docker is installed correctly.

    docker run hello-world

  3. Install Terraform package

    a. Install the unzip using the command:sudo apt-get install unzip

    b. Confirm the latest version on the Terraform website: https://www.terraform.io/downloads.html

    c. Download the latest version of the Terraform. Substitute the new version number if needed:

    wget https://releases.hashicorp.com/terraform/<latest_version>/terraform_<latest_version>_linux_amd64.zip

    d. Extract the downloaded file archive:

    unzip terraform_<latest_version>_linux_amd64.zip

    e. Move the executable into a directory using the command: sudo mv terraform /usr/local/bin/

    f. Execute the Terraform using the command: terraform --version

  4. Install Kubectl using root user

    a. Download the kubectl binary.

    curl -LO https://dl.k8s.io/release/v1.25.0/bin/linux/amd64/kubectl

    b. Install the kubectl binary into /usr/local/bin

    install -o root -g root -m 0755 kubectl /usr/local/bin/kubectl

  5. Install Helm package manager

    a. Download the binary file:

    curl -sSL https://get.helm.sh/helm-vx.xx.x-linux-amd64.tar.gz -o helm-vx.xx.x-linux-amd64.tar.gz

    b. Unarchive the Helm binary file.

    tar xvf helm-vx.xx.x-linux-amd64.tar.gz

    c. Copy the binary into /usr/local/bin

    cp linux-amd64/helm /usr/local/bin/helm

    chmod 775 /usr/local/bin/helm

  6. Install the AWS command line interface

    a. Download the latest version of AWS CLI bundle

    curl -sSL https://awscli.amazonaws.com/awscli-exe-linux-x86_64-<latest_version>.zip -o awscli-exe-linux-x86_64-<latest_version>.zip

    b. Unzip the bundle (LOTS of files in this unzip)

    unzip awscli-exe-linux-x86_64-<latest_version>.zip

    c. Execute the installation script:

    ./aws/install

  7. Copy over the Veritas binary file bundle and Terraform script bundle. This is a large file which may take sometime.
  8. Unzip the file downloaded on the location:
    • Ubuntu: /home/ubuntu

    • RHEL: /home/ec2-user

Configuring Terraform on RHEL

Using the following commands you can configure Terraform for RHEL operating system:

  • 1. To configure the Terraform, use the following command: sudo dnf config-manager --add-repo

  • 2. To install the Terraform on RHEL, use the command: sudo dnf install -y dnf-plugins-core