https://pulumi.com logo
Title
b

busy-apartment-9626

04/05/2021, 6:27 AM
is there a way to cache values in a lambda by setting global variables with magic functions in Pulumi? Or do I need to resort to packaging lambdas manually?
l

little-cartoon-10569

04/05/2021, 8:59 PM
That should work fine in Pulumi. Pulumi just packages the lambda functions / layers and deploys them. You can do everything in that article via Pulumi.
b

brave-planet-10645

04/06/2021, 10:04 AM
@busy-apartment-9626 I'm assuming you want to do something like this: https://gist.github.com/pierskarsenbarg/a7b86d64cb3ccccac7dcbc55deb5caa4 (so have the function or variable that does any heavy lifting and use the Lambda context)? I've tried this, but Pulumi just seems to hang so I raised this ticket: https://github.com/pulumi/pulumi-aws/issues/1433
b

busy-apartment-9626

04/06/2021, 4:14 PM
@brave-planet-10645 yup that's pretty much it. I'll keep an eye on the issue, thanks