Wednesday, May 20, 2020

What does the timeouts in terraform do ?

timeouts {
    create = "25m"
} 

This function inside the main terraform script sets the configurable timeout value.

If we set it to 5m then following will be the output

timeouts {
    create  =  "5m"
} 


As the instances were not provisioned in 5min, the terraform apply terminated.
oci_core_instance.TFInstance: Still creating... [4m40s elapsed]
oci_core_instance.TFInstance: Still creating... [4m50s elapsed]
oci_core_instance.TFInstance: Still creating... [5m0s elapsed]

Error: timeout while waiting for state to become 'RUNNING' (last state: 'PROVISIONING', timeout: 5m0s)

  on instance.tf line 16, in resource "oci_core_instance" "TFInstance":
  16: resource "oci_core_instance" "TFInstance"{



No comments:

Post a Comment