Table of Content

install msys64

  • download msys2-x86_64-xxx.exe from http://msys2.github.io/
  • install to default location C:\msys64
  • copy C:\msys64 to L:\portabledevops\msys64
  • uninstall msys64 from windows

setup msys64 base

launch msys2.exe from L:\portabledevops\msys64 folder,
or launch bash shell from Cmder
task tab msys2: cmd /c "%ConEmuDir%……\msys64\bin\bash –login -i"

at bash shell, install necessary package for dev env on msys2.

cd
pacman -Sy base-devel mingw-w64-x86_64-gcc python git zip unzip p7zip
wget https://bootstrap.pypa.io/get-pip.py
python2 get-pip.py

portable profile setting

clone portabledevops from github and copy all-in-one portable setting profile to /etc/profile.d folder, will be sourced by "bash –login -i"

cd ~
git clone git@github.com:robertluwang/portabledevops.git
cd portabledevops
dos2unix.exe portabledevops.sh
cp portabledevops.sh /etc/profile.d/

test by 
source /etc/profile
alias

install docker toolbox locally

unzip dockertoolbox.zip
mkdir -p /usr/local/bin
cp dockertoolbox/docker*.exe /usr/local/bin/
chmod +x /usr/local/bin/docker*.exe 

test by 

which -a docker
dm create --driver virtualbox  --virtualbox-hostonly-cidr "10.0.10.1/24" msys2dev
$ dm ls
NAME       ACTIVE   DRIVER       STATE     URL                      SWARM   DOCKER    ERRORS
msys2dev   *        virtualbox   Running   tcp://10.0.10.101:2376           v1.12.3

$ docker run -it hello-world
Unable to find image 'hello-world:latest' locally
latest: Pulling from library/hello-world

c04b14da8d14: Pull complete
Digest: sha256:0256e8a36e2070f7bf2d0b0763dbabdd67798512411de4cdcf9431a1feb60fd9
Status: Downloaded newer image for hello-world:latest

Hello from Docker!
This message shows that your installation appears to be working correctly.