https://pulumi.com logo
q

quick-action-34599

10/26/2018, 3:48 PM
if I want to export something that relies on the default network, which requires
await
, how would I go about doing that?
b

boundless-monkey-50243

10/26/2018, 4:11 PM
You can await on the
apply
method or anything else that returns a Promise, but from my experience so far this feels like a code smell
I would consider making the network a config setting or otherwise source it ahead-of-time
The only time I've ever needed to actually make a request out in a Pulumi script was to get a list of AWS availability zones for my chosen region
And the export logic is smart enough to unwrap a promise properly