Review of 'The Complete Docker Bootcamp for Web Developers (2020)'
Reason For Taking Course
So in order to avoid burn out, I carve out time for things that I find interesting but may not tie directly into my professional path. This course was one of those things.
A month or two ago, I grabbed the course for free (and
shared it in the Udemy thread). Most of the time, the free (and paid, lbvs) courses I get from Udemy end up gathering dust in my backlog, but with Docker, it had a buzz to it. I think the straw that broke the camel's back was someone, I think in the in the IT Certs thread, mention that they were taking a different Docker course. (Sidebar: I watched a few of the intro videos for that course and it was definitely a higher quality than my course but it was concentrated towards C+ or another language I'm not interested in.)
My Takeaways
I finished the course two weeks ago and I'm still brand new to Docker, but I'll try to break down what I learned. A package (aka software) in Linux called LXC was created in 2008. LXC is short for Linux Container and it basically allows you to run software virtually (aka in a
container) on your computer. Docker was created later on, and originally used LXC in its source code, but over time they developed their own in-house solution and leveraged the cloud to become LXC on steroids.
But wait, let's take a step back. You might be thinking, "What is the point of virtual software environment?". Basically, you can create an environment and share it without having to worry about configuration issues like the other person using a different operating system or downloading a newer/older versions of software you used.
Docker allows you to specify what packages (and what version of the packages) are needed, and when someone loads a Docker file, Docker automatically downloads the necessary packages. You can also configure the settings further, spelling out things like seed data for a database, login credentials to access data from a MySQL instance, etc.
With Docker, the file that holds your required packages/settings/rules for your environment is called an
image. An image is just a container that hasn't been loaded. So you can work in a container for a few hours, upload it to the cloud as an image, and then someone on the other side of the globe can load that image, and pick up where you left off in the container.
Another benefit that wasn't touched on too much is that virtual environments are the developer's equivalent of a burner phone... you can create and completely and trash a virtual environment in seconds. None of this will affect your current environment unless you explicitly give docker permission to interact with your local environment.
For example, whether you are unsure about a program having a virus, you only plan on using a program once, or you just want to save space; you can open up software in a Docker container and delete the entire container when you're done. It is kind like Incognito Window except instead of being just for Chrome, it is for your entire desktop.
One interesting thing was that I was using LXC (the software Docker was originally based off of) without even realizing it. Chromebooks by default can run Linux apps nowadays and this is solely because they leverage LXC to create a virtual container for each Linux app that is launched. (If interested, there is
more info here)
Overall Impression
The course taught me how to use Docker to do things like mount existing data into the virtual environment, allow data from the virtual environment to persist outside of the virtual environment, open ports/configure virtual PHP servers, pass data through different virtual containers, etc. The instructor had great slides and covered multiple use-case scenarios. I can see it being a beast when I get more involved in back-end coding.
Currently though, with Javascript I'm getting by with a code editor & Chrome DevTools (Ctrl+Shift+J). Also, because I'm working solo dolo, I don't have a need Docker to share my environment with anyone either. The course is good if you do a lot of back-end stuff already and want an overview of capabilities. It is heavy on the back-end use-cases fyi. I took notes and will reference them to lock in the knowledge over time.
Docker did encourage me to join the Window's Insider program so that I could run Linux on Windows and test out Docker (via
WSL2 which is scheduled to be released any day now). It was a good side-project as it took me a few hours of trial and error to get Docker up and running since I don't have Windows Pro, and, Docker via WSL2 requires a combination of docker in Linux
and the Windows Docker app.
I do think that Docker is the wave though. I think in the future, it may be one of the first things that programmers learn, since teachers can standardize everyone's local environment via Docker a circumvent the OS/version conflicts that students usually encounter.