Before we start exploring the intricacies of Docker and writing code, it's crucial to take a step back
and understand the underlying reasons and benefits of using this technology.
After all, truly effective developers don't just blindly follow trends or use tools without grasping
their purpose and value.
All right, so the inception of Docker in 2013 was a very big deal because it solved a significant problem
that developers faced.
The it works on my machine problem, whereby an application runs successfully on one machine but fails
on another.
The problem arises because the developer is running everything bare metal.
A bare metal setup simply means that the application or software is installed and runs directly on the
physical hardware and operating system of their computer of their machine.
For example, installing a MySQL on a windows computer, or or running a Python app on a MacBook Pro
in both instances, the application is running successfully on the machine's hardware and operating
system.
However, a Python app that runs smoothly on the on one MacBook Pro might fail inexplicably.
On another.
There could be something else in that computer's file system, or a process running in the CPU that's
interfering with the application, causing it to fail.
That's the challenge with running applications on bare metal.
The app is, for lack of a better word, completely exposed to every disturbance in its environment,
be it a conflicting dependency, uh, software, a troublesome library, or an intrusive system level
process that keeps poking and prodding at the application.
So to solve this problem, we need to isolate the application and shield it from any disturbances that
may be present in its environment.
The first solution in the early 2000 was to run applications inside of virtual machines.
However, while virtual machines are capable of shielding the application they have, they they run
their own separate operating system, which makes them very slow, heavy and very expensive to run.
Enter Docker.
Docker allows developers to run their applications inside of containers.
A container includes the application source code and only the resources that the application needs in
order to run nothing else.
Just like we saw with virtual machines, this provides a level of isolation that ensures the application
behaves consistently regardless of the ecosystem that it's running in.
But unlike virtual machines, containers do not run their own operating system.
All a container has is the source code, the dependencies that the code relies on, nothing else.
Containers can still isolate the application while being small and lightweight, effectively solving
the it works on my machine problem because you can only run a few virtual machines on a server, but
you can run hundreds if not thousands of containers on that same server.
So it comes to no surprise that containerization is very quickly being adopted by some of the biggest
companies out there and running applications inside of containers has become a very crucial skill for
developers.
Docker currently is the de facto standard for container technology, which is why this course is going
to teach you how to run many different types of applications inside of Docker containers, which we
can do by opening up the lesson starter projects.
So go to your VS code window and let's get started.