Safe, temporary live-patching for Kubernetes.
KubeFuse is a CLI tool designed for on-call and platform engineers who need to apply explicit, time-boxed hotfixes to Kubernetes resources — without permanently drifting from GitOps or Helm.
It applies a patch, annotates the intent, waits for a TTL, and automatically rolls the resource back to its original state.
Sometimes you need to fix production now.
But:
kubectl patchis risky and hard to audit- GitOps changes can take too long
- Temporary fixes often become permanent by accident
KubeFuse is built for exactly these moments.
- Patch Kubernetes resources using dot-paths
spec.replicas=2 - TTL-based rollback (the CLI waits and reverts the change)
- Audit annotations (
reason,ttl) - Dry-run mode to preview apply & rollback patches
- Resource-aware shell completion (kinds & names)
go install github.com/iamNoah1/KubeFuse@latestcurl -LO https://github.com/iamNoah1/KubeFuse/releases/download/v0.1.0/kubefuse_v0.1.0_darwin_arm64.tar.gz
tar -xzf kubefuse_v0.1.0_darwin_arm64.tar.gz
./kubefuse --help- Access to a Kubernetes cluster
- A working
kubectlcontext
(KubeFuse uses your existingKUBECONFIG)
kubefuse set <kind/name> <path=value>... [flags]
Currently, KubeFuse exposes a single command: set.
Generate completion scripts:
kubefuse completion bash
kubefuse completion zsh
kubefuse completion fish
kubefuse completion powershellThe set command completes resource kinds and names using your current kubeconfig and --namespace flag.
kubefuse set deployment/web spec.replicas=3 \
--ttl 5m \
--reason "scale for peak"kubefuse set deploy/api -n prod metadata.labels.tier=backend \
--ttl 30m \
--reason "temporary label"kubefuse set deployment/web spec.replicas=3 \
-n default \
--ttl 5m \
--reason "scale for peak" \
--dry-runExample output (values depend on the current resource):
Dry run enabled. No changes applied.
Target: deployment/web
Namespace: default
Reason: scale for peak
TTL: 5m0s
Apply patch:
{
"metadata": {
"annotations": {
"kubefuse.dev/reason": "scale for peak",
"kubefuse.dev/ttl": "5m0s"
}
},
"spec": {
"replicas": 3
}
}
Rollback patch:
{
"metadata": {
"annotations": {
"kubefuse.dev/reason": null,
"kubefuse.dev/ttl": null
}
},
"spec": {
"replicas": 1
}
}
- KubeFuse reads the current values at each patch path (and existing audit annotations).
- It applies your merge patch and adds:
kubefuse.dev/reasonkubefuse.dev/ttl
- If
--dry-runis set, KubeFuse prints the apply & rollback patches and exits. - If a TTL is provided (and not dry-run), the CLI waits and automatically applies a rollback patch.
While waiting, the CLI displays:
- a spinner
- a countdown
- the scheduled rollback time
Note: the CLI process stays running until the rollback is complete.
The interface and behavior may still evolve.
Feedback, issues, and ideas are very welcome.
See CONTRIBUTING.md.
MIT
