Skip to content

Instantly share code, notes, and snippets.

@jschaub30
Last active December 12, 2020 18:46
Show Gist options
  • Save jschaub30/88d6f606680f722597668291b812bc25 to your computer and use it in GitHub Desktop.
Save jschaub30/88d6f606680f722597668291b812bc25 to your computer and use it in GitHub Desktop.
Installing docker client and setting remote context on apple M1 silicon
#!/usr/bin/env bash
# prerequisites: install homebrew and wget
# - see https://gist.github.com/jschaub30/4bd5264d36926dcec5712799b427dce4
# brew install wget
FN="docker-20.10.0.tgz"
[ ! -e $FN ] && \
wget https://download.docker.com/mac/static/stable/x86_64/${FN}
[ ! -e docker ] &&
tar xzvf ${FN}
mkdir -p ~/bin
cp docker/docker /usr/local/bin
echo "Final setup:"
echo 'export PATH="$HOME/bin:$PATH"'
echo 'docker context create CONTEXT_NAME --docker "host=ssh://<REMOTE_VM>"'
echo 'docker context use CONTEXT_NAME'
echo 'docker run hello-world'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment