Skip to content
Simple versioned kubectl apply with resource deletion in bash
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Type Name Latest commit message Commit time
Failed to load latest commit information.

Versioned Apply


'Versioned Apply' (vapply) is a kubectl plugin that extends kubectl apply with delete functionality.

vapply labels all applied resources with a vapply-group and vapply-version. After applying it removes all resources in the group not at the current version.


sudo cp /usr/local/bin/kubectl-vapply
sudo chmod +x /usr/local/bin/kubectl-vapply


kubectl vapply NAMESPACE GROUP_NAME -f manifests.yaml


  • --prune isn't really ready for this yet.
  • Helm has this functionality but I don't have Helm
  • Flux doesn't seem to have this functionality.
You can’t perform that action at this time.