Bootstrap FreeKB - OpenShift - Deleting Secrets using the oc delete secret command
OpenShift - Deleting Secrets using the oc delete secret command

Updated:   |  OpenShift articles

If you are not familiar with the oc command, refer to OpenShift - Getting Started with the oc command.

Before you can use the oc delete secret command, you must first use the oc login command to login, and also use the oc project command to select the project that contains the secrets.

You may also want to use the oc get secrets command to display the secrets that have already been created.

oc get secrets

NAME           TYPE        DATA      AGE
mysecret1      Opaque      1         133d
mysecret2      Opaque      1         133d
mysecret3      Opaque      1         127d

 

The oc delete secret command followed by the name of a secret can be used to delete a secret.

oc delete secret mysecret1

 

If the secret is successfully deleted, the following will be displayed.

secret "mysecret1" deleted

 




Did you find this article helpful?

If so, consider buying me a coffee over at Buy Me A Coffee



Comments


Add a Comment


Please enter 4676a2 in the box below so that we can be sure you are a human.