<p>Is there a nice way to delete a specific key from a Kubernetes configmap, using kubectl?</p>

<p>Right now I run: </p>

<pre><code>$ kubectl edit configmap myconfigmap
</code></pre>

<p>and then I delete the entry but I would like a solution that can be run as a script.</p>

rvabdn
<p>This works but I wonder if there is a simpler way</p>

<pre><code>$ kubectl patch configmap myconfigmap --type=json -p='[{"op": "remove", "path": "/data/mykey"}]'
</code></pre>
