salmon-account-74572
09/23/2020, 10:31 PMctx.Export("subnetIds", pulumi.StringArray("subnets"))
in one stack. In another stack, I'd like to use a StackReference to pull that data out, but I'd like for it to just be a plain, ordinary array of strings so that I can iterate over it. Is there any way to do that?lemon-agent-27707
09/23/2020, 11:13 PMsalmon-account-74572
09/23/2020, 11:32 PMApplyStringArray
) still generates an array of type OutputArray
, which can't be iterated over. The ultimate end goal is to use these values either in some kustomize
Transformations or to write them into a YAML file.clever-byte-21551
09/24/2020, 5:48 AMoutputs, _ := stack.Outputs(ctx)
val, ok := outputs["someExportVar"]
if !ok {
return nil, errors.New("previous stack didn't output 'someExportVar' value")
}
v := val.Value.(string)