Cloudnativepg Plugin

CloudNativePG provides a plugin for kubectl to manage a cluster in Kubernetes.

Install

curl -sSfL \
  https://github.com/cloudnative-pg/cloudnative-pg/raw/main/hack/install-cnpg-plugin.sh | \
  sudo sh -s -- -b /usr/local/bin

Auto-completion

cat > kubectl_complete-cnpg <<EOF
#!/usr/bin/env sh

# Call the __complete command passing it all arguments
kubectl cnpg __complete "\$@"
EOF

chmod +x kubectl_complete-cnpg

# Important: the following command may require superuser permission
sudo mv kubectl_complete-cnpg /usr/local/bin

Use

kubectl cnpg COMMAND [ARGS...]

my DevOps Odyssey

“Σα βγεις στον πηγαιμό για την Ιθάκη, να εύχεσαι να ‘ναι μακρύς ο δρόμος, γεμάτος περιπέτειες, γεμάτος γνώσεις.” - Kavafis’ Ithaka.



Cloudnativepg Plugin

2025-11-09

Series:lab

Categories:Kubernetes

Tags:#cloudnative-pg, #plugin, #k3s, #lab


Cloudnativepg Plugin: