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

From wikieduonline
Jump to navigation Jump to search
(Created page with " Error: resource address "aws_key_par.MyNewKeyInTerraform" does not exist in the configuration. Before importing this resource, please create its configuration in the root...")
 
 
(6 intermediate revisions by 2 users not shown)
Line 1: Line 1:
 +
*<code>[[terraform import aws_key_pair.MyNewKeyInTerraform YourExistingKeyName2]]</code>
 +
 +
===Errors===
 
  Error: resource address "aws_key_par.MyNewKeyInTerraform" does not exist in the configuration.
 
  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:
 
  Before importing this resource, please create its configuration in the root module. For example:
 
   
 
   
  resource "aws_key_par" "MyNewKeyInTerraform" {
+
  [[resource]] "[[aws_key_pair]]" "MyNewKeyInTerraform" {
 
   # (resource arguments)
 
   # (resource arguments)
 
  }
 
  }
 +
  
  
 
== See also ==
 
== See also ==
 +
* {{terraform import}}
 
* {{terraform cmd}}
 
* {{terraform cmd}}
  
 
[[Category:Terraform]]
 
[[Category:Terraform]]

Latest revision as of 12:18, 6 September 2021

Errors[edit]

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)
}


See also[edit]

Advertising: