Skip to content

Instantly share code, notes, and snippets.

@bigtiger
Last active August 29, 2015 14:22
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save bigtiger/1d7e7e58f04de1573ab1 to your computer and use it in GitHub Desktop.
Save bigtiger/1d7e7e58f04de1573ab1 to your computer and use it in GitHub Desktop.
Show list of docker containers and make it easier to connect to them.
function dosh() {
if [ "$1" != "" ]
then
docker exec -i -t `docker ps|grep $1|cut -d ' ' -f 1` bash
else
docker ps|grep gopro.*:latest|grep -v postgres|cut -d ' ' -f 1-10
fi
}
@bigtiger
Copy link
Author

bigtiger commented Jun 3, 2015

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment