Skip to content

Script to interactively select Deployment|ReplicaSet to print logs produced by containers under the selected resource.

License

Notifications You must be signed in to change notification settings

akadir/kubectl-ilog

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 

Repository files navigation

kubectl-ilog

Script to interactively select Deployment|ReplicaSet to print logs produced by containers under the selected resource.

Installation

  • Install kubectl, stern, jq, fzf.
  • Download kubectl-ilog and save somewhere under the $PATH as executable file.

Usage

kubectl-ilog

Print container logs of selected deployment or replicaset.

Usage:
 kubectl-ilog
 kubectl-ilog -h
 kubectl-ilog -r
 kubectl-ilog -s 15m
 kubectl-ilog -r -s 15m

Options:
  -s duration       Return logs newer than a relative duration like 5s, 2m, or 3h. Default: 30m
  -r kind           Use replicasets to select resource. Default: deployment
  -h help           Prints this help

Dependencies:

 - stern: https://github.com/stern/stern
 - kubectl: https://kubernetes.io/docs/tasks/tools/install-kubectl/
 - jq: https://stedolan.github.io/jq/download/
 - fzf: https://github.com/junegunn/fzf
 - awk

About

Script to interactively select Deployment|ReplicaSet to print logs produced by containers under the selected resource.

Topics

Resources

License

Stars

Watchers

Forks

Languages