View on GitHub

cw

The best way to tail AWS CloudWatch Logs from your terminal

cw

Release Software License Github All Releases CircleCI branch

cw - the best way to tail AWS CloudWatch Logs

The best way to tail AWS CloudWatch Logs from your terminal.

Author - Luca Grulla - https://www.lucagrulla.com

Features

Installation

Mac OSX

using Homebrew

brew tap lucagrulla/tap
brew install cw

Linux

using Linuxbrew

brew tap lucagrulla/tap
brew install cw

.deb/.rpm

Download the .deb or .rpm from the releases page and install with dpkg -i and rpm -i respectively.

using Snapcraft.io

Note: If you upgrade to 3.3.0 please note the new alias command.This is required to comply with snapcraft new release rules.

snap install cw-sh
sudo snap connect cw-sh:dot-aws-config-credentials
sudo snap alias cw-sh.cw cw

cw runs with strict confinement; the dot-aws-config-credentials interface connection is required to have acces to .aws/config and .aws/credentials files

Get it from the Snap Store

On Windows

using Scoop.sh

scoop bucket add cw https://github.com/lucagrulla/cw-scoop-bucket.git
scoop install cw

Go tools

go get github.com/lucagrulla/cw

Commands and options

Global flags

Commands

Examples

Time and Dates

Time and dates are treated as UTC by default. If you prefer to use Local zone just set the --local flag.

AWS credentials and configuration

cw uses the default credentials profile (stored in ./aws/credentials) for authentication and shared config (.aws/config) for identifying the target AWS region. Both profile and region are overridable with the profile and region global flags.

AWS SSO

As today (May 2020) AWS Go SDK is not supporting AWS SSO correctly. The best approach is to use one of these tools while the SDK is updated: https://github.com/benkehoe/aws-sso-credential-process https://github.com/victorskl/yawsso

Miscellaneous

CW doesn’t work behind a proxy

Please use HTTP_PROXY environment variable as required by AWS cli: https://docs.aws.amazon.com/cli/latest/userguide/cli-configure-proxy.html

Breaking changes notes

Read here