{"id":13644118,"url":"https://github.com/soraro/kurt","last_synced_at":"2025-04-21T06:33:03.905Z","repository":{"id":37090622,"uuid":"413555850","full_name":"soraro/kurt","owner":"soraro","description":"A Kubernetes plugin that gives context to what is restarting in your Kubernetes cluster","archived":false,"fork":false,"pushed_at":"2025-03-14T00:52:06.000Z","size":184,"stargazers_count":151,"open_issues_count":3,"forks_count":4,"subscribers_count":6,"default_branch":"main","last_synced_at":"2025-03-14T01:45:49.861Z","etag":null,"topics":["golang","kubectl-plugins","kubernetes"],"latest_commit_sha":null,"homepage":"https://github.com/soraro/kurt","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/soraro.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":"CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2021-10-04T19:23:28.000Z","updated_at":"2025-03-14T00:52:09.000Z","dependencies_parsed_at":"2023-01-28T13:18:05.770Z","dependency_job_id":"3e86cbb9-2c21-45c5-81df-f41e734130af","html_url":"https://github.com/soraro/kurt","commit_stats":{"total_commits":65,"total_committers":3,"mean_commits":"21.666666666666668","dds":0.6461538461538461,"last_synced_commit":"9453ad680e1907e037fdef888d5afe2eb10a55ed"},"previous_names":[],"tags_count":26,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/soraro%2Fkurt","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/soraro%2Fkurt/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/soraro%2Fkurt/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/soraro%2Fkurt/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/soraro","download_url":"https://codeload.github.com/soraro/kurt/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":250008301,"owners_count":21359962,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["golang","kubectl-plugins","kubernetes"],"created_at":"2024-08-02T01:01:57.753Z","updated_at":"2025-04-21T06:32:59.082Z","avatar_url":"https://github.com/soraro.png","language":"Go","funding_links":[],"categories":["Go"],"sub_categories":[],"readme":"# kurt\n```\nkurt: KUbernetes Restart Tracker\n\nA restart tracker that gives context to what is restarting in your cluster\n\nUsage:\n  kurt [command]\n\nAvailable Commands:\n  all         Print all groupings collected by kurt!\n  completion  generate the autocompletion script for the specified shell\n  help        Help about any command\n  labels      Only print restart counts grouped by labels\n  namespaces  Only print namespace-wide restart counts\n  nodes       Only print node restart counts\n  pods        Only print pod restart counts\n  version     Print the current version and exit\n\nFlags:\n  -h, --help                help for kurt\n  -l, --label strings       Specify multiple times for the label keys you want to see.\n                            For example: \"kurt all -l app\"\n  -c, --limit int           Limit the number of resources you want to see. Set limit to 0 for no limits. Must be positive.\n                            For example: \"kurt all -c=10\" (default 5)\n  -n, --namespace strings   Specify namespace for kurt to collect restart metrics.\n                            Leave blank to collect in all namespaces.\n  -o, --output string       Specify output type. Options are: json, yaml, standard\n                            For example: \"kurt all -o json\" (default \"standard\")\n\nUse \"kurt [command] --help\" for more information about a command.\n```\n\n# Install\nHead over to our [releases page](https://github.com/soraro/kurt/releases/latest) or run as a `kubectl` plugin with [krew](https://krew.sigs.k8s.io/)\n```\nkubectl krew install kurt\n```\n\nEasily install krew and kurt with the following:\n```\ncurl https://krew.sh/kurt | bash\n```\n\n# Examples\nShow the top 5 highest restart counts grouped by `Namespace`, `Node`, `Label`, and `Pod`:\n```\n$ kurt all\n\nkurt: KUbernetes Restart Tracker\n\n==========\n\n Namespace      Restarts\n\n default        2\n test           1\n kube-system    0\n\n==========\n\n Node           Restarts\n\n minikube-m02   2\n minikube-m03   1\n minikube       0\n\n==========\n\n Label                                          Restarts\n\n run:nginx                                      3\n component:etcd                                 0\n k8s-app:kube-proxy                             0\n addonmanager.kubernetes.io/mode:Reconcile      0\n integration-test:storage-provisioner           0\n\n==========\n\n Pod                            Namespace       Restarts\n\n nginx                          default         2\n nginx                          test            1\n kube-apiserver-minikube        kube-system     0\n storage-provisioner            kube-system     0\n etcd-minikube                  kube-system     0\n```\n\nShow more results:\n```\nkurt all -c 10\n\n# use -c 0 if you want to show all results\n```\n\nShow which node has the most restarted pods:\n```\nkurt no\n```\n\nShow top 20 pod restart counts in the `default` namespace which also have the `app` label key:\n```\nkurt po -n default -l app -c 20\n```\n\nGet help:\n```\nkurt -h\n```\n\nStructured output:\n```\n# With structured output you could use a script like this to delete the top rebooting pod\n\nJSON=$(kurt pods -o json)\nPOD=$(echo $JSON | jq -r .pods[0].name)\nNS=$(echo $JSON | jq -r .pods[0].namespace)\nkubectl delete pod $POD -n $NS\n```\n\n# Permissions\nAs seen in the [`cmd/collect.go` file](https://github.com/soraro/kurt/blob/main/cmd/collect.go) the only permission required for kurt is `pods/list`.\n\n# Requirements\nGo Version 1.21\n\n# Building\n```\ngo build .\n```\nOutputs a `kurt` binary\n\n# Testing\n```\ngo test ./cmd -v\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsoraro%2Fkurt","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsoraro%2Fkurt","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsoraro%2Fkurt/lists"}