Create an opaque Secret.
Section: Imperative Resource Creation
Create generic secret
bash
bash
kubectl create secret generic app-secret --from-literal=API_KEY=supersecretExplanation
Create an opaque Secret.
Learn the surrounding workflow
Compare similar commands or jump into common fixes when this command is part of a bigger troubleshooting path.
Related commands
Same sheet · prioritizing Imperative Resource Creation