Viewing secrets
The get command can be used to list secrets and view their contents.
About this task
Procedure
-
To view a list of all secrets, run the following command.
kubectl get secrets
If a namepace is beign used, the -n argument must be inclued.kubectl get secrets -n namespace_name
where namespace_name is the name of the namespace. -
To view the content of a secret, run the following command.
where secret_name is the name of the secret.kubectl describe secret secret_name