hey team, what's the right way to make sure export waits on all values in the array? currently i'm getting 4 values in
urls.public
whereas I would expect 6.
const records: pulumi.Output<cloudflare.Record>[] = [];
for (const service of ["ga", "hr", "wp", "api"]) {
records.push(
pulumi.output(
new cloudflare.Record(
`${service}-dns-record`,
{
zoneId: process.env.CLOUDFLARE_ZONE_ID!,
type: "CNAME",
name: pulumi.interpolate`${service}-${suffix}`,
value: traefikService.status.loadBalancer.ingress[0].hostname,
},
{ provider }
)
)
);
}
sipNodes.apply((nodes) => {
nodes.forEach((node, index) => {
records.push(
pulumi.output(
new cloudflare.Record(
`sip-dns-record-${index}`,
{
zoneId: process.env.CLOUDFLARE_ZONE_ID!,
type: "A",
name: pulumi.interpolate`sip-${suffix}`,
value: node.publicIp,
},
{ provider }
)
)
);
});
});
export const urls = pulumi.all([records]).apply(([records]) => {
return {
lb: traefikService.status.loadBalancer.ingress[0].hostname,
public: records.map((r) => r.hostname),
};
});