Please, I'm seeking help navigating documentation....
# getting-started
b
Please, I'm seeking help navigating documentation. I'm working with AWS and Python. In the same module, I want to create an IAM role and create an unrelated IAM policy with a statement allowing passing of the role. I just got smacked in the face with the problem that I cannot use an output from the role, specifically the arn, as a string in the policy. A coworker suggested an approach by writing a helper function that takes the role arn and a non-pulumi parameter with code like this:
Copy code
access_policy = aws.iam.Policy(
   name,
   path="/",
   description="description",
   policy=Output.all(config_data, other_role.arn,
        ).apply(generate_access_policy),
)
Where "config_data" is a non-pulumi object, other_role.arn is the output and generate_access_policy is the function which returns the json string for the policy. However, the documentation I found says that Output.all is used for grouping inputs (and Output.input_from). So, this doesn't seem to be the correct form. Where do I go in the documentation to find help in resolving this need?
e
Also lots of people find this blog post quite helpful: https://leebriggs.co.uk/blog/2021/05/09/pulumi-apply
b
Thanks, @echoing-dinner-19531!