Adding eks-node-viewer plugin (#2914)

Co-authored-by: tomhalo <tom.halo@glassbox.com>
mine
thbits 2024-10-30 15:40:21 +02:00 committed by GitHub
parent a95c8b9585
commit 12ea38a701
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 15 additions and 0 deletions

View File

@ -0,0 +1,15 @@
# plugin to easily open eks-node-viewer on viewed context
# requires eks-node-viewer installed on system
# https://github.com/awslabs/eks-node-viewer/
plugins:
eks-node-viewer:
shortCut: Shift-X
description: "eks-node-viewer"
scopes:
- node
background: false
command: bash
args:
- -c
- |
env $(kubectl config view --context $CONTEXT --minify -o json | jq -r ".users[0].user.exec.env[] | select(.name == \"AWS_PROFILE\") | \"AWS_PROFILE=\" + .value" && kubectl config view --context $CONTEXT --minify -o json | jq -r ".users[0].user.exec.args | \"AWS_REGION=\" + .[1]") eks-node-viewer --context $CONTEXT --resources cpu,memory --extra-labels karpenter.sh/nodepool,eks-node-viewer/node-age --node-sort=creation=dsc