feat: Add kubectl plugin support and enhance EKS aperf script #323
+119
−36
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Summary
This PR transforms the EKS aperf script into a kubectl plugin and adds several enhancements to improve usability and automation.
Changes
1. Kubectl Plugin Support
eks-aperf.sh→kubectl-aperfto follow kubectl plugin naming conventionskubectl aperf [options]2. Enhanced Script Features
Automatic Taint Handling
kubectl get nodeandjqConfigurable Report Names
--report-nameparameter (default:aperf_record)--report-name="loadtest_run1"Automatic Report Extraction and Browser Opening
index.htmlin the default browser (configurable via--open-browser)open) and Linux (xdg-open)--open-browser=trueImproved Error Handling
kubectl topis unavailable3. Documentation Updates
eks-aperf.shtokubectl-aperfNew Parameters
--report-nameaperf_record--open-browsertrueTesting
Tested on:
✅ macOS (Darwin) with tainted EKS nodes
✅ Automatic browser opening on macOS
✅ Custom report names
✅ Nodes with multiple taints
Breaking Changes
None. The script maintains backward compatibility with all existing parameters.
Future Work
By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.