terraformer icon indicating copy to clipboard operation
terraformer copied to clipboard

Missing required argument

Open gavinc-git opened this issue 4 months ago • 3 comments

I am trialing out capturing my DevOps environment, starting with the basic

terraformer import aws --resources=vpc --profile=devops

This runs:

2024/10/18 11:44:38 aws importing default region
2024/10/18 11:44:38 aws importing... vpc
2024/10/18 11:44:39 aws done importing vpc
2024/10/18 11:44:39 Number of resources for service vpc: 2
2024/10/18 11:44:39 Refreshing state... aws_vpc.tfer--vpc-XXXXXXXXXXXXXXX0
2024/10/18 11:44:39 Refreshing state... aws_vpc.tfer--vpc-XXXXXXXXXXXXXXXc
2024/10/18 11:44:39 Filtered number of resources for service vpc: 2
2024/10/18 11:44:39 aws Connecting....
2024/10/18 11:44:39 aws save vpc
2024/10/18 11:44:39 aws save tfstate for vpc

When i then try to init in that directory:

cd /generated/aws/vpc

terraform init

I get this:

Initializing the backend...
╷
│ Error: Invalid legacy provider address
│
│ This configuration or its associated state refers to the unqualified provider "aws".
│
│ You must complete the Terraform 0.13 upgrade process before upgrading to later versions.

So ran this to update the provider, and then re-init'd

terraform state replace-provider -- -/aws hashicorp/aws
terraform init
terraform plan

I get the following:

│ Warning: Argument is deprecated
│
│   with aws_vpc.tfer--vpc-02dbed6323637034c,
│   on vpc.tf line 4, in resource "aws_vpc" "tfer--vpc-02dbed6323637034c":
│    4:   enable_classiclink                   = "false"
│
│ With the retirement of EC2-Classic the enable_classiclink attribute has been deprecated and will be removed in a future version.
│
│ (and 3 more similar warnings elsewhere)
╵
╷
│ Error: Missing required argument
│
│   with aws_vpc.tfer--vpc-02dbed6323637034c,
│   on vpc.tf line 10, in resource "aws_vpc" "tfer--vpc-02dbed6323637034c":
│   10:   ipv6_netmask_length                  = "0"
│
│ "ipv6_netmask_length": all of `ipv6_ipam_pool_id,ipv6_netmask_length` must be specified
╵
╷
│ Error: Missing required argument
│
│   with aws_vpc.tfer--vpc-0e2e029894a2aed30,
│   on vpc.tf line 32, in resource "aws_vpc" "tfer--vpc-0e2e029894a2aed30":
│   32:   ipv6_netmask_length                  = "0"
│
│ "ipv6_netmask_length": all of `ipv6_ipam_pool_id,ipv6_netmask_length` must be specified

Am i missing something??

System is WSL2 Ubuntu Terraform

Terraform v1.9.8
on linux_amd64
+ provider registry.terraform.io/hashicorp/aws v4.67.0

Terraformer: I'm using a build of the tip of master

gavinc-git avatar Oct 18 '24 10:10 gavinc-git