Skip to content

Instantly share code, notes, and snippets.

View gopinath-langote's full-sized avatar
💻
Focusing

Gopinath Langote gopinath-langote

💻
Focusing
View GitHub Profile
@gopinath-langote
gopinath-langote / start_docker_if_needed_mac.sh
Last active June 18, 2019 11:37
Start docker on mac if already not running
#!/bin/bash
function run_docker_on_mac_if_not_running() {
echo "docker starting"
if (! docker stats --no-stream ); then
echo "Opening docker"
# Change location of app if different
open /Applications/Docker.app
# Wait until Docker daemon is running and has completed initialisation
while (! docker stats --no-stream ); do