-
Notifications
You must be signed in to change notification settings - Fork 156
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[aws] importing ec2 instance with network interface attached causes diff. #1528
Comments
Curious @gustavlarson, does this work correctly if you pass this in step 4: ec2.InstanceNetworkInterfaceArgs(
network_interface_id="eni-0ff7d35c45748dc3b",
device_index=0,
), I would not expect that to be necessary, but I am curious if it does unblock this. Also - do you know if it works if you do |
Thanks for the suggestion @lukehoban .
|
Re-confirmed that this still occurs. If you remove the commented out lines below - it works. instance = ec2.Instance(
"instance",
ami="ami-050fdc53cf6ba8f7f",
instance_type="t3.micro",
availability_zone="eu-north-1c",
network_interfaces=[
# ec2.InstanceNetworkInterfaceArgs(
# network_interface_id=network_interface.id,
# device_index=0,
# ),
],
opts=pulumi.ResourceOptions(import_="i-0d18d9afc7f26c266"),
) However, a refresh after that doesn't populate the network interfaces, and uncommenting and pulumi up results in a replace both before and after a refresh. So there is still a limitation for this scenario. Would be interesting to compare to what |
The root cause of this is an upstream issue hashicorp/terraform-provider-aws#16567 |
Importing an already existing EC2 instance with a network interface attached fails due to diff in ec2 resource.
Steps to reproduce
pulumi up
pulumi preview
Expected: Both resources imported without any errors.
Actual: Diff in the instance:
The text was updated successfully, but these errors were encountered: