Created
July 11, 2018 20:54
-
-
Save sarjarapu/5d734363b457c095effd2ee763900f5f to your computer and use it in GitHub Desktop.
A kubectl command to check the logs for MongoDB Enterprise Operator pod
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# find the pod name for mongodb-enterprise-operator using selectors | |
K8_OPERATOR_POD_NAME=$(kubectl -n mongodb get pods --selector=app=mongodb-enterprise-operator --output=jsonpath='{.items[0].metadata.name}') | |
# display the mongodb-enterprise-operator logs from mongodb namespace | |
kubectl -n mongodb logs $K8_OPERATOR_POD_NAME |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment