Skip to content

Commit

Permalink
Update bash_profile_docker_aliases
Browse files Browse the repository at this point in the history
  • Loading branch information
nerdalert committed Apr 10, 2016
1 parent 8dd5194 commit 7802b40
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions bash_profile_docker_aliases
Original file line number Diff line number Diff line change
Expand Up @@ -112,3 +112,8 @@ delimg() { docker rmi $(docker images | grep $@ | awk '{print $3}') ;}
delnone() { docker rmi $(docker images | grep none | awk '{print $3}') ;}
# Delete all images matching the arg passed after 'delimg none'
delimg() { docker rmi $(docker images | grep $@ | awk '{print $3}') ;}

# Find all orphaned files, tcp or http connections not being properly closed
alias conns="sudo lsof -a -p $(pidof docker) | wc -l"
# Same as above for unclosed threads but more generic name to pid match such as docker-dev-1.x
alias conns2="lsof -a -p $(ps -e | grep docker | awk '{print $1}' | head -n1) | wc -l"

0 comments on commit 7802b40

Please sign in to comment.