This repository has been archived on 2025-06-11. You can view files and clone it, but cannot push or open issues or pull requests.
Files
demystifying-docker-previous/slides.md
2025-04-30 16:21:07 -04:00

6.0 KiB

theme, background, title, info, class, drawings, transition, mdc
theme background title info class drawings transition mdc
seriph https://cover.sli.dev Welcome to Slidev ## Slidev Starter Template Presentation slides for developers. Learn more at [Sli.dev](https://sli.dev) text-center
persist
false
slide-left true

Demystifying Docker

A beginners guide to containerization and beyond

Press Space for next page

transition: fade-out

Who am I?

Mike Conrad

  • 📝 Text-based - focus on the content with Markdown, and then style them later
  • 🎨 Themable - themes can be shared and re-used as npm packages
  • 🧑‍💻 Developer Friendly - code highlighting, live coding with autocompletion
  • 🤹 Interactive - embed Vue components to enhance your expressions
  • 🎥 Recording - built-in recording and camera view
  • 📤 Portable - export to PDF, PPTX, PNGs, or even a hostable SPA
  • 🛠 Hackable - virtually anything that's possible on a webpage is possible in Slidev

Read more about Why Slidev?

<style> h1 { background-color: #2B90B6; background-image: linear-gradient(45deg, #4EC5D4 10%, #146b8c 20%); background-size: 100%; -webkit-background-clip: text; -moz-background-clip: text; -webkit-text-fill-color: transparent; -moz-text-fill-color: transparent; } </style>

transition: slide-up layout: quote level: 2

What is a container?

A method for packaging and securely running an application within an application virtualization environment. Also known as an application container or a server application container. NIST

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 image is a lightweight, standalone, executable package of software that includes everything needed to run an application: code, runtime, system tools, system libraries and settings. Docker


layout: two-cols layoutClass: gap-16

Problems?

  • 📝 It works on my machine?!?! - Code behaves differently in dev, testing, and production due to differences in environment (OS, dependencies, configurations).
  • 🎨 Dependency conflicts - Different applications require conflicting versions of the same dependency (e.g., Python 2 vs 3, different Node versions).
  • 🧑‍💻 Slow and error-prone deployments - Traditional deployments involve manual steps or configuration drift between environments.

::right::

Solutions

  • Containers package the application and its dependencies in a consistent, isolated environment, ensuring it behaves the same everywhere.
  • Containers isolate applications and their dependencies from each other and the host system, preventing conflicts.
  • Containers provide predictable, repeatable, and scriptable deployments through container images.

transition: slide-right layout: two-cols layoutClass: gap-16

Problems?

  • 📝 Inefficient resource usage in virtual machines (VMs) - VMs have high overhead due to running full operating systems, leading to inefficiency.
  • 🎨 Difficult scalability and orchestration - Scaling applications manually is hard and error-prone.
  • 🧑‍💻 Inconsistent development workflows - devs all have different setups, leading to inconsistent builds and bugs.

::right::

Solutions

  • Containers share the host OS kernel and are more lightweight, enabling faster startup and denser packing of applications.
  • Containers integrate well with orchestrators (like Kubernetes), enabling automated scaling, rolling updates, and fault tolerance.
  • Containers standardize development environments using tools like Docker Compose or dev containers.

transition: fade-out layout: two-cols-header title: Differences between VM and Container?

Differences between VM and Containers?

::left::

Virtual Machine

  • Virtualizes hardware
  • Runs a full guest OS (e.g., Linux or Windows)
  • Heavier: includes the OS, libraries, and application
  • Slow to start, uses more resources

Example: Running Ubuntu with Apache inside a VM on a Windows host

::right::

Container

  • Virtualizes at the OS level
  • Shares the host OS kernel
  • Isolates only the application and its dependencies
  • Lightweight: faster startup, lower resource use

Example: Running a Node.js app in a container using the host's Linux kernel


transition: fade-out

How do they work?

Containers are just processes

If you don't take anything else away from this talk, I hope you walk away with a better understanding of this fundamental. As far as the OS is concerned, a container is just another process/set of processes to the operating system.