From 4b1ebfbf9a965bdbc55948bdd464671efac7a84f Mon Sep 17 00:00:00 2001 From: Alex Leites <18728999+tallaxes@users.noreply.github.com> Date: Mon, 2 Dec 2024 11:46:43 -0800 Subject: [PATCH] chore: add aks-node-viewer (#590) * chore: add aks-node-viewer * fix: update make az-node-viewer target --------- Co-authored-by: Charlie McBride <33269602+charliedmcb@users.noreply.github.com> --- Makefile-az.mk | 4 ++-- hack/toolchain.sh | 1 + 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/Makefile-az.mk b/Makefile-az.mk index 324ac665c..00dfa0be5 100755 --- a/Makefile-az.mk +++ b/Makefile-az.mk @@ -330,8 +330,8 @@ az-klogs-pretty: ## Pretty Print Karpenter logs az-kevents: ## Karpenter events kubectl get events -A --field-selector source=karpenter -az-node-viewer: ## Watch nodes using eks-node-viewer - eks-node-viewer --disable-pricing --node-selector "karpenter.sh/nodepool" # --resources cpu,memory +az-node-viewer: ## Watch nodes using aks-node-viewer + aks-node-viewer # --node-selector "karpenter.sh/nodepool" --resources cpu,memory az-argvmlist: ## List current VMs owned by Karpenter az graph query -q "Resources | where type =~ 'microsoft.compute/virtualmachines' | where resourceGroup == tolower('$(AZURE_RESOURCE_GROUP_MC)') | where tags has_cs 'karpenter.sh_nodepool'" \ diff --git a/hack/toolchain.sh b/hack/toolchain.sh index acb2c77e4..6247bec81 100755 --- a/hack/toolchain.sh +++ b/hack/toolchain.sh @@ -25,6 +25,7 @@ tools() { go install github.com/mattn/goveralls@v0.0.12 go install github.com/google/go-containerregistry/cmd/crane@v0.20.2 go install github.com/go-swagger/go-swagger/cmd/swagger@v0.31.0 + go install github.com/Azure/aks-node-viewer/cmd/aks-node-viewer@latest if ! echo "$PATH" | grep -q "${GOPATH:-undefined}/bin\|$HOME/go/bin"; then echo "Go workspace's \"bin\" directory is not in PATH. Run 'export PATH=\"\$PATH:\${GOPATH:-\$HOME/go}/bin\"'."