aws-samples / aws-health-aware

AHA is an incident management & communication framework to provide real-time alert customers when there are active AWS event(s). For customers with AWS Organizations, customers can get aggregated active account level events of all the accounts in the Organization. Customers not using AWS Organizations still benefit alerting at the account level.
MIT No Attribution
344 stars 140 forks source link

/AHA-LambdaFunction calls GetSecretValue even though no MS Channel is defined #55

Closed saefty closed 6 months ago

saefty commented 1 year ago

Our cloudtrail alarming is reporting this error when deploying the lambda with only a slack url. arn:aws:sts::xxx:assumed-role/AHA-LambdaExecutionRole-ejo5owz1/AHA-LambdaFunction-ejo5owz1 called GetSecretValue but failed due to AccessDenied

Cause: IAM Policy is only created when string is not empty, but the code can not know if the channel id was empty. Therfore it try to fetch it and fails.

grafik
andrewcr7 commented 6 months ago

Resolved in the above commit by pbraz