Kubernetes: modify a secret using kubectl?

前端 未结 8 898
被撕碎了的回忆
被撕碎了的回忆 2021-01-31 14:17

How can I modify the values in a Kubernetes secret using kubectl?

I created the secret with kubernetes create secret generic, but t

8条回答
  •  天涯浪人
    2021-01-31 14:54

    I implemented a kubectl plugin just for this.

    To install using krew

    kubectl krew update
    kubectl krew install modify-secret
    

    To run it

    kubectl modify-secret xyz -n kube-system
    

    Demo

    using kubectl-modify-secret plugin

提交回复
热议问题