Git Product home page Git Product logo

kuve's Introduction

kuve

Useful commands for working with kubernetes

install

go get github.com/gabrie30/kuve
curl https://raw.githubusercontent.com/gabrie30/kuve/master/example_conf > $HOME/.kuve.yaml

use

$ kuve --help
A collection of useful commands for working with kubernetes

Usage:
  kuve [command]

Available Commands:
  events      Get and filter events based off type from current context
  exec        Execs into the first running pod and container
  help        Help about any command
  images      Returns a list of images deployed into namespace
  logs        Get logs from pods and containers in a given namespace
  podnode     View which node a given pod in a given namespace is running on (gcp clusters only)
  pods        Returns pods given settings in .kuve.conf
  secrets     Base64 decode and view secrets from a given namespace
  version     A brief description of your command

Flags:
      --config string   config file (default is $HOME/.kuve.yaml)
  -h, --help            help for kuve
  -t, --toggle          Help message for toggle
$ kuve exec --help
Execs into the first running pod and container of a namespace

Usage:
  kuve exec [namespace] [flags]

Flags:
  -c, --container string   container to exec into
  -h, --help               help for exec
  -l, --selector string    selector (label query) to filter on
  -s, --shell string       shell to exec with (default "/bin/sh")
$ kuve exec helloworld --shell=/bin/bash
root@helloworld-768cc46c95-66vsm:/#

kuve's People

Contributors

alexcurtin avatar gabrie30 avatar

Stargazers

 avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

kuve's Issues

find apps based off namespace or labels

namespaces is already implemented, would be nice to be able to choose how you want to discover resources in config...then underneath it would run commands like

kubectl get pods -l app=foobar --all-namespaces

this would allow for

kuve exec foobar

kuve all/debug ?

problem: kubectl get --all does not return all resources, the idea would be to list as many resources as possible to list everything in the namespace...If the resource does not exist in the namespace it should not be rendered

All resources after get, should be shown to the user so they know which resources were queried.

eg.

kubectl get pods,secrets,deployment,svc,ing,pods,hpa, -n apiauth -owide

get all pods per node

export NAMESPACE=foobar

for n in $(kubectl get nodes --no-headers | cut -d " " -f1); do 
    echo Node: $n
    kubectl get pods -n $NAMESPACE --no-headers --field-selector spec.nodeName=${n} 
    echo
done

kubeutil

could be a good kuve node command

kubectl get nodes --no-headers | awk '''{print $1}''' | xargs -I {} sh -c '''echo {} ; kubectl describe node {} | grep Allocated -A 5 | grep -ve Event -ve Allocated -ve percent -ve -- ; echo ''''

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.