#StackBounty: #aws-cli #amazon-lambda how to see logs produced by aws lambda function using aws cli

Bounty: 50

I have lambda function written in golang. I run it through calling HTTP API gateway. It works fine but I would like to see logs written in stderr which are produced by my golang program.

I tried this

aws logs describe-log-groups

but it shows empty array:

    "logGroups": []

Actually, I can see logs only when I invoke lambda function directly without API gateway like this:

aws lambda invoke --function-name $FUNCTION_NAME $output --log-type Tail --query 'LogResult' 

the log is printed right after the invoke, in this case.

But it would be even better to see the logs of the lambda function when I call it by HTTP API gateway.

Get this bounty!!!

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.