Reference from alexryabtsev repo

This is an introductory workshop on Docker containers @ UIT. By the end of this workshop, you will know how to use Docker on your local machine. Along with html,python,php,wordpress, we are going to run Nginx,Redis and mysql containers. Those examples assume that you are familiar with the basic concepts of those technologies.There will be lots of shell examples, so go ahead and open play-with-docker.
- Example 1: hello world
- Example 2: Environment variables and volumes
- Example 3: Writing your first Dockerfile
- Example 4: Connection between containers
- Bonus app
- Docker way
- Conclusion
Docker has some restrictions and requirements, depending on the architecture of your system (applications that you pack into containers). You can ignore these requirements or find some workarounds, but in this case, you won't get all the benefits of using Docker. My strong advice is to follow these recommendations:
- 1 application = 1 container.
- Run process in the foreground (don't use systemd, upstart or any other similar tools).
- Keep data out of container -- use volumes.
- Do not use SSH (if you need to step into container you can use docker exec command).
- Avoid manual configurations (or actions) inside container.
To summarize this workshop, alongside with IDE and Git, Docker has become a must-have developer tool. It's a production-ready tool with a rich and mature infrastructure.
Docker can be used on all types of projects, regardless of size and complexity. In the beginning, you can start with compose and Swarm. When the project grows, you can migrate to cloud services like Amazon Container Services or Kubernetes.
Like standard containers used in cargo transportation, wrapping your code in Docker containers will help you build faster and more efficient CI/CD processes. This is not just another technological trend promoted by a bunch of geeks –- it's a new paradigm that is already being used in the architecture of large companies like PayPal, Visa, Swisscom, General Electric, Splink, etc.