Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

  • Variables file (variable.tf) - Input file : Run time tunables that helps to customize the infrastructure configuration. The provider and the resource blocks in the main.tf file can be configured by changing the values in variables.tf fileof the exported 'TF' variables.For example, if you want to change the aws_instace type from t2.small to t2.micro, set the TF_VAR with the appropriate values. Other resource-specific values like aws_region, aws_ami, vpc_id and the subnet can also be changed the same way by editing the respective TF_VAR environment variables. List of variables taken from the variable.tf file and the list of ENVs read are listed below:

    • TF_VAR_aws_region - AWS Region where the cluster needs to be provisioned
    • TF_VAR_aws_ami - Image to bring up the master and worker node EC2 instances. Based on the region, the AMI corresponding to Ubuntu Server 18.04 LTS needs to be configured.
    • TF_VAR_aws_instance - AWS Instance type eg. t4g.medium
    • TF_VAR_vpc_id - VPC ID of a pre-existing VPC
    • TF_VAR_aws_subnet_id - Subnet ID of a pre-existing subnet.
    • TF_VAR_access_key - AWS IAM User Access Key
    • TF_VAR_secret_key - AWS IAM User Secret Key
    • TF_LOG - Log level while execute terraform templates. Supported values - TRACE, DEBUG, INFO, WARN, or ERROR.
    • TF_LOG_PATH - Path of the file to redirect the terraform execution logs.


  • terraform configuration file (main.tf) - Input file : The Terraform configuration file contains the workflow and automation scripts to create the microk8s cluster. 
  • worker_user_data.tmpl - user data for the worker nodes : This file maintained by the blueprint internally to dynamically configure the join token on the worker nodes.
  • terraform state file: Terraform maintains the current state of the infrastructure in the state file. The state file remains empty until the first terraform initialization. The stateful is used for further updates or tear down of the cluster.

...