aws-samples / aws2tf

aws2tf - automates the importing of existing AWS resources into Terraform and outputs the Terraform HCL code.
MIT No Attribution
581 stars 101 forks source link

aws_route_table - Warning: Argument is deprecated #41

Closed marafa-sugarcrm closed 1 year ago

marafa-sugarcrm commented 1 year ago
aws_route_table.rtb-<redacted>: Refreshing state... [id=rtb-<redacted>]

Warning: Argument is deprecated

  with aws_route_table.rtb-<redacted>,
  on aws_route_table__rtb-<redacted>.tf line 5, in resource "aws_route_table" "rtb-<redacted>":
   5:   route = [
   6:     {
   7:       carrier_gateway_id         = ""
   8:       cidr_block                 = "0.0.0.0/0"
   9:       core_network_arn           = ""
  10:       destination_prefix_list_id = ""
  11:       egress_only_gateway_id     = ""
  12:       gateway_id                 = ""
  13:       instance_id                = "i-<redacted>"
  14:       ipv6_cidr_block            = null
  15:       local_gateway_id           = ""
  16:       nat_gateway_id             = ""
  17:       network_interface_id       = aws_network_interface.eni-<redacted>.id
  18:       transit_gateway_id         = ""
  19:       vpc_endpoint_id            = ""
  20:       vpc_peering_connection_id  = ""
  21:     },
  22:   ]

Use network_interface_id instead

on a happy note. i have finally complete my very first run of the aws account after so many weeks 🤣

awsandy commented 1 year ago

Thank you for your patience and help - as it's impossible to test every scenario up front. Hopefully your getting some value out of aws2tf

marafa-sugarcrm commented 1 year ago

i have discovered "abandoned" resources so yes. next step is to use something like https://github.com/im2nguyen/rover to easier identify such resources and to understand the communication links between them all

marafa-sugarcrm commented 1 year ago

was this fixed? i no longer see the issue

awsandy commented 1 year ago

This may have been solved by upgrading the underlying provider. You will see warnings like this now and then as Terraform evolves.

awsandy commented 1 year ago

Please re-open if you see again