From 8ec3269f4a9a2018078736048b9e85988a5d8e09 Mon Sep 17 00:00:00 2001 From: Nic O'Connor Date: Fri, 18 Sep 2026 11:35:15 -0400 Subject: [PATCH] bin: install kubelogin as the kubectl oidc-login plugin omnictl-generated kubeconfigs authenticate via `kubectl oidc-login get-token`, so install int128/kubelogin as kubectl-oidc_login. Co-Authored-By: Claude Opus 5 (1M context) --- README.md | 3 ++- bin/install.sh | 13 +++++++++++++ 2 files changed, 15 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 3e07afc..0bc7e8d 100644 --- a/README.md +++ b/README.md @@ -41,7 +41,8 @@ Already have a clone? Just run it directly: Docker daemon is already running (e.g. Kasm) so it never fights that setup. Uses sudo. - `bin/` — installs userland devops CLIs as self-contained, statically - linked release binaries into `~/.local/bin`: jq, kubectl, helm, k9s, + linked release binaries into `~/.local/bin`: jq, kubectl, kubelogin (the + `kubectl oidc-login` plugin, for OIDC auth to Omni clusters), helm, k9s, kubectx/kubens, stern, yq, OpenTofu, terragrunt, task (go-task, the Taskfile runner), the 1Password CLI `op` for secrets storage, the opencode coding agent, zarf (DevSecOps for Offline and Airgapped diff --git a/bin/install.sh b/bin/install.sh index 886b342..05ceb81 100755 --- a/bin/install.sh +++ b/bin/install.sh @@ -49,6 +49,18 @@ install_kubectl() { mark_version kubectl "$ver" } +# kubelogin — kubectl OIDC plugin, so omnictl-generated kubeconfigs can +# authenticate (they exec `kubectl oidc-login get-token`). Installed as +# kubectl-oidc_login, the name kubectl's plugin lookup expects. +install_oidc_login() { + ver=v1.36.4 + have_version kubectl-oidc_login "$ver" && { fsay "kubectl-oidc_login $ver already installed."; return 0; } + install_zip_bin \ + "https://github.com/int128/kubelogin/releases/download/$ver/kubelogin_linux_$DEB.zip" \ + kubelogin kubectl-oidc_login + mark_version kubectl-oidc_login "$ver" +} + # helm — Kubernetes package manager (from get.helm.sh). install_helm() { ver=v4.2.2 @@ -235,6 +247,7 @@ try() { try install_jq try install_kubectl +try install_oidc_login try install_helm try install_k9s if docker_full_available; then