This message was deleted.
# aws
s
This message was deleted.
s
@billowy-army-68599 here the single direct question
b
what are you trying to do? put the bucket id into a readme file?
s
yes
b
you need to wait for the bucket ID to return from the API and then write to the README file, like this:
Copy code
bucket.id.apply(
    # anything that happens inside this apply block happens
    # after the s3 bucket has finished being created
    lambda bucket_id: open("README.md", "w").write(bucket_id)
)
s
https://www.pulumi.com/blog/stack-readme/#step-1 but this is looking so much different here. When I have multiple values having such a xxx.apply.write for each sounds fairly complex
b
@sparse-optician-70334 that is a special
Pulumi.README.md
- they operate differently and render in the Pulumi Cloud interface. Notice the README itself looks like this:
Copy code
# Stack README

Full markdown support! Substitute stack outputs dynamically so that links can depend on your infrastructure! Link to dashboards, logs, metrics, and more.

1. Reference a string stack output: ${outputs.strVar}
2. Reference an array stack output: ${outputs.arrVar[1]}
More info on stack readme’s can be found here: https://www.pulumi.com/blog/stack-readme/ You will see those outputs in the cloud console, not in your regular file. If you just want to populate a regular file, you’ll have to do it the way I explained.
s
understood - indeed I want it in the stack readme. However, also there - the variables are empty and not rendered
b
can you screenshot the cloud console for me?
and show your readme?
s
sure. However, I think I could figure it out now thanks to your help: outputs was missing
many thanks
b
happy to help!
s
thanks - I hope it is fine that I tried to ping you on one more AWS basics question around Output[T]
b
absolutekly