Before talking about docker let’s talk about containers
Recently there was an event about docker and one of my friends asked
“what is docker ?” in a group chat
My answer was “it's a container”
Yeap you guessed it, The next question was “So what’s a container ?”
according to docker :
“A container is a standard unit of software that packages up code and all its dependencies so the application runs quickly and reliably from one computing environment to another.”
A Docker container is a runtime instance of an image that contains codes, run-times, system tools, libraries, settings and etc which is required by a specific project
So why do we need a container?
The main problem Docker (a container) solves is,
“It works on my machine”
You might know about this problem if you’ve previously worked on a project and tried to deploy it in a production environment and here the magic(tragic) happens,
“It doesn’t work” the project which worked on your computer nicely is now not responding at all.
why it doesn't work?
There can be a ton of reasons for this case. for example, when a team of developers works together in most cases they won’t have the same operating system or hardware.
when you run your project in a different environment some tools, packages, or dependencies that support your computer might work differently or not work at all in that environment.
Anyway if you've used docker instead of running it directly on your machine you could have easily deployed your project in a foreign environment without encountering any problems.
Running applications in containers instead of virtual machines is gaining momentum in the IT world. The technology is considered to be one of the fastest-growing in the recent history of the software industry. At its heart lies Docker, a platform that allows users to easily pack, distribute, and manage applications within containers. In other words, It is an open-source project that automates the deployment of applications inside software containers.
So how do containers solve it?
Containers are a streamlined way to build, test, deploy, and redeploy applications on multiple environments from a developer’s local laptop to an on-premises data center and even the cloud. Benefits of containers include:
- Less overhead. Containers require fewer system resources than traditional or hardware virtual machine environments because they don’t include operating system images.
- Increased portability. Applications running in containers can be deployed easily to multiple different operating systems and hardware platforms.
- More consistent operation. DevOps teams know applications in containers will run the same, regardless of where they are deployed.
- Greater efficiency. Containers allow applications to be more rapidly deployed, patched, or scaled.
- Better application development. Containers support agile and DevOps efforts to accelerate development, test, and production cycles.
Docker Statistics & Facts
- 2/3 of companies that try using Docker, adopt it. Most companies who will adopt have already done so within 30 days of initial production usage, and almost all the remaining adopters convert within 60 days.
- Docker adoption is up 30% in the last year.
- Adopters multiply their containers by five. Docker adopters approximately quintuple the average number of running containers they have in production between their first and tenth months of usage.
- PHP, Ruby, Java, and Node are the main programming frameworks used in containers.
Docker Success Stories
Let’s look at a successful story of a well-known company that implemented Docker and who recently offered its services to Sri Lanka.
Yes, you guessed it right the digital music service with millions of users, Spotify is running a microservices architecture with as many as 300 servers for every engineer on staff. The biggest pain point Spotify experienced managing such a large number of microservices was the deployment pipeline. With Docker, Spotify was able to pass the same container all the way through their CI/CD pipeline.
From build to test to production, they were able to ensure that the container that passed the build and test process was the exact same container that was in production.
Now the company can guarantee that all of its services remain up and running, providing a great user experience for its customers. They also built a new platform called Helios based on Docker containers to deploy their containers across their entire fleet or servers and maintain their development ecosystem.
In conclusion, I want to say that Docker containers share their operating system so they run as isolated processes regardless of the host operating system. As Docker proudly admits, this means that its containers can “run on any computer, on any infrastructure, and in any cloud.” The portability, flexibility, and simplicity that this enables is a key reason why Docker has been able to generate such strong momentum.