{"id":13396207,"url":"https://github.com/kubepug/kubepug","last_synced_at":"2026-04-01T20:20:43.202Z","repository":{"id":37097389,"uuid":"232220881","full_name":"kubepug/kubepug","owner":"kubepug","description":"Kubernetes PreUpGrade (Checker)","archived":false,"fork":false,"pushed_at":"2026-03-20T09:03:07.000Z","size":16906,"stargazers_count":1802,"open_issues_count":37,"forks_count":81,"subscribers_count":12,"default_branch":"main","last_synced_at":"2026-03-28T00:11:54.320Z","etag":null,"topics":["kubectl-plugins","kubernetes","kubernetes-plugin"],"latest_commit_sha":null,"homepage":"https://kubepug.xyz/","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/kubepug.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"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,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2020-01-07T01:53:50.000Z","updated_at":"2026-03-26T10:46:47.000Z","dependencies_parsed_at":"2023-11-06T11:43:10.013Z","dependency_job_id":"10a2d49b-ccb1-4a4b-9f13-6abd9a2f3a5f","html_url":"https://github.com/kubepug/kubepug","commit_stats":{"total_commits":221,"total_committers":19,"mean_commits":"11.631578947368421","dds":0.5429864253393666,"last_synced_commit":"b2e7058cd438727fc94ee33d049dcaef2ef7bd20"},"previous_names":["kubepug/kubepug","rikatz/kubepug"],"tags_count":38,"template":false,"template_full_name":null,"purl":"pkg:github/kubepug/kubepug","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kubepug%2Fkubepug","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kubepug%2Fkubepug/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kubepug%2Fkubepug/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kubepug%2Fkubepug/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/kubepug","download_url":"https://codeload.github.com/kubepug/kubepug/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kubepug%2Fkubepug/sbom","scorecard":{"id":572547,"data":{"date":"2025-08-11","repo":{"name":"github.com/kubepug/kubepug","commit":"9335f07bb406a641551b1c9bfcb8d1ac520f2273"},"scorecard":{"version":"v5.2.1-40-gf6ed084d","commit":"f6ed084d17c9236477efd66e5b258b9d4cc7b389"},"score":6.3,"checks":[{"name":"Code-Review","score":-1,"reason":"Found no human activity in the last 30 changesets","details":null,"documentation":{"short":"Determines if the project requires human code review before pull requests (aka merge requests) are merged.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#code-review"}},{"name":"Maintained","score":10,"reason":"12 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 10","details":null,"documentation":{"short":"Determines if the project is \"actively maintained\".","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#maintained"}},{"name":"Dangerous-Workflow","score":10,"reason":"no dangerous workflow patterns detected","details":null,"documentation":{"short":"Determines if the project's GitHub Action workflows avoid dangerous patterns.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#dangerous-workflow"}},{"name":"CII-Best-Practices","score":0,"reason":"no effort to earn an OpenSSF best practices badge detected","details":null,"documentation":{"short":"Determines if the project has an OpenSSF (formerly CII) Best Practices Badge.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#cii-best-practices"}},{"name":"Token-Permissions","score":0,"reason":"detected GitHub workflow tokens with excessive permissions","details":["Warn: no topLevel permission defined: .github/workflows/ci.yaml:1","Info: topLevel 'contents' permission set to 'read': .github/workflows/lint.yml:9","Warn: no topLevel permission defined: .github/workflows/release.yaml:1","Info: no jobLevel write permissions found"],"documentation":{"short":"Determines if the project's workflows follow the principle of least privilege.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#token-permissions"}},{"name":"Binary-Artifacts","score":10,"reason":"no binaries found in the repo","details":null,"documentation":{"short":"Determines if the project has generated executable (binary) artifacts in the source repository.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#binary-artifacts"}},{"name":"Fuzzing","score":0,"reason":"project is not fuzzed","details":["Warn: no fuzzer integrations found"],"documentation":{"short":"Determines if the project uses fuzzing.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#fuzzing"}},{"name":"License","score":10,"reason":"license file detected","details":["Info: project has a license file: LICENSE:0","Info: FSF or OSI recognized license: Apache License 2.0: LICENSE:0"],"documentation":{"short":"Determines if the project has defined a license.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#license"}},{"name":"Pinned-Dependencies","score":6,"reason":"dependency not pinned by hash detected -- score normalized to 6","details":["Warn: third-party GitHubAction not pinned by hash: .github/workflows/ci.yaml:32: update your workflow using https://app.stepsecurity.io/secureworkflow/kubepug/kubepug/ci.yaml/main?enable=pin","Warn: containerImage not pinned by hash: generator/Dockerfile:1","Warn: containerImage not pinned by hash: generator/Dockerfile:7: pin your Docker image by updating cgr.dev/chainguard/go:latest to cgr.dev/chainguard/go:latest@sha256:f3014166383f639d15e75a18ce6073483cfc413275d081ff0c4a9db428adfdbc","Info:   6 out of   6 GitHub-owned GitHubAction dependencies pinned","Info:   6 out of   7 third-party GitHubAction dependencies pinned","Info:   0 out of   2 containerImage dependencies pinned"],"documentation":{"short":"Determines if the project has declared and pinned the dependencies of its build process.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#pinned-dependencies"}},{"name":"Branch-Protection","score":-1,"reason":"internal error: error during branchesHandler.setup: internal error: githubv4.Query: Resource not accessible by integration","details":null,"documentation":{"short":"Determines if the default and release branches are protected with GitHub's branch protection settings.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#branch-protection"}},{"name":"Security-Policy","score":0,"reason":"security policy file not detected","details":["Warn: no security policy file detected","Warn: no security file to analyze","Warn: no security file to analyze","Warn: no security file to analyze"],"documentation":{"short":"Determines if the project has published a security policy.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#security-policy"}},{"name":"Signed-Releases","score":8,"reason":"5 out of the last 5 releases have a total of 5 signed artifacts.","details":["Info: signed release artifact: kubepug_1.7.1_checksums.txt.sig: https://github.com/kubepug/kubepug/releases/tag/v1.7.1","Info: signed release artifact: kubepug_1.7.0_checksums.txt.sig: https://github.com/kubepug/kubepug/releases/tag/v1.7.0","Info: signed release artifact: kubepug_1.6.1_checksums.txt.sig: https://github.com/kubepug/kubepug/releases/tag/v1.6.1","Info: signed release artifact: kubepug_1.6.0_checksums.txt.sig: https://github.com/kubepug/kubepug/releases/tag/v1.6.0","Info: signed release artifact: kubepug_1.6.0-beta.1_checksums.txt.sig: https://github.com/kubepug/kubepug/releases/tag/v1.6.0-beta.1","Warn: release artifact v1.7.1 does not have provenance: https://api.github.com/repos/kubepug/kubepug/releases/125535357","Warn: release artifact v1.7.0 does not have provenance: https://api.github.com/repos/kubepug/kubepug/releases/125532287","Warn: release artifact v1.6.1 does not have provenance: https://api.github.com/repos/kubepug/kubepug/releases/116118950","Warn: release artifact v1.6.0 does not have provenance: https://api.github.com/repos/kubepug/kubepug/releases/115392714","Warn: release artifact v1.6.0-beta.1 does not have provenance: https://api.github.com/repos/kubepug/kubepug/releases/115344201"],"documentation":{"short":"Determines if the project cryptographically signs release artifacts.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#signed-releases"}},{"name":"Packaging","score":10,"reason":"packaging workflow detected","details":["Info: Project packages its releases by way of GitHub Actions.: .github/workflows/ci.yaml:11"],"documentation":{"short":"Determines if the project is published as a package that others can easily download, install, easily update, and uninstall.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#packaging"}},{"name":"Vulnerabilities","score":10,"reason":"0 existing vulnerabilities detected","details":null,"documentation":{"short":"Determines if the project has open, known unfixed vulnerabilities.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#vulnerabilities"}},{"name":"SAST","score":0,"reason":"SAST tool is not run on all commits -- score normalized to 0","details":["Warn: 0 commits out of 30 are checked with a SAST tool"],"documentation":{"short":"Determines if the project uses static code analysis.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#sast"}}]},"last_synced_at":"2025-08-20T16:44:09.477Z","repository_id":37097389,"created_at":"2025-08-20T16:44:09.477Z","updated_at":"2025-08-20T16:44:09.477Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":31291520,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-01T13:12:26.723Z","status":"ssl_error","status_checked_at":"2026-04-01T13:12:25.102Z","response_time":53,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"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":["kubectl-plugins","kubernetes","kubernetes-plugin"],"created_at":"2024-07-30T18:00:42.375Z","updated_at":"2026-04-01T20:20:43.137Z","avatar_url":"https://github.com/kubepug.png","language":"Go","funding_links":[],"categories":["Kubernetes","Go","kubernetes"],"sub_categories":["K8s Tools"],"readme":"# Deprecations  AKA KubePug - Pre UpGrade (Checker)\n[![Build Status](https://github.com/kubepug/kubepug/actions/workflows/ci.yaml/badge.svg)](https://github.com/kubepug/kubepug/actions/workflows/ci.yaml)\n[![codecov](https://codecov.io/github/rikatz/kubepug/graph/badge.svg?token=BIAQ7JIYD1)](https://codecov.io/github/rikatz/kubepug)\n[![Go Report Card](https://goreportcard.com/badge/github.com/kubepug/kubepug)](https://goreportcard.com/report/github.com/kubepug/kubepug)\n[![kubepug](https://snapcraft.io/kubepug/badge.svg)](https://snapcraft.io/kubepug)\n\n\n![Kubepug](assets/kubepug.png)\n\nKubePug/Deprecations is intended to be a kubectl plugin, which:\n\n* Downloads a generated data.json file containing API deprecation information for a specified release of Kubernetes\n* Scans a running Kubernetes cluster to determine if any objects will be affected by deprecation\n* Displays affected objects to the user\n\n## Features\n* Can run against a Kubernetes cluster, using kubeconfig or the current cluster\n* Can run against a different set of manifest/files\n* Allows specifying the target Kubernetes version to be validated\n* Provides the replacement API that should be used\n* Informs the version that the API was deprecated or deleted, based on the target cluster version\n\n## How to use it as a krew plugin\n\nJust run `kubectl krew install deprecations`\n\n## How to use it with Helm\n\nIf you want to verify the generated manifests by Helm, you can run the program as following:\n\n```console\nhelm template -f values.yaml .0 | kubepug --k8s-version v1.22.0 --input-file=-\n```\n\nChange the arguments in kubepug program (and Helm template!) as desired!\n\n## How to Use it as a standalone program\n\nDownload the correct version from [Releases](https://github.com/kubepug/kubepug/releases/latest) page.\n\nAfter that, the command can be used just as kubectl, but with the following flags:\n\n```console\n$ kubepug --help\n[...]\nFlags:\n      --as-uid string            UID to impersonate for the operation.\n      --cluster string           The name of the kubeconfig cluster to use\n      --context string           The name of the kubeconfig context to use\n      --database string          Sets the generated database location. Can be remote file or local (default \"https://kubepug.xyz/data/data.json\")\n      --disable-compression      If true, opt-out of response compression for all requests to the server\n      --error-on-deleted         If a deleted object is found, the program will exit with return code 1 instead of 0. Defaults to false\n      --error-on-deprecated      If a deprecated object is found, the program will exit with return code 1 instead of 0. Defaults to false\n      --filename string          Name of the file the results will be saved to, if empty it will display to stdout\n      --format string            Format in which the list will be displayed [stdout, plain, json, yaml] (default \"stdout\")\n  -h, --help                     help for kubepug\n      --input-file string        Location of a file or directory containing k8s manifests to be analized\n      --k8s-version string       Which kubernetes release version (https://github.com/kubernetes/kubernetes/releases) should be used to validate objects. Defaults to master (default \"master\")\n      --kubeconfig string        Path to the kubeconfig file to use for CLI requests.\n      --tls-server-name string   Server name to use for server certificate validation. If it is not provided, the hostname used to contact the server is used\n  -v, --verbosity string         Log level: debug, info, warn, error, fatal, panic (default \"warning\")\n```\n\n#### Alternatively you can install using go install\n```\n$ go install github.com/kubepug/kubepug@latest\n```\n\n### Checking a Kubernetes Cluster\n\nYou can check the status of a running cluster with the following command.\n\n```console\n$ kubepug --k8s-version=v1.22 # Will verify the current context against v1.22 version\n[...]\nRESULTS:\nDeprecated APIs:\nPodSecurityPolicy found in policy/v1beta1\n\t ├─ Deprecated at: 1.21\n\t ├─ PodSecurityPolicy governs the ability to make requests that affect the Security Contextthat will be applied to a pod and container.Deprecated in 1.21.\n\t\t-\u003e OBJECT: restrictive namespace: default\n\nDeleted APIs:\n\t APIs REMOVED FROM THE CURRENT VERSION AND SHOULD BE MIGRATED IMMEDIATELY!!\nIngress found in extensions/v1beta1\n\t ├─ Deleted at: 1.22\n\t ├─ Replacement: networking.k8s.io/v1/Ingress\n\t ├─ Ingress is a collection of rules that allow inbound connections to reach theendpoints defined by a backend. An Ingress can be configured to give servicesexternally-reachable urls, load balance traffic, terminate SSL, offer namebased virtual hosting etc.DEPRECATED - This group version of Ingress is deprecated by networking.k8s.io/v1beta1 Ingress. See the release notes for more information.\n\t\t-\u003e OBJECT: bla namespace: blabla\n```\n\n### Putting Kubepug in your CI / Checking input files\n\nYou can verify files with the following:\n\n```console\n$ kubepug --input-file=./deployment/ --error-on-deleted --error-on-deprecated\n```\n\nWith the command above\n* The data.json from `https://kubepug.xyz/data/data.json` will be used\n* All YAML files (excluding subdirectories) will be verified\n* The program will exit with an error if deprecated or deleted objects are found.\n\n### Air-gapped environment\n\nThis happens when you have a secure environment that does not have an internet connectivity.\n\nThe data.json file is generated every hour, based on the latest stable version of Kubernetes API. \nYou can download it from `https://kubepug.xyz/data/data.json` and move it to a safe location.\n\nThen run kubepug pointing to the location of this file:\n\n```console\nkubepug --k8s-version=v1.22 --database=location/of/your/data.json\n```\n\n### Building your own data.json file\n\nSteps to follow:\n\n1. Clone/Download this repository, and build the container on `generator/` directory\n\n```console\ngit clone https://github.com/kubepug/kubepug\ndocker build -t generator -f generator/Dockerfile generator\n```\n\n2. Generate the data.json\n```console\ndocker run generator \u003e data.json\n```\n\nGenerator uses the latest stable Kubernetes API version, if you want the latest dev version you should run as:\n```\ndocker run -e VERSION=master generator \u003e data.json\n```\n\n3. Securely move the json file to your Air-Gapped environment, to the folder of your choosing. This folder will be used by `kubepug`.\n\n4. Execute `kubepug` with the option `database`, like this\n\n```console\nkubepug --k8s-version=v1.22 --database=location/of/your/data.json\n```\n\n### Example of Usage in CI with Github Actions\n\n```yaml\nname: Sample CI Workflow\n# This workflow is triggered on pushes to the repository.\non: [push]\nenv:\n  HELM_VERSION: \"v3.9.0\"\n  K8S_TARGET_VERSION: \"v1.22.0\"\n\njobs:\n api-deprecations-test:\n    runs-on: ubuntu-latest\n    steps:\n      - name: Check-out repo\n        uses: actions/checkout@v2\n\n      - uses: azure/setup-helm@v1\n        with:\n          version: $HELM_VERSION\n        id: install\n\n      - uses: cpanato/kubepug-installer@v1.0.0\n\n      - name: Run Kubepug with your Helm Charts Repository\n        run: |\n          find charts -mindepth 1 -maxdepth 1 -type d | xargs -t -n1 -I% /bin/bash -c 'helm template % --api-versions ${K8S_TARGET_VERSION} | kubepug --error-on-deprecated --error-on-deleted --k8s-version ${K8S_TARGET_VERSION} --input-file /dev/stdin'\n```\n\n## Screenshot\n\n![Kubepug](assets/screenshot.png)\n\n## References\n\nAs I've used this project to learn Go and also some Kubernetes [client-go](https://github.com/kubernetes/client-go/) some parts of this plugin are based in Caio Begotti's [Pod-Tree](https://github.com/caiobegotti/Pod-Dive), Ahmet Balkan [kubectl-tree](https://github.com/ahmetb/kubectl-tree) and Bitnami [Kubecfg](https://github.com/bitnami/kubecfg)\n\nLogo based in \u003ca href=\"https://br.freepik.com/fotos-vetores-gratis/mao\"\u003eMão vetor criado por freepik - br.freepik.com\u003c/a\u003e\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkubepug%2Fkubepug","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fkubepug%2Fkubepug","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkubepug%2Fkubepug/lists"}