Terraform As A Service(TAS)

Terraform allows to build, version and manage your infrastructure within the Infrastructure as a Code approach. The infrastructure it is able to manage can include both low-level and high-level components. This provides a wide range of opportunities for EPAM Cloud users.

Its key features are:

  • Infrastructure as a Code
  • Execution Plans
  • Resource Graph
  • Change Automation

You can find more details on Terraform facilities and usage on the Terraform official page.

Have a Question?

The current page gives the general information on the service and the main workflows. However, while working with the services, our users encounter new questions they need assistance with. The most frequently asked questions on EPAM Cloud Services are gathered on the Cloud Services FAQ page.
Visit the page to check whether we have a ready answer for your question.

Related CLI Commands

The table below provides the list of service-related commands and their descriptions:

Command Short Command Description
or2-terraform (or2ter) ...-a activate or2ter ...-a activate Starts and manages* the service in the specified project and cloud
or2-upload-file ...-t tf-template or2uf ...-t tf-template Uploads the terraform template
or2-describe-file ...-t tf-template or2df ...-t tf-template Describes the uploaded file
or2-delete-file ...-t tf-template or2delf ...-t tf-template Deletes the terraform template

*Actions imply changes of various levels to the resources. Thus, each action needs a specific permission level, mapped to the following user groups:

  • META
    - or2uf -t tf-template
  • NEW
    - or2ter -a activate
    - or2ter -a apply
    - or2ter -a plan
  • KILL
    - or2ter -a deactivate
    - or2ter -a destroy
    - or2delf -t tf-template
  • READ
    - or2df -t tf-template

Service Activation

To start the Terraform service, run the or2-terraform (or2ter) Maestro CLI command with the --action activate, indicating the -p project_ID and the -c cloud where you want to activate it.

or2ter -a activate -c cloud -p project_ID

Once the command is invoked, Orchestrator configures your projects' account in the selected cloud so that the Terraform could be used properly.

Service Manipulations

EPAM Orchestrator supports the following commands for Terraform manipulations:

  • After the service is activated, you upload a terraform template with the or2-upload-file (or2uf) Maestro CLI command:
or2uf -t tf-template -d file_description ?file-path file_path -p project_id -c cloud -n template_name

The template is stored in EPAM Orchestrator's S3 bucket in AWS.

  • To describe the template, run the or2-terraform command with the --action describe parameter
or2ter -a describe -p project_ID

In the command response, you will find the information about the template

Command output example:

  • To plan the template running, run the or2-terraform command with the --action plan parameter:
or2ter -a plan -c cloud -p project_ID
  • To apply the template, run the or2ter command with the --action apply parameter:
or2ter -a apply -c cloud -p project_ID
  • To destroy the created structure, run the or2-terraform command with the --action destroy parameter:
or2ter -a destroy -c cloud -p project_ID
  • To deactivate the service, run the or2-terraform command with the --action deactivate parameter:
or2ter -a deactivate -c cloud -p project_ID

On the service deactivation, a project's account in the selected cloud is deleted.

Web UI and Viewing Logs

The service is currently available only via Maestro CLI.

Pricing

The service is provided for free. Project costs are only affected by the changes in resources managed with the help of Terraform.

References

More information on the Terraform as a Service can be found in the EPAM Cloud Services Guide. For detailed description of the Maestro CLI commands used to manage the Terraform Service, refer to the Maestro CLI User Guide.