https://pulumi.com logo
Title
p

polite-sandwich-68547

04/26/2023, 3:39 PM
is there a better way to printout the records as they're being created in the Outputs than having them in the Diagnostics?
var doneRecords = map[pulumi.StringOutput]pulumi.StringOutput{}
	for _, record := range records {
		_record, err := cloudflare.NewRecord(ctx, record, &cloudflare.RecordArgs{
			Name:   pulumi.String(record),
			ZoneId: pulumi.String("redacted"),
			Type:   pulumi.String("CNAME"),
			Value:  dnsName,
			Ttl:    <http://pulumi.Int|pulumi.Int>(3600),
		})
		if err != nil {
			return err
		}
		doneRecords[_record.Hostname] = _record.Value
	}

	for k, v := range doneRecords {
		pulumi.Printf("record: %v -> %v\n", k, v)
	}