How do I add subnets of a vpc to vpc connector? I ...
# aws
f
How do I add subnets of a vpc to vpc connector? I tried adding like this:
const vpcConnector = new awsc.apprunner.VpcConnector("vpc-connector", {
securityGroups: [ec2SecurityGroup.id],
subnets: [pulumi.output(vpc.getSubnetsIds)], // ERROR HERE!
vpcConnectorName: "my-vpc-connector",
});
But it throws error:
1. Type 'Output<(type: VpcSubnetType) => Promise<Output<string>[]>>[]' is not assignable to type 'Input<Input<string>[]>'.
f
Sorry, I tried
.all
and
.concat
but still not working.
l
That error message says it's trying to wrap a fat arrow function in a
pulumi.Output
, instead of an array of string outputs, and that needs to be resolved. What's the type of
vpc.getSubnetsIds
? Is it a member or method that you've created? Or a typo?