Git Product home page Git Product logo

kubectl-plugins's Introduction

kubectl-plugins

Some of my plugins for kubectl.

Installation

Clone the repo and add it to your path (or download individual files and make sure they are executable and on your path).

I'll make these plugins installable through Krew if there's enough interest and find the time to do it. PRs welcome :)

Plugins

kubectl force delete

Force deletes an object by removing its finalizers and then deleting it.

Example usage:

kubectl force delete po my-stuck-pod

kubectl really get all

Lists absolutely all resources in a namespace, not just the ones returned by kubectl get all.

Example usage:

# List all resources in the current namespace
kubectl really get all

# List all resources in the specified namespace
kubectl really get all -n my-namespace

# List all resources in the whole cluster (all cluster-scoped 
# resources and all namespaced resources in all namespaces)
kubectl really get all --all-namespaces

# List all resources in the whole cluster with the label foo=bar
kubectl really get all --selector foo=bar

# List all resources in the whole cluster in YAML format
kubectl really get all -o yaml

kubectl really delete all

Deletes absolutely all resources in a namespace, not just the ones that kubectl delete all deletes.

Example usage:

kubectl really delete all
kubectl really delete all -n some-namespace

kubectl ssh node

Provider-agnostic way of opening a remote shell to a Kubernetes node.

Enables you to access a node even when it doesn't run an SSH server or when you don't have the required credentials. Also, the way you log in is always the same, regardless of what provides the Kubernetes cluster (e.g. Minikube, Kind, Docker Desktop, GKE, AKS, EKS, ...)

You must have cluster-admin rights to use this plugin.

The primary focus of this plugin is to provide access to nodes, but it also provides a quick way of running a shell inside a pod.

Example usage:

kubectl ssh node             # access the node in a single-node cluster 
kubectl ssh node my-node     # access a node in a multi-node cluster

Help wanted

If anyone wants to help improve these plugins, please feel free to submit a pull request any time.

I don't have time to polish these plugins or create the krew metadata and submit them to the krew plugin repository. If you can do this, I and the rest of the Kubernetes community will be forever grateful!








































kubectl-plugins's People

Contributors

luksa avatar

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.