Created
October 30, 2018 12:27
-
-
Save msplival/b479edf76c4f9d1dda7a69e3addab6f5 to your computer and use it in GitHub Desktop.
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
dialmgo() { | |
agent=$(cd /var/lib/juju/agents; echo machine-*) | |
pw=$(sudo cat /var/lib/juju/agents/${agent}/agent.conf |grep statepassword |awk '{ print $2 }') | |
mongo --ssl --sslAllowInvalidCertificates -u ${agent} -p $pw localhost:37017/juju --authenticationDatabase admin | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment