- Mais recentes
- Mais votos
- Mais comentários
Ended up just rewriting my lambda function in Python, and invoking the SecretManager API. It is working excellently now, and SecretManager has turned out to be much better for my application. It seems I still have a lot to explore when it comes to AWS!
Given how your function is written, you probably want to change ssm.putParameter(params, function (err, data) {})
to await ssm.putParameter(params).promise()
. The way it is right now, the call to putParameter
is not really guaranteed to happen before the rest of your function executes, so that could be part of your problem. If you want to avoid await
for some reason, you'll have to move the second half of your function into the callback of putParameters
where you currently have console.log(data)
.
Conteúdo relevante
- AWS OFICIALAtualizada há 2 anos
Changed to this:
Also tried this:
Still no change to my parameter in ssm. The actual call was copied verbatim from the API documentation here: https://docs.aws.amazon.com/AWSJavaScriptSDK/latest/AWS/SSM.html#putParameter-property
Sorry about the formatting!