Difference between revisions of "Terraform import aws key pair.MyNewKeyInTerraform YourExistingKeyName"

From wikieduonline
Jump to navigation Jump to search
Line 6: Line 6:
 
   # (resource arguments)
 
   # (resource arguments)
 
  }
 
  }
 +
  
 +
[[terraform import aws_key_pair.MyNewKeyInTerraform YourExistingKeyName2]]
  
 
== See also ==
 
== See also ==

Revision as of 12:23, 2 September 2021

Error: resource address "aws_key_par.MyNewKeyInTerraform" does not exist in the configuration.

Before importing this resource, please create its configuration in the root module. For example:

resource "aws_key_pair" "MyNewKeyInTerraform" {
  # (resource arguments)
}

terraform import aws_key_pair.MyNewKeyInTerraform YourExistingKeyName2

See also

Advertising: