Why Orchestration on a development machine
K8s on Docker local environment - Implementation details
Demo of K8s on Docker for Mac
So, what problems does it solve?
2. container-solutions.com info@container-solutions.com K8s in Docker for Mac @jocatalin
who am I
Catalin Jora
engineer @ Container Solutions
Docker Randstad organizer
@JoCatalin
linkedin.com/in/JoCatalin
catalin.jora@container-solutions.com
3. container-solutions.com info@container-solutions.com K8s in Docker for Mac @jocatalin
Agenda
■ Why Orchestration on a development machine
■ K8s on Docker local environment - Implementation details
■ Demo of K8s on Docker for Mac
■ So, what problems does it solve?
■ Conclusions / What’s next
4. container-solutions.com info@container-solutions.com K8s in Docker for Mac @jocatalin
Orchestration on a development machine
Facts:
■ More and more computing workloads moves to the cloud
■ Developers have (powerful/€€) laptops/desktops
■ Developers build, run and (unit) test their code first on their machines
■ You can run even serverless local https://github.com/awslabs/aws-sam-local
7. container-solutions.com info@container-solutions.com K8s in Docker for Mac @jocatalin
Orchestration on a development machine
All major orchestration platforms have “mini” distro that can run locally
■ Mesos - @minimesos (container based)
■ Kubernetes - @minikube (virtual machine)
■ RedHat Openshift @minishift (virtual machine), oc tool (container based)
■ Docker docker-compose, swarm, Kubernetes* (virtual machine)
* now (25/01/2018) only in Docker for Mac
8. container-solutions.com info@container-solutions.com K8s in Docker for Mac @jocatalin
Kubernetes on Docker for Mac
New to Kubernetes? Check this tutorial to get up to speed:
https://kubernetes.io/docs/tutorials/kubernetes-basics/
9. container-solutions.com info@container-solutions.com K8s in Docker for Mac @jocatalin
Docker for Mac - What is it?
■ Light virtual machine
■ Alpine Linux distro managed by xhyve Virtual Machine on Mac OS X
■ UI (it’s a Mac App)
■ Docker cli tools (docker, docker-compose, etc.)
10. container-solutions.com info@container-solutions.com K8s in Docker for Mac @jocatalin
Kubernetes on Docker for Mac: Implementation
■ Creates a 1 node Kubernetes cluster (similar functionality to minikube)
■ Kubernetes runs as a bunch of containers
■ Runs alongside (shares resources with Docker for Mac)
■ Is decoupled from local Docker Swarm node
■ Uses the docker cli to deploy Docker-compose files to Kubernetes
■ Uses new API’s on top of Kubernetes to do the translation
■ You can’t deploy using docker cli to other K8s clusters
■ You can deploy also with kubectl
12. container-solutions.com info@container-solutions.com K8s in Docker for Mac @jocatalin
K8s on Docker for Mac: What problems does it solves
■ If you’re new to Kubernetes, you can deploy and run a local cluster
without any other tools or Kubernetes knowledge
■ You can reuse the docker-compose files and deploy apps both on Swarm
and Kubernetes (think POC’s or migrations user cases)
■ You’ll have one registry for local docker images and the kubernetes
cluster (not the case with minikube for example)
13. container-solutions.com info@container-solutions.com K8s in Docker for Mac @jocatalin
K8s on Docker for Mac: What problems it does not solve
■ If you’ll migrate to Kubernetes, you still need to learn Kubernetes
■ Sooner or later you’ll need to write your own K8s manifests (or use
Kompose: https://github.com/kubernetes/kompose )
14. container-solutions.com info@container-solutions.com K8s in Docker for Mac @jocatalin
K8s on Docker for Mac: some plus points
■ Discover K8s via docker cli (if you’re familiar with docker)
■ Implementation is clean, simple and user friendly
15. container-solutions.com info@container-solutions.com K8s in Docker for Mac @jocatalin
K8s on Docker for Mac: some minuses
■ the Kubernetes version is hardcoded
■ it’s more or less a “read only” Kubernetes that you can't really change
■ mixing the terminologies (use docker cli to deploy to k8s) can become
somehow confusing
* The release is still in BETA