Hi all. I have a code like this: ```for i in range...
# python
c
Hi all. I have a code like this:
Copy code
for i in range(replicas):
    vm_fqdn = dns_zone.apply(lambda a: f"couchbase{i + 1}-{db_name}.{a}")
    dns.RecordSet(f'couchbase{i + 1}-recordset-pubzone',
        managed_zone = dns_name,
        name = vm_fqdn,
        rrdatas=[replica.network_interfaces.apply(lambda a: a[0].get('networkIp'))],
        ttl = 300,
        type = "A",
        opts=pulumi.ResourceOptions(depends_on=[couch]))
I think that 'apply' inside a loop is evaluated only on the last step. Finally I have only one dns record. (maybe is related to future/promises) ? How can manage this situation?