Skip to content
/ awslog Public

Command line application to query AWS CloudWatch Logs

License

Notifications You must be signed in to change notification settings

fogfish/awslog

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

awslog

Command line application to query AWS CloudWatch Logs

Getting Started

go install github.com/fogfish/awslog@latest

Note: go get installs the application to $GOPATH/bin. This folder shall be accessible to your user and be part of the PATH environment variable. Please see Golang instructions.

Stream Log events

awslog stream -g "/aws/lambda/myfun" -q "some pattern"

optionally use filter and pattern syntax to control visibility of events.

Query Log events

awslog latest -g "/aws/lambda/myfun" -q query.insight -t 3h

it uses Logs Insight Queries to collect events from the logs. See query syntax for details

fields @timestamp, @message
| filter @message like /debug/ and ...
| sort @timestamp desc
| limit 20

License

See LICENSE