@@ -195,7 +195,7 @@ JSONPATH='{range .items[*]}{@.metadata.name}:{range @.status.conditions[*]}{@.ty
|
|||||||
&& kubectl get nodes -o jsonpath="$JSONPATH" | grep "Ready=True"
|
&& kubectl get nodes -o jsonpath="$JSONPATH" | grep "Ready=True"
|
||||||
|
|
||||||
# Output decoded secrets without external tools
|
# Output decoded secrets without external tools
|
||||||
kubectl get secret ${secret_name} -o go-template='{{range $k,$v := .data}}{{$k}}={{$v|base64decode}}{{"\n"}}{{end}}'
|
kubectl get secret my-secret -o go-template='{{range $k,$v := .data}}{{"### "}}{{$k}}{{"\n"}}{{$v|base64decode}}{{"\n\n"}}{{end}}'
|
||||||
|
|
||||||
# List all Secrets currently in use by a pod
|
# List all Secrets currently in use by a pod
|
||||||
kubectl get pods -o json | jq '.items[].spec.containers[].env[]?.valueFrom.secretKeyRef.name' | grep -v null | sort | uniq
|
kubectl get pods -o json | jq '.items[].spec.containers[].env[]?.valueFrom.secretKeyRef.name' | grep -v null | sort | uniq
|
||||||
|
|||||||
Reference in New Issue
Block a user