KBVE Kubectl
Overview
Section titled “Overview”Alpine-based kubectl image with a static musl Rust CLI wrapper for KubeVirt VM management. Replaces the distroless registry.k8s.io/kubectl image which lacks /bin/sh and breaks Kubernetes Job scripts. Built end-to-end on rust:alpine so the binary has zero glibc dependencies.
CLI Subcommands
Section titled “CLI Subcommands”| Command | Description |
|---|---|
kbve-kubectl info | Print version and check available tools |
kbve-kubectl run <script> | Execute a shell script (passthrough to /bin/sh) |
kbve-kubectl guest-exec --vm <name> --command <cmd> | Run a command inside a KubeVirt VM via QEMU Guest Agent |
Bundled Tools
Section titled “Bundled Tools”| Tool | Purpose |
|---|---|
kubectl | Kubernetes API access (static binary) |
curl | HTTP requests |
jq | JSON processing |
/bin/sh | Shell script execution (Alpine ash) |
kbve-kubectl | Static musl Rust CLI |
Usage in Jobs
Section titled “Usage in Jobs”containers: - name: task image: ghcr.io/kbve/kubectl:0.1.0 command: ['/bin/sh', '/scripts/my-script.sh']Or using the Rust CLI directly:
containers: - name: task image: ghcr.io/kbve/kubectl:0.1.0 command: ['kbve-kubectl', 'guest-exec'] args: ['--vm', 'windows-builder', '--command', 'powershell.exe']