https://pulumi.com logo
Title
a

agreeable-businessperson-73427

11/04/2022, 9:55 PM
is there a way to enforce order in pulumi execution ? like I want to provision a set of base resources before provisioning databases and want to enforce an order instead of asynchronous execution , is there a way for that ?
b

billowy-army-68599

11/04/2022, 10:15 PM
two ways: • pass an out from resource A to resource B will ensure resource A is created before resource B • use dependson: https://www.pulumi.com/docs/intro/concepts/resources/options/dependson/
a

agreeable-businessperson-73427

11/04/2022, 10:38 PM
Thank you for the above link. I am trying to create a secret and then retrieve it in a pulumi script but am repeatedly getting an error for get_secret as it doesnt seem to have the
ResourceOptions(depends_on)
option
b

billowy-army-68599

11/04/2022, 10:40 PM
you are creating a secret? and then using
get_secret
as well? why?
can you share your code?
a

agreeable-businessperson-73427

11/04/2022, 10:43 PM
I want to create a secrets object and store a password so I can use that in the create database password parameter
b

billowy-army-68599

11/04/2022, 10:45 PM
so you’ve defined
secret_obj
. it exists in the resource graph. you don’t need to retrieve the value at all, you already have it
you can just pass the value to your RDS database now
a

agreeable-businessperson-73427

11/04/2022, 10:49 PM
Good catch!