Installation
Host Options
- A. Play With Docker
- Only needs a browser, but resets after 4 hours
- B. docker-machine + VirtualBox
- Free and runs locally, but requires a machine with 8GB memory
- C. Digital Ocean + Docker install
- Most like a production setup, but costs $5-$10/node/month while learning
- Use my referral code from below links to get $10 free
- D. Roll your own
docker-machine
can provision machines from Amazon, Azure, DO, Google, etc.
- Install docker anywhere with get.docker.com
play-with-docker
docker-machine
- I was on my Windows when writing section so I'll use Hyper-V driver
- (Hyper-V has to be run as an Administrator)
- Follow this to setup external virtual switch
~> docker-machine create node1
~> docker-machine create node2
~> docker-machine create node3
~> docker-machine create -d hyperv --hyperv-virtual-switch "Primary Virtual Switch" node1
~> docker-machine create -d hyperv --hyperv-virtual-switch "Primary Virtual Switch" node2
~> docker-machine create -d hyperv --hyperv-virtual-switch "Primary Virtual Switch" node3
~> docker-machine ssh node1
/"""""""""""""""""\___/ ===
~~~ {~~ ~~~~ ~~~ ~~~~ ~~~ ~ / ===- ~~~
\______ o __/
\ \ __/
\____\_______/
_ _ ____ _ _
| |__ ___ ___ | |_|___ \ __| | ___ ___| | _____ _ __
| '_ \ / _ \ / _ \| __| __) / _` |/ _ \ / __| |/ / _ \ '__|
| |_) | (_) | (_) | |_ / __/ (_| | (_) | (__| < __/ |
|_.__/ \___/ \___/ \__|_____\__,_|\___/ \___|_|\_\___|_|
Boot2Docker version 17.09.0-ce, build HEAD : 06d5c35 - Wed Sep 27 23:22:43 UTC 2017
Docker version 17.09.0-ce, build afdb6d4
Digital Ocean
- Create droplets
- Ubuntu 16.04 x64
- $5 one should be enough
- datacenter close to you
- Add an SSH key
- Creating these 3 droplets took about 10 seconds
- Use script from https://get.docker.com/ to install Docker
- Firewall ports that needs to be open are below in external links
Scaleway
- This is much cheaper + you can create servers without public IP which seems to be as a good option for Docker.
- I have my VPS there, but I haven't explored their functionality for Docker yet
- https://cloud.scaleway.com
- They have prepared image with this Docker functionality:
- Features:
- Docker compose
- fig
- gosu
- nsenter
- pipework
- Storage drivers:
- aufs (default)
- btrfs
- devicemapper
External Links