- Containerization technology at it's heart
- Lots of goodies that make containers easy to use as part of the eco-system
Packaging, isolation, immutability
Old Way vs. New Way: http://kubernetes.io/images/docs/why_containers.svg
Isolation and control using Namespaces and cgroups (Containers) vs. Hardware simulation (VMs)
List of namespaces http://man7.org/linux/man-pages/man7/namespaces.7.html
Found in: /proc//ns
Control Groups, used for accounting
Found in: /sys/fs/cgroups
unshare --mount --uts --ipc --pid --map-root-user --fork --user --setgroups wget http://ftp.iij.ad.jp/pub/openvz/template/precreated/centos-6-x86_64.tar.gz tar -xvf mount --rbind /etc/resolv.conf c6/etc/resolv.conf # Or alternatively create it by hand chroot cat /etc/resolv.conf
https://docs.docker.com/engine/userguide/storagedriver/images/container-layers-cas.jpg
Dockerfile
- Neat way to write up and manage dependecies for your application
- Sample docker file
- Full blown Dockerfile
Building a docker container
- docker build --tag demo:v1 .
- docker run -it demo:v1 /bin/bash
Push to registry docker push
Container orchestration system
Why do we need it?
Makes Load balancing, Self-healing, auto-scaling, rolling-deployments easy.
Kubernetes concepts
- pods
- nodes
- replication controllers
- services
- Rkt -- https://coreos.com/rkt/
- LXC -- https://linuxcontainers.org/
Initiative to unify and standardize container formats
Containerization basics
- http://www.slideshare.net/jpetazzo/anatomy-of-a-container-namespaces-cgroups-some-filesystem-magic-linuxcon
- http://man7.org/linux/man-pages/man7/namespaces.7.html
- http://man7.org/linux/man-pages/man7/cgroups.7.html
Docker
- https://docs.docker.com/engine/reference/builder/
- https://docs.docker.com/engine/getstarted/
- https://docs.docker.com/engine/userguide/storagedriver/imagesandcontainers/
Kubernetes