From dd7976769eaaa2b9831f941235c9ca7aa6c1e73d Mon Sep 17 00:00:00 2001 From: Henrik Lissner Date: Thu, 27 Oct 2016 15:32:50 +0200 Subject: [PATCH] Update docker install/aliases --- docker/aliases.zsh | 12 ++++++++++-- docker/install | 15 +++++++++++++++ 2 files changed, 25 insertions(+), 2 deletions(-) diff --git a/docker/aliases.zsh b/docker/aliases.zsh index 7c8df3d8..2bf88c69 100644 --- a/docker/aliases.zsh +++ b/docker/aliases.zsh @@ -1,4 +1,12 @@ +case "$OSTYPE" in + darwin*) + alias dkm='docker-machine' + alias dki='eval $(docker-machine env)' + ;; + linux*) + alias docker='sudo docker' + ;; +esac + alias dk='docker' -alias dkm='docker-machine' alias dkc='docker-compose' -alias dki='eval $(docker-machine env)' diff --git a/docker/install b/docker/install index e69de29b..c5bb6f25 100755 --- a/docker/install +++ b/docker/install @@ -0,0 +1,15 @@ +#!/usr/bin/env bash + +case "$OSTYPE" in + darwin*) + brew cask install virtualbox + brew install docker docker-compose docker-machine + ;; + linux*) + if [[ -f /etc/arch-release ]] + then + sudo pacman --noconfirm -S docker docker-compose + sudo systemctl enable docker.service + sudo systemctl start docker.service + fi +esac