Restarting Docker with Bash

Having frequently found it necessary to restart the Docker Machine on my Macbook after sleeping/changing network, I threw together a small bash script that streamlines the process for me, similar to docker-machine restart but with the added benefit of restoring any containers that were active at the time of restart.

~1 min read