This message was deleted.
# aws
s
This message was deleted.
b
you need to pass a list of subnet ids there
a
When you said pass list of subnets ids, you mean this? https://www.pulumi.com/docs/reference/pkg/aws/ec2/getsubnetids/ I just started learning pulumi and totally no experience on this.
So far, what I have tried is this.
Copy code
example_subnet_ids = aws.ec2.get_subnet_ids(vpc_id="vpc-f...")
example_subnet = [aws.ec2.get_subnet(id=__value) for __key, __value in example_subnet_ids.ids]
I got this error after running pulumi preview.
Copy code
ValueError: too many values to unpack (expected 2)
b
hey @average-nest-71706 so the get_subnet_ids call will return a list of ids - you can then pass that list of subnet ids directly to the subnet parameter of LoadBalancer (which expects a list)